Cometd is a scalable HTTP-based event routing bus that uses a push technology pattern known as Comet. The term 'Comet' was coined by Alex Russell in his post 'Comet: Low Latency Data for the Browser'. Cometd consists of a protocol spec called Bayeux, javacript libraries (dojo toolkit), and an event server.
Jetty now has just an implementation of the cometd event server that uses the Continuation mechanism for asynchronous servlets.
Jetty already has comet implementations for DWR and activemq, but both of these use custom protocols which can lead to interoperability problems that cometd intends to solve.
Because browsers commonly permit only two connections to each server, it is not possible for a web page to use more than one Ajax library that is using comet techniques. The intent of cometd is to define a common protocol that can be shared between libraries and thus encourage interoperability.
Cometd provides a two multi-channel communications paradigm that allows asynchronous message delivery from server to client as well as client to server. The multi-channel nature of the protocol, will eventually allow a single comet connections to be shared between multiple Ajax toolkits
Jetty has implemented the server side of this protocol, which will allow it to be used with whatever client side implementations emerge (currently only dojo, but I plan to port activemq once it is stable). However to achieve true interoperability, we will need to develop standardized APIs on both the client and server side. Having standard protocol is a start on this, as it defines the capabilities that will need to be expressed in the APIs
Posted at 08:36PM Aug 03, 2006 by gregw in General | Comments[16]
Posted by Anonymous Coward on August 08, 2006 at 06:03 AM EST #
http://svn.codehaus.org/jetty/jetty/trunk/modules/cometd/
leads nowhere. Is the cometd module available?
Posted by Anonymous on September 03, 2006 at 12:38 PM EST #
http://svn.jetty.codehaus.org/browse/jetty/jetty/trunk/extras/cometd
Posted by Greg Wilkins on September 11, 2006 at 04:39 PM EST #
Hi,
Will it support Reverse Ajax as it is there in DWR?
Is there any working example where the server is pushing data to the client?
Posted by Hemasa on October 15, 2006 at 04:46 AM EST #
Posted by Chris Bucchere on November 22, 2006 at 12:59 PM EST #
We are using cometd on a project at my company and have run into an issue that we could really use some help with.
We are using JBoss with Tomcat 5.5 and I was hoping to keep things that way, so I put the cometd and jetty jar files into my webapp. What appears to be happening is that when two or more clients are connected through the cometd servlet (using dojo.io library), only the last client within the subscribers list will actually have a message delivered to them. After some debugging, it looks like only that last client actually has a Continuation. Is this possibly a by-product of using Tomcat instead of Jetty, or do you think there might be something else going on?
Posted by katy on January 03, 2007 at 02:21 PM EST #
probably best if you send an email to the cometd dev list and we can help you there . Difficult to have a conversation in blog comments
Posted by Greg Wilkins on January 07, 2007 at 01:44 AM EST #
I went to the new link http://svn.jetty.codehaus.org/browse/jetty/jetty/trunk/extras/cometd, but the zip i get there is corrupted. The cometd folder is not in the parent directory either. Could you tell me where you moved it?
Many thanks.
Posted by Dominique on July 06, 2007 at 07:39 AM EST #
I have reverse ajax application but it is eating the memory like hell. I think by using Jetty the problem might disappear.
Posted by Bashar on August 16, 2007 at 05:08 AM EST #
Posted by eman on June 03, 2009 at 12:56 AM EST #
Posted by Greg Wilkins on June 03, 2009 at 06:30 AM EST #
Posted by eman on June 04, 2009 at 04:30 AM EST #
Posted by Greg Wilkins on June 04, 2009 at 09:28 PM EST #
Posted by Web Performance on June 15, 2009 at 02:00 AM EST #
Posted by eman on June 16, 2009 at 03:00 PM EST #
Posted by eman on July 17, 2009 at 01:25 AM EST #