mirror of
https://github.com/savoirfairelinux/opendht.git
synced 2026-11-08 12:28:42 +00:00
Server: Reduce HTTP idle connection timeout from ~24 days (numeric_limits<int>::max() milliseconds) to 1 hour. Dead mobile clients are now cleaned up promptly instead of holding server resources for weeks. Client: Add exponential backoff for proxy reconnection when disconnected (1 min -> 2 -> 4 -> 8 -> 16 -> 30 min cap). Previously used a fixed 1-minute retry which drained battery on flaky mobile networks. Reset backoff on successful connection or explicit connectivity change (WiFi/cellular switch). Client: Add small random jitter (0-2s) before resubscribing all listeners on reconnection to avoid burst of requests to the server. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Change-Id: Ic29c4a0b2850997db9e559f01146024f41190a5c