Conversation
Export function timer count and total-time changes as independent positive counter deltas while preserving reset and invalid-value semantics. Keep timer aggregation correct across instances by avoiding synthetic means and distributions that Micrometer's cumulative values cannot represent. Co-Authored-By: Claude <noreply@anthropic.com>
Contributor
|
This was referenced Sep 15, 2026
📲 Install BuildsAndroid
|
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.
PR Stack (Micrometer)
📜 Description
Add passive polling for Micrometer
FunctionTimermeters.Each function timer emits positive changes in its cumulative count and total time as
<name>.countand<name>.total_timeSentry counters. The implementation establishes an initial baseline, handles source resets, skips invalid values, and resets its state when the meter is removed.💡 Motivation and Context
Micrometer function timers expose cumulative count and total-time callbacks. Those values cannot reconstruct the original observations needed for a Sentry distribution or a meaningful per-instance mean, so this PR preserves their representable semantics as independent counter deltas.
Keeping this mapping separate makes the semantic tradeoff explicit and reviewable.
💚 How did you test it?
Tests cover baselines, positive deltas, count-only and time-only changes, resets, non-finite and negative values, meter removal, units, tags, and callback failures.
📝 Checklist
sendDefaultPIIis enabled.🔮 Next steps
Add opt-in Spring Boot 2, 3, and 4 integration in the final stack PR.
#skip-changelog