i am using ktor-client-websockets and i cannot get...
# ktor
n
i am using ktor-client-websockets and i cannot get the websocket to close cleanly, not sure if it is my fault or the server not responding to close frames..
Copy code
client.websocket(host, port, path) {
    for(frame in incoming) {
        // a `break` somewhere in here
    }
 
    close(CloseReason(CloseReason.Codes.GOING_AWAY, "OK"))
    <http://logger.info|logger.info> { "sent close" }
}
<http://logger.info|logger.info> { "websocket closed" }
i see the
sent closed
log message but after that it hangs is there any other way to close the websocket ? PS: seems like it works better when not using CIO engine maybe such incompabilities should be put in the docs ?
a
CIO is the future but is not production ready yet