chickadee » websockets » ping-interval

ping-interval #!optional numberparameter

How often to ping the client, in seconds, in the background. If 0 then automatic pinging will be disabled. This defaults to 15 seconds.

If this is set to a value greater than 0 then a thread will run in the background sending ping messages to the client at the specified interval. This is used to keep connections open that will otherwise be closed. Often connections without a transmission will be killed after awhile. Receiving pongs in response to a ping will also reset the connection close timer.

pong responses to ping messages are not passed through to the user but they are used to update the timestamp that the connection timeout thread uses to decide if it should kill a connection.