is ping/pong in websocket handled automatically in...
# ktor
a
is ping/pong in websocket handled automatically in ktor?
o
Yes, but you need to enable it
a
Copy code
install(WebSockets) {
        pingPeriod = Duration.ofMinutes(5)
    }
Is this it?
c
Note that setting
pingPeriod
enables server to client ping while client side pings are handled automatically unless you have raw websocket (responding and instance of
WebSocketUpgrade
starts raw websocket as well)
a
I see. Thanks!