Skip to content

Rate limiter too aggressive for batch queue operations #41

@mriechers

Description

@mriechers

Issue

The RATE_EXPENSIVE rate limit on POST /api/queue/ blocks legitimate batch operations after ~10 requests per minute. For an internal editorial tool with a single user, this is overly restrictive.

Reproduction

Queue more than 10 jobs in rapid succession — subsequent requests return 429 Too Many Requests.

Suggested Fix

Options (not mutually exclusive):

  • Increase the RATE_EXPENSIVE threshold for the queue endpoint
  • Add a bulk queue endpoint (POST /api/queue/bulk) that accepts an array of jobs in a single request
  • Make rate limits configurable via environment variable
  • Exempt authenticated internal requests from rate limiting

Context

The upload endpoint (POST /api/upload/transcripts) already supports batch uploads of up to 20 files. The queue endpoint should have parity.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions