Skip to content

feat(rust-provider): add HTTP retry for flagLog writes#452

Draft
nicklasl wants to merge 4 commits into
mainfrom
nicklasl/rust-flaglog-retry
Draft

feat(rust-provider): add HTTP retry for flagLog writes#452
nicklasl wants to merge 4 commits into
mainfrom
nicklasl/rust-flaglog-retry

Conversation

@nicklasl

Copy link
Copy Markdown
Member

Summary

  • Add retry with exponential backoff to LogSender::send() in the Rust provider, matching the JS provider's flagLog retry behavior
  • 3 attempts, 500ms base delay, 2x backoff, ±10% jitter
  • Retries on 5xx, 408, 429, and network errors; no retry on other 4xx
  • Respects Retry-After header from server (takes precedence over computed backoff)
  • Warns (not errors) after retries exhausted since log failures shouldn't disrupt flag evaluation

Test plan

  • Unit tests for retry on 503, 429, 408
  • Unit tests for no-retry on 400, 403
  • Unit test for Retry-After header respect
  • Unit tests for jitter bounds and parse_retry_after
  • is_retryable_status coverage for all relevant codes
  • Full crate test suite passes (95 tests)
  • clippy clean

🤖 Generated with Claude Code

nicklasl and others added 4 commits June 18, 2026 12:37
3 attempts, 500ms base backoff with 2x multiplier.
Retries on 5xx, 408, 429 and network errors.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

1 participant