-
Notifications
You must be signed in to change notification settings - Fork 2.6k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
metricstarttimeprocessor: Copy true reset strategy from prometheus receiver #37855
base: main
Are you sure you want to change the base?
Conversation
de62187
to
1be705b
Compare
metricstarttime: | ||
|
||
# specify the strategy to use for setting the start time | ||
strategy: true_reset_point |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What are other strategies that you envision this processor supporting? using another metric's value for the start time (process_start_time_seconds
)? Wouldn't those also need to use the true_reset_point
strategy to deal with resets?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If a metric's value resets, it seems like we should always reset the start time, but I don't think that should involve inserting a "true reset" point. I think it should be implicit for all adjustment strategies (maybe with an on/off config option, similar to fallback to collector start time?).
Description
Copy the "metric adjuster" from the prometheus receiver to a new "true_reset_point" strategy in the metricstarttimeprocessor
Link to tracking issue
Part of #37186
Testing
Copied unit tests
Documentation
Updated the README.
Notes for reviewers
AdjustMetrics
to match the processMetrics function so that it doesn't need an additional wrapper layer.