DontPush - Vaadin Add-on Directory
WebSockets for GWT and Vaadin.NOTE: this add-on has a sister project DontPush OzoneLayer. Its is currently more actively maintained and the suggested web socket/server push solution by the author.
This add-on takes server side push to a next level. The open connection is used for both inbound and outbound traffic, instead of using poller or separate connection just to notify the client about the updates. No need for a push() method to notify about changes, but things will just work. Also the latency to previous solutions/workarounds should be superior.
The add-on contains a custom servlet and a client side engine with steroids to replace XHR based communication with WebSocket protocol. WebSocket is a part of the HTML5 standard and already implemented in Safari, Chrome, Opera and FF4. (UPDATE FF4 and Opera finally left WebSocket support out of current releases). For older browsers the add-on use flash fallback called web-socket-js.
For non-vaadin users the jar file contains a GWT module called org.vaadin.dontpush.vwebsocket.VWebSocket that can be used independently of Vaadin. Compared to alternatives that I found it is superior because it supports hosted mode properly.
To use this with Vaadin you will currently need to:
* grab the latest Jetty 7.4
* use the org.vaadin.dontpush.server.impl.jetty.DontPushServlet instead of default Vaadin servlet
* rebuild the widgetset with this add-on jar
To use this with plain GWT:
* grab the jar file and inherit org.vaadin.dontpush.vwebsocket.VWebSocket from it
* use WebSocket class to connect your GWT app to your own custom WebSocket server
Note, this is early prototype release. Don't expect everything to work. Patches and comments are welcome.
Discussion ForumOnline Demo
Issue Tracker
DontPush OzoneLayer
Author Homepage
Source Code
DontPush version 0.1.0
A prototype for early adopters. Known issues e.g. support just for main windows (at top level).
DontPush version 0.2.0
Flash fallback via web-socket-js for IE and virtually all major browsers. Haven't tested that much still though.
DontPush version 0.3.0
* now supports jetty 7.4 series
* fixed some bugs
* maven based build
DontPush version 0.3.1
removed dependency to obsolete parent project (manual, demos etc)