I had configured logging in crossbar and I found this in the log which might help you track the bug.
2016-02-22T08:02:33-0500 [Router 17124 twisted.internet.defer] Unhandled error in Deferred:
2016-02-22T08:02:33-0500 [Router 17124 twisted.internet.defer]
Traceback (most recent call last):
File “/opt/crossbar/site-packages/autobahn/wamp/protocol.py”, line 742, in onMessage
File “/opt/crossbar/site-packages/txaio/tx.py”, line 80, in resolve
File “/opt/crossbar/site-packages/twisted/internet/defer.py”, line 393, in callback
File “/opt/crossbar/site-packages/twisted/internet/defer.py”, line 501, in _startRunCallbacks
File “/opt/crossbar/site-packages/twisted/internet/defer.py”, line 588, in _runCallbacks
current.result = callback(current.result, *args, **kw)
File “/opt/crossbar/site-packages/crossbar/router/dealer.py”, line 214, in on_authorize_success
exceptions.KeyError: <crossbar.router.session.RouterSession object at 0x000000000580cde8>
I’m suspecting somehow the session id is set as null and then the client can no longer register the rpc. Further, I have seen this occurring when the WiFi is switched off and on in succession or when transitioning from mobile data to Wi-Fi (and vice-versa). Any pointers?
On Sunday, 31 January 2016 14:31:15 UTC+5:30, Tobias Oberstein wrote:
Am 31.01.2016 um 06:28 schrieb rajiv godhwani:
I have a strange and what may seem to be a random issue. I have my clients (Android) register some rpcs with crossbar. The client re-registers the rpcs on disconnect and here is the where the issue arises, crossbar says the rpc is already registered.
I now that after a dirty disconnect, crossbar will remove all registered rpcs after a ping is lost. But in this case it doesn’t.
And when I fire (post ping lose) ‘wamp.registration.list_callees’ I get response as [null] and if I fire ‘wamp.registration.count_callees’ I get 1 as response.
I digged into the python code for the above rpcs and it seems that the ‘callee._session_id’ seems to be null on line number 424 of sservice.py
I can’t reproduce the issue in a definite way so can’t provide any steps to reproduce.
This is affecting the communication of the server with the client. Could you please check and provide a solution or workaround? Let me know if you need any more info
Without a way to reproduce, no way to track down whether there even is
an issue at all, not to speak of a fix.