Skip to content

[FEAT] Add healthcheck and resource limits for llm-service #95

Description

@MikeNovikoff

Feature description

Ensure the LLM service is robust in production by adding Docker healthchecks and sensible HTTP timeouts.

What is needed to be done

  • docker-compose.yml: healthcheck block using Python HTTP client to hit /health
  • quiz_core/internal/api/handlers/llm/generate.go: http.Client{Timeout: 120s}
  • quiz_core/internal/api/handlers/llm/generate.go: http.MaxBytesReader on request body

Acceptance Criteria

  • Docker healthcheck polls localhost:7000/health every 10s
  • Go HTTP client timeout is set to 120 seconds
  • Request body limited to 1 MB to prevent abuse
  • Uploaded file extension restricted to .txt

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status
    No status

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions