Post image for PubSubHubbub + Wordpress + Feedburner + FriendFeed = Realtime Awesomeness

PubSubHubbub + Wordpress + Feedburner + FriendFeed = Realtime Awesomeness

by Jorge Escobar on July 27, 2009

PubSubHubbub is a fancy name for a rather new protocol being promoted by various services like FriendFeed, which allows you to receive updates of RSS feeds without polling.

Basically it will allow blogs and readers to communicate real time, in a push-like method, like instant messaging, and not via pulls like the way it happens now, which can take minutes or even hours (for an explanation of push and pull technologies, you can read my previous post about it).

The cool thing about PubSubHubbub is that it works on top of existing protocols (in this case Atom) so readers and source don’t have to change much. The only thing you need is to notify a server that you published and the clients have to be subscribed to that server. Dave Winer has a good, deeper, explanation of how it works.

In this tutorial I will show you how to implement PubSubHubbub in a self-hosted installation of Wordpress, using Feedburner for feed distribution and FriendFeed as the receiving client. With this system in place, your blog posts will appear in your FriendFeed in a matter of seconds.

Let’s start with Wordpress. You need to make sure that your auto-discovery RSS feed is pointing to feedburner instead of your own blog’s feed.

The way to check for that is to do a view source of your blog. On the header, you must see this:

<link rel=”alternate“ type=”application/rss+xml“ title=”jungleG RSS Feedhref=”http://feeds.feedburner.com/jungleg” />

Be careful, as some themes do not handle this properly, so you might need to manually edit the “header.php” or similar template and hardcode the Feedburner address.

I use a plugin to handle all my Feedburner chores called FD Feedburner.

Even though my blog’s feed is located at jungleg.com/feed, I don’t want the services to subscribe to this, as Wordpress won’t be able to ping the clients subscribed to the blog. We want to leave that to Feedburner, which has implemented this properly.

For the images on your blog to show up in FriendFeed, I have enabled the MediaRSS plugin, but that might not be necessary, as Feedburner pulls those fine. But if images aren’t showing up for you, try installing it.

We now move to Feedburner. Make sure you have the Ping Shot option checked:

feedburner-pingshot

This allows Feedburner to ping FriendFeed or any other subscribers that you have posted new content.

Last, but not least, you will need to configure FriendFeed. What you want to do is setup your feed to point to the Feedburner RSS feed URL (in my case http://feeds.feedburner.com/jungleg) and not your regular blog URL or regular feed URL. That way FriendFeed is directly pinged by Feedburner instead of waiting for our blog to do so, which as I said earlier won’t work.

If you want the excerpts to show, you might want to setup your feed as a Custom RSS/Atom feed and check the ”Include entry description as a comment” option (thanks Ivan for the tip).

You’re all set. You should now be able to see your posts come up in FriendFeed as soon as the Wordpress Cron (wp-cron) process is run by your blog. This might be immediate or take a minute or two to be triggered (if you’re seeing your apache logs real time, you’ll something come up like the line below (click on the line to see it in full).

wp-cron

I want to give a special thanks to Brett Slatkin for always being there for me throughout this process.

Now let’s see how this post goes up realtime on FriendFeed.

17 Comments 22 Tweets 11 Other Comments

{ 8 trackbacks }

PubSubHubbub – revjim.net
August 5, 2009 at 10:32 pm
The Pushbutton Web Now In Google Reader | Lifehacker Australia
August 6, 2009 at 1:17 am
The Pushbutton Web Now in Google Reader [Google Reader] - Kikil News
August 6, 2009 at 1:30 am
stories of a neuromancer » Blog Archive » Realtime Awsomeness in my Blog
August 6, 2009 at 9:27 am
Trying stuff out (you can ignore this) | Paul Jacobson
August 9, 2009 at 10:25 am
Lifestream events for August 23rd « mvalente.eu/mv.*
August 23, 2009 at 5:03 pm
Wochenschau Folge 15: Beginn der neuen Saison mit Facebook, Internet Manifest, RSSCloud und mehr
September 16, 2009 at 2:57 am
In My Life » PubSubHubbub – instant blogging?
December 17, 2009 at 2:59 pm

{ 50 comments… read them below or add one }

Brett Slatkin July 27, 2009 at 2:41 pm

Great how-to guide on using WordPress, FeedBurner, and PubSubHubbub together.

This comment was originally posted on FriendFeed

Reply   More from author

Josh Fraser July 27, 2009 at 3:00 pm

Great post and explanation of PSH. I also wrote a WP plugin for anyone who wants to publish directly to a hub without relying on Feedburner. You can check it out here:

http://wordpress.org/extend/plugins/pubsubhubbub

Reply   More from author

Holden July 27, 2009 at 3:24 pm

you share jungleg so much I am gonna give them a look

This comment was originally posted on FriendFeed

Reply   More from author

Dave Hodson July 27, 2009 at 3:27 pm

@Louis – what I am missing here? He justs points everything to Feedburner and turns on Pingshot??

This comment was originally posted on FriendFeed

Reply   More from author

Louis Gray July 27, 2009 at 3:43 pm

Holden, Jungleg is a great blog. Dave, if you are a FeedBurner user, turn on Pingshot, which notifies many services at once and supports Pubsubhubbub. I have this enabled as well.

This comment was originally posted on FriendFeed

Reply   More from author

Jorge Escobar July 27, 2009 at 3:50 pm

@Dave, what looks really easy for some, may be difficult for others. I am a coder with many years of web experience and even I had a hard time making all the pieces work. Thanks Louis for the constant support, BTW!

This comment was originally posted on FriendFeed

Reply   More from author

Dave Hodson July 27, 2009 at 3:55 pm

@Jorge – exactly my point, as in, "hey this is freaking easy"!

This comment was originally posted on FriendFeed

Reply   More from author

Bwana July 27, 2009 at 4:21 pm

My latest post took 2 minutes to show up… pubsubhub still has a ways to go, but it’s a good start

This comment was originally posted on FriendFeed

Reply   More from author

Brett Slatkin July 27, 2009 at 4:25 pm

Bwana: What’s the burned feed url? I can try to help debug from the FeedBurner Hub’s viewpoint. Otherwise, be sure to check your Apache logs. The WordPress cronjob can be very slow sometimes, taking quite a while before it actually sends the pings.

This comment was originally posted on FriendFeed

Reply   More from author

Jorge Escobar July 27, 2009 at 4:32 pm

Bwana: Indeed, the lag is usually the wp-cron script that might be set to run every 2 – 3 minutes. Per my post, the moment this cron runs and notifies Feedburner there’s new content, FriendFeed publishes immediately.

This comment was originally posted on FriendFeed

Reply   More from author

Bwana July 27, 2009 at 4:52 pm

I’ll check my cron

This comment was originally posted on FriendFeed

Reply   More from author

Samuel Wood July 28, 2009 at 9:49 am

I should write up an article on how to do this sort of thing without FeedBurner. It’s possible, you just need a bit of extra software.

This comment was originally posted on FriendFeed

Reply   More from author

Samuel Wood July 28, 2009 at 9:50 am

Oh, also, on your article, your "check" value is exposed on the wp-cron.php call. You should blur that out, the check variable is supposed to be private. It’s there to prevent a possible DOS attack against your site.

This comment was originally posted on FriendFeed

Reply   More from author

Brett Slatkin July 28, 2009 at 9:51 am

Indeed, you can use PubSubHubbub directly if you don’t use FeedBurner. There’s already a plug-in here that works with WordPress: http://wordpress.org/extend/plugins/pubsubhubbub/

This comment was originally posted on FriendFeed

Reply   More from author

Jorge Escobar July 28, 2009 at 9:53 am

@Samuel thanks

This comment was originally posted on FriendFeed

Reply   More from author

Julien July 28, 2009 at 10:13 am

An this will not only help FriendFeed, but also Superfeedr and any other service. By the way, how many hubs do you reference, and which ones?

Reply   More from author

dashes.com/anil/ August 6, 2009 at 12:54 am

Aw, you’re too kind! I am excited about this evolution for Reader, but in looking at Chrome’s bookmark synching, I find myself wishing it was using PSHB tech instead of XMPP. That way I could start to use (for example) sharing links in Reader as a way to add bookmarks to my Chrome bookmark list. Right now, the XMPP-based synching system just isn’t that hackable.

I wonder if we can convince Google to collaborate internally by talking to them from the outside.

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

Gina Trapani August 6, 2009 at 1:15 am

I wonder if we can convince Google to collaborate internally by talking to them from the outside.

Sounds like a challenge worth taking on!

So both Wave and Chrome bookmark synching use XMPP to avoid polling. Hmm. Would Brad go to bat for PSHB support in Chromium? I may have to fly up to 6A’s office tomorrow for the meetup to ask him!

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

google.com/accounts/o8… August 6, 2009 at 1:57 am

Anil: Collaboration like that sounds good to me. =)

Gina: Please contact me if you’re seeing any issues with Reader to FriendFeed updates. It’s working great for everyone I’ve been talking to. Perhaps there’s something funny about your setup? Let’s get to the bottom of it!

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

Gina Trapani August 6, 2009 at 2:42 am

Thanks Brett!

FriendFeed. Both are super-fast.

It’s Smarterware posts showing up immediately in Google Reader that doesn’t seem to happen for me (like in the CrunchUp demo). But I’m not clear about whether or not GReader has full-on hub/subscriber support built-in (yet).

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

google.com/accounts/o8… August 6, 2009 at 3:09 am

Ah okay great, happy it’s working! Otherwise, what you say here makes sense. At the CrunchUp we showed a prototype of Reader as a full Hubbub subscriber. This feature does not yet exist in the Reader that everyone out there uses. So that’s the source of the confusion. Obviously, we’d like Reader to fully support subscription for all feeds on all hubs out there. We’ll get there!

(also, sorry for my awful open ID url… another thing that needs to be fixed)

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

Robert Higgins August 6, 2009 at 5:29 am

nice cant wait till i have a moment to spare to do this

This comment was originally posted on FriendFeed

Reply   More from author

Scott of Two Countries August 6, 2009 at 5:47 am

I’m using WP SUP right now. Is there any reason to switch from that to PubSubHubbub?

This comment was originally posted on FriendFeed

Reply   More from author

Samuel Wood August 6, 2009 at 9:12 am

PubSubHubbub is more generic than WP-SUP (which is basically FriendFeed specific). Any system can use PubSubHubbub.

This comment was originally posted on FriendFeed

Reply   More from author

Brett Slatkin August 7, 2009 at 10:48 am

Wooh! Very cool! Happy it’s working for you.

This comment was originally posted on http://revjim.net/)“>revjim.net

Reply   More from author

Jim Reverend August 7, 2009 at 10:48 am

I’m not entirely sure that you care, either. I think it’s quite nice to see feeds update in my Google Reader and on Friend Feed mere seconds after authors hit the publish button. I’d like it a lot if your feed did that too.

This feature is more for your readers/feed consumers than it is for you.

I’m using the FD Feedburner plug in and some feedburner features to take care of the two small tasks involved with enabling PubSubHubbub. But, it could just as easily be done manually. It really requires very little from the publisher. It’s the Hub and the consumers that have to change things. And, thankfully, those bits have been done for us.

This comment was originally posted on http://revjim.net/)“>revjim.net

Reply   More from author

FarrisGoldstein August 7, 2009 at 10:48 am

I’ve read a bunch of HubBub about this, but still don’t really know if I care. You know me better than most on the webzisses. Do I need to use this, or will it eventually just use me?

This comment was originally posted on http://revjim.net/)“>revjim.net

Reply   More from author

Jonathan August 9, 2009 at 7:35 pm

For people using WordPress without Feedburner, there’s a plugin that will enable this on your blog: http://wordpress.org/extend/plugins/wp-pubsubhubbub/

This comment was originally posted on http://smarterware.org/)“>Smarterware

Reply   More from author

Chris August 23, 2009 at 9:28 am

Newbie, I set this up (correctly I believe) w/ Blogger, Feedburner, and Friendfeed (tried Google reader but then read pubsub is not supported yet). So far seeing response times of 17 and 10 minutes to see my blog updates in my FriendFeed. Is this normal at this early stage or do I need to tweak?

Reply   More from author

Chris August 23, 2009 at 6:34 pm

Last test came in at 45 seconds, not sure what was going on earlier with the 17 and 10 min response times but I did not change a thing

Reply   More from author

Leave a Comment

Additional comments powered by BackType

Previous post:

Next post: