Skip to content

fix: let 15m metrics fall back to the 5m window - #87

Open
TastyHeadphones wants to merge 1 commit into
paypal:masterfrom
TastyHeadphones:fix/fifteen-minute-fallback-to-5m
Open

TastyHeadphones wants to merge 1 commit into
paypal:masterfrom
TastyHeadphones:fix/fifteen-minute-fallback-to-5m

Conversation

@TastyHeadphones

Copy link
Copy Markdown

GetLatestWatcherMetrics is supposed to try 15m, then 10m, then 5m. A request for 15m that found nothing in the first two windows never looked at the 5m buffer, because that branch only matched TenMinutes/FiveMinutes.

Changed the third case so FifteenMinutes can fall through there too. Added a small test that only fills the 5m window.

Fixes #86

GetLatestWatcherMetrics docs say 15m → 10m → 5m, but a 15m request
that missed both larger windows never considered the 5m buffer.

@lawwong1 lawwong1 left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changes look good

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GetLatestWatcherMetrics: 15m requests never fall back to the 5m window

2 participants