Skip to content

Proposal: Expose configurable Redis timeout (radix) and optional circuit breaker for Redis backend #978

@notdu

Description

@notdu

Currently, the ratelimit service uses the radix Redis client with a hard-coded ~10s timeout. When Redis is down or slow, this causes blocking calls, goroutine buildup, and high memory usage. The timeout isn’t configurable, which can lead to OOMs in failure scenarios.

Proposal:

  • Expose Redis connection/read/write timeouts via environment variables (e.g. REDIS_TIMEOUT_MS or separate fields).
  • Expose an ENV variable to optionally add a circuit breaker mode that temporarily skips Redis calls after repeated timeouts, retrying periodically.

This would allow operators to tune latency and prevent cascading failures during Redis outages.
Can I open a PR to add this configuration and optional circuit breaker behavior?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions