fix: increase failure cache TTL from 15s to 5min to prevent 429 retry storm#189
Closed
YASoftwareDev wants to merge 1 commit intojarrodwatts:mainfrom
Closed
fix: increase failure cache TTL from 15s to 5min to prevent 429 retry storm#189YASoftwareDev wants to merge 1 commit intojarrodwatts:mainfrom
YASoftwareDev wants to merge 1 commit intojarrodwatts:mainfrom
Conversation
… storm When the usage API returns 429 (rate limited), the previous 15s failure cache TTL caused the HUD to retry 4 times/minute indefinitely, making recovery from a transient rate-limit impossible and keeping the 'Usage ⚠ (429)' warning permanently in the status bar. Bumping CACHE_FAILURE_TTL_MS to 300s (5 minutes) is the standard backoff approach for rate-limited APIs: one retry every 5 minutes gives the server time to recover while still refreshing promptly once the limit clears. Fixes jarrodwatts#188
b59b98b to
e2d5596
Compare
Owner
|
Closing as superseded by merged PR #193, which carries the 429 mitigation forward on top of current main with broader cache/backoff test coverage. |
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.
Bumps 'CACHE_FAILURE_TTL_MS' from 15s to 5 minutes.
With the 15s failure TTL, a single 429 response leads to an infinite cycle where the HUD retries 4 times/minute, actively preventing recovery from a transient rate-limit and keeping the 'Usage ⚠ (429)' warning permanently in the status bar.
Fixes #188, related to #187