How do TCP/IP and HTTP work together?

The network layers use abstraction and encapsulation. The lower layers encapsulate the higher layers. The Application layer can have its own protocols, e.g. HTTP. HTTP communicates with HTTP on the target device, and it is a protocol that transfers the application data (HTML). The Transport layer (layer 4) encapsulates the application datagrams, and it communicates … Read more

What is a message boundary?

No, message boundaries have nothing to do with destinations or ports. A “message boundary” is the separation between two messages being sent over a protocol. UDP preserves message boundaries. If you send “FOO” and then “BAR” over UDP, the other end will receive two datagrams, one containing “FOO” and the other containing “BAR”. If you … Read more

Difference between message-oriented protocols versus stream-oriented protocols [closed]

Message Oriented protocols send data in distinct chunks or groups. The receiver of data can determine where one message ends and another begins. Stream protocols send a continuous flow of data. Here is an example with mobile phones. Text messages would be a message oriented protocol as each text message is distinct from the other … Read more

What is the difference between IPoIB and TCP over InfiniBand?

InfiniBand adapters (“HCAs”) provide a couple of advanced features that can be used via the native “verbs” programming interface: Data transfers can be initiated directly from userspace to the hardware, bypassing the kernel and avoiding the overhead of a system call. The adapter can handle all of the network protocol of breaking a large message … Read more

“java.net.BindException: Address already in use” when trying to do rapid Socket creation and destruction for load testing

You are exhausing the space of outbound ports by opening that many outbound sockets within the TIME_WAIT period of two minutes. The first question you should ask yourself is does this represent a realistic load test at all? Is a real client really going to do that? If not, you just need to revise your … Read more

Is it possible to connect to SSH using JavaScript?

Sorry, given your constraints (client-side Javascript only), there is no way to connect to a plain old SSH server. WebSockets is not plain TCP. It’s a framed protocol with a HTTP-like handshake between the client and server that includes origin policy. Flash can make plain TCP connections, but it also has origin policy enforcement. The … Read more

HttpWebRequest’s Timeout and ReadWriteTimeout — What do these mean for the underlying TCP connection?

This problem has been debated on another question, see Adjusting HttpWebRequest Connection Timeout in C#. The discussion made my head spin, so I’ll offer my summary. Although, MSDN explains that the HttpWebRequest.Timeout Property applies to HttpWebRequest.GetResponse and HttpWebRequest.GetRequestStream calls, the description is a bit confusing. Jim Mischel is more helpful: Timeout “is the time for … Read more

Is TCP protocol stateless?

You can’t assume that any stacked protocol is stateful or stateless just looking at the other protocols on the stack. Stateful protocols can be built on top of stateless protocols and stateless protocols can be built on top of stateful protocols. One of the points of a layered network model is that the kind of … Read more