Server push and Comet (Rails user group Hamburg 2009-06-10)1. Server Push
or „How to initiate client side changes from the server
without polling every second or so“
Donnerstag, 11. Juni 2009
4. var myWebSocket = new(quot;ws://www.websocket.orgquot;);
myWebSocket.onmessage = function(evt)
{ alert( quot;Received Message: quot; + evt.data); };
Donnerstag, 11. Juni 2009
18. Comet servers
reduce server-side resources per connection
• Reduce overhead per thread
• use event libraries
• use microthreads (e.g. Erlang)
Donnerstag, 11. Juni 2009
25. BUT
data flow occurs on the server‘s schedule
close approximation of the server → client flow
Donnerstag, 11. Juni 2009
29. many servers use it
Cometd
ErlyComet
GlassFish
Jetty
Orbited
Persevere
...
Donnerstag, 11. Juni 2009
30. many client libs use it
Dojo (inventor)
jQuery
GWT
...
Donnerstag, 11. Juni 2009
36. can hold ten thousands connections on a single server
Donnerstag, 11. Juni 2009
38. RMDS2Web Server
500.000 concurrent users on single Dell-server
quot;most scalable real-time push web systemquot;
commercial
Donnerstag, 11. Juni 2009
39. APE (Ajax Push Engine)
quot;Real time data streamingquot;
open source client and server
proprietary protocol (NOT Bayeux)
Donnerstag, 11. Juni 2009
41. Facebook
Meebo (Chat)
...
Donnerstag, 11. Juni 2009
43. Reminder:
Rails-Konferenz call for papers deadline:
1st of July
Donnerstag, 11. Juni 2009