Skip to content

Mark throttler re-checks after a timeout with X-Is-Retry - #39

Closed
baweaver wants to merge 1 commit into
mainfrom
mark-timeout-retries-with-x-is-retry
Closed

baweaver wants to merge 1 commit into
mainfrom
mark-timeout-retries-with-x-is-retry

Conversation

@baweaver

@baweaver baweaver commented Oct 28, 2026 •

Copy link
Copy Markdown

No description provided.

Add an is_retry request option that sends the X-Is-Retry: true header,
and an opt-in mark_timeout_retries throttler option that sets it only
on checks repeating a check for the same store that timed out or got
an HTTP 408 response. Re-checks after a throttled answer are polling
and stay unmarked.

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Copilot AI auto review requested due to automatic review settings October 28, 2026 21:39

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🟢 Approval recommended

No active review issues were identified for the opt-in timeout retry marking changes.

No open issues 🎉

What changed in this PR

Adds opt-in retry marking so load balancers can distinguish throttler checks repeated after timeouts from normal polling. Existing behavior remains the default.

Changes:

  • Adds the is_retry request option to send X-Is-Retry: true.
  • Adds mark_timeout_retries to track timeout retries per store and per throttle call.
  • Documents both options and adds tests for header behavior, reset, isolation, and defaults.
File Description
test/​freno/​throttler_retry_header_test.rb Tests timeout retry marking, polling, isolation, and defaults.
test/​freno/​client/​requests/​check_test.rb Tests explicit retry headers and their default omission.
README.md Documents configuration and retry-versus-polling behavior.
lib/​freno/​throttler.rb Tracks timeout retries and conditionally marks repeated checks.
lib/​freno/​client/​request.rb Adds request-level retry header support.
lib/​freno/​client.rb Documents the is_retry request option.
CHANGELOG.md Records both options under Unreleased.

Review effort: Balanced (auto)

@baweaver baweaver closed this Oct 28, 2026
@baweaver
baweaver deleted the mark-timeout-retries-with-x-is-retry branch October 28, 2026 21:45
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.

2 participants