xmpp api unsubscribe

Skip to first unread message


Nov 10, 2010, 2:44:01 PM11/10/10
to collecta-...@googlegroups.com

unsubscribing from the search node seems to unsubscibe from all active searches for the (anonymous guest) jid,
not just the one specified by a subid ...

<iq to="search.collecta.com" id="zvOT6_6" type="set"><pubsub xmlns="http://jabber.org/protocol/pubsub"><unsubscribe jid="394885319912...@guest.collecta.com/9423599141289416108627277" node="search" subid="50965971CB2E21317DE3A0"/></pubsub></iq>

<iq to="394885319912...@guest.collecta.com/9423599141289416108627277" from="search.collecta.com" id="zvOT6_6" type="result"/>

.. as i no longer get updates for other subscriptions on the search node.

is there another way to unsubscribe from a single search ?


Christopher Zorn

Nov 10, 2010, 2:51:51 PM11/10/10
to collecta-...@googlegroups.com
This should work. If you unsubscribe with a subid and it fails it will not unsubscribe all subscriptions. It would send an item-not-found error or it would just keep sending data. The error case should not be a removal of all subscriptions. Do you do anything else before or after the unsubscribe?


Nov 10, 2010, 3:09:28 PM11/10/10
to collecta-...@googlegroups.com
no error .. as expected a iq-result, but then all updates stop (get unsubscribed).
i don't send anything before the unsubscribe.


Nov 10, 2010, 3:30:41 PM11/10/10
to collecta-...@googlegroups.com
hm .. stange, i just had one out of about 50 cases where it worked as expected .. maybe i have a nasty bug somewhere else in my application.
nevermind for now, on bug hunt here.

i am developing a google chrome browser extension for collecta search.
you can install a very early version from here:

.. i wouldn't let it turned on while not in front of the computer since currently there are no limits for recieving updates which could be a disaster if you recieve a looot of them.



Nov 10, 2010, 8:20:02 PM11/10/10
to collecta-...@googlegroups.com
i've extracted the unsubscription thing having the same problem ..

here is the test i've used:
(open firebug/dev-console to track XMPP transfer)
.. creates two subscriptions one for 'test' and one for 'another'
.. if you unsubscribe from one it stops getting updates for the other too.

below is an unsubscription including the subid:

<iq to="search.collecta.com" id="HGN+J_6" type="set"><pubsub xmlns="http://jabber.org/protocol/pubsub"><unsubscribe jid="354107801289...@guest.collecta.com/23052939121289436748698023" node="search" subid="5096AA0D929741454B7230"/></pubsub></iq>

TestApp.hx:44 : Unubscribed [test]

seems to be a bug on your side or i am missing something
.. but i don't know what ()

Christopher Zorn

Nov 11, 2010, 8:12:17 AM11/11/10
to collecta-...@googlegroups.com
Thanks for the information. We are looking into this and will get back with what we find. 
Reply all
Reply to author
0 new messages