<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	>

<channel>
	<title>Comet Daily</title>
	<atom:link href="http://cometdaily.com/feed/" rel="self" type="application/rss+xml" />
	<link>http://cometdaily.com</link>
	<description>Information about Comet techniques.</description>
	<pubDate>Wed, 23 Jul 2008 13:59:59 +0000</pubDate>
	<generator>http://wordpress.org/?v=2.5.1</generator>
	<language>en</language>
			<item>
		<title>Persevere Tutorial</title>
		<link>http://cometdaily.com/2008/07/23/persevere-tutorial/</link>
		<comments>http://cometdaily.com/2008/07/23/persevere-tutorial/#comments</comments>
		<pubDate>Wed, 23 Jul 2008 13:52:34 +0000</pubDate>
		<dc:creator>DylanSchiemann</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[dojo]]></category>

		<category><![CDATA[HTTPChannels]]></category>

		<category><![CDATA[Persevere]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=363</guid>
		<description><![CDATA[Kris Zyp has published a great tutorial on using Persevere with Dojo.]]></description>
			<content:encoded><![CDATA[<p>Kris Zyp has published a <a href="http://www.sitepen.com/blog/2008/07/23/getting-started-with-persevere-using-dojo/">great tutorial on using Persevere with Dojo</a>.</p>
<blockquote><p>The Persevere server is an open source JSON application and storage server. Persevere pairs well with Dojo; the Dojo Data paradigm has a strong correlation to Persevere’s data storage structure. Virtually everything you can create or action you can perform with Dojo Data can be persisted in Persevere’s data storage including subobjects, arrays, circular references, and functions. Combining Persevere with Dojo allows you to rapidly develop simple database applications with create, read, update, and delete (CRUD) capabilities with minimal effort.</p></blockquote>
<p>Comet support in Persevere occurs with <a href="http://cometdaily.com/2008/05/13/http-channels-2/">HTTP Channels</a>.</p>
<blockquote><p>You can start building applications almost instantly; no need to create schemas or table definitions ahead of time, simply start creating and building dynamic persistent objects in your data stores, and connect them to widgets for display. You can build your entire application, client and server, in JavaScript.</p></blockquote>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F23%2Fpersevere-tutorial%2F&amp;title=Persevere+Tutorial" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/23/persevere-tutorial/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Interview with InfoQ</title>
		<link>http://cometdaily.com/2008/07/22/interview-with-infoq/</link>
		<comments>http://cometdaily.com/2008/07/22/interview-with-infoq/#comments</comments>
		<pubDate>Wed, 23 Jul 2008 06:52:35 +0000</pubDate>
		<dc:creator>DylanSchiemann</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[infoq]]></category>

		<category><![CDATA[interview]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=364</guid>
		<description><![CDATA[I was recently interviewed by InfoQ on the topics of Ajax, Comet, Bayeux, RIAs and the Dojo Toolbox.]]></description>
			<content:encoded><![CDATA[<p>I was recently interviewed by InfoQ on the topics of <a href="http://www.infoq.com/news/2008/07/dylan_schiemann_qna">Ajax, Comet, Bayeux, RIAs and the Dojo Toolbox</a>.</p>
<p>I was asked to give my definition of Comet in reference to the <a href="http://cometdaily.com/2008/06/30/enough-already-with-the-connections/">enough with the connections discussion</a>:</p>
<blockquote><p>Comet is a collection of techniques, transports, protocols, servers, and clients to deliver low-latency data transit between the server and the client.</p>
<p>The XHR is the least common denominator of Comet, and everything else is an attempt to improve upon the XHR to deliver faster, real-time applications. My definition intentionally avoids some points of the debate, as I prefer to be inclusive and broad, much as Ajax has come to represent everything dynamic in a browser to most people.</p></blockquote>
<p>I also touch briefly as Bayeux and standards bodies, and JSR-315 for Java Comet servers, and many more general development topics.</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F22%2Finterview-with-infoq%2F&amp;title=Interview+with+InfoQ" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/22/interview-with-infoq/feed/</wfw:commentRss>
		</item>
		<item>
		<title>This Week in Comet</title>
		<link>http://cometdaily.com/2008/07/21/this-week-in-comet/</link>
		<comments>http://cometdaily.com/2008/07/21/this-week-in-comet/#comments</comments>
		<pubDate>Mon, 21 Jul 2008 22:13:30 +0000</pubDate>
		<dc:creator>DylanSchiemann</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[erlycomet]]></category>

		<category><![CDATA[orbited]]></category>

		<category><![CDATA[oscon]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=362</guid>
		<description><![CDATA[The first Comet book is about to be released, and a great Comet talk is scheduled for OSCON.]]></description>
			<content:encoded><![CDATA[<p>A few months ago we <a href="http://cometdaily.com/2008/03/28/comet-book-interview-comet-and-reverse-ajax-the-next-generation-ajax-20/">interviewed David Crane</a> about his forthcoming book <a href="http://astore.amazon.com/dylanschie-20/detail/1590599985/104-6591074-5501544">Comet and Reverse Ajax: The Next Generation Ajax 2.0</a>.  According to the publisher&#8217;s web site, the book will be available this week.</p>
<p>Also this week is OSCON where Comet Daily&#8217;s Michael Carter and Jacob Rus are <a href="http://en.oreilly.com/oscon2008/public/schedule/detail/3048">speaking about Orbited</a> including a great eight-player real-time game.  Check back later this week for more details.</p>
<p>Also at OSCON is the talk <a href="http://en.oreilly.com/oscon2008/public/schedule/detail/3065">Beautiful Concurrency with Erlang</a> by Kevin Scaldeferri.  While this talk is not limited to Comet or specifically about erlyComet, it should be a great introduction to concepts that are interesting to the Comet crowd.</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F21%2Fthis-week-in-comet%2F&amp;title=This+Week+in+Comet" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/21/this-week-in-comet/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Dojo HttpChannels Module</title>
		<link>http://cometdaily.com/2008/07/18/dojo-httpchannels-module/</link>
		<comments>http://cometdaily.com/2008/07/18/dojo-httpchannels-module/#comments</comments>
		<pubDate>Fri, 18 Jul 2008 07:28:23 +0000</pubDate>
		<dc:creator>Kris Zyp</dc:creator>
		
		<category><![CDATA[articles]]></category>

		<category><![CDATA[cometd]]></category>

		<category><![CDATA[dojo]]></category>

		<category><![CDATA[HTTPChannels]]></category>

		<category><![CDATA[jsonreststore]]></category>

		<category><![CDATA[Persevere]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=344</guid>
		<description><![CDATA[HTTP Channels is implemented in Dojo 1.2 with the HttpChannels module. HTTP Channels is intended to provide data synchronization and update notifications by leveraging the ubiquitous HTTP REST semantics.]]></description>
			<content:encoded><![CDATA[<p><a href="http://cometdaily.com/2008/05/13/http-channels-2/">HTTP Channels</a> is implemented in <a href="http://dojotoolkit.org">Dojo</a> 1.2 with the HttpChannels module. HTTP Channels is <a href="http://cometdaily.com/2008/06/05/intended-usage-of-http-channels/">intended to provide data synchronization</a> and update notifications by leveraging the ubiquitous HTTP REST semantics. Within Dojo, HTTP Channels are particularly useful, integrating directly with Dojo Data for live data synchronization. The HttpChannels module is very flexible as well; it can be used in several different ways:</p>
<h2>Live REST Updates</h2>
<p>The easiest and highest level use of HTTP Channels is in conjunction with the <a href="http://www.sitepen.com/blog/2008/06/13/restful-json-dojo-data/">JsonRestStore</a>. HttpChannels can be used as an enhancement for the REST service, to enable &#8220;live&#8221; data (real-time updates that directly alter the data in caches/indexes). To add enable live updates through HTTP Channels messages to the data in JsonRestStore, simply add HttpChannels after loading the JsonRestStore:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript">dojo.<span style="color: #006600;">require</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;dojox.data.JsonRestStore&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
dojo.<span style="color: #006600;">require</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;dojox.cometd.HttpChannels&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>Now, we can create and use a <a href="http://www.sitepen.com/blog/2008/06/13/restful-json-dojo-data/">JsonRestStore exactly the same way</a> as you would without HttpChannels:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #003366; font-weight: bold;">var</span> myStore <span style="color: #339933;">=</span> <span style="color: #003366; font-weight: bold;">new</span> dojox.<span style="color: #006600;">data</span>.<span style="color: #006600;">JsonRestStore</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span>target<span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;/myTable&quot;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>This is all that is needed on the client side (of course on the server side you need a HTTP Channels capable storage system, like <a href="http://sitepen.com/labs/persevere.php">Persevere</a>). All resource/data retrievals made by the JsonRestStore will automatically trigger subscriptions to the resources, and data updates that are sent from the server will automatically trigger the appropriate <a href="http://api.dojotoolkit.org/jsdoc/dojo/HEAD/dojo.data.api.Notification">Dojo Data notifications</a> for updates in widgets.</p>
<p>This means that building an application with Dojo that can load data from a server and receive updates on data changes and update the UI with these changes can be as simple as plugging a JsonRestStore data store into a widget like a grid, and letting Dojo handle all the communication and notification routing. Plugging a &#8220;live&#8221; data store into a grid can be done like:</p>

<div class="wp_syntax"><div class="code"><pre>&lt;table dojoType=&quot;dojox.grid.DataGrid&quot; store=&quot;myStore&quot; ...</pre></div></div>

<p>We can see a very simple <a href="http://persevere.sitepen.com/examples/customer.html">example of using a live data store with a grid widget</a>.</p>
<h2>Cometd Transport</h2>
<p>HTTP Channels is a Bayeux compliant transport, and the HttpChannels module can also be used as a Cometd transport. Simply load HttpChannels after Cometd and it will auto-register itself as a Cometd transport:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript">dojo.<span style="color: #006600;">require</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;dojox.cometd&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
dojo.<span style="color: #006600;">require</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;dojox.cometd.HttpChannels&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #006600; font-style: italic;">// initialize cometd</span>
dojox.<span style="color: #006600;">cometd</span>.<span style="color: #006600;">init</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;/cometd&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #006600; font-style: italic;">// subscribe to a channel</span>
dojox.<span style="color: #006600;">cometd</span>.<span style="color: #006600;">subscribe</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;/weather/slc&quot;</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span> ... <span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #006600; font-style: italic;">// publish to a channel</span>
dojox.<span style="color: #006600;">cometd</span>.<span style="color: #006600;">publish</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;/news/slc&quot;</span><span style="color: #339933;">,</span> <span style="color: #009900;">&#123;</span>title<span style="color: #339933;">:</span><span style="color: #3366CC;">&quot;Hot Weather&quot;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p>By loading the HttpChannels module after Cometd, HttpChannels will register itself as an available transport. If the server advertises the ability to handle the &#8220;http-channels&#8221; transport, the Cometd module will use HTTP Channels for handling subscriptions and publishing messages. It is important to note that HTTP Channels integrates pub-sub messaging with REST resource locators, and therefore publishing messages and subscribing are executing by HTTP requests directly to the target path. With an HTTP Channels compliant server, the example above would result in HEAD request with a subscription header to the relative URL &#8220;/weather/slc&#8221;, and POST request to the relative URL &#8220;/news/slc&#8221;.</p>
<h2>Standalone Protocol</h2>
<p>To use the HttpChannels module standalone, you first get an instance of HttpChannels, the default instance (which is used with the REST services and Cometd by default) can be retrieved:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #003366; font-weight: bold;">var</span> httpChannels <span style="color: #339933;">=</span> dojox.<span style="color: #006600;">cometd</span>.<span style="color: #006600;">HttpChannels</span>.<span style="color: #006600;">defaultInstance</span><span style="color: #339933;">;</span></pre></div></div>

<p>You can now directly access the HttpChannels API. The primary HttpChannels functions are <code>get</code>, <code>subscribe</code>, <code>unsubscribe</code>, and <code>receive</code>. The <code>subscribe</code> function allows you to subscribe to a resource and provide a callback for notifications. The <code>get</code> function also does a subscribe, but it gets the target resource at the same time as sending a subscription request. The <code>receive</code> function is called whenever data is received from the server. You can use <code>dojo.connect</code> to listen for all messages from the server. For example:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript">dojo.<span style="color: #006600;">require</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;dojox.cometd.HttpChannels&quot;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
<span style="color: #003366; font-weight: bold;">var</span> httpChannels <span style="color: #339933;">=</span> dojox.<span style="color: #006600;">cometd</span>.<span style="color: #006600;">HttpChannels</span>.<span style="color: #006600;">defaultInstance</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// get the current weather and subscribe to future changes</span>
httpChannels.<span style="color: #006600;">get</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;/weather/slc&quot;</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>weatherReport<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span> 
	<span style="color: #006600; font-style: italic;">// this is called for the initial response and all updates</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span> 
dojo.<span style="color: #006600;">connect</span><span style="color: #009900;">&#40;</span>httpChannels<span style="color: #339933;">,</span><span style="color: #3366CC;">&quot;receive&quot;</span><span style="color: #339933;">,</span><span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>message<span style="color: #009900;">&#41;</span><span style="color: #009900;">&#123;</span>
	<span style="color: #006600; font-style: italic;">// this is called for all notifications from the server</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span></pre></div></div>

<p><img src="https://cometdaily.com/wp-content/uploads/2008/07/httpchannels.png" alt="" title="httpchannels" class="alignnone size-medium wp-image-361" /></p>
<p>Dojo&#8217;s new HttpChannels module provides an efficient implementation of HTTP Channels with strong integration with other modules in Dojo including Cometd and JsonRestStore. HttpChannels can be used for rapidly developing data-centric applications that rely on real-time updates; Dojo provides all the facilities for creating a Comet connection with the server, handling server-sent messages, appropriately updating data, delivering notifications through data stores, and updating widget user interfaces in response to these notifications.</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F18%2Fdojo-httpchannels-module%2F&amp;title=Dojo+HttpChannels+Module" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/18/dojo-httpchannels-module/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Thinking About Browser Protocols</title>
		<link>http://cometdaily.com/2008/07/17/thinking-about-browser-protocols/</link>
		<comments>http://cometdaily.com/2008/07/17/thinking-about-browser-protocols/#comments</comments>
		<pubDate>Thu, 17 Jul 2008 07:25:25 +0000</pubDate>
		<dc:creator>MichaelCarter</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[protocols orbited xmpp irc imap stomp]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=360</guid>
		<description><![CDATA[In light of the recent discussion about sockets and protocols and Comet, I've been thinking about browser protocols]]></description>
			<content:encoded><![CDATA[<p>In light of the recent discussion about sockets and protocols and Comet, I&#8217;ve been thinking about browser protocols:</p>
<p><strong>XMPP:</strong></p>
<ul>
<li>Put IM on your website</li>
<li>Manage XMPP components from a browser</li>
</ul>
<p><strong>IMAP:</strong></p>
<ul>
<li>Write Gmail in 20 minutes <img src='http://cometdaily.com/wp-includes/images/smilies/icon_wink.gif' alt=';-)' class='wp-smiley' /> </li>
</ul>
<p><strong>IRC:</strong></p>
<ul>
<li>Collaborate on Open (and otherwise) Software from a browser</li>
</ul>
<p><strong>STOMP:</strong></p>
<ul>
<li>Message Queue integration &#8212; Browsers can be first-class clients in MQ systems</li>
</ul>
<p>We have already started the above choices with the <a href="http://www.orbited.org">Orbited</a> project. But there are hundreds of additional protocol choices. What protocols do you want in the browser?</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F17%2Fthinking-about-browser-protocols%2F&amp;title=Thinking+About+Browser+Protocols" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/17/thinking-about-browser-protocols/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Comet Daily at Upcoming Conferences</title>
		<link>http://cometdaily.com/2008/07/14/comet-daily-at-upcoming-conferences/</link>
		<comments>http://cometdaily.com/2008/07/14/comet-daily-at-upcoming-conferences/#comments</comments>
		<pubDate>Mon, 14 Jul 2008 07:04:07 +0000</pubDate>
		<dc:creator>DylanSchiemann</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[conferences]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=331</guid>
		<description><![CDATA[Join the contributors of Comet Daily at a conference near you!]]></description>
			<content:encoded><![CDATA[<p>After a break for June and most of July, conference season is about to pick back up again.  If you&#8217;re interested in learning more about Comet, there are talks on Comet by Comet Daily contributors at the following conferences (and likely many more):</p>
<ul>
<li><a href="http://conferences.oreillynet.com/oscon/">OSCON</a> (end July, Portland Oregon)</li>
<li><a href="http://www.therichwebexperience.com/">Rich Web Experience</a> (early September, Washington DC and San Jose, CA)</li>
<li><a href="http://ajaxexperience.techtarget.com/east/index.html">Ajax Experience</a> (late September, Boston, MA)</li>
<li><a href="http://en.oreilly.com/webexberlin2008/public/content/home">Web2.0 Expo Europe</a> (late October, Berlin, Germany)</li>
<li><a href="http://www.javoxx.com/display/JV08/Home">Javoxx</a> (early December, Antwerp, Belgium)</li>
</ul>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F14%2Fcomet-daily-at-upcoming-conferences%2F&amp;title=Comet+Daily+at+Upcoming+Conferences" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/14/comet-daily-at-upcoming-conferences/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Maven Repositories for Dojo and Cometd</title>
		<link>http://cometdaily.com/2008/07/11/maven-repositories-for-dojo-and-cometd/</link>
		<comments>http://cometdaily.com/2008/07/11/maven-repositories-for-dojo-and-cometd/#comments</comments>
		<pubDate>Fri, 11 Jul 2008 07:02:29 +0000</pubDate>
		<dc:creator>GregWilkins</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[cometd]]></category>

		<category><![CDATA[dojo]]></category>

		<category><![CDATA[maven]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=359</guid>
		<description><![CDATA[Using  maven to build your project is fantastic for managing your dependencies and avoiding having dependencies (and their dependencies) checked into your own svn.]]></description>
			<content:encoded><![CDATA[<p>Using  maven to build your project is fantastic for managing your dependencies and avoiding having dependencies (and their dependencies) checked into your own svn.  The only fly in the ointment, is projects that don&#8217;t publish maven artifacts, and the Ajax Dojo Toolkit and Cometd have been one of these. Until now that is !</p>
<p>The new repositories are at </p>
<ul>
<li>http://download.dojotoolkit.org/maven2-snapshot/
  </li>
<li>http://download.dojotoolkit.org/maven2/</li>
</ul>
<p>I have <a href="http://blogs.webtide.com/gregw/2008/07/10/1215675720000.html">blogged at length</a> about the maven incantations needed to use these.</p>
<p>Currently only 1.2-SNAPSHOTs of Dojo and 1.0-SNAPSHOTs of parts of Cometd are published. Releases (including dojo 1.1.1) will be forthcoming once we have some feedback.</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F11%2Fmaven-repositories-for-dojo-and-cometd%2F&amp;title=Maven+Repositories+for+Dojo+and+Cometd" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/11/maven-repositories-for-dojo-and-cometd/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Comet Presentation at MySpace</title>
		<link>http://cometdaily.com/2008/07/10/comet-presentation-at-myspace/</link>
		<comments>http://cometdaily.com/2008/07/10/comet-presentation-at-myspace/#comments</comments>
		<pubDate>Thu, 10 Jul 2008 07:12:54 +0000</pubDate>
		<dc:creator>MichaelCarter</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[myspace]]></category>

		<category><![CDATA[orbited]]></category>

		<category><![CDATA[tcpsocket]]></category>

		<category><![CDATA[websocket]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=357</guid>
		<description><![CDATA[A few weeks ago MySpace invited me to give a presentation about using Orbited to create scalable Comet applications. ]]></description>
			<content:encoded><![CDATA[<p>A few weeks ago <a href="http://myspace.com/">MySpace</a> invited me to give a presentation about using <a href="http://orbited.org/">Orbited</a> to create scalable Comet applications. While I can&#8217;t speak to any plans on the part of MySpace, I did get permission to post my speaking notes and slides.  One point to keep in mind is that this presentation was made shortly before the naming of WebSocket was decided in the HTML5 spec, so the slides refer to the then-current name &#8220;TCPConnection&#8221;.</p>
<p><center><a href='http://orbited.org/blog/files/myspace-talk2.pdf' >Slides</a><br />
<a href='http://orbited.org/blog/files/myspace-talk2.pdf'><img src="http://cometdaily.com/wp-content/uploads/2008/07/myspace-talk-300x225.png" alt="" title="Orbited at Myspace Slides Preview" width="300" height="225" class="aligncenter size-medium wp-image-358" /></a></center></p>
<h3> Speaking Notes </h3>
<blockquote><p>
<!-- (Part I - what is Comet + transports: 10 minutes) --><br />
Slide: Orbited Logo + Michael Carter</p>
<p>-My name is Michael Carter<br />
- Founder Lead developer of Orbited<br />
    - 2 years in development<br />
    - countless architectures tested<br />
    - now we&#8217;ve found the best<br />
    - javascript work</p>
<p>Slide: Comet</p>
<p>- Here to tell you about Comet<br />
- Everything I&#8217;ve learned in two years of Comet work<br />
- You probably already know what Comet is. But i&#8217;ll say it again just in case.</p>
<p>Slide: What is Comet</p>
<p>- Its about asynchronous updates in the browser (Pushing data)<br />
- Not necessarily about a particular technology<br />
    - could be flash<br />
    - polling<br />
    - javascript hacks (streaming)<br />
- Its about an interaction model &#8212; user is notified asap with new data<br />
- Its about the applications that you can build with that interaction model<br />
    - Chat, clearly<br />
    - Financials<br />
    - Gaming<br />
    - Auctions<br />
    - Sports reporting<br />
    - Collaborative Editing<br />
    - Network monitor reporting / system administration<br />
    - Election Monitoring (Andrew Betts / London Paper)<br />
    - Air traffic control (no joke)<br />
    - To name a few<br />
- In practice though, everyone wants Comet without the need for flash or bad performance of polling<br />
- Just plain old js and html, low latency<br />
- Which brings us to Transports</p>
<p>Slide: Transports<br />
- These are the actual mechanisms for delivering data<br />
- There are many</p>
<p>Slide: Iframe</p>
<p>- Originally we had script tag streaming<br />
- but it made sense to put it in an iframe<br />
- So we refer to it now as iframe streaming</p>
<p>Slide: Iframe Diagram</p>
<p>- Application page has a callback &#8220;receive&#8221;<br />
- Finishes loading, creates and iframe<br />
- Iframe causes an HTTP request to the server<br />
- the server sends headers<br />
- (transfer-encoding chunked for http 1.1)<br />
- And then stops<br />
- The key to this transport is incremental rendering<br />
- Browser will try to display any open/close tag pair that it receives<br />
- This includes displaying invisible elements, like script tags<br />
- So the server can cause the browser to execute arbitrary javascript<br />
- <script>parent.receive("payload!");</script></p>
<p>Slide: Iframe Code<br />
- Easy to implement<br />
- Works in all browsers with the same code<br />
- Suffers from..</p>
<p>Slide: Iframe Usability<br />
- Loading Bars<br />
- Hour glasses<br />
- clicking noises?!</p>
<p>Slide: Iframe Unacceptable<br />
- Modern applications can&#8217;t have clicking noises and hour glasses.<br />
- The users would get too confused<br />
- So Iframe streaming isn&#8217;t the most popular transport<br />
- Instead, the most popular transport is&#8230;</p>
<p>Slide: XHR Long polling</p>
<p>- Long polling is what the cool kids do.<br />
- (Meebo and Facebook, for instance)</p>
<p>Slide: XHR diagram</p>
<p>- Browser says, &#8216;Give me an event&#8217;<br />
- Server says, &#8216;&#8230;&#8217;<br />
- Server says, &#8216;event.&#8217;<br />
- Browser says, &#8216;Give me an event&#8217;<br />
- server says &#8216;&#8230;&#8217;<br />
- Its cross-browser</p>
<p>Slide: Long polling code<br />
- still easy to implement<br />
- and no usability issues!<br />
- seems like a big win<br />
- but how does long polling performance compare to iframe streaming?<br />
- Consider an island off the coast<br />
- its surrounded by water</p>
<p>Slide: Island<br />
- We want to send conveys to the island, so we build a bridge</p>
<p>Slide: Bridge<br />
- Conveys can now go to the island as they please<br />
- But maybe a big ugly bridge is not what we wanted&#8230; its too unsightly<br />
- So instead we build a boat</p>
<p>Slide: A boat<br />
- The convey arrives at the boat, and the boat takes it to the island<br />
- no problem<br />
- But what about the second convey that arrived just after the boat leaves?<br />
- It waits for the boat to go to the island<br />
- It waits for the boat to come back<br />
- It gets on, and waits for the boat to go to the island<br />
- 3x travel duration<br />
- Well Iframe streaming is the bridge, and the boat is long polling<br />
- Meaning, long polling suffers from a 3x latency performance hit<br />
- But thats not all<br />
Slide: Bandwidth comparison<br />
- You also have to send headers all the time<br />
- Your buddy says &#8216;hows it hanging&#8217;<br />
- But the browser says &#8216;GET /some/url HTTP/1.1\r\nUser-Agent: &#8230;etc&#8217;<br />
- And the server says &#8216;HTTP/1.1 200 ok\r\nContent-type&#8230;.&#8217;<br />
- your 15 byte message can easily incur 300 bytes of headers, or more!<br />
- thats a 20x bandwidth increase in that case</p>
<p>Slide: Long polling unacceptable<br />
- 3x latency is too much<br />
- 20x bandwidth is too much</p>
<p>Slide: Strike 2, you&#8217;re out<br />
- Strike 2, you&#8217;re out<br />
- or so we thought</p>
<p>Slide: Htmlfile Object<br />
- htmlfile object to the rescue</p>
<p>Slide: ActiveX!<br />
- but safe for scripting<br />
- hides usability issues</p>
<p>Slide: Garbage crossout<br />
- leaks live connections on navigations<br />
- But we can fix that by explicitly calling the garbage collector</p>
<p>Slide: Htmlfile works great<br />
- Streaming<br />
- But No side effects<br />
Slide: Explorer only<br />
- partial solution<br />
Slide: Xhr Streaming<br />
- transport for ff and safari<br />
Slide: ready state 3<br />
- don&#8217;t do one event per request/response cycle<br />
- do a hundred. a thousand&#8230;<br />
- ready state 3 saves the day<br />
- callbacks for download progress from server<br />
- responseText is just plain text without any inherent meaning</p>
<p>Slide: Manually parse<br />
- So invent our own format<br />
- parse it manually<br />
- And we&#8217;re set for firefox and safari<br />
- Without loading bars or anything<br />
- and the same bandwidth and latency constraints of iframe streaming<br />
- So we&#8217;ve got all the browsers<br />
- Except opera</p>
<p>Slide: SSE</p>
<p>- Opera goes above and beyond the call of duty<br />
- I don&#8217;t ask that browser&#8217;s make my life easy<br />
- They can keep their nasty forest of terrible hacks<br />
- All I ever asked from browsers is that they make it possible to do comet<br />
- But Opera actually makes comet a first class citizen of the browser<br />
- Create an event source, name a url, add a listener. The end.</p>
<p>Slide: Html5</p>
<p>- Then they went on to propose that the this be included in HTML5<br />
- after discussions with other vendors, gained support, a new spec came up</p>
<p>Slide: deprecated</p>
<p>- so the new one isn&#8217;t implemented<br />
- but thats okay<br />
- we can use the deprecated one in opera 8+</p>
<p>Slide: Transport Conclusions 10.18.20<br />
- Ten minutes to explain<br />
- Years to discover</p>
<p>Slide: hacks<br />
- And yes, its hacks, hacks hacks</p>
<p>Slide: aim carefully<br />
- Developing these transports is like trying to throw darts at a board</p>
<p>Slide: moving target<br />
- but the board moves after you&#8217;ve thrown the dart<br />
- That is to say, just imagine the most frustrating game you can<br />
- That game is twice as fun as building transports</p>
<p>Slide: sleek bridge<br />
- We can avoid the boat transport (long polling)<br />
- And provide great user experience<br />
- get a nice looking bridge</p>
<p>Slide: sleek bridge image with orbited logo superimosed<br />
- And orbited does just that</p>
<p><!-- (Part II - Scaling Comet - 8 Minutes) --></p>
<p>Slide: Scalability<br />
- Once you have a way to do comet, you need to scale it<br />
- where transports are frustrating, scaling is hard<br />
- Step 1,</p>
<p>Slide: Vertical Scalability<br />
- How do you put lots of users on one machine?<br />
- Seems like such a hard problem, but really there&#8217;s a simple trick<br />
- And once you know the trick, its possible<br />
- Don&#8217;t use threads.<br />
- People  have tried this with servers like apache<br />
- A reasonable thread count, of 20, will service 20 users<br />
- A better user count is a 1000 though<br />
- But a 1000 threads brings a system to its knees with context switches<br />
- No comet, just thrashing</p>
<p>Slide: Comet + threads != scalable<br />
- So use the little trick of omitting threads, and you&#8217;re golden<br />
- Build event-based servers<br />
- You don&#8217;t want your comet apps to be like nature preserves<br />
- You don&#8217;t want your app to be a lonely desert with the occasional wanderer<br />
- it should be a riot, with users tearing down the walls, sucking your resources dry, demanding more&#8230;</p>
<p>Slide: desert -> riot<br />
- So use event based programming for your comet server<br />
- And I guarantee, your app will be a riot, not a desert. </p>
<p>Slide: zzzz<br />
This is the easy problem<br />
The harder problem is the other &#8220;half&#8221; of scaling,</p>
<p>Slide: Horizontal Scalability<br />
- If one server supports 1000 users, does 2 support 2000? and n, n-1000?<br />
- This is a truly tough problem<br />
- Really though, it depends on the application<br />
- No one answer.<br />
- But a few core rules are in order<br />
- 1. Don&#8217;t share state between comet servers<br />
- 2. Only do Comet in the Comet server. no Pub/sub, no jabber/game server, no load balancing, just comet<br />
- 3. Treat comet as the last leg of the journey</p>
<p>Slide: Two Comet servers (sharded by user) doing pub sub (ajaxworld slide)<br />
- For some reason, comet servers are all trying to provide a pub/sub api<br />
- Developers like it, great.<br />
- But it was already a hard problem before Browser&#8217;s existed<br />
- And the people solving the problem, RabbitMQ/ActiveMQ, aren&#8217;t part of the comet community. (there have  been minor inroads)<br />
- Integrating streaming comet sith real publish/subscribe message queues would be great<br />
- But, thats just a specific case of a larger issue<br />
- The real issue with scaling comet applications is that<br />
     - Comet is difficult<br />
     - Comet imposes architectural constraints on web apploications that we aren&#8217;t used to (can&#8217;t do round robin balancing per http request)<br />
     - Its a moving part that has to be closely tied to the other pieces of the system<br />
- But integrating comet with existing technologies would allow us to solve the horizontal scaling problem however these existing technologies already solve it.<br />
- How could you scale a thick client deployment?<br />
- We want that to be the only question to answer when scaling a comet application.<br />
- So How do you integrate comet servers with X?</p>
<p><!-- (Part III - Integrating Comet - 10 Minutes) --></p>
<p>Slide: Offboard Comet integrated with Jabber<br />
- This is an example of how a typical comet server is integrated with jabber.<br />
- the browser maintains a connection with the comet server and the &#8220;bridge&#8221;<br />
- The bridge is an http server (hopefully event based as well!)<br />
- and also an xmpp client<br />
- and also a &#8220;Comet client&#8221; (dispatch protocol)<br />
- Message flow goes browser -> bridge -> jabber -> bridge -> comet -> browser</p>
<p>Slide: A lolcat tangled up<br />
- This is a bit of a mess<br />
- complex systems are hard to scale</p>
<p>Slide: previous slide (Offbard comet integrated with jabber)<br />
- you can&#8217;t scale this with your typical web load balancer<br />
- the mapping between comet servers, bridges, and xmpp servers are almost certainly not giong to be 1-1<br />
- so you have the complex task of figuring out load balancing between each part<br />
- and then you have to implement each client twice<br />
- once for the bridge, once for the browser<br />
- the bridge speaks xmpp to the jabber server, but json-chat (made up protocol) to the browser<br />
- Clearly not the solution&#8230;</p>
<p>Slide: Victory march picture, maybe the planting of the american flag in some battle<br />
- Standards save the day.<br />
- HTML5 has specified a TCPConnection standard for the browser</p>
<p>Slide: TCPConnection (word)<br />
- I&#8217;ve been working closely with whatwg/w3c to specify the protocol and api that solves all of our problems<br />
- tcpconnection is just like a socket, but for javsacript in browsers<br />
- It will<br />
    -traverse forward proxies<br />
    - speak ssl<br />
    - include cookies (auth integration)<br />
    - use a single socket for both directions<br />
    - revolutionize web applications<br />
- Think about it &#8212; tcp connections revolutionized network programming in the 70s.<br />
Slide: Iron Man screenshot during test sequence<br />
- tcp/ip. Thats how dad did it, thats how america does it, and its worked out pretty well so far<br />
- And we don&#8217;t even have to wait for browser vendors</p>
<p>Slide: The future is now (sci-fi-ish picture + words?)<br />
- Orbited provides a TCPConnection to all major browsers, today.</p>
<p>Slide: Browser < - > Comet Proxy < - > Jabber diagram<br />
- Orbited speaks comet transports on the front<br />
- and plain old tcp on the back<br />
- So you put it in front of ANY tcp server<br />
- and the browsers can interact as if they&#8217;d connected directly to the backend server over tcp.<br />
- and the server doesn&#8217;t need to be altered whatsoever.<br />
- No need for a bridge or dispatch protocol<br />
- Much less complex means easier to scale<br />
- Load Balancing?<br />
- We can simplify this picture still</p>
<p>Slide: Browser < - > ( comet Proxy + Jabber Diagram single machine)<br />
- Treat the comet proxy as part of the server<br />
- One comet proxy per backend server<br />
- Now you can all sigh in relief</p>
<p>Slide: Sigh of relief<br />
- Because Comet isn&#8217;t going to get in the way<br />
- Scaling Comet applications horizontally isn&#8217;t a twofold problem anymore<br />
- If you know how to scale a network application, then you can scale a comet application.</p>
<p>Slide: Jabber server cloud with half Comet proxies, half normal<br />
- And whats more, there&#8217;s no difference between the browser and the desktop</p>
<p>Slide: Auth + persistence (a pair of keys and some kind of storage)<br />
- There are a couple of details: authentication and persistence</p>
<p>Slide: Jabber server with comet proxy on left, web app on the right, sql server behind both<br />
- Just have the network server and the web app coordinate on the back end<br />
- put the sql server behind both<br />
- User creates an account over the web app<br />
- but can log in to jabber<br />
- jabber saves logs to the database<br />
- and the user can see those logs via the web app<br />
- And your problems are over.</p>
<p>Slide:Conclusion  (Bullseye (with orbited logo somewhere))<br />
- Transports are frustrating, but Orbited implements them (indeed, a number of projects take our implementation directly)<br />
- Vertical Scalability and threads don&#8217;t mix. Orbited use event-based network IO.<br />
- Horizontal scalability is tough because you have two problems.<br />
- If you can solve integration, then you can get a handle on horizontal scalability by normal means<br />
- TCPConnection is the perfect integration point. It works with all past, present, and future tcp/ip servers. Out of the box.<br />
- Orbited provides that functionality today.</p></blockquote>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F10%2Fcomet-presentation-at-myspace%2F&amp;title=Comet+Presentation+at+MySpace" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/10/comet-presentation-at-myspace/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Implementing a Bayeux to JMS Bridge</title>
		<link>http://cometdaily.com/2008/07/09/implementing-a-bayeux-to-jms-bridge/</link>
		<comments>http://cometdaily.com/2008/07/09/implementing-a-bayeux-to-jms-bridge/#comments</comments>
		<pubDate>Wed, 09 Jul 2008 20:46:00 +0000</pubDate>
		<dc:creator>JordiAlbornoz-Mulligan</dc:creator>
		
		<category><![CDATA[articles]]></category>

		<category><![CDATA[Comet]]></category>

		<category><![CDATA[dojo]]></category>

		<category><![CDATA[java]]></category>

		<category><![CDATA[jms]]></category>

		<category><![CDATA[open anzo]]></category>

		<category><![CDATA[openanzo]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=356</guid>
		<description><![CDATA[At the Open Anzo project, we're using Cometd Bayeux to expose JMS, the Java Message Service, to the browser.]]></description>
			<content:encoded><![CDATA[<p>At the <a href="http://www.openanzo.org/">Open Anzo project</a>, we&#8217;re using Cometd Bayeux to expose <a href="http://java.sun.com/products/jms/">JMS</a>, the Java Message Service, to the browser. The Open Anzo system is built around an asynchronous message-passing architecture. I&#8217;ll describe how we expose that functionality to browser clients with a Bayeux to JMS bridge built using dojox.cometd and Jetty&#8217;s Cometd implementation. JMS is interesting because its a widely supported mechanism of accessing message brokers. So bridging between Bayeux and JMS means easily tapping into such systems.</p>
<h2>Why Comet</h2>
<p>The Open Anzo project uses Comet to provide a unique programming model for data stored on a server. With Open Anzo, you can replicate chunks of data from a server to work with the data locally. Those replicas are automatically kept up-to-date via Comet messages sent whenever the data changes. This model lets the developer focus on working with the data rather than focusing on the requests and mechanisms for retrieving the data. Since Open Anzo implements this model using a message broker, we are able to extend the model to the web by building a Bayeux to JMS bridge.</p>
<h2>Nuts &#038; Bolts</h2>
<p>With a thin JavaScript object wrapper around Cometd and a small server side component, we are able to expose most of the basic JMS functionality to the browser. While we don&#8217;t expose every nuance of the JMS API, we can communicate with a JMS cloud as a full participant even from a browser. For our implementation we use <a href="http://activemq.apache.org/">ActiveMQ</a> as the message broker, which has its own <a href="http://activemq.apache.org/ajax.html">Comet bridge</a>. We chose to build our own bridge using Cometd Bayeux for its various advantages such as pluggable Comet transports and resiliency across transient network failures. Also, we need it to work with any other JMS message broker.</p>
<p>The core of the bridge implementation is the <a href="http://www.openanzo.org/projects/openanzo/browser/trunk/openanzo-repository/src/main/java/org/openanzo/server/combus/bayeux/BayeuxJMSBridge.java?rev=2660">BayeuxJMSBridge</a> server-side component. Its sits on a Jetty server instance and listens for Bayeux messages from clients and forwards the messages via JMS on behalf of the client. It also receives messages from the JMS cloud and then forwards them onto the interested clients as a Bayeux message. Browser clients use the <a href="http://www.openanzo.org/projects/openanzo/browser/trunk/openanzo-js/src/anzo/messaging/JMSClient.js?rev=2551">JMSClient</a> object to subscribe to JMS topics or to send messages to queues. For example:</p>

<div class="wp_syntax"><div class="code"><pre class="javascript"><span style="color: #006600; font-style: italic;">// Subscribe to a JMS topic</span>
anzo.<span style="color: #006600;">messaging</span>.<span style="color: #006600;">JMSClient</span>.<span style="color: #006600;">subscribeToTopics</span><span style="color: #009900;">&#40;</span><span style="color: #3366CC;">&quot;interestingTopic&quot;</span><span style="color: #339933;">,</span>
<span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>msg<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #006600; font-style: italic;">// msg.properties contains the JMS message properties</span>
    <span style="color: #006600; font-style: italic;">// msg.body contains the JMS message body</span>
    <span style="color: #006600; font-style: italic;">// ...</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#41;</span><span style="color: #339933;">;</span>
&nbsp;
<span style="color: #006600; font-style: italic;">// Send a request and expect a response.</span>
anzo.<span style="color: #006600;">messaging</span>.<span style="color: #006600;">JMSClient</span>.<span style="color: #006600;">publish</span><span style="color: #009900;">&#40;</span><span style="color: #009900;">&#123;</span> properties<span style="color: #339933;">:</span> <span style="color: #009900;">&#123;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span> body<span style="color: #339933;">:</span> <span style="color: #3366CC;">&quot;my request&quot;</span><span style="color: #009900;">&#125;</span><span style="color: #339933;">,</span>
<span style="color: #3366CC;">&quot;myDestination&quot;</span><span style="color: #339933;">,</span> <span style="color: #003366; font-weight: bold;">function</span><span style="color: #009900;">&#40;</span>msg<span style="color: #009900;">&#41;</span> <span style="color: #009900;">&#123;</span>
    <span style="color: #006600; font-style: italic;">// Work with response message...</span>
<span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span><span style="color: #009900;">&#125;</span></pre></div></div>

<p>Notice that the &#8216;publish&#8217; method supports <a href="http://cometdaily.com/2008/05/15/the-many-shades-of-bayeuxcometd-2/">request/response</a> style interactions. Internally, the JMSClient object will add a randomly generated &#8220;correlation id&#8221; to the message and save the given callback function mapped to that id. Then, whenever a message arrives on a Bayeux channel on the client, we check if it contains a correlation id. If so, we look up the corresponding callback and invoke it with the newly arrived response message. This is all transparent to the client. It simply knows that it has sent a message and its callback is eventually called with the appropriate response message. The difference between a PubSub message and a request/response message is simply that a request/response message contains a correlation id. </p>
<p>Whenever a browser client connects to the bridge, a new JMS temporary topic is created on behalf of that client. That is where messages bound only for that specific user will be sent. Each such topic is mapped to a Bayeux channel for the specific user (ex. &#8220;/anzo/user/myUser/34xWtez-i&#8221;). To make sure that only the intended client can subscribe to that client-specific Bayeux channel we plug in an implementation of &#8216;dojox.cometd.SecurityPolicy&#8217;.</p>
<h2>Future Enhancements</h2>
<p>For private request/response messages we create a Bayeux channel per user. We might consider a less resource intensive approach as <a href="http://cometdaily.com/2008/05/15/the-many-shades-of-bayeuxcometd-2/">Greg Wilkins describes</a>. Also, JMS message brokers provide various quality of service guarantees but, with our implementation, those guarantees aren&#8217;t preserved between the browser and the bridge. We will explore some of the many methods to add service guarantees to Comet.</p>
<h2>Conclusion</h2>
<p>With Comet, Open Anzo is able to provide a powerful model for manipulating data on the web. Having small local replicas of data automatically kept up-to-date lets developers focus on rendering and using the data rather than building APIs to get at it. And by tapping into JMS-based infrastructure we make the browser a full participant in an asynchronous message passing architecture.</p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F09%2Fimplementing-a-bayeux-to-jms-bridge%2F&amp;title=Implementing+a+Bayeux+to+JMS+Bridge" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/09/implementing-a-bayeux-to-jms-bridge/feed/</wfw:commentRss>
		</item>
		<item>
		<title>Comet Chat with Rupy</title>
		<link>http://cometdaily.com/2008/07/08/comet-chat-with-rupy/</link>
		<comments>http://cometdaily.com/2008/07/08/comet-chat-with-rupy/#comments</comments>
		<pubDate>Tue, 08 Jul 2008 07:47:53 +0000</pubDate>
		<dc:creator>DylanSchiemann</dc:creator>
		
		<category><![CDATA[Musings]]></category>

		<category><![CDATA[chat]]></category>

		<category><![CDATA[java]]></category>

		<category><![CDATA[rupy]]></category>

		<guid isPermaLink="false">http://cometdaily.com/?p=352</guid>
		<description><![CDATA[In my recent review of Comet projects hosted by Google code, I ran across Rupy, which recently added a Comet chat demo.]]></description>
			<content:encoded><![CDATA[<p>In my recent review of Comet projects hosted by Google code, I ran across <a href="http://code.google.com/p/rupy/">Rupy</a>, which recently added a Comet <a href="http://group.rupy.se/talk.html">chat demo</a>, also known as the Hello World of Comet.</p>
<p>Rupy takes an interesting approach with a very very tiny Java server implementation.  Even if Java is not your server-side language of choice, it&#8217;s worth taking a look:</p>
<blockquote><p>
Weighing less than 50KB, rupy is probably the smallest Java NIO HTTP server in the world.</p>
<p>Rupy is inherently non-blocking asynchronous, which makes it the ideal candidate for high concurrency real-time applications pushing dynamic data.</p>
<p>Tested with acme, rupy performs on average ~1500 requests per second. To put that figure in perspective; acme doesn&#8217;t use keep-alive, so that means 1500 unique TCP connections serving dynamic content per second! Thanks to NIO and an event queue to avoid selector trashing, this figure degrades gracefully under high concurrency.
</p></blockquote>
<p>In the succinct words of Rupy project lead Marc Larue that help define what Comet is really all about:</p>
<blockquote><p>
As for a starting point I think that there is a bigger picture to the new-wave of web techniques that fueled rupy&#8217;s creation.</p>
<p>Comet and REST both have simplicity as the common energy source, after all HTTP is just TCP and web-services being over-engineered is an understatement.
</p></blockquote>
<p><img src="http://cometdaily.com/wp-content/uploads/2008/07/picture-79.png" alt="Firebug Output for Rupy Chat App" title="Rupy Request Traffic" width="499" height="115" class="alignnone size-full wp-image-353" /></p>


<span class="slashdigglicious">
<a href="http://slashdot.org/bookmark.pl?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Slashdot It!"><img src="http://slashdot.org/favicon.ico" height="16" width="16" alt="[Slashdot]" /></a>
<a href="http://digg.com/submit?phase=2&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Digg This Story"><img src="http://digg.com/favicon.ico" width="16" height="16" alt="[Digg]" /></a>
<a href="http://reddit.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Reddit"><img src="http://reddit.com/favicon.ico" width="16" height="16" alt="[Reddit]" /></a>
<a href="http://del.icio.us/post?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Save to del.icio.us" onclick="window.open('http://del.icio.us/post?v=4&amp;noui&amp;jump=close&amp;url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy', 'delicious', 'toolbar=no,width=700,height=400'); return false;"><img src="http://images.del.icio.us/static/img/delicious.small.gif" width="16" height="16" alt="[del.icio.us]" /></a>
<a href="http://www.facebook.com/share.php?u=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F" title="Share on Facebook"><img src="http://www.facebook.com/favicon.ico" width="16" height="16" alt="[Facebook]" /></a>
<a href="http://technorati.com/faves?add=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F" title="Add to my Technorati Favorites"><img src="http://technorati.com/favicon.ico" width="16" height="16" alt="[Technorati]" /></a>
<a href="http://www.google.com/bookmarks/mark?op=edit&amp;output=popup&amp;bkmk=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Save to Google Bookmarks"><img src="http://www.google.com/favicon.ico" width="16" height="16" alt="[Google]" /></a>
<a href="http://www.stumbleupon.com/submit?url=http%3A%2F%2Fcometdaily.com%2F2008%2F07%2F08%2Fcomet-chat-with-rupy%2F&amp;title=Comet+Chat+with+Rupy" title="Stumble it!"><img src="http://www.stumbleupon.com/favicon.ico" width="16" height="16" alt="[StumbleUpon]" /></a>
</span>]]></content:encoded>
			<wfw:commentRss>http://cometdaily.com/2008/07/08/comet-chat-with-rupy/feed/</wfw:commentRss>
		</item>
	</channel>
</rss>
