Finally! Grizzly's Bayeux implementation updated (previously called gCometd)!
After months of inactivities, I've updated the Grizzly's Bayeux implementation (previously called gCometd) to reflect the current 1.0 specification. I'm no longer using the gCometd name based on a note I've read from the cometd-dev team, who recommended to not use their name. But first, thanks to the community for the great feedback I got from the initial Bayeux implementation in Grizzly. Wow the joy of open source! The beta implementation is now available out of the box in Grizzly 1.0.19, GlassFish v2.1 (9.1ur1 b09), Sailfin (how cool it will be to mix SIP and Comet!) and Grizzly snapshots/1.6.2
The example (grizzly-cometd-chat.war) can be downloaded from here. It uses the latest DOJO Toolkit library (0.9.x). To use it with GlassFish, start GlassFish, enable comet support, and then deploy grizzly-cometd-chat.jar:
% asadmin start-domain
% asadmin set --user admin --host localhost --port 4848 --echo=true --terse=true server.http-service.http-listener.http-listener-1.property.cometSupport=true
% asadmin deploy --user admin --host localhost --port 4848 --upload=false grizzly-cometd-chat.war
Then point your browser(s) to http://localhost:8080/grizzly-cometd-chat/index.html
If you use Grizzly 1.0.18 or 1.6.2, just do:
% mkdir grizzly-cometd-chat
% cd grizzly-cometd-chat
% unzip grizzly-cometd-chat.war
// Start Grizzly 1.6-SNAPSHOT or 1.6.2
& java -jar cometd-1.6-SNAPSHOT.jar 8080 <path-to>/grizzly-cometd-chat/
% java -jar grizzly-1.0.19.jar 8080 <path-to>/grizzly-cometd-chat/
Then point your browser(s) to http://localhost:8080/index.html
Of course for developing I recommend Grizzly standalone as it starts extremely fast (and this is what GlassFish v3 will soon offer). As usual, send me feedback and patches are more than welcome!