In this lesson, you will learn how to calculate the speed at which your error budget is being consumed to predict potential outages before they impact your users.
Understanding Burn Rate
An error budget represents the maximum amount of downtime or unreliability your service can afford within a specific period (e.g., a month) while still meeting your Service Level Objectives (SLOs). The Burn Rate tells you how fast you are consuming that budget.
If you have a 99.9% SLO, you have an error budget of 0.1%. A burn rate of 1.0 means you are consuming your budget exactly at the rate that will exhaust it by the end of the month. If your burn rate spikes to 10.0, you are consuming your budget 10 times faster than intended, meaning you will hit your error limit in 1/10th of the time.
Calculating the Burn Rate
To calculate this in a Prometheus-based environment, you compare the rate of errors over a short window to the rate of errors over a long window.
# Burn Rate Calculation
(
rate(http_requests_total{status=~"5.."}[1h]) /
rate(http_requests_total[30d])
) / (1 - target_slo)
By analyzing this ratio, you gain a predictive signal:
- Low Burn Rate (<1): You are operating well within your reliability targets.
- High Burn Rate (>5): You are experiencing a significant incident. You should be alerted immediately, even if your total monthly budget hasn't been exhausted yet.
- Critical Burn Rate (>14): You are burning through your budget at an alarming speed; a total breach of your SLO is imminent within hours.
Why This Matters for CI/CD
Analyzing burn rates allows you to move from reactive firefighting to proactive reliability. If a new deployment triggers a high burn rate in the first 15 minutes, your CI/CD pipeline should automatically trigger a rollback. By monitoring these rates, you ensure that engineering teams maintain the velocity required for feature delivery while keeping the system stable enough to meet user expectations. You aren't just measuring past failures; you are calculating the "velocity of unreliability" to steer your production operations safely.
Key Takeaway: Analyzing burn rates provides a predictive "early warning system" that triggers interventions—like rollbacks or incident responses—long before your total error budget is exhausted.