feat(sdk): 心跳失败指数退避(1m..15m)
- heartbeatLoop 失败后指数退避、成功后恢复 normal interval - 新增退避计算测试
This commit is contained in:
3 files changed
+90
-9
No files matched your search
@@ -188,6 +188,8 @@ type Client struct {
|
||||
lastWall atomic.Int64 // 最近观测到的本地墙钟(回拨检测)
|
||||
noCheckWarn sync.Once
|
||||
fromCache bool
|
||||
backoffBase time.Duration // 测试可缩短
|
||||
backoffMax time.Duration
|
||||
}
|
||||
|
||||
// trustedNow 返回经 server_time 校正的可信时间。
|
||||
|
||||
Reference in new issue
Block a user