Closed smeana closed 1 year ago
Check your server. It seems not to accept WebSocket connections at the given port.
@agalakhov Thanks, It is sorted now was a version issue.
Does tokio-tungstenite in build functionality to handle ping pong ?
Does tokio-tungstenite in build functionality to handle ping pong and reconnection in case of server failure? any example to manage this?
Automatic handling of pings/pongs is part of the RFC, so tungstenite
supports it out-of-the-box.
WebSocket does not have a mechanism of some sort of a fast recovery/reconnection, so reconnection is just establishing a new connection after the first one was closed, so we don't do automatic reconnects. You can reconnect by just re-establishing the connection once your existing connection stops.
Hello
I am unable to connect to wss (endpoint is working fine as I am connected from a java client) with the following code:
I had the following issue:
thread 'main' panicked at 'Can't connect: Http(Response { status: 400, version: HTTP/1.1, headers: {"date": "Wed, 08 Mar 2023 13:18:27 GMT", "content-type": "text/plain", "content-length": "20", "connection": "keep-alive"}, body: None })', src\main.rs:12:10
cargo.toml