Changes

Jump to: navigation, search

Platform/AreWeFunYet

363 bytes added, 22:12, 15 March 2012
WebSockets
WebSockets is a bi-directional connection-oriented reliable-transport protocol designed to give an option to developers for low-latency communications between browsers and servers. It isn't a raw socket protocol for security reasons, and is initiated on HTTP ports via an [http://tools.ietf.org/html/rfc6455 HTTP upgrade].
 
WebSockets is ''not'' intended to be a Peer2Peer protocol. It's intended to be the next step after HTTP as far as client-to-server communications goes and allows for long running connections, bi-directional communication with delivery guarantees. If what you are looking for is UDP based communication, or Peer2Peer connections, then WebRTC is the answer there.
You can actually do most of what WebSockets does over normal HTTP with long-hanging gets. However, the overhead of doing that over HTTP means that for small transactions - think key strokes, or a few bytes at a time - can have quite a bit of overhead because of HTTP headers. So WebSockets is really built for applications that require low-latency communications. Think live games or keystroke-based interactive applications.
Confirm
716
edits

Navigation menu