If anyone comes across similar problems, the issue has now been
solved. Basically, it turns out the Java implementation provided on
Google Code hadn't actually been tested with the appspot hub and it
didn't work properly.

So, the problem was that the callback URL must end with a slash,
otherwise it leads to a redirect of the requests from the hub (to the
address with the slash), it's something to do with the way that the
Jetty handlers work. Similar issue is described here:
http://comments.gmane.org/gmane.comp.java.jetty.support/9936

Now, the PubSubHubbub specification says: "The hub MUST consider all
other subscriber response codes as failures; that means subscribers
MUST not use HTTP redirects for moving subscriptions." So basically if
there is a redirect, the appspot hub discards the request it has sent
and that's why I wasn't receiving anything.

The bug has now been fixed in the Subscriber code.
http://code.google.com/p/pubsubhubbub-java/source/detail?r=51


On Jun 21, 10:50 am, Lucie <[email protected]> wrote:
> Now, fixed the firewall issue and I still have the same problem. Still
> can't verify my subscriptions.
>
> My POST request looks something like this:
>
> header: application/x-www-form-urlencoded
> body: hub.callback=http://<machine-name>.doc.res.ic.ac.uk:8082/
> push&hub.mode=subscribe&hub.topic=http://pubsubhubbub-example-
> app.appspot.com/feed&hub.verify=sync
>
> I keep getting 409 Conflict.
>
> The same thing happens even if I use the 
> websitehttps://pubsubhubbub.appspot.com/subscribe
> and enter the parameters for the POST request I am using
> Callback: (the subscriber URL) 
> http://<machine-name>.doc.res.ic.ac.uk:8082/push
> Topic: (the feed URL)http://pubsubhubbub-example-app.appspot.com/feed
> Verify type: Synchronous
> Mode: Subscribe
>
> I get "Error trying to confirm subscription"
>
> My subscriber is simply not receiving any GET request from the hub. If
> I put the callback URL into a browser & hit enter, I receive a GET
> request at the subscriber, so it's definitely listening for requests.
>
> Is there something wrong with the parameters of the POST request?
>
> On Jun 13, 4:47 pm, Lucie <[email protected]> wrote:
>
>
>
>
>
>
>
> > I think I figured it out now, it was a firewall issue. My webserver
> > was not visible to the outside world because my college only allows me
> > to use ports 5500 - 5600. The appspot hub only allows ports '80',
> > '443', '4443', '8080', '8081', '8082', '8083', '8084', '8085', '8086',
> > '8087', '8088', '8089', '8188', '8444', '8990' -- all of which are
> > blocked by my college firewall so that's why I wasn't getting anything
> > back from the hub when I tried to use 8080.
>
> > Lucie J.
>
> > On Jun 13, 10:22 am, Lucie <[email protected]> wrote:
>
> > > The sync error -- 409 just says "Conflict"
>
> > > On Jun 13, 3:04 am, Julien Genestoux <[email protected]>
> > > wrote:
>
> > > > Lucie,
>
> > > > I'm not so sure about the implementation of the Google hub, but :
> > > > - you will always get 202 with async.
> > > > - the hub should actually return 422 for sync on errors. Have you 
> > > > checked
> > > > the body of the response.
>
> > > > Also, please post your request here, so we can help you debug.
>
> > > > Thanks,
>
> > > > On Fri, Jun 10, 2011 at 3:43 PM, Lucie <[email protected]> 
> > > > wrote:
> > > > > Hi guys,
>
> > > > > I'm beginner with Pubsubhubbub so excuse me if this is a dumb
> > > > > question.
> > > > > I have a subscriber that subscribes to feeds on
> > > > >http://pubsubhubbub.appspot.com
>
> > > > > When I use the sync mode I always get 409, when I use async I get
> > > > > 202 ... so I figured the subscription request is received by the hub
> > > > > but then I am never getting the verification request back from the
> > > > > hub?
>
> > > > > I've checked onhttp://pubsubhubbub.appspot.com/subscribeanditfinds
> > > > > my subscription but says
> > > > > state:  not_verified
> > > > > Confirmation failures:  4
>
> > > > > Any ideas? As far as I can see my callback server is running fine
> > > > > (i.e. when I open the callback url in my browser, I can see that a GET
> > > > > request is received by the server ...)

Reply via email to