GetLatestWatcherMetrics: 15m requests never fall back to the 5m window
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 84/100
- Issue type
- Bug
- Clarity
- Clearly specified
- Activity status
- Active
- Tech stack
- go
- Domain
- observability
Research direction
Start in pkg/watcher/watcher.go at GetLatestWatcherMetrics, around lines 188–207, and compare the doc comment with the fallback conditions. Verify the 15m request behavior when the 15m and 10m buffers are empty but the 5m buffer has data. Done means the documented fallback behavior and implementation agree, with an error only when no applicable buffer contains data.
Written by the indexing model from the issue text.
Description
The doc comment on GetLatestWatcherMetrics describes a 15m → 10m → 5m fallback, but a request for the 15 minute window can only fall back to the 10 minute window. If both the 15m and 10m buffers are empty, the call returns an error even when the 5m buffer holds data.
For duration == FifteenMinutes, the third case condition (duration == TenMinutes || duration == FiveMinutes) never evaluates to true, so the 5 minute buffer is unreachable regardless of its contents.
Is the current behaviour intentional, or should the third case also accept FifteenMinutes?
I'm happy to send a PR for whichever you prefer — adjusting the condition, or the comment.
- Dominant language
- Go
- Stars
- 78
- Forks
- 38
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from paypal/load-watcher
-
no premisstion Open
Difficulty 3/5 1-2 days Newbie friendliness 35/100
paypal/load-watcher#81 · 1 comment ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
paypal/load-watcher#72 · 1 reaction ·
-
Difficulty 3/5 1-2 days Newbie friendliness 35/100
paypal/load-watcher#71 ·
-
Difficulty 3/5 1-2 days Newbie friendliness 42/100
paypal/load-watcher#56 · 3 comments ·
-
paypal/load-watcher#51 · 1 comment · 1 assignee ·
All issues in paypal/load-watcher
Similar issues
-
Difficulty 1/5 Under an hour Newbie friendliness 84/100
-
enhancement needs triage
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
kind/cleanup
Difficulty 2/5 1-3 hours Newbie friendliness 88/100
kubernetes-sigs/kueue#15947 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
sympozium-ai/sympozium#627 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 86/100