mirror of
https://github.com/ekzhang/bore.git
synced 2026-04-18 22:50:21 +00:00
Implement automatic client reconnection with exponential backoff and heartbeat timeout
- Add heartbeat timeout to client control connection using server heartbeats for dead connection detection - Introduce exponential backoff with jitter for reconnection delays - Add CLI flags: --no-reconnect to disable auto-reconnect, --max-reconnect-delay to configure backoff cap - Classify authentication errors as fatal (never retried), all others retried automatically - Configure TCP keepalive on control connections for OS-level dead connection detection - Update documentation (README.md, CLAUDE.md) to describe reconnection behavior and new flags - Add unit tests for backoff logic and error classification
This commit is contained in:
parent
042fa78742
commit
a13e03372e
9 changed files with 438 additions and 126 deletions
|
|
@ -26,7 +26,8 @@ hmac = "0.12.1"
|
|||
serde = { version = "1.0.136", features = ["derive"] }
|
||||
serde_json = "1.0.79"
|
||||
sha2 = "0.10.2"
|
||||
tokio = { version = "1.17.0", features = ["rt-multi-thread", "io-util", "macros", "net", "time"] }
|
||||
socket2 = { version = "0.5", features = ["all"] }
|
||||
tokio = { version = "1.21.0", features = ["rt-multi-thread", "io-util", "macros", "net", "time"] }
|
||||
tokio-util = { version = "0.7.1", features = ["codec"] }
|
||||
tracing = "0.1.32"
|
||||
tracing-subscriber = "0.3.18"
|
||||
|
|
@ -35,4 +36,4 @@ uuid = { version = "1.2.1", features = ["serde", "v4"] }
|
|||
[dev-dependencies]
|
||||
lazy_static = "1.4.0"
|
||||
rstest = "0.15.0"
|
||||
tokio = { version = "1.17.0", features = ["sync"] }
|
||||
tokio = { version = "1.21.0", features = ["sync"] }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue