poll, ping, pubsub, pubsubhub, pubsubhubbub

September 6, 2009 by · 5 Comments
Filed under: technology 

In case you are skeptical, there is a method in the madness above, in the title of the post. In tech circles it is unlikely that you haven’t heard of pubsubhubbub. In fast few months, it has been one of the top three talked about things. Other two being homomorphic encryption and Google wave[ 1.]. Coming back to current post – terms in the title indicate how you get the contents from other people. Following details become more clear, if you imagine things happening with respect to blogs, even though they are conceptually not restricted to blogs.

Polling refers to the scenario where clients keep asking the server if something new has come up. How often to ask for updates will always be a problem with polling too frequent or too infrequent, but as one reader pointed out here that one great , thing with polling is that server doesn’t have to maintain state.

Ping refers to the case where when post an article, you(or your software) also updates some popular (central) update services. Some background here.

Next is pubsub which stands for publish/subscribe , one of the earliest pitch for it was made here by Evan Henshaw-Plath and Kellan Elliott-McCrea (72 slides but worth going through). Compelling example they gave against was this – on a particular date, Friendfeed crawled Flickr 2.9 million times to get the latest photos of 45,754 users, of which 6,721 had visited Flickr in those 24 hrs and could have ‘potentially’ uploaded a photo . Note that what they proposed was not a new technology, as they point out ‘revolutionary new 20 year old technology’ . If you do it for blogs then one of the major problems with xmpp – presence data overhead, which may be as high as 60-70 % can be reduced a lot.

pubsubhub stands for publish subscribe hub and pubsubhubbub is a protocol , core of which is idea of pubsubhub. Wherein publishers(say bloggers) update the hub which(may be more than one hubs, which talk to each other) resides ‘somewhere in cloud’, as per protocol this can be push or pull as per the protocol but the next link in the chain, hub to client(say readers) it is always push model. This page is good starting point for pubsubhubbub, overview slides are good. Ever eloquent Anil Dash describes it here as pushbutton web.
Two other related reads are webhooks which is basically http callbacks. Github uses it, so does paypal for asynchronous notifications of payment in ipn.So do many others. Related concept is rsscloud which is again pubsub hub. Follow this link for details.

You might be wondering what is the point of writing all these here, there are two 1. These things are worth knowing, minimally at least and 2. This blog is pubsubhubbub enabled now via appspot hub using this wordpress plugin and feed too is pubsubhubbub enabled via feedburner, link here

[1]. – Good introductory read for fully homomorphic encryption is this article by Bruce Schneier and this talk is more or less only source for Google wave.

-UPDATE – This post explains how the requirement of public server for callback can be worked around for desktop clients by using xmpp gateway(for pubsubhubbub).

  • Recent Posts