Is there any way for an application to get notified if WAMP router drops connection?

5 views
Skip to first unread message

Rosa Lisin

unread,
Feb 26, 2019, 3:20:27 PM2/26/19
to CppWAMP
Hello,

I've ran into the following problem and I was hoping for an advice on how to resolve it.  My application uses CoroSession to connect to the WAMP router (crossbar.io).  The router is pretty busy in our system, and once in a while it drops connection to the application due to the ping timeout. Although we increased the timeout value,  the disconnection still happens once in a while.  The problem is that there is no immediate notification from the CoroSession to the application that the connection was dropped. Application finds out that the connection was dropped only when it tries to call a remote procedure or publish event. Until then it is unaware that it is not really connected to the router.  Is there a way for an application to find out that the connection is lost immediately?

Thanks,
Rosa
  


Emile Cormier

unread,
Feb 26, 2019, 7:29:11 PM2/26/19
to CppWAMP
Hi Rosa,

Unfortunately, there's currently no built-in way to do this in CppWAMP. A GitHub issue has already been raised to add a feature that allows one to register a callback for when the session disconnects: https://github.com/ecorm/cppwamp/issues/78

I can't really provide a time frame on when this feature will be implemented. You are the second one to request this feature, so I'll make it higher priority when I have time again to work on CppWAMP.

Cheers,
Emile
Reply all
Reply to author
Forward
0 new messages