<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Notifications and Subscriptions</title><link>http://blogs.msdn.com/liveframework/archive/2009/04/16/notifications-and-subscriptions.aspx</link><description>In this post, we will explain how to make use of notifications in the Live Framework. When you subscribe to a specific resource, the Live Framework provides notifications when changes are made to that resource. This allows you to optimize interactions</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>Dew Drop - April 17, 2009 | Alvin Ashcraft's Morning Dew</title><link>http://blogs.msdn.com/liveframework/archive/2009/04/16/notifications-and-subscriptions.aspx#9554179</link><pubDate>Fri, 17 Apr 2009 15:36:01 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9554179</guid><dc:creator>Dew Drop - April 17, 2009 | Alvin Ashcraft's Morning Dew</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://www.alvinashcraft.com/2009/04/17/dew-drop-april-17-2009/"&gt;http://www.alvinashcraft.com/2009/04/17/dew-drop-april-17-2009/&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: Notifications and Subscriptions</title><link>http://blogs.msdn.com/liveframework/archive/2009/04/16/notifications-and-subscriptions.aspx#9554609</link><pubDate>Fri, 17 Apr 2009 23:40:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9554609</guid><dc:creator>Oran</dc:creator><description>&lt;p&gt;Nice concise post. &amp;nbsp;I think the choice of JSON for the examples helps to make it easy to read and understand.&lt;/p&gt;
&lt;p&gt;Even though I wrote a lengthy post exploring how notifications work, I learned some new things from this post. &amp;nbsp;I learned that I can rely on the ETag returned by a new subscription to detect changes. &amp;nbsp;I also learned that notification queues can overflow, and that you can create a new queue by PUTing the watermark to a dead queue.&lt;/p&gt;
&lt;p&gt;I think it's important to mention that in steps 3 and 6, the Notifications GET request will park on the server for 25 to 30 seconds before returning with an empty feed. &amp;nbsp;In my opinion, request parking is the coolest feature of notification queues. &amp;nbsp;However, the same request to the local LOE will return immediately. &amp;nbsp;In the case of the cloud LOE, the potential 30-second interval needs to be taken into consideration when renewing the queue based on its TTL. &amp;nbsp;In the case of the local LOE, the immediate return means that, unlike the cloud LOE, you can't afford to poll the local LOE's queue in a tight loop.&lt;/p&gt;
&lt;p&gt;The 300-second default queue ExpirationDuration is true for the cloud LOE. &amp;nbsp;The local LOE's default is 600 seconds.&lt;/p&gt;
&lt;p&gt;The first paragraph in step 2 is unclear to me. &amp;nbsp;It makes more sense to me if the word &amp;quot;from&amp;quot; is changed to &amp;quot;using&amp;quot;.&lt;/p&gt;
&lt;p&gt;I take issue with the ability to create a new queue by PUTing the AllSubscriptionsLost watermark to a dead queue. &amp;nbsp;Perhaps there's a good reason to use PUT to create a new queue, but I don't see it. &amp;nbsp;This is a weird way to use HTTP, and the behavior is unexpected and inconsistent. &amp;nbsp;First, the PUT response's Content-Location header contains the original queue's URI which doesn't match the response's SelfLink URI. &amp;nbsp;Second, the queue at the original URI remains dead, you must use the new SelfLink to access the new queue. &amp;nbsp;SelfLinks should remain stable. &amp;nbsp;SelfLinks most certainly shouldn't change as the result of a PUT, especially when the SelfLink in the request is unchanged. &amp;nbsp;I believe it is much simpler to just POST a new queue when you receive AllSubscriptionsLost. &amp;nbsp;The effect is the same, the behavior is more consistent and predictable, and you can delete the weird POST-tunneled-through-PUT logic.&lt;/p&gt;
&lt;p&gt;This post doesn't mention the 10-notification paging limit. &amp;nbsp;In practice, users will run into the paging limit long before they run into lost notifications due to queue overflow. &amp;nbsp;Still, I fully agree that users should make it a practice to always post the latest watermark which will make both of these limits irrelevant.&lt;/p&gt;
&lt;p&gt;Hopefully this comment doesn't come across as unnecessarily critical. &amp;nbsp;Over all, this is a great post describing a great feature. &amp;nbsp;I would definitely point people here first to learn more about notifications, and then point them to my own post. :-)&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://orand.blogspot.com/2009/03/exploring-live-framework-notifications.html"&gt;http://orand.blogspot.com/2009/03/exploring-live-framework-notifications.html&lt;/a&gt;&lt;/p&gt;
</description></item></channel></rss>