A small JavaScript library that decorates the WebSocket API to provide a WebSocket connection that will automatically reconnect if the connection is dropped.
reconnectingwebsocket
git://github.com/joewalnes/reconnecting-websocket.git