WAMP/WS meta events for auto_ping?

#1

Hi All,

I’m wondering if it is possible to subscribe to auto_ping events like wamp meta events?

I am using custom authentication/authorization from python 3 guest workers that are disconnecting from the router after some time. I’m guessing their connections are getting killed by mid-stream routers after 20 minutes which is typical on the internet, if they don’t pass some traffic in that time. Hence, I was pleased to find the auto_ping capability but would like some print in the console of the router when the ping payload is sent.

http://crossbar.io/docs/Session-Metaevents-and-Procedures/

An old reference of similar type:

https://github.com/tavendo/WAMP/issues/90

Config (Websocket) options I’m referring to:

http://crossbar.io/docs/WebSocket-Options/

  • auto_ping_interval: Send a WebSocket ping every this many ms (default: null)

  • auto_ping_timeout: Drop the connection if the peer did not respond to a previously sent ping in this many ms (default: null)

  • auto_ping_size: Payload size for pings sent, must be between 4 and 125 (default: null)

    Thanks for any help!

    Dave

0 Likes

#2

Hi Dave,

no, there isn’t anything like that: WAMP does not know about WebSocket nor WebSocket ping/pongs. That is a transport feature, and WAMP is deliberately designed to be agnostic to that.

You can enable “debug” on the WebSocket transport, and then get (ultra-verbose) logging in log output of Crossbar.io, which will include log messages for sending, receiving, timing out etc WebSocket ping/pongs. But it’ll be barely useful, since you will get a ton of output …

Cheers,
/Tobias

···

Am Donnerstag, 25. Juni 2015 22:20:02 UTC+2 schrieb Dave Thomas:

Hi All,

I’m wondering if it is possible to subscribe to auto_ping events like wamp meta events?

I am using custom authentication/authorization from python 3 guest workers that are disconnecting from the router after some time. I’m guessing their connections are getting killed by mid-stream routers after 20 minutes which is typical on the internet, if they don’t pass some traffic in that time. Hence, I was pleased to find the auto_ping capability but would like some print in the console of the router when the ping payload is sent.

http://crossbar.io/docs/Session-Metaevents-and-Procedures/

An old reference of similar type:

https://github.com/tavendo/WAMP/issues/90

Config (Websocket) options I’m referring to:

http://crossbar.io/docs/WebSocket-Options/

  • auto_ping_interval: Send a WebSocket ping every this many ms (default: null)

  • auto_ping_timeout: Drop the connection if the peer did not respond to a previously sent ping in this many ms (default: null)

  • auto_ping_size: Payload size for pings sent, must be between 4 and 125 (default: null)

    Thanks for any help!

    Dave

0 Likes