13
Jan
11

Twitter News Backend

Well, put this one down in the “too obvious to occur to us” category:

Using Twitter as a Backend(!)

Do you need a simple news feed for your application? You could probably rent a piece of server and code something in PHP, Ruby or Python, you could for example use google app engine as your backend.

But did you think about using Twitter?

No. No, we’ve implemented custom server managed news feeds, RSS news feeds, and probably half a dozen others that escape us at the moment … but using Twitter, that never occurred to us. And now that we think about it, there’s no functionality our various news implementations provided that couldn’t have been shoehorned into tweets. And the savings in coding time and management time, why yes indeed those are decidedly non-trivial. Next time the question of a news feed comes up, you can be sure that this will be the first suggestion we throw out, yes indeed it will.

And as a nice piece of synchronicity with that idea, we just noticed the availability of an open source Twitter client which looks quite well suited to this application:

… This time, we extended the functionality of the Twitter client with (1) a parser for Tweets and (2) the follower list.

The Twitter Parser looks for occurrences of special Tweets, which describe Service requests which occur in Tweetflows. Internally, the Twitter Parser uses regular expressions that describe the patterns which are searched for. If a Tweet matches the regular expression, the result is encapsulated in the TweetParserResult. We trigger the Tweet parser as soon as the delegate method statusesReceived of the Twitter Engine is called…

So there you go, then, save yourself a bunch of effort next time you want to put a news feed in an app!

h/t: @coffeedan, iphonesdk!


3 Responses to “Twitter News Backend”


  1. 1 Thud Jan 14th, 2011 at 3:40 am

    Maybe for something smallish, but if I have business relying on it I’m not sure I want to anagrammatically tie my communication to something that failwhales quite so often.

  2. 2 Alex Jan 14th, 2011 at 7:34 am

    I suppose I wouldn’t architect a real time game around it no, but for most news feed type features — at least the ones we’ve done — announcements like ‘download our new version’ aren’t so delivery sensitive that the occasional outage is a dealbreaker. Not when the price and speed advantages are taken into account, anyways.

  1. 1 Tweets that mention Twitter News Backend at Under The Bridge -- Topsy.com Pingback on Jan 14th, 2011 at 4:53 am

Leave a Reply