mirror of
https://github.com/pezkuwichain/pezkuwi-telemetry.git
synced 2026-06-11 22:21:09 +00:00
No use denying "Earth" – they renamed
Send Close frame with reason when the remote missed a heartbeat
This commit is contained in:
@@ -90,6 +90,7 @@ impl NodeConnector {
|
||||
// check client heartbeats
|
||||
if Instant::now().duration_since(act.hb) > CLIENT_TIMEOUT {
|
||||
// stop actor
|
||||
ctx.close(Some(CloseReason { code: ws::CloseCode::Abnormal, description: Some("Missed heartbeat".into())}));
|
||||
ctx.stop();
|
||||
}
|
||||
});
|
||||
@@ -113,11 +114,6 @@ impl NodeConnector {
|
||||
match &*node.chain {
|
||||
"Kusama CC3" => node.chain = "Kusama".into(),
|
||||
"Polkadot CC1" => node.chain = "Polkadot".into(),
|
||||
"Earth" => {
|
||||
// Temp, there is too many of them
|
||||
ctx.stop();
|
||||
return;
|
||||
},
|
||||
_ => ()
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user