The name of this type of technology is Push (English Push), where the server initiates a transaction with the client (in your case, the browser).
It’s the opposite of what we normally use in web applications, where the action starts on the client side (Pull, from English Pull).
In this mechanism, the client state is changed at the request of the server. There are several ways to implement this behavior in modern browsers:
- Traditional polling: Your application asks from time to time, via Xmlhttprequest or equivalent, if the server has any status update.
- Long-Polling: Your application keeps an open parallel request that is only closed when the server sends some content.
- Forever Frame: The same as Long-Polling, but without the overhead of creating/destroying the client’s control objects, and usually with a permanent connection.
- Websockets: a relatively new protocol (2011) that operates in parallel to HTTP and optimizes bi-directional communication between client and server.
For more information, check the Wikipedia entry.
If I’m not mistaken, it’s by Websockets
– gmsantos
Yes, Websockets, the implementation is not so difficult, however it requires a few hours to understand where and how to apply it so that the optimization is well done.
– Diego Vieira