Hey OB1,

The spec makes it pretty clear that hubs should subscribe to the self url,
rather than the 'location" url. This way you do not have the problem of
matching one to the other (because you only consider the self url). If the
self is missing, then, use the "location"... but that should fix the issue
at least any Atom feed and a lot of RSS2.0 feeds.

Additionally, it's good practice to use different callbacks for each feed,
which means that the callback url actually allows you to identfiy the feed,
without even parsing the content of the notification. It's quite common to
see people using some kind of internal id for the feed in the callback
http://domain.tld/feed/123 for feed 123 and http://domain.tld/feed/124 for
feed 124... etc. Some people do also use the encoded feed URL as a query
param (that works too, but makes the callback urls much longer).

Cheers,






--
Julien Genestoux,
http://twitter.com/julien51

+1 (415) 830 6574
+33 (0)9 70 44 76 29



On Fri, Dec 17, 2010 at 10:46 PM, ob1 <[email protected]> wrote:

> Here's an observation.
>
> I'm finding that in the wild, many advertised feed URLs do not match
> the "self link" URL contained in the feed content.
>
> E.g. My own PSHB enabled toy blog advertises the URL as
> http://pushituphill.blogspot.com/feeds/posts/default
> However in the feed content I find <link rel='self' type='application/
> atom+xml' href='http://www.blogger.com/feeds/51568063726361007/posts/
> default'/>
>
> This causes me a minor problem for content distribution, since the
> feed URL from the content doesn't match with the feed URL that was
> passed to the hub.
> My immediate thought was that it would be nice if the PSHB protocol
> would pass me back the subscription URL, however,  I can see that this
> wouldn't work for multiple content distribution.
>
> I currently have two solutions, that fit with the protocol.
> 1) Include the subscription URL as a parameter in the callback URL.
> This way I'm passed it back as a parameter.
> 2) Always subscribe using the URL from the feed content rather than
> the advertised URL. However sometimes these are no existent or wrong!
>
> Just an observation.
> Keep pushing on...

Reply via email to