Skip to content

Document in-memory rate limiter tradeoff #622

Description

@itsmiso-ai

Parent umbrella issue: #616
Source audit: Weekly tech debt audit: dispatch - 2026-07-15
Source audit date: 2026-07-15

Recommendation

Problem: The rate limiter (src/lib/rate-limit.ts) is an in-memory fixed-window Map with no persistence, meaning a process restart resets all limits. This is acceptable for a single-node internal ops tool but not documented as an architectural tradeoff.

Evidence:

  • src/lib/rate-limit.ts line 44: const windows = new Map<string, WindowEntry>();
  • src/lib/rate-limit.ts line 56: fixed-window check (allows burst at boundary)

Acceptance: Mention the single-node, in-memory rate-limiter tradeoff in docs/accepted-risks.md alongside the existing entries.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions