Examples using SUP?

1 view
Skip to first unread message

jamescrowley

unread,
Sep 17, 2009, 4:13:33 AM9/17/09
to contextvoice-dev
Hi everyone,

Does anyone have any examples using SUP? (Simple Update Protocol). I
think I understand how it works to notify a provider of an update, but
how do I set up a URL so I get those notifications myself? (so
ContextVoice will ping me, so to speak).

Also, is there any way to limit it to the set of URLs that I have
submitted to ContextVoice? Or is that a commercial only feature?

Many thanks

James

Bogdan Sandulescu

unread,
Sep 17, 2009, 6:02:01 AM9/17/09
to contextv...@googlegroups.com
Hi James,

On Thu, Sep 17, 2009 at 11:13 AM, jamescrowley <james....@gmail.com> wrote:

Hi everyone,

Does anyone have any examples using SUP? (Simple Update Protocol). I
think I understand how it works to notify a provider of an update, but
how do I set up a URL so I get those notifications myself? (so
ContextVoice will ping me, so to speak).

I can provide a simple example for using SUP. Assuming you are interested in a number of conversations stored in your system you check the CV SUP every minute (every "period" from the JSON response) and for each resource ID (You should POST the conversations that you are interested in to CV and retrieve the ID of the conversation and store that in your database) you see if you are interested in the updates.

If you are interested in the updates for http://uk.techcrunch.com/2009/08/19/greactions-shows-blog-comments-right-inside-google-reader/ (this conversation has the id ce118870c21c80701e9dbcd42dd2fad8) and the SUP file contains this id, then you should get the newest reactions from the reactions endpoint using the since argument.

* At this moment we are not pushing data to the client.
 

Also, is there any way to limit it to the set of URLs that I have
submitted to ContextVoice? Or is that a commercial only feature?

Yes, this is a commercial feature at this moment as it is a resource intensive process. If this feature is important to you tell us a little bit more about your application and the amount of data your are tracking (ping us at he...@contextvoice.com and we'll make you an offer :) ) .For a small/medium database the approach described above should work pretty well. If queries to find if any of the ids from the SUP file are in your database take too long consider using a key/value database (even memcache could work).
 

Many thanks

James


Bogdan

James Crowley

unread,
Sep 17, 2009, 6:26:15 AM9/17/09
to contextv...@googlegroups.com
Hi Bogdan,

Thanks for the info. I'll get in touch off-list to discuss further.

James

2009/9/17 Bogdan Sandulescu <bogd...@gmail.com>:
--
James Crowley
Managing Director
Developer Fusion - Connecting developers worldwide

Developer Fusion Ltd | 58 Sandringham Close | Enfield, EN1 3JH
mob: 07986 624128 web: http://www.developerfusion.com/
Reply all
Reply to author
Forward
0 new messages