Repository navigation
Add option to disable staggering - #698
Merged
shortdudey123 merged 2 commits intoDec 29, 2021
Merged
shortdudey123 merged 2 commits into
shortdudey123 merged 2 commits into
Conversation
added 2 commits
February 28, 2018 21:06
The stagger functionality was added in 87da1c5. This works, however in cases where only one collector is configured, it's possible that the maximum collection time calculated is not long enough and the collection is terminated with, "Took too long to run!". This is despite the fact that the configured interval gives more than enough time for the collector to finish its run. Therefore, add a new 'stagger_collection' option that stops this behaviour. When disabled/cleared/set to false, the maximum collection time will remain static, or in other words it will be set to the interval configured and will not be increased if the collector doesn't finish within this time period. This change could potentially screw up existing deployments that rely on the existing stagger functionality, so by default 'stagger_collection' is enabled.
1 similar comment
mattrobenolt
reviewed
Jan 6, 2022
| next_window = math.floor(time.time() / interval) * interval | ||
| stagger_offset = random.uniform(0, interval - 1) | ||
|
|
||
| if str_to_bool(self.config['stagger_collection']): |
Member
There was a problem hiding this comment.
I'm guessing this needs to be collector.config['stagger_collection'] instead of self.
But I have no capacity or ability to test this.
shortdudey123
added a commit
that referenced
this pull request
Jan 14, 2022
Fix for issue introduced in #698
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.