Auto-Reconnect
v1.0
·
Updated 2 weeks ago
Auto-Reconnect
When the connection is lost, the client automatically attempts to reconnect.
Detection
The connection is considered lost when:
- The last handshake is older than 180 seconds
- 3 consecutive connection checks fail
Reconnection Strategy
The client uses exponential backoff (increasing wait times):
| Attempt | Wait time |
|---|---|
| 1 | 2 seconds |
| 2 | 3 seconds |
| 3 | 4.5 seconds |
| 5 | 10 seconds |
| 10 | 60 seconds (maximum) |
After 10 failed attempts, the client gives up and displays an error notification.
Notifications
| Event | Message |
|---|---|
| Connected | GateControl: Connected |
| Disconnected (manual) | GateControl: Disconnected |
| Reconnect successful | GateControl: Reconnected |
| Reconnect failed | GateControl: Connection lost |