Project Description
nComet is a .NET implementation of the Comet (reverse-AJAX push) architecture. This server-side pipeline uses long-lived client-initiated HTTP connections to push messages to the client. Once the client receives a response, it immediately opens another HTTP request, which the server holds until a message is ready. This architecture allows the server to push dynamic html/xml/json/etc to the browser, rather than the browser polling the server.

This project is scoped to the .NET server-side architecture, initially providing a HttpListener (for a custom host communicating with HTTP.SYS directly) as well as a ASP.NET implementation, where the ASP.NET implementation can be hosted inside IIS as well as an external process. The library will simplify the implementation of common message patterns such as pushing the latest data, as well as sync. Example code and links to multiple client-side javascript implementations will also be provided.


Initial release
Look for an initial beta release in November...

Sample
To run the time sample included:
  • comets.exe time http://localhost/
    • after time, you can add multiple URLs and a timezone, such as "Eastern Standard Time" or "Pacific Standard Time"
      • ex: comets.exe time http://localhost/ http://mycomputer/ncomet/time/ "Eastern Standard Time"
  • In Vista, you must run this sample as administrator, or delegate the HTTP namespace

Future Direction


Last edited Nov 13 2008 at 3:54 PM by gtsiokos, version 14
Comments
imebgo wrote  Jul 12 2008 at 10:47 AM 
Nice to see people are investigating this technology futher with ASP.NET, I will be following this closely.

It would be nice to get some feedback on an implementation I put together:

http://www.codeproject.com/KB/aspnet/CometAsync.aspx
http://www.codeproject.com/KB/aspnet/AspNetComet.aspx

gtsiokos wrote  Jul 12 2008 at 12:26 PM 
This implementation does not use threads to determine a push event, it uses semaphores. A request is blocked by the semaphore and the thread handling the request is released back to the pool. When a push event happens, the semaphore is signaled, and a thread is dispatched to complete the request.

imebgo wrote  Jul 12 2008 at 12:30 PM 
Clearly it is a good method to queue the request. Have you thought about how this work function load balanced? I.e the client is waiting for a push event on one server and a request comes in from another client to create the push event on another server?

gtsiokos wrote  Jul 12 2008 at 6:06 PM 
After I finish the lower-level work of dealing with many open connections, I plan to attack the next level which would include extensible notification for multiple servers to publish a single event. This required a higher abstraction than what is currently delivered – currently the class library includes a Bus<T> object that the CometHandler “subscribes” to when a connection arrives. Anyone can publish to the bus and all subscribers receive the latest T value. In a higher abstraction, an “event” must be defined that multiple handlers on multiple servers subscribe to. The current implementation allows any type of message to flow between client and server – the multi-server object will continue that design and a higher-abstraction will implement more specific communication protocols, such as bayeaux. In addition, this higher-level object would optionally support recording and responding to historical event requests. Thanks for the feedback!

bikerboyroy wrote  Sep 23 2008 at 5:29 PM 
Hello, Has everyone gone to sleep on this project ?
I have been away travelling for the last two months, seems nothing has been contributed/released.
Are there any pending releases ?
I'm hoping to do a bit myself starting mid October

gtsiokos wrote  Oct 15 2008 at 4:31 PM 
No updates yet - be sure to check back late November for more check-ins. First alpha release will be Early 2009.

ChristianWeyer wrote  Dec 4 2008 at 10:27 AM 
Hi gtsiokos,

It is beginning of December now ;)
Any news? This seems to be a very interesting project.

Thanks.

hazem_salem wrote  Dec 23 2008 at 1:22 PM 
Hi all,
Finally we just did it.
We just make a new release of commet implementation i'll add the idea and the code soon.
Thanks

Updating...
© 2006-2009 Microsoft | About CodePlex | Privacy Statement | Terms of Use | Code of Conduct | CodePlex Blog | Version 2008.12.9.14291