even more aggressive reconnect on stale connections
Signed-off-by: William Casarin <jb55@jb55.com>
This commit is contained in:
@@ -84,7 +84,7 @@ class RelayPool {
|
||||
|
||||
let is_connecting = c.isReconnecting || c.isConnecting
|
||||
|
||||
if is_connecting && (Date.now.timeIntervalSince1970 - c.last_connection_attempt) > 10 {
|
||||
if is_connecting && (Date.now.timeIntervalSince1970 - c.last_connection_attempt) > 5 {
|
||||
print("stale connection detected (\(relay.descriptor.url.absoluteString)). retrying...")
|
||||
relay.connection.connect(force: true)
|
||||
} else if relay.is_broken || is_connecting || c.isConnected {
|
||||
|
||||
Reference in New Issue
Block a user