Websockets in HTML5 turbocharges web communications

Under the original HTTP protocol, a client, such as a Web browser, must open a connection to a server, make a request, wait for a response, and then close the connection. If the client needs more data, it must open a new connection. It’s like hanging up the phone and redialing after every sentence of a conversation. And if the server has new info for the client, it must wait until the client requests it rather than sending it over instantly.

The nearly-complete HTML5 standard for current and future Web software includes just such a solution, a new protocol called WebSockets. This protocol allows a Web client to create a connection, keep it open as long as it wants, and both send and receive data continuously.

The appeal of WebSocket tech is that “it is agnostic to the specific type of [Web] browser—IE, Firefox, Chrome. Developers don’t have to write a specific extension for each browser,” which they often do for workaround solutions. (Currently, Internet Explorer requires an add-on to handle WebSockets.) Chrome, Firefox, Opera, and some other browsers have support built-in.

Reducing kilobytes of data to 2 bytes […] and reducing latency from 150 milliseconds to 50 milliseconds is far more than marginal. In fact, these two factors alone are enough to make WebSockets seriously interesting to Google.”

If you liked this article, please give it a quick review on ycombinator or StumbleUpon. Thanks

Subscribe on Google News