After running edge for a while I spotted that it was suddenly sleeping for 62 seconds, and then 64 seconds. Double checking I see that we add jitter to previous interval instead of resetting back to initial configured duration before adding jitter.
Steps to reproduce the bug
Start edge with RUST_LOG=warn,unleash_edge=trace
Observe
2024-02-29T12:09:33.846888Z TRACE unleash_edge::http::background_send_metrics: Done posting traces. Sleeping for 62 seconds and then going again
2024-02-29T12:09:33.846888Z TRACE unleash_edge::http::background_send_metrics: Done posting traces. Sleeping for 70 seconds and then going again
?
Profit?
Expected behavior
Interval should never exceed initial configured interval + max_jitter unless we're erroring. Since all posts succeeded, we probably shouldn't add jitter at all. the normal interval due to random startup times should be enough
Logs, error output, etc.
2024-02-29T12:09:33.846888Z TRACE unleash_edge::http::background_send_metrics: Done posting traces. Sleeping for 70 seconds and then going again
Describe the bug
After running edge for a while I spotted that it was suddenly sleeping for 62 seconds, and then 64 seconds. Double checking I see that we add jitter to previous interval instead of resetting back to initial configured duration before adding jitter.
Steps to reproduce the bug
RUST_LOG=warn,unleash_edge=trace
Expected behavior
Interval should never exceed initial configured interval + max_jitter unless we're erroring. Since all posts succeeded, we probably shouldn't add jitter at all. the normal interval due to random startup times should be enough
Logs, error output, etc.
Screenshots
No response
Additional context
No response
Unleash version
Edge 17.1.0
Subscription type
None
Hosting type
None
SDK information (language and version)
No response