Skip to content

Intermittent peak memory above 256MB in coupon-bot #271

Description

@github-actions

Problem

The coupon-bot observed a peak memory usage of 355.9 MB in the last 24 hours, exceeding the project threshold of 256 MB. Current memory is low (85.0 MB) and there are no restarts or error logs, but the peak suggests an intermittent memory pressure or temporary leak under load.

Evidence

  • Metrics snapshot (24h): Peak Memory: 355.9 MB (from the project's metrics snapshot).
  • No container restarts (Container Restarts (total): 0).
  • No Error/Fatal log entries in Loki (24h) and log volume is low (706 lines).

Suggested Approach

  1. Add short-term profiling to reproduce the spike in staging: enable .NET memory allocation/heap metrics or take a periodic memory dump when process RSS > 300 MB.
  2. Instrument hotspots: record per-endpoint allocation rates (requests/min, memory delta) and large-object-heap usage in production/staging metrics.
  3. If reproducible, run dotnet-gcdump / dotnet-trace on a staging pod and analyze with PerfView or dotnet-dump.
  4. If not reproducible, schedule increased sampling (short-lived heap dumps) for a window of higher traffic.

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions