This document provides actionable steps for the most common critical alerts generated by the teachLink_backend alerting service.
Description: The payment failure rate has exceeded the critical threshold (default > 5%). Potential Impact: Users cannot successfully complete checkouts, resulting in immediate revenue loss.
- Check the Stripe dashboard (or equivalent payment provider) for ongoing global incidents.
- Review the backend application logs for
PaymentsModuleerrors. Look for API key expiration or network timeouts. - If the payment gateway API is down, update the Statuspage to inform users of the degradation.
- Verify webhooks are successfully processing by checking the
stripe-webhook.guard.tslogs.
Description: Database connection pool usage has exceeded 95%. Potential Impact: The application cannot serve requests that require database access, leading to cascading HTTP 5xx errors.
- Identify any long-running transactions or deadlocks using
pg_stat_activity. - Check if a recent deployment introduced N+1 queries.
- If necessary, temporarily scale up the database connection pool in the environment variables and restart the pods.
- If legitimate traffic spikes caused the exhaustion, evaluate horizontally scaling the database read-replicas.
Description: Application memory usage has exceeded 95%. Potential Impact: OOM (Out of Memory) crashes resulting in pod restarts and degraded performance.
- Examine the application performance metrics for memory leaks (e.g., unbounded array growth, unresolved Promises).
- Look for large file processing jobs in the
MediaModulethat might be loading full files into memory rather than streaming. - If a specific pod is consistently running out of memory, manually restart it.
- Consider scaling up the pod memory limits if the baseline usage has naturally increased.
Description: HTTP 5xx error rate has exceeded 5%. Potential Impact: Users are experiencing a degraded application experience.
- Check Datadog/Kibana for the most frequent 5xx errors and their stack traces.
- Correlate the spike with recent deployments or infrastructure changes.
- Roll back the latest deployment if a specific PR is identified as the root cause.
- If the errors correlate with a specific downstream microservice outage, ensure Circuit Breakers are correctly failing fast.