Skip to content
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

[feature] Support custom refresh intervals for each group of metrics #2718

Open
wants to merge 29 commits into
base: master
Choose a base branch
from

Conversation

zuobiao-zhou
Copy link
Member

What's changed?

close #2188

Support custom refresh intervals for each group of metrics. The specific implementation is as follows:

  1. Construct a cycle of job refresh interval list based on the refresh intervals of each metric.
  2. When the job dispatches, select metrics that are due for refresh to form priorMetrics.

Checklist

  • I have read the Contributing Guide
  • I have written the necessary doc or comment.
  • I have added the necessary unit tests and all cases have passed.

@github-actions github-actions bot added doc Improvements or additions to documentation collector backend labels Sep 15, 2024
@zuobiao-zhou
Copy link
Member Author

zuobiao-zhou commented Sep 15, 2024

@tomsun28 Hi, the strange problem mentioned here #2271 (comment) has been solved.
According to the previous code, for jobs with multiple collection metrics, the metrics.setCollectTime execution time for metrics with a higher priority is somewhat delayed. This causes them to be missed during the selection of expired metrics in the next cycle, resulting in updates occurring every two cycles. so I move metrics.setCollectTime in constructPriorMetrics.
image
image
image
image
image
image
Customize collect intervals have been tested and there are no problem.

@tomsun28 tomsun28 added the good first pull request Good for newcomers label Sep 16, 2024
@tomsun28
Copy link
Contributor

👍👍thanks LGTM, test passed. Since this involves basic scheduling, and we are preparing a new version, can we merge this major feature after the 1.6.1 release (maybe end of this month)?

@tomsun28 tomsun28 added this to the 1.6.2 milestone Sep 18, 2024
@zuobiao-zhou
Copy link
Member Author

👍👍thanks LGTM, test passed. Since this involves basic scheduling, and we are preparing a new version, can we merge this major feature after the 1.6.1 release (maybe end of this month)?

I agree, we need to make this feature more stable before releasing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend collector doc Improvements or additions to documentation good first pull request Good for newcomers new feature
Projects
Development

Successfully merging this pull request may close these issues.

[Task] Customizable Refresh Intervals for Monitoring Metrics
5 participants