views:

158

answers:

4

Are there any protocols/standards that work over TCP that are optimized for high throughput and low latency?

The only one I can think of is FAST.

At the moment I have devised just a simple text-based protocol delimited by special characters. I'd like to adopt a protocol which is designed for fast transfer and supports perhaps compression and minification of the data that travels over the TCP socket.

+1  A: 

If layered on top of TCP, you won't get better throughput or latency than the 'barest' TCP connection.

there are other non-TCP high-throughput and/or low-latency connection-oriented protocols, usually layered on top of UDP.

almost the only one i know is UDT, which is optimized for networks where the high bandwidth or long round trip times (RTT) makes typical TCP retransmissions suboptimal. These are called 'extremely long fat networks' (LFN, pronounced 'elefan').

Javier
+3  A: 
mav
+1  A: 

You may want to consider JMS. JMS can run on top of TCP, and you can get reasonable latency with a message broker like ActiveMQ.

It really depends on your target audience though. If your building a game which must run anywhere, you pretty much need to use HTTP or HTTP/Streaming. If you are pushing around market data on a LAN, than something NOT using TCP would probably suite you better. Tibco RV and JGroups both provide reliable low-latency messaging over multicast.

brianegge
A: 

Just as you mentioned FAST - it is intended for market data distribution and is used by leading stock exchanges and is running on the top of UDP multicast.

In general, with current level of networks reliability it always worth putting your protocol on the top of UDP. Whatever having session sequence number, NACK+server-to-client-heartbeat and binary marshalling should be close to theoretical performance.

bobah