-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[connector/spanmetrics] Add feature to expire metrics #31106
[connector/spanmetrics] Add feature to expire metrics #31106
Conversation
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
@matej-g wonderful, thank you 👍 Going to give this a try. My only issue is the ever growing test |
@portertech will I get extra imaginary points if I give it a try? 🙃 |
@portertech done, I simplified the method somewhat and removed couple of parameters, let me know what you think |
Signed-off-by: Matej Gera <[email protected]>
Signed-off-by: Matej Gera <[email protected]>
All feedback should be addressed, I also added validation for the metrics flush interval. |
Any chance this could be re-reviewed soon? Thanks folks, cc @portertech @TylerHelmuth |
Hello folks! |
@bogdandrutu any chance you are able to review this PR? I see Tyler is on vacation, it would be nice to get this staged for the next release 🙇 |
…#31106) **Description:** Adds a new feature to expire metrics that are considered stale. If no new spans are received within given time frame, on the next export cycle, the metrics are considered expired and will no longer be exported by the `spanmetricsconnector`. This intends to solve a situation where a service is no longer producing spans (e.g. because it was removed), but the metrics for such spans keep being produced indefinitely. See the linked issue for more details. Feature can be configured by setting `metrics_expiration` option. The current behavior (metrics never expire) is kept as the default. **Link to tracking Issue:** open-telemetry#30559 **Testing:** Added unit tests and tested manually as well. **Documentation:** Updated in-code documentation and README. --------- Signed-off-by: Matej Gera <[email protected]>
…#31106) **Description:** Adds a new feature to expire metrics that are considered stale. If no new spans are received within given time frame, on the next export cycle, the metrics are considered expired and will no longer be exported by the `spanmetricsconnector`. This intends to solve a situation where a service is no longer producing spans (e.g. because it was removed), but the metrics for such spans keep being produced indefinitely. See the linked issue for more details. Feature can be configured by setting `metrics_expiration` option. The current behavior (metrics never expire) is kept as the default. **Link to tracking Issue:** open-telemetry#30559 **Testing:** Added unit tests and tested manually as well. **Documentation:** Updated in-code documentation and README. --------- Signed-off-by: Matej Gera <[email protected]>
Description:
Adds a new feature to expire metrics that are considered stale. If no new spans are received within given time frame, on the next export cycle, the metrics are considered expired and will no longer be exported by the
spanmetricsconnector
.This intends to solve a situation where a service is no longer producing spans (e.g. because it was removed), but the metrics for such spans keep being produced indefinitely. See the linked issue for more details.
Feature can be configured by setting
metrics_expiration
option. The current behavior (metrics never expire) is kept as the default.Link to tracking Issue: #30559
Testing: Added unit tests and tested manually as well.
Documentation: Updated in-code documentation and README.