Skip to content
Tech Interview Prep
Technical interview guide

SLIs, SLOs & Error Budgets

The vocabulary reliability is measured in, and how an error budget turns 'be reliable' into a concrete number.

Minutes to read
4
Practice MCQs
25
Interview Q&A
25
Edition
v5
Editorial status
Reviewed

Scope: Google SRE guidance, Prometheus, and OpenSLO current 2026-08-31.

Interview Q&A

Treat each question like a live interview question: answer out loud first (structure, assumptions, tradeoffs), then open the model answer to spot gaps and rehearse a tighter follow-up.

Curated: · Written: · Reviewed:

25 questions

Q&A-1

Define an SLI, SLO, SLA, and error budget with one coherent example.

Answer

First 90 seconds

Assume a checkout service doing ~100 eligible requests/min, instrumented at the edge. Four terms, four different jobs: the SLI is the measurement, the SLO is the internal target on that measurement, the error budget is the failure the SLO permits, and the SLA is the contract with money behind it. Keep them separate or the numbers stop meaning anything.

The example

Eligible request: a checkout POST from a logged-in user with a non-empty cart. Good: the user receives a committed order confirmation within 2 s. SLI = good events / eligible events, measured at the edge (load-balancer logs), not inside the app: the app can't see requests that died in the CDN or never got a connection.

SLO: 99.9% of eligible requests over a rolling 28-day window.

Error budget: the 0.1% the SLO allows. At 100 req/min that's 4.03M eligible requests per window and 4,032 bad events: an allowed bad rate of 6/hour.

SLA: a separate commercial contract. Say 99.5% per calendar month with service credits, exclusions for scheduled maintenance and client-side failures. Set it looser than the SLO on purpose: you want to be paged and fix things long before you owe anyone money.

Budget arithmetic

eventbad events% of 4,032 budgetburn rate
10 min at 5% error501.2%50x
1 h at 1.44% error862.1%14.4x
6 h at 0.6% error2165.4%6x
steady 0.1% error4,032100%1x

Burn rate is observed bad rate ÷ allowed bad rate; 1x exhausts the budget exactly at the end of the window. Alert on burn rate, not raw error rate: 14.4x over 1 h pages (2% of budget gone), 6x over 6 h pages (5%), 1x over 3 days files a ticket (10%).

Trade-offs

Edge SLI vs proxy SLI. Edge catches DNS, CDN and connection failures users actually hit; it's noisier and harder to join to backend traces. A server-side "200 within 2 s" proxy is cheap and stable but blind to everything in front of the app. Pick edge for a revenue journey; pick proxy for an internal batch job.

Window length. Rolling 28 days is stable and slow: a 10-minute outage barely moves it. Short windows react fast and flap. Multiwindow multi-burn-rate gets both.

Target level. Each nine costs roughly 10x. 99.9% allows 43 min/month; 99.99% allows 4.3 min/month. 99.99% on a checkout that depends on a third-party payment provider is a promise you can't keep.

Failure modes

Burn-rate alerts misconfigured: alerting on raw error rate pages on a 0.5% blip that's inside budget, or misses a slow 2x burn that empties the budget in two weeks. Detect by plotting alert firings against budget consumption and replaying a synthetic bad-traffic window.

Budget exhausted with no policy: the SLO becomes decorative. The policy has to say what stops: feature launches freeze, reliability work takes the sprint, and who decides. Detect by tracking budget remaining and reviewing it at every window boundary.

Wrong boundary: SLI measured inside the app misses edge failures; measured at the edge it double-counts retries. Detect by computing the SLI at both boundaries and expecting a known divergence.

Missing data, if the metric pipeline drops, is a request good or bad? Choose, record it, and alert on scrape gaps so a silent pipeline doesn't read as 100%.

What would change my answer

If the journey can't be measured at the edge, I'd say so and use a proxy SLI with the gap documented, not quietly measure the wrong thing.

Curated: · Written: · Reviewed:

Difficulty: Medium
Q&A-4

Define the numerator and denominator for a request-based SLI.

Answer

The answer, in the first minute

Numerator: the count of eligible requests that succeeded. Denominator: the count of all eligible requests. The SLI is numerator divided by denominator: a ratio, not a count. Everything hard about this question lives in the two adjectives, eligible and succeeded. Get those wrong and you still have a number, just not a useful one.

Decide eligibility before you look at the outcome. If the denominator is "requests that returned a status code," the outcome has already leaked in: a request that times out and never returns has no status code, and it is exactly the one you most want counted as bad.

Eligibility

Fix the population first: service and operation, client class, region, version, time window. Then name what is out. Health checks, synthetic probes and load-test traffic are out: they are not user demand, and a probe hitting a dead backend every 10 seconds will dominate a low-traffic denominator. Internal admin calls are usually out. Everything else is in, including requests that fail.

Good

Good = eligible AND semantically successful AND (optionally) within a latency threshold. For HTTP: 2xx and 3xx good, 5xx bad. 4xx is the judgement call. A 400 from a malformed client payload is the client's fault and arguably should not burn your budget; a 401 because your token service is down is yours. Pick a rule, write it down, apply it consistently.

Latency is a separate axis. A request that returns 200 in 4 seconds is a success for availability and a failure for latency. If you fold latency in, say so, "good = 200 within 300 ms", because it changes the number.

Retries: the decision that moves the number most

Physical attempt or logical operation? A client retries three times and all three fail: denominator 3, numerator 0. A client retries three times and the third succeeds: denominator 3, numerator 1, so 33% success. Even though the user saw success. Deduplicating needs a stable operation ID propagated across retries and a bounded window (60 seconds is typical) to collapse them into one event.

Worked check

A 5-minute window carries 2,000,000 eligible requests; 1,998,000 are good. That is 99.9%. Against a 30-day 99.9% SLO the budget is 0.1% of requests, so 2,000 bad requests in this window is exactly the budget for the window: one bad minute of a retry storm can spend a day's worth.

In PromQL:

PROMQL
sum(rate(http_requests_total{job="api",code!~"5.."}[5m]))
/
sum(rate(http_requests_total{job="api"}[5m]))

This counts 4xx as good. Adjust the matcher to whatever rule you wrote down above.

Failure modes

  • Denominator drift. A new endpoint ships without the metric label, its traffic is silently uncounted, and the ratio looks healthy because the failing traffic is invisible.
  • Unknown classification. Events matching neither good nor bad. Monitor the unclassified rate; once it exceeds roughly 0.1% of the denominator, the SLI is lying to you.
  • Exclusion creep. Every incident adds an exclusion until the SLI measures the exclusions. Each one needs an owner and a date, and removing genuine harm because "that's the client's fault" is how a 99.9% SLI hides a broken service.

Curated: · Written: · Reviewed:

Difficulty: Medium
Q&A-3

Choose the measurement point for a user-facing SLI.

Answer

The 90-second answer

Pick the measurement point closest to the user that you can actually trust and afford, then say out loud which blind spot you accepted. For a browser-based product I default to two SLIs: availability and error rate from the edge/load balancer, because it sees every request that reached your infrastructure and is centrally available; and latency/experience from real user monitoring, because only the browser knows whether the page rendered. Server-side metrics are the diagnostic layer, not the SLI.

State your assumptions: the journey is browser-based, you can ship client instrumentation, and you control the load balancer.

Where success is lost

DNS failure, TCP/TLS handshake failure, edge 5xx, application 5xx, dependency timeout, and post-response failures the server never sees: the user closed the tab, the JS bundle failed to parse, a third-party script blocked rendering. Each measurement point sees a different subset.

PointSeesMissesNamed signal
Edge / LBevery request that arrived, pre-app failuresclient rendering, semantic completionEnvoy RESPONSE_FLAGS: UH no healthy upstream, UF upstream connection failure, UT upstream timeout; nginx $request_time vs $upstream_response_time
Server / apphandler detail, dependency latencyrequests that never arrived, post-response failuresPrometheus histogram_quantile(0.99, sum(rate(http_request_duration_seconds_bucket[5m])) by (le))
RUMrender, interaction, abandonmentusers who never loaded the tag, blocked beaconsweb-vitals LCP / INP / CLS
Synthetica controlled journey from many regionsthe real workload mixcanary journey every 1 min

Thresholds that make it concrete

Core Web Vitals: LCP good ≤ 2.5 s, poor > 4.0 s; INP good ≤ 200 ms, poor > 500 ms; CLS good ≤ 0.1. All at the 75th percentile, the aggregation CrUX uses. TTFB target ≤ 800 ms at p75. So "the page is slow" becomes "p75 LCP is 3.1 s, in the needs-improvement band, and most of it is TTFB."

Failure modes and how you detect them

  • RUM beacon loss. Ad blockers and privacy browsers drop beacons. Compare RUM session count against edge request count for the same route and window; a gap that widens is coverage loss, not a traffic drop. Send beacons with navigator.sendBeacon on visibilitychange → hidden, not on unload.
  • Slow-client contamination at the edge. $request_time includes time waiting on the client; $upstream_response_time does not. When they diverge, your edge latency SLI is measuring the network, not your service.
  • Missing data read as success. If the RUM tag fails to load, the page looks perfect. Treat absent data as unknown and exclude it from the denominator, or you will report 100% success during an outage.
  • Synthetic-only blind spot. The canary journey passes while a real workload path fails.

Validation

Keep one independent view for cross-checking: edge error rate against RUM error rate, or synthetic against RUM. Bind events by app version and time so a deploy is visible in the series. When the two disagree, the disagreement is the finding.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-6

Calculate and explain an error budget correctly.

Answer

An error budget is the bad-event allowance implied by an SLO over a declared window: budget = (1 − SLO) × eligible events. The arithmetic is trivial; the definitions decide the number. Before computing, pin down four things: which events are eligible, which of them are bad, which window applies (rolling or calendar), and when the data is final. Get those wrong and the budget is a number with no meaning.

The arithmetic

quantityvalue
SLO99.9% good
eligible events in window10,000,000
budget10,000 bad events
bad observed2,500
consumed25%
remaining75%

Burn rate is what drives alerts

A 30-day window with a 10,000-event budget allows 10,000 / 30 = 333.3 bad events per day. Burning 2,500 in one day is a burn rate of 2,500 / 333.3 = 7.5×. Sustained at 7.5×, the 30-day budget is gone in 4 days. That is why alerting uses burn rate rather than raw consumption: 25% consumed on day 1 and 25% consumed on day 29 are different emergencies.

Python
def budget_state(good, total, slo, window_days, elapsed_days):
    budget = (1 - slo) * total          # 0.001 * 10_000_000 = 10_000.0
    consumed = total - good             # 10_000_000 - 9_997_500 = 2_500
    burn = (consumed / budget) / (elapsed_days / window_days)
    return budget, consumed, consumed / budget, burn

budget_state(9_997_500, 10_000_000, 0.999, 30, 1)
# (10000.0, 2500, 0.25, 7.5)

The Google SRE workbook's multi-window thresholds for a 30-day 99.9% SLO are 14.4× over 1h (5m short window), 6× over 6h (30m), and 1× over 3d (6h). The short window confirms the burn is still happening; the long window prevents a single spike from paging.

Event-based versus time-based

A request-based objective weights by traffic: 2,500 bad requests out of 10M is 25% of budget regardless of when they landed. A time-based availability objective weights by interval: 30 days is 43,200 minutes, so 0.1% is 43.2 minutes of full unavailability. Partial degradation maps differently: 50% of requests failing for 86.4 minutes consumes the same 43.2 minutes. Do not convert one into the other; a quiet hour and a peak hour are not interchangeable under a time-based SLI.

Failure modes and how you catch them

  • Denominator drift. Traffic halves and the same absolute bad count doubles the ratio. Track count and rate side by side; a rate-only dashboard hides this.
  • Late events. Recomputing after the window closes can flip a passing window to failing. Finalize after a fixed lag (commonly 24h) and re-evaluate, rather than freezing the first number.
  • Exclusions. Dropping health checks or a noisy client changes numerator and denominator. Every exclusion needs a written reason and a review date.
  • Rounding at low volume. 100 events at 99.9% gives a budget of 0.1 events: one failure is 10× over. Use a longer window or a count-based objective.
  • Time-based masking. An interval counts as good only if fully good, so a minute at 50% failure consumes a full bad minute.

Policy, not permission

Remaining budget is decision capacity: it is the release velocity the SLO permits. Exhausting it triggers a freeze and reliability work, not a licence to keep shipping. The budget tells you how much unreliability you have already spent, not how much harm is acceptable.

Curated: · Written: · Reviewed:

Difficulty: Medium
Q&A-11

Choose rolling versus calendar SLO windows.

Answer

What I'd say first

Ask what the objective decides. If it drives paging and error-budget policy, use a rolling window: 28 or 30 days is the common default (Datadog SLOs offer 7/30/90-day rolling; Prometheus computes it with rate(errors[30d]) or a recording rule). If it's a contractual or billing commitment: "99.9% per calendar month": the window is fixed by the contract and you use calendar. State three assumptions up front: timezone, data-finalization lag, and whether the SLA and the internal SLO share a budget.

Why rolling

Rolling is a moving aggregate over the last N days. It never resets, so an incident stays visible until it ages out. The cost is that you must aggregate over a moving range, and late-arriving data (samples that land 1–5 min after the fact) can change a window you already alerted on. Pin evaluation to finalized data.

Why calendar

Calendar aligns to the period people plan and bill in, and it's trivial to explain. The failure mode is the reset: at 00:00 on the 1st the budget snaps back to 100%, so an incident straddling the boundary is split and partly hidden.

Worked trace

99.9% over 30 days = 43.2 min of budget (0.001 × 30 × 1440). An incident starts 23:50 on Jan 31 and lasts 20 min.

windowJan consumptionFeb consumption
rolling 30d20 min = 46% of budgetsame window, still 46%
calendar month10 min = 23% of Jan budget10 min = 23% of Feb budget

Calendar splits the incident and hands February a 23% hole before the month starts; rolling keeps it whole.

Burn-rate alerting

Use multiwindow burn rates (Google SRE workbook): page at 14.4× over 1h (2% of a 30-day budget in an hour) confirmed by a 5m short window; page at 6× over 6h (5%); ticket at 3× over 1d (10%) and 1× over 3d (10%). These are built for rolling windows; on calendar they misfire near the reset.

Failure modes

  • Calendar reset hides a straddling incident: detect by comparing month-to-date burn against the same point in prior months.
  • Rolling over unfinalized data: alerts flap as late samples land; detect by re-evaluating the window after the finalization lag.
  • Timezone drift: a "monthly" SLO in UTC vs local shifts the boundary; name it explicitly.
  • SLA/SLO budget mixing: keep separate named calculations and never blend their budgets.

Backtest both against seasonality and past outages before committing.

Curated: · Written: · Reviewed:

Difficulty: Medium
Q&A-15

Instrument a latency SLO with Prometheus histograms.

Answer

First 90 seconds

Assume the SLO is 99% of GET /search under 300 ms over a 28-day window, service api, 15s scrape interval, and seconds as the base unit. Latency and availability are separate objectives, so 5xx is excluded from both sides of the latency ratio.

The measurement needs one number you can defend at exactly 300 ms. A Prometheus histogram gives that as a cumulative bucket count, so the SLI is the fraction of requests in the le="0.3" bucket. A quantile cannot give that: histogram_quantile interpolates linearly inside whatever bucket the threshold falls in, and per-instance quantiles are not averageable. The bucket ratio is additive, so it survives aggregation.

Instrument it

Go
// Go, client_golang v1.19. Buckets are seconds; 0.3 is an exact boundary.
var reqDur = prometheus.NewHistogramVec(prometheus.HistogramOpts{
    Name:    "http_request_duration_seconds",
    Help:    "Request latency.",
    Buckets: []float64{0.05, 0.1, 0.2, 0.3, 0.5, 1, 2.5},
}, []string{"route", "method", "status_class"})

reqDur.WithLabelValues(route, method, cls).Observe(elapsed.Seconds())

The library default layout (0.005 to 10s, jumping 0.25 then 0.5) has no 0.3 boundary, so it must be overridden. le is inclusive: an observation of exactly 0.3 s lands in le="0.3", not the next bucket. Seven buckets is seven bucket lines plus _sum and _count per label set; 20 routes * 4 methods * 3 status classes is roughly 2160 series, which is cheap.

The SLI query

PROMQL
sum by (job) (rate(http_request_duration_seconds_bucket{job="api",le="0.3"}[5m]))
/
sum by (job) (rate(http_request_duration_seconds_count{job="api"}[5m]))

Record that twice as job:sli_good:rate5m and job:sli_total:rate5m, then weight the 28-day window by volume:

PROMQL
sum(sum_over_time(job:sli_good:rate5m[28d]))
/
sum(sum_over_time(job:sli_total:rate5m[28d]))

Summing the rate before dividing keeps a busy hour from counting the same as a quiet one. The budget is 1% of 28 days, 403 minutes. 14.4x burn over 1h spends 2% of it, which is the alert I would staff.

Failure modes

  • Threshold is not a bucket boundary. With a 0.25/0.5 layout, le="0.3" matches nothing, the ratio is empty, and a < 0.99 alert stays silent. Guard the denominator: page when the 5m count rate is zero while traffic is expected.
  • Fast errors look good. How fast is a 3 ms 503. Carry status_class and filter status_class!="5xx" in numerator and denominator.
  • Unit drift. Millisecond values observed under a _seconds name make le="0.3" empty, the same silent failure. Caught by a unit test, not by production.
  • Staleness. A dead pod's series go stale after about 5 minutes while the rest keep reporting, so the ratio moves with no traffic change. Alert on sum(up{job="api"}).
  • Cardinality. Label by route, method, status class. Raw path or user ID multiplies against every bucket and is the usual outage.
  • Native histograms. With the server flag --enable-feature=native-histograms you can drop the fixed layout and use histogram_fraction(0.3, +Inf, rate(http_request_duration_seconds[5m])), which removes boundary artifacts, at the cost of the plain le query and tooling that ignores native histograms.

Check it works

A unit test through testutil.CollectAndCompare observing 0.299, 0.3 and 0.301: the first two land in le="0.3", the third in le="0.5". That one assertion pins the boundary and the unit. After any bucket change, keep the old recording rule or version its name, because a 28-day ratio spanning the change compares two different definitions.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-23

How should retried requests be counted in a request-based SLI, once per logical user request or once per attempt, and what does each choice do to the error budget when a downstream dependency is flaky?

Answer

Count once per logical user request for the success SLI. The SLI is a proxy for "did the user get what they asked for," and a request that succeeds on retry did: the user never saw the first failure. Counting per attempt measures the dependency's reliability, not the user's experience, and it turns the error budget into a proxy for your retry policy.

State the assumptions that make this valid: retries are transparent to the user (same logical operation, idempotent, bounded retry budget), and you can correlate attempts back to the logical request. A client-generated request ID, or a proxy/sidecar that owns the retry and emits one event per logical request with outcome and attempts.

Worked example. 1,000,000 logical requests over 28 days, 99.9% success SLO → 1,000 bad events of budget. A downstream dependency goes flaky: 0.5% of logical requests fail on the first attempt, and 90% of those succeed on one retry.

Once per logical requestOnce per attempt
Denominator1,000,000 requests1,005,000 attempts
Bad events500 final failures5,000 failed attempts
Error rate0.05%0.4975%
Budget consumed50%500%

Same incident. One definition leaves half the budget; the other says you are 5x over and the error-budget policy should freeze releases. The per-attempt number is dominated by failures no user experienced.

Mechanism: the denominator is the unit of work the user asked for. Retries are an implementation detail of delivering it. Count attempts and your error rate scales with your retry policy rather than with user harm: a team that retries 3x looks 3x worse than a team that retries once, for identical user experience. That inverts the incentive: it rewards giving up early.

When per-attempt is right: the retry is user-visible (the user re-submits), the operation is non-idempotent and a retry can double-charge or duplicate a write, or you are defining the dependency's own SLO rather than the caller's. Also when retries are unbounded: an infinite retry loop means the user waits forever, so "eventually succeeded" is not a success.

Failure modes and detection:

  • Retry storm. Per-logical counting hides amplification. If every caller retries 3x against a flaky dependency, load triples and the dependency degrades further. Detect with a separate diagnostic SLI: attempts / logical requests, alert when it exceeds ~1.05 for 10 minutes. That is a capacity signal, not an error-budget signal.
  • Latency SLI. A retried request's user-observed latency includes the retry. Count the full wall-clock from the user's perspective: a 200 ms p99 can become 600 ms while the success SLI stays clean. Success counts once; latency counts the whole duration.
  • Client-side retries. If the browser or mobile client retries, the server sees two requests and cannot tell they are the same logical operation without a correlation ID. If you cannot dedupe, you are implicitly counting per attempt: say so, and measure at the client if you can.
  • Hidden dependency degradation. Per-logical counting can keep the success SLI green while a dependency fails 2% of first attempts. Pair the success SLI with a dependency-level SLI so flakiness is visible before it becomes user-visible.

The error budget should be consumed by user-visible failures. Retry rate belongs in a separate alert that pages the dependency owner, not in the numerator of the user SLI.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-2

Design availability and latency SLOs for an API.

Answer

What I'd say in the first two minutes

Before picking numbers I'd ask three things: which client journeys matter, what the user experiences as failure, and what the dependency chain can actually support. Then I'd state assumptions out loud: public read/write API, interactive traffic, one region, the team owns the service end to end.

My default shape: availability SLI is good requests over valid requests, where good means a semantically correct response, not merely HTTP 200. Latency SLI is the fraction of valid requests served under a threshold, not an average. Targets: 99.9% availability and 99% of requests under 300 ms, over a rolling 28-day window. 99.9% over 30 days is 43 minutes 12 seconds of error budget: that's the number I'd defend in review.

What counts as a valid request

Exclude client cancellations (no outcome was produced), 4xx from malformed or unauthenticated traffic (the client's fault, not ours), and synthetic or load-test traffic tagged at the edge. Count 5xx and timeouts as bad. For retries, either count every attempt at the edge or dedupe by request ID: pick one and write it down. I'd dedupe, so a retry storm doesn't inflate the denominator and quietly improve the ratio.

Dependency-caused failures count as bad. Hiding them behind a separate dependency SLO doesn't help the user who saw the failure.

Where to measure

At the edge or load balancer, not the app server, so DNS, TLS and CDN misses are in scope. Compare that against client RUM and server-side histograms; a gap between them usually means edge or network, and it's the first thing I'd chase when the SLI looks better than the complaints.

Latency as a ratio, not an average

99% under 300 ms is a different promise from p99 = 300 ms, and the ratio form is what you can alert on. If bulk endpoints exist, give them their own looser threshold rather than averaging them into the interactive number.

Windows and alerting

Rolling 28 days for the SLO; calendar months only if finance or a contract needs them. For paging, the standard multiwindow, multi-burn-rate scheme from the SRE Workbook, applied to a 30-day window:

burn ratelong windowshort windowbudget consumed
14.41h5m2%
66h30m5%
13d6h10%

The short window is what makes the alert resolve quickly once the burn stops.

Edge cases I'd name

Low traffic: if a segment gets under roughly 1,000 valid requests per window, widen the window or aggregate segments. Don't alert on a three-request denominator. Missing telemetry: treat it as bad for availability, and cap the excluded fraction; if more than about 1% of requests lack telemetry, page.

Failure modes worth calling out: server-only measurement hides edge failures; averages hide the tail; per-operation objectives multiply until nobody reads the dashboard. Segment by region and operation only where user harm actually differs; and a target copied from another company's status page is a number, not an objective.

What would change my mind

If the dependency can't hold 99.9%, I'd lower the target and say so rather than publish a number we can't meet. If the product is bulk or batch, I'd split the objectives. Before paging anyone, I'd backtest against the last two incidents and shadow the alerts for two weeks.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-5

Set an SLO target without copying current availability.

Answer

Don't start from current uptime. Start from what the user needs and what the business can afford. For a checkout API, the user-visible SLI is successful checkout requests (HTTP 200 with order confirmation) over total attempts, measured at the load balancer over a rolling 28-day window. Current availability might be 99.95%, but that doesn't mean the target should be 99.95%. Instead, ask: what's the cost of downtime? If a 1-hour outage costs $50k in lost revenue and support, and we have 10 such incidents per year, that's $500k. If we can reduce to 1 incident per year with an extra $200k in engineering, the target might be 99.99% (52.6 minutes/year). But we need to check if we can detect and mitigate within the error budget. For 99.99%, monthly budget is 4.32 minutes. If our p99 detection time is 5 minutes, we can't defend it. So we might set 99.9% (43.2 minutes/month) initially, with a plan to improve detection to 1 minute and then tighten.

Assume a B2B SaaS with a 99.9% contractual SLA, 10k requests/min, and a 5-minute p99 detection latency. The table shows the trade-offs:

TargetMonthly error budgetRequired detection+mitigationCost to achieve
99.9%43.2 min< 10 min$0 (current)
99.95%21.6 min< 5 min$5k/month
99.99%4.32 min< 1 min$20k/month

The table shows that 99.99% is not attainable with current detection. A single 10-minute outage consumes 2.3x the monthly budget. You'll miss the SLO before you even know it's happening. Detection: alert on burn rate over 1-hour window; if 2% of budget consumed in 1 hour, page. But if your metrics pipeline has 2-minute delay, you can't react fast enough.

Backtest against historical incidents. Last year we had one incident of 2 hours (120 minutes). That would have blown 99.9% (43.2 min/month). So 99.9% is not attainable without architecture changes. We need to add redundancy to the database, which costs $5k/month. Then we can set 99.95% (21.6 min/month). A 20-minute outage would still consume 92% of the monthly budget, so we need to improve MTTR to 5 minutes. Set an error budget policy: if budget exhausted, freeze feature launches and focus on reliability. Review date: 3 months. Tighten only when user value and sustained evidence justify it; relax only through explicit product decision, never to erase a miss.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-13

Compose end-to-end reliability from dependency objectives.

Answer

First 90 seconds. I'd ask what the promise is, to whom, and over what window. "Checkout succeeds" at 99.95% monthly is 21.6 minutes of budget in a 30-day month (43,200 min × 0.0005): that number decides everything downstream. Then I'd draw the journey's conditional call graph and give each dependency its own objective, because end-to-end reliability is a budget you spend across dependencies, not a number you multiply.

Assumptions: single region, one checkout journey, monthly window, 30-day month.

The graph and the objectives.

dependencyrole in journeyobjectivemeasurednote
authrequired, blocking99.99%99.99%shared with login
inventoryrequired, blocking99.95%99.93%
paymentrequired, blocking99.99%99.98%external
fraudrequired, blocking99.9%99.9%
taxrequired, blocking99.95%99.97%
receipt emailoptional, async99.0%99.5%bypass on failure

Why multiplication lies. The product of the five blocking terms is 99.78%, or 95 min/month: four times the budget. That figure is a mean-field estimate valid only under independence. All five sit in one region behind one connection pool, so the tail is set by the shared component, not the product: a 4-minute region event hits all five at once, and the fallback path (cached inventory, queued receipt) usually lives in the same region and goes with them. Correlation moves the same mean loss into one large outage instead of many small blips: worse p99, worse user experience, and a single error-budget burn that trips the freeze.

Fanout and retries. Five blocking calls, each retried 3× on a 2s timeout, is 30s of worst-case latency against a 3s p99 budget for checkout. Retries must be budgeted per journey, not applied blanket: a retry budget of 10% of requests, with a circuit breaker that opens after 5 consecutive failures and a 30s half-open probe, keeps a slow dependency from becoming a load amplifier.

Failure modes, detection, cost.

failurehow it shows updetectioncost
retry stormpayment p99 300ms → 3s, retries triple load, queue growsattempts-per-request ratio, dependency queue depthmetastable: stays down after the trigger clears
shared pool exhaustionone slow dependency holds connections; unrelated calls p99 40ms → 180mspool wait-time histogram, saturation at 20 connectionscollateral: healthy dependencies fail
fallback that isn't goodfraud bypass approves orders, chargebacks risechargeback rate, not availabilityrevenue booked then reversed
stale partial successtax cache serves an old rate, order accepted silentlycache-age metric, daily reconciliationsilent financial drift

What I'd change. If the chain can't support the promise, in order: drop a blocking dependency (make receipt email async. Already done), add a tested fallback with a defined good outcome, isolate the shared pool per dependency, or renegotiate the objective with the product owner explicitly. Monitor the end-to-end user SLI as the authority and dependency metrics only for diagnosis; fault-test the correlated case (kill the region) and the partial case (return stale tax) and check that fallback outcomes still count as good.

When this is overkill. For an internal nightly batch job with no user-facing promise, one dependency objective and a retry is enough: the composition work only pays off when a user-visible budget is at stake.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-14

Design SLOs for an asynchronous data pipeline.

Answer

What I'd say first

Before picking numbers I need the decision this pipeline feeds and how late is too late. Assume: Postgres CDC → Kafka → Flink → Iceberg on S3 → dbt → a transactions_scored table a fraud model reads every 5 minutes. The consumer's decision is "score this transaction before the card is authorized," so a record that lands 20 minutes late is worthless. Freshness and completeness are separate SLOs; I would never collapse them into one uptime number.

The three SLIs

SLIDefinitionTargetWindow
Freshnessp99 of (publish_time − event_time) for records landing in the target≤ 5 min99% of 5-min windows over 30d
Completenessfraction of source CDC LSNs reflected in the target within 15 min≥ 99.9%30d rolling
Correctnesshourly partitions whose row count and amount sum match source control totals within 0.01%≥ 99.95%30d rolling

Freshness is measured on event time, not processing time: a Flink job that is alive but 40 minutes behind has perfect uptime and a broken SLO. Completeness is measured against source offsets (Kafka offsets or Postgres LSN), so a quiet period with zero events is 100% complete, not 0%.

Error budget and alerting

99.9% over 30 days is 43.2 minutes of budget. I'd use multi-window burn-rate alerts rather than a static lag threshold:

YAML
- alert: FreshnessBudgetFastBurn
  expr: (1 - sli:freshness_ratio:5m) / 0.001 > 14.4
  for: 2m
- alert: FreshnessBudgetSlowBurn
  expr: (1 - sli:freshness_ratio:1h) / 0.001 > 6
  for: 15m

14.4x over 1 hour burns 2% of the 30-day budget; 6x over 6 hours burns 5%. The fast alert pages, the slow one files a ticket. A static "lag > 5 min" alert fires on every backfill and gets muted within a week.

Failure modes I'd design for

  • Late or corrected data: the source emits a correction 3 hours later. The target must be idempotent on (source_key, event_time) so replay overwrites rather than duplicates. Detect via control-total mismatch, not row counts.
  • Backfill: excluded from the SLO window by tagging runs backfill=true; otherwise a 6-hour reprocess burns the whole month's budget.
  • Partial publication: Flink checkpoints to Iceberg but dbt has not run. The SLI reads the consumer-facing table, not the raw sink, so partial publication counts as a miss.
  • Telemetry outage: if the metric pipeline is down the SLI is unknown, not good. Alert on absent() and treat unknown as budget-consuming after 15 minutes.

What I'd not do

Not use HTTP uptime or job-success rate as the SLI: a job that succeeds while dropping 30% of records passes both. Not set the target from what the pipeline currently achieves; set it from the decision's tolerance, then check recovery capability. If we cannot reprocess 6 hours in under an hour, the target is aspirational and the on-call rotation will tell you so within a month.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-25

How do you define SLIs and SLOs for an internal platform service whose consumer is another engineering team, and keep the objective meaningful when the user journey is a caller's API contract?

Answer

Start by naming the caller and its contract. An internal platform's user is the calling service, and the user journey is the sequence of calls that service makes to you on a path it owns. So the first move is not to pick a metric but to read the caller's code and its timeout/retry config: which endpoints it calls, with what deadline, what it does on error, and whether it has a fallback. That tells you what "good" means at the boundary.

Assume the platform is a shared service (e.g., a feature-flag or auth service) with a handful of high-volume callers. Define one SLI per critical endpoint, measured where the caller experiences it. For a synchronous RPC, that is usually server-side at your handler, but the validity and success conditions must encode the caller's deadline: a request that returns 200 after the caller's 100 ms deadline is a failure, not a success. A workable SLI:

good = count of EvaluateFlag calls that return a decision with status OK and server latency <= 50 ms valid = count of EvaluateFlag calls that reach the handler and are not rejected by client-side validation

endpointgoodvalidtarget
EvaluateFlagOK and <=50 msreached handler99.9%
GetUserOK and <=200 msreached handler99.95%

SLO: 99.9% over a 28-day rolling window. Do not set the target from current performance; ask the caller what it needs and what it would page on. If the caller's own SLO assumes your service is 99.95%, your 99.9% is already a breach in their composition, so negotiate the number with them, and write it down.

Error budget: 0.1% of valid calls. At 1,000 rps that is ~2.4M failed calls over 28 days. The budget is only meaningful if it is shared and if breaching it changes behavior. The policy should say: when the budget is exhausted, the platform team freezes non-critical changes and the caller enables its fallback (e.g., cached flag values). If nothing changes, the SLO is decoration.

Three failure modes to name. First, measuring at the wrong point: server-side success while the caller times out and retries, so your SLI is green and the caller is burning its own budget. Second, aggregating heterogeneous callers: one caller at 10 qps and another at 10k qps in a single SLI hides the small caller's pain; break out per-caller or per-endpoint guardrails. Third, ignoring correctness: returning a stale or wrong decision in 5 ms is a fast failure, not a success. Add a correctness SLI (e.g., fraction of flag evaluations matching the authoritative config) if the caller depends on it.

Alternatives: a single composite SLI across all endpoints is easy to report but hides which contract broke; per-endpoint SLIs with per-caller breakdowns are more work but map to decisions. For low-traffic internal endpoints, use a longer window or a request-count-based objective rather than a percentage that never moves.

Keep the objective meaningful by tying it to a decision the caller and platform team both own. Review it when the caller's architecture changes: a new cache or a new deadline changes what "good" means.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-9

Write an error-budget policy for a product team.

Answer

Assume one product team owns a user-facing service, one SLO per critical journey, and a 28-day rolling window. I'd write this policy in the repo next to the SLO.

Core policy. The error budget is 100% minus SLO. For a 99.9% availability SLO over 28 days, that's 40 minutes 19 seconds of full outage equivalent. The budget is computed from the same request metrics that page on-call: e.g., a Prometheus recording rule over the load balancer's 5xx and latency histograms, not a separate dashboard. Burn rate is error rate divided by (1 - SLO). A burn rate of 1 exhausts the budget exactly at the end of the window. The policy has four states, triggered automatically.

StateTriggerAction
Normalburn < 1x and budget > 50%Ship normally. Canary 5% for 10 minutes.
Threatened2% budget in 1h (14.4x) or 5% in 6h (6x)Page on-call. Freeze risky releases: schema changes, new dependencies, traffic shifts. Canary 1% for 30 minutes. Reliability work gets top priority in sprint.
Exhaustedbudget <= 0Freeze all non-security releases. Any exception needs director approval. Incident review within 5 days.
Recoveringbudget > 0 and burn < 1x for 7 daysUnfreeze gradually: canary 1% -> 5% -> 25% over three releases.

Why burn rate instead of raw budget? Raw budget tells you how much is left; burn rate tells you how fast you're spending it. A team at 80% budget with a 14.4x burn will exhaust in hours. The 2%-in-1h alert catches fast burns; the 5%-in-6h catches slower ones.

Exceptions. Security fixes always ship, but they still count against the budget if they cause user-visible errors. Reliability remediations ship if they have a rollback and a canary; they count too. External or company-wide incidents are excluded only when the incident commander documents that the root cause is outside the product's control and the product could not have mitigated it. Load tests are excluded only in a maintenance window with synthetic traffic tagged; if they leak to real users, they count. Classification errors are corrected within 24 hours by two people, with an audit log entry. No exception is permanent; each has an owner, rationale, scope, and expiry date.

Dispute escalation. Product owner and SRE lead resolve disagreements in one business day. If unresolved, VP Engineering decides within one more day. Consumer communication: user-visible incidents get a status page update; internal budget state goes to #reliability.

Late data. If metrics arrive late, recompute the state. If the state changes, apply the actions from the original timestamp, but don't retroactively punish a team that already shipped under the old state.

Review. Monthly, review whether actions improved outcomes: did burn rate drop after a freeze? Did canary catch regressions? Check for gaming: exclusions above 5% of total errors, SLO target changes without an error-budget review, repeated classification errors. If found, the policy is violated.

Trade-off. Freeze when burn rate > 6x and errors are user-visible. Ship when the change is a security fix or a reliability remediation with a canary. The alternative, a hard freeze at any budget spend, kills innovation; no freeze at all kills reliability. The deciding criteria are blast radius, reversibility, and user impact. A failure mode to watch: if the SLO is set too tight, the team freezes permanently; detect by tracking days per quarter in Exhausted.

Curated: · Written: · Reviewed:

Difficulty: Medium
Q&A-10

Decide whether an incident should consume error budget.

Answer

Yes, if a real user's request failed, the budget moves. Who caused it decides who fixes it, not whether the number goes down.

Assumptions I'd state first: the SLO is defined on a user-facing SLI, e.g. 99.9% of /checkout requests returning non-5xx over a 28-day rolling window. That gives an error budget of 0.1% of valid events: 40 minutes 19 seconds of full-outage equivalent (28 days = 40,320 minutes; 0.1% = 40.32 min). Everything numeric below is a labelled hypothetical.

Worked example. The payment provider starts returning 503 at 14:02. Checkout requests fail for 12 minutes until the circuit breaker trips and the fallback queue takes over. Twelve minutes of full failure is 12 / 40.32 = 29.8% of the 28-day budget gone in one incident. The payment team didn't write the bug. The budget still burns, because the SLO is a promise about what users get, not a ledger of who to blame.

Why it works that way: the budget's only job is to predict user pain and gate releases. The moment you exclude failures by cause, the number stops tracking what users experience and becomes gameable: every hard incident gets reclassified as "external." Users don't have a dependency column in their mental model.

Alternatives, and when to pick them:

ApproachWhen it's rightWhat it costs
Budget counts all user-visible failuresDefault; the SLO is a user promiseTeams get dinged for vendor outages
Exclude dependency failuresOnly if the SLI is explicitly scoped to owned componentsBudget stops predicting user pain; invites blame-shifting
Separate budget from attribution ledgerAlways, alongside the first rowExtra bookkeeping, but no ambiguity

Deciding criteria: did a valid user request fail? Then budget. Does the team control the fix? Then they own remediation. Those are two different questions, and conflating them is how SLOs die.

Failure modes, with detection and cost:

  1. Dependency 5xx counted as good. Detection: compare edge 5xx count to the SLI good-event count each hour; a gap means the classifier only sees app-emitted errors. Cost: budget reads healthy while checkout is down, so releases ship into a broken journey.
  2. Budget exhausted unnoticed. Detection: multiwindow burn-rate alerts. 2% of budget in 1 hour (13.4× burn) pages, 5% in 6 hours (5.6× burn) tickets. Cost: the freeze lands after the window is already blown.
  3. Post-incident reclassification to protect the number. Detection: audit log of every classification change with approver and reason; a change that moves failing events to good without a code fix is the tell. Cost: the SLO loses credibility and teams route around it.

Unknown telemetry gets its own class and an investigation, not a default to good. Valid tests, malicious traffic and client cancellations follow the valid-event definition decided before the incident, not during it.

The rule: budget measures experienced unreliability. Attribution decides who carries the pager.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-18

Respond when an error budget is exhausted.

Answer

Assumptions I'd state first: a tier-1 user-facing service, availability SLI = fraction of non-5xx requests, SLO 99.9% over a rolling 30 days, multiwindow burn-rate alerting in Prometheus, and an error-budget policy that product and engineering signed off before the incident.

The answer in the first two minutes: find out whether something is still burning. If a page-level burn alert is live, that is incident response: mitigate first, policy second. Once the burn has stopped, apply the pre-agreed policy instead of negotiating it: freeze or throttle risky change on the affected service, its serving dependencies and the journeys that burned, exempt security patches and the reliability work that fixes the burn, attach a named owner and exit criteria to each contributing cause, and re-enter with staged deploys. The freeze is not a ban on all change, and it does not end on a calendar date.

Why the budget gates change at all. Burn rate is the observed error ratio divided by the budget rate: burn = error_ratio / (1 - SLO). At 99.9% the divisor is 0.001, so a 0.6% error ratio is a burn rate of 6x, and the budget window is 30 * 24 = 720 hours. A 6x burn held for 6 hours costs 6 * 6 / 720 = 5% of the budget. This gates deploys because change rate is the leading source of new failure modes, and the budget is the decision rule both sides agreed on before the incident: nobody is arguing about acceptable unreliability at 3am.

Long windowShort windowBurn rateBudget consumedAction
1 h5 m14.4x2%page
6 h30 m6x5%page, freeze tier-1 change
3 d6 h1x10%ticket, owner assigned

The long window is what alerts, the short window is what resolves; that pair stops a single blip from paging and stops a resolved incident from staying firing. Burn rate is computable directly:

sum(rate(http_requests_total{job="api",code=~"5.."}[1h]))
  / sum(rate(http_requests_total{job="api"}[1h])) / 0.001

What the policy says, concretely.

ControlFrozen during exhaustionExempt
DeploysTier-1 service and its serving dependenciesSecurity fixes, the fix for this burn, docs
FlagsNew default-on rollouts and broad cohort rampsKill switches, turning off the feature that burned
ApprovalsNormal peer review is not enough; add the service ownerIncident hotfix path, same canary

Exit criteria, not a date. Rolling compliance can recover on its own only as fast as the window rolls: if a 2-hour incident consumed the whole 30-day budget, that burn ages out over roughly 30 days. So policies exit on burn-rate signals plus risk reduction: no page-level burn alert for 24 hours, the top contributing action closed with its owner, and a floor on remaining budget (25% works as a starting number), then a staged re-entry: one deploy per service per day for three days, with an extended canary bake.

Failure modes I'd name. The release storm: work queues behind the freeze and ships in one burst, pushing change rate above the level that caused the burn, which is exactly why re-entry is staged. The blanket freeze that blocks the security patch or the fix for the burn itself. Freezing the wrong service because the SLI aggregates a shared dependency's failures. And SLO laundering: relaxing the target mid-burn to turn the number green. Reviewing the SLO afterwards, with data, is legitimate; it belongs in a separate documented change, not an emergency move.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-7

Design multiwindow burn-rate alerts for an SLO.

Answer

Assume a 99.9% availability SLO over a 30-day rolling window. The error budget is 0.1% of requests: 43.2 minutes of full-outage equivalent (0.001 × 43,200 min). The SLI is the fraction of requests that are good, classified at the edge: a 5xx or a timeout is bad, a client 4xx is not.

Burn rate is the observed bad-event rate divided by the allowed bad-event rate: burn = bad_rate / 0.001. Burn rate 1 exhausts the budget exactly at the end of the 30 days; burn rate 14.4 exhausts it in about two days. You don't ship one alert. You ship a set of (long window, short window, threshold) triples, each tied to how much budget you're willing to spend before you're told.

LongShortBurnBudget spentAction
1h5m14.42%page
6h30m65%page
1d2h310%ticket
3d6h110%ticket

Derive each threshold instead of copying it. threshold = budget_fraction × SLO_period / window. For 2% over 1h with a 720h period: 0.02 × 720 / 1 = 14.4. For 5% over 6h: 0.05 × 720 / 6 = 6. The fraction is the decision you actually make, how much budget you'll let a fast incident eat before paging, and the window follows from how long you're willing to wait.

Detection latency falls out of the same arithmetic. A total outage runs at burn 1000 (100% errors / 0.001). The 1h window's average reaches 14.4 after 14.4 / 1000 × 60 min ≈ 52 s, so the fast tier pages under a minute into a hard outage. The 6h tier reaches 6 after 6 / 1000 × 360 min ≈ 2.2 min. A partial outage at exactly 1.44% errors sits at burn 14.4 and takes the full hour to trip: severity buys you speed.

Why pair a short window with each long one. The long window is what makes the alert meaningful: it averages out noise and only fires on sustained burn. But it also holds history, so after the incident recovers the long window keeps showing elevated burn for up to its full length and the alert stays firing. The short window is the reset condition: it must also be over threshold right now. A three-minute blip at 100% errors drags the 1h average to burn 50 and would page on its own; the 5m window reads zero once the blip ends, so the pair stays quiet. That is the whole mechanism: long window for significance, short window for currency.

Concrete failure modes and how you catch them:

  • Low-traffic cohorts. One bad request out of three is a 33% error rate, burn 333, and pages on nothing. Gate evaluation on a minimum request rate (say ≥ 1 req/s across the window); below it, suppress and rely on a slower aggregate.
  • Missing data. If the metric pipeline stalls, bad_rate is 0/0 and the alert reads healthy while you're blind. Alert separately on absence of samples (no data for 5 min), not on burn.
  • Flapping. Without the short window, a recovered incident keeps the long window hot and you page on something already fixed. The short window going to zero is the clear.
  • Cohort blindness. Aggregating to get signal can hide a single critical endpoint failing. Keep a per-cohort burn alert on the endpoints that matter, accepting the lower traffic.

The 1d/3d tiers are tickets, not pages: 10% of budget is worth a working-hours response, not a 3 a.m. wake-up. Route them to the owning team with the objective, runbook and dashboard linked, and dedupe so one incident doesn't fire four tiers at once. Before trusting any of it, backtest the thresholds against past incidents and benign spikes, then shadow-run them against live traffic and check precision, recall, time-to-detect and time-to-reset.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-8

Handle SLO alerting for a low-traffic service.

Answer

For a low-traffic service, the standard multiwindow multi-burn-rate alerts from the Google SRE workbook break because the short windows have too few requests to compute a meaningful burn rate. I'd start by quantifying the traffic and the error budget. Assume 1 request per minute, SLO 99.9% over 30 days. That's 43,200 requests per month, error budget 43.2 minutes. One failed request consumes 2.3% of the monthly budget. A 1-hour window at 1 req/min has 60 requests; a single failure is a 1.67% error rate, which is 16.7x burn, so it would page on a 14.4x threshold. That's too noisy. So I'd move to longer windows: 6h and 3d, with a minimum request count.

Burn rate is error rate divided by (1 - SLO). For 99.9%, 1x burn equals a 0.1% error rate. A 6x burn is 0.6% error rate. Over 6h at 1 req/min, that's 360 requests, so 0.6% of 360 is 2.16 requests. You need at least 3 failures in 6h to hit 6x burn. That's a reasonable page. For slow burn, use a 3-day window: 4320 requests, 1x burn is 0.1% error rate, so 4.32 requests. Five failures in 3 days is a ticket.

WindowBurn rateError rateRequests at 1/minFailures to triggerAction
6h6x0.6%3603Page
3d1x0.1%43205Ticket

Add a minimum request count so the alert doesn't fire on a single request. In Prometheus 2.45, a rule for the 6h page looks like this:

YAML
- alert: HighErrorBudgetBurn
  expr: |
    sum(rate(http_requests_total{job="my-service", code=~"5.."}[6h]))
    /
    sum(rate(http_requests_total{job="my-service"}[6h]))
    > 0.006
    and
    sum(increase(http_requests_total{job="my-service"}[6h])) > 10
  for: 5m
  labels:
    severity: page

The increase(...) > 10 guard means the burn rate is only evaluated when there are at least 10 requests in the window. If traffic drops to zero, the denominator is zero and the expression yields NaN, which doesn't trigger. But that guard can hide a real outage if all requests fail and the count is below 10. So add a separate invariant alert: if every request in the last 5 minutes is a 5xx and there is at least one request, page immediately. That catches total failure without waiting for volume.

YAML
- alert: TotalFailure
  expr: |
    sum(rate(http_requests_total{job="my-service", code=~"5.."}[5m]))
    ==
    sum(rate(http_requests_total{job="my-service"}[5m]))
    and
    sum(increase(http_requests_total{job="my-service"}[5m])) >= 1
  for: 1m
  labels:
    severity: page

Failure modes: a minimum-volume rule can mask a slow degradation if traffic is low but errors are consistent. Synthetic traffic can keep the denominator high and hide real user impact. Aggregating similar services can dilute a single service's outage. Fallback or queueing converts failures into latency, which still violates a latency SLO. Detect these by simulating a single failure, a burst, a prolonged outage, and no traffic; then review page precision and user impact. Show raw counts beside ratios so you can see whether a burn rate comes from 3 failures out of 360 or 300 out of 36,000. Use tickets for slow burn when response need not be immediate. If the metric is missing, don't treat it as zero errors; alert on missing data separately.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-19

Handle delayed or corrected telemetry in SLO reporting.

Answer

Clarify first. Two things decide the design: is the SLO a rolling 30-day window or a calendar month, and does the consumer of the number take an automated action (page, freeze releases, error-budget policy) or just look at a dashboard? A 99.9% SLO over 30 days is 43.2 minutes of budget. A 12-minute late batch is 28% of it, so lateness handling is not a rounding detail.

Assumptions I'd state. Events carry a producer timestamp (event time) and arrive with a lag; the pipeline has a bounded lateness budget; the SLO is computed from a deduplicated, versioned event table; alerts may read provisional data, policy actions read only finalized data.

The core. Keep two clocks. Kafka's message.timestamp.type defaults to CreateTime, i.e. producer event time: that is what you window on; LogAppendTime gives broker ingestion time, which is what you measure lag with. In Flink, watermarks track event time and allowedLateness defaults to 0, so any element later than the watermark is dropped unless you set a lateness bound and route late elements to a side output. Set the bound from measured lag, not taste: if p99 ingestion lag is 90s and p99.9 is 12 minutes, a 15-minute lateness bound and a 30-minute finalization boundary cover all but a sliver. (Hypothetical figures, for the shape of the argument.)

Then split the report into provisional and finalized. Provisional is everything ingested so far, labelled with coverage (events seen / events expected from the manifest) and freshness (now minus max event time). Finalized means the window is closed and the aggregate is frozen. Alerts can fire on provisional data: the multiwindow multi-burn-rate recipe in the Google SRE Workbook pairs a 5-minute short window against a 1-hour long window at 14.4x burn (2% of a 30-day budget), 30m/6h at 6x, and 6h/3d at 1x, but a policy action like "freeze releases" should require the finalized number, or explicitly declare that it acts on provisional data and can be reversed.

Dedupe by a stable event identity (producer id + sequence, or a content hash), never by arrival order. Corrections are new versions, not in-place updates:

SQL
-- Postgres 16
WITH latest AS (
  SELECT *, ROW_NUMBER() OVER (PARTITION BY event_id ORDER BY version DESC) AS rn
  FROM slo_events
)
SELECT window_start,
       COUNT(*) FILTER (WHERE outcome = 'bad') AS bad,
       COUNT(*) AS total
FROM latest
WHERE rn = 1
GROUP BY window_start;

Trace on four rows: (e1,v1,10:00,good), (e2,v1,10:00,bad), (e2,v2,10:00,good), (e3,v1,10:00,bad). The window function numbers e1→1, e2v2→1, e2v1→2, e3→1. After rn = 1 the survivors are e1 good, e2 good, e3 bad. Output: 10:00 | 1 | 3, a 33.3% error rate. Before the correction it was 2 | 3, 66.7%. That delta is what a restatement notice has to carry: prior value, new value, cause, and which policy decisions (breach declared, release frozen) are affected.

Failure modes. A watermark stalls when one partition goes quiet: use an idle-source timeout, or the pipeline freezes and provisional never becomes final. Clock skew between producers puts events in the wrong window; clamp event time to ingestion time ± the lateness bound and count the clamps. DST and timezone changes break naive date_trunc bucketing: store UTC and bucket in UTC. Backfills arrive as a bulk restatement, not as late events; run them through the same versioned path so the audit trail is uniform. Prometheus's TSDB rejects samples older than the newest sample for a series unless out-of-order ingestion is enabled, so a backfill into Prometheus needs a different route: recompute recording rules, or write a separate backfill series.

Don't. Don't silently rewrite a closed report, and don't shift late bad events into the current window to make last month look clean. Reconcile finalized aggregates against the raw event manifest and notify owners when a restatement changes breach or SLA status.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-16

Validate an SLO implementation before using it for policy.

Answer

Assume a user-facing checkout API, 30-day rolling window, 99.9% availability target. Error budget is 43m12s per 30 days (30×24×60×0.001). Measurement point is the edge load balancer, not the app server, because client aborts and TLS failures never reach the app. Owner is payments platform. If this SLO only feeds a dashboard, I'd do a lighter pass: spec review plus one week of query-vs-raw reconciliation. If it pages or gates releases, I'd run the full validation below.

First, freeze the spec in version control: service, population, good condition, measurement point, target, window, exclusions, missing/late-data policy, owner. The spec is the oracle. For this SLO, good means edge status 2xx/3xx and duration ≤300ms; excluded means health checks and synthetic probes; missing means no edge event, and I treat it as bad rather than dropping it.

Second, build fixtures where every classification and budget value is hand-computable.

#edge eventexpectedbudget
1200, 120msgood0
2500, 80msbad1
3200, 300msgood0
4200, 301msbad1
5499, 2000msbad1
6health check 200, 10msexcluded0
7retry: 500 then 200, same request_idgood0
8client timeout, no edge eventbad1
9unknown status "-"bad1
10duplicate edge event, same request_idignored0

Counted requests = 8. Good = 3 (#1, #3, #7). Bad = 5 (#2, #4, #5, #8, #9). SLI = 3/8 = 37.5%. Error budget consumed = 5/8 × 43m12s = 27m. If the query returns 50% or 100%, it is counting retries or health checks.

Third, reconcile. Run this as a recording rule slo:checkout_availability:ratio_30d:

PROMQL
sum(rate(edge_requests_total{job="checkout",route="/pay",excluded!="true",status!~"5.."}[5m]))
/
sum(rate(edge_requests_total{job="checkout",route="/pay",excluded!="true"}[5m]))

For the latency half, use http_request_duration_seconds_bucket{le="0.3"}. Compare the rule to a Python/SQL calculation over raw edge logs. Fail if any hour differs by more than 1 bad event or 0.05 percentage points. Reconciliation catches drift because the query aggregates at scrape time; raw logs show the actual request_id, status, and duration.

Fourth, replay 3 incidents and 3 healthy days. Example: a provider timeout from 14:00–14:20 should drop SLI from 99.95% to 97.2%; a healthy day should stay 99.93–99.97%. If SLI moves on a deploy that only changes internal health checks, the exclusion is wrong.

Fifth, inject failures. Drop 5 minutes of edge metrics: query must return no data or fire absent(), not 100%. Reset a counter: rate() handles it. Delay ingestion by 10 minutes: late data must not be treated as missing. Duplicate events: dedup by request_id. Rename status_code to http_status: CI must fail.

Sixth, policy parity. Dashboard, alert, and release gate must read the same recording rule. If the alert uses 5m and the gate uses 30d, they can disagree. Shadow decisions for 2 weeks before enforcement. Review permissions: the SLI query must not read PII; use aggregate labels.

Alternative: synthetic probes. They catch total outage but miss partial user harm and client aborts; use them as a second signal, not the SLI. Full validation costs about 3 engineer-days plus 2 weeks shadow. A dashboard-only SLO gets spec review and one reconciliation run. A vendor SLO engine still needs reconciliation because retry and missing-data semantics differ.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-20

Audit SLO exclusions for gaming and drift.

Answer

Answer

An SLO exclusion is a filter on the event stream that feeds the SLI. It moves the numerator and the denominator at the same time, so a wide enough exclusion makes a breach disappear without changing what any user experienced. That is the threat model, and the audit exists to make that movement visible and bounded.

Assumptions worth stating up front: the raw, unfiltered event stream is retained alongside the filtered one; exclusion rules live in version control as part of the SLI definition, not in a policy wiki; every rule carries an owner, an approval and an expiry date.

Two different problems get called "exclusion governance". Gaming is widening a filter, often lazily rather than maliciously, so failing traffic stops counting. Drift is a filter that was defensible when written and became wrong while nobody touched it: a wildcard matcher absorbs a new endpoint when a deprecated route name is added, ownership transfers out of the org, a dependency becomes critical-path, a new status code lands inside an existing "expected" bucket.

The audit is four moves.

  1. Make the rule the unit of record, not the policy document. The actual expression, its owner, its approval, effective and expiry dates, its approved cap as a fraction of traffic, and the volume it matches today.
  2. Measure excluded volume as a fraction of total traffic, per rule, never as a raw count. Alert when a rule exceeds its cap or doubles week over week.
  3. Verify against evidence. Sample excluded events (100 per rule per month, or all of them if fewer), replay against raw edge or client telemetry, and compute exclusion precision: truly-outside divided by sampled. A rule below roughly 95% precision is too broad.
  4. Control change like code: review, cap, expire. Do not accept an exclusion added solely to clear a breach; do accept reasoned reclassification, with old and new SLI values both logged.

Here is what one exclusion can hide. Hypothetical but representative numbers: a 99.9% journey SLO over 10,000,000 requests per day permits 10,000 bad events. A dependency outage fails 300,000 requests, 3% of daily traffic. Excluding "dependency-caused" cuts the denominator to 9,700,000, so permitted bad drops to 9,700 and the 300,000 failures leave the visible record. At the daily rate of 10,000, one exclusion erased 30 days of error budget. If that dependency sits on the critical path, users saw an outage and the dashboard stayed green. Excluding events from your SLO never excludes them from the user's experience.

The rule and its guardrail, a fragment of a rule group checked against Prometheus 2.x syntax:

YAML
- record: slo:excluded_fraction:5m        # keep the rule label
  expr: |
    sum by (rule) (rate(slo_events_total{excluded="true"}[5m]))
      / sum by (rule) (rate(slo_events_total[5m]))

- alert: SLOExclusionOverCap
  expr: slo:excluded_fraction:5m > on (rule) slo_exclusion_cap_fraction
  for: 30m

The unfiltered counter is the audit's anchor: a gap between the raw stream and the filtered one that widens with no matching rule commit is drift by definition.

PatternSignal that catches it
Wildcard absorbs a new routeRule matches label sets it never matched the week before
Owner dissolved, rule survivesExclusion owner missing from the on-call directory
Denominator shrinkExclusion fraction above its approved cap
Retcon after an incidentRule committed within 24h of a burn-rate alert
Relabelling at ingestionGap between raw and filtered event counts

What this costs. Sampling, replay and review of SLI changes is real work, and a per-change approval gate stalls incident response during a genuine dependency outage. So pre-approve a capped, expiring class of dependency exclusions that responders apply immediately, with review the next business day. For a team with fewer than ten exclusions, a quarterly review with the SLO owner and no per-change gate is enough; the full apparatus earns its keep only where excluded traffic is a material share of the total. Alert on fractions rather than counts, or ordinary traffic growth pages you. And a blanket ban on retroactive change pushes corrections into ingestion-time relabelling, which is worse because it is invisible.

Two failure modes to name out loud. An exclusion whose precision was never measured, so nobody knows the user harm it conceals. And ownership loss: the rule outlives its team, nobody can defend it, and it survives by default.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-17

Migrate an existing SLO definition without rewriting history.

Answer

Assumptions. The SLO is defined as code (a Prometheus recording rule generated by Sloth, or an OpenSLO/Datadog definition) under version control, and its error budget drives burn-rate alerts and release policy. Prometheus is the store, default retention 15d (--storage.tsdb.retention.time=15d), scrape interval 1m. The question is how to change the definition without making the historical budget unreadable.

Core answer. Version the definition; never edit it in place. Keep the old recording rule writing under its old series name and add the new one under a new name, so both are evaluated against live traffic. Backtest the new predicate over the retention window, quantify the delta, then cut over by freezing the old series and repointing dashboards and alerts at the new one. History survives because raw samples are immutable; what changes is which derived series the budget is computed from.

Why history breaks. An error budget is a ratio accumulated over the window. Change the good-event predicate or the population and you change the numerator and denominator of every past instant, but the old derived series was computed under the old predicate. You cannot recompute it unless the underlying telemetry carries the new dimension. If the new exclusion is a label that was never emitted, the backtest returns empty series; that is the signal to fix instrumentation, not to tune the target.

PROMQL
# old
sum(rate(http_requests_total{code=~"5..|4.."}[5m]))
  / sum(rate(http_requests_total[5m]))
# new
sum(rate(http_requests_total{code=~"5..",path!="/healthz"}[5m]))
  / sum(rate(http_requests_total{path!="/healthz"}[5m]))

Trade-off: new SLO vs migrate. Decide on comparability. If the change alters population or measurement point (client-side to server-side, adding an exclusion cohort) old and new numbers are not comparable and consumers cannot read a trend across the boundary, so create a new SLO with a new name and a fresh budget. If it is a target or window change on the same SLI, migrate in place. Cost of migrating: a step change in the series that every consumer must be told about. Cost of a new SLO: two names to track and no historical budget context.

Worked backtest. 30-day window, target 99.9%, 100M requests.

oldnew
populationall requestsexcludes /healthz (2M)
bad events5xx 80k + 4xx 30k = 110k5xx only = 80k
denominator100M98M
SLI99.89%99.918%
allowed bad100k98k
budget consumed110%81.6%

The system did not change; the definition moved the SLO from over budget to under budget. That delta is what you explain to consumers before cutover, not after.

Failure modes. Late-arriving events in a warehouse-computed SLI change the numerator after the window closes: detect by recomputing at T+1h and T+24h and diffing. Parallel-run alert duplication: both old and new burn-rate rules fire, doubling pages. Count pages per shift and silence the old rule's notifications, not its evaluation. Label cardinality blowup from a new exclusion: check series count before enabling.

Cutover. Record the effective timestamp and owner in the definition. Freeze the old series (stop writing, keep samples for retention), repoint dashboards and the burn-rate alerts (14.4x over 1h/5m, 6x over 6h/30m for a 30d SLO, per the SRE Workbook) at the new series. Keep the old samples until retention expires so the transition is auditable. Rollback is a config revert; it does not delete the new series' samples.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-12

Prevent aggregate SLOs from hiding cohort harm.

Answer

Assumptions first. The global SLO is a contract on aggregate traffic; harm is per cohort. A cohort is any label combination with a distinct journey or consequence: region, operation, device class, tenant tier, accessibility path. I'd also assume the global objective is worth keeping: the goal is to stop it hiding harm, not to replace it with 200 objectives.

The core answer. Three tiers.

  1. Own SLO, own owner, own burn alerts for cohorts with a distinct contract or a blast radius that matters: paid tier, a region under data-residency rules, a critical accessibility path. Same SLI definition, different objective, different routing.
  2. A guardrail that ignores the budget. For each critical cohort, alert on absolute cohort error rate, error_ratio > 0.05 for 10m, regardless of how much global budget is left. This is what catches a cohort that is 100% down while the aggregate is green.
  3. Diagnostic slicing for the rest. Dashboards and ad-hoc queries, no paging.

Why the aggregate can't do it. A 99.9% SLO over 30 days is a 43.2-minute budget. Burn rate is error_ratio / (1 - SLO), so the standard page threshold of 14.4 (2% of budget in 1h, from the Google SRE Workbook's multiwindow multi-burn-rate scheme) needs a global error ratio of 1.44%.

cohort share of trafficcohort fully down 24hglobal error ratio during outageglobal burn ratepages at 14.4?
0.1%yes0.1%1.0no
1%yes1%10no
5%yes5%50yes

Any cohort below ~1.4% of traffic can be completely down and never trip the page threshold. At 0.1% it doesn't even reach the 1.0 ticket threshold.

Implementation. Recording rules per cohort class, not per tenant:

YAML
- record: slo:sli_error:ratio_rate5m
  expr: |
    sum by (tenant_class) (rate(http_requests_total{code=~"5.."}[5m]))
    / sum by (tenant_class) (rate(http_requests_total[5m]))
- record: slo:burn_rate5m
  expr: slo:sli_error:ratio_rate5m / (1 - 0.999)
- record: slo:burn_rate1h
  expr: |
    (sum by (tenant_class) (rate(http_requests_total{code=~"5.."}[1h]))
     / sum by (tenant_class) (rate(http_requests_total[1h]))) / (1 - 0.999)

Alert on two windows so one spike doesn't page:

YAML
- alert: TenantErrorBudgetBurn
  expr: slo:burn_rate1h{tenant_class="paid"} > 14.4
        and slo:burn_rate5m{tenant_class="paid"} > 14.4
  for: 2m

Sloth, Pyrra and OpenSLO generate these from an SLO spec; Datadog SLOs support group-by with per-group alerting; Grafana and Nobl9 do the same. Pick one and keep the SLI definition identical across tiers so the numbers stay comparable.

Failure modes and what catches them.

  • Cardinality blowup. A per-tenant label over 10k tenants × 4 SLIs × 3 windows is 120k series before you add anything else. Slice by class, not by tenant; keep tenant-level detail in logs or a warehouse.
  • Tiny samples. A cohort doing 50 requests/day can't support 99.9%: one failure is a 2% error rate. Require a minimum volume (say ≥1 req/min) before a cohort gets an SLO; below that use synthetics or a direct critical-failure alert.
  • Alert storm. 200 cohorts × page = 200 pages. Cap paging cohorts to a handful, route the rest to tickets, and add a count threshold so one cohort can't page more than once per window.
  • Privacy. Tenant IDs in labels leak into shared Grafana dashboards and alert payloads. Use opaque class labels in metrics, keep the mapping in the config repo, and never put tenant names in a public dashboard URL.

The test I'd run. Take the smallest critical cohort, take it fully down in staging, and confirm the global objective stays green while the cohort guardrail fires and routes to the right owner. Then check the reverse: a global outage still pages. If the cohort alert doesn't fire, the slicing is decorative.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-22

Design privacy-conscious client-side SLI telemetry.

Answer

Core answer, first 90 seconds

Assumptions I'd state up front: multi-tenant web app, GDPR-style regime, telemetry justified as strictly necessary; the SLI is checkout completion rate plus p75/p95 journey duration; durations come from performance.now() deltas, which are monotonic, so an NTP correction mid-session cannot produce a negative or inflated value.

The design: one allowlisted event per journey boundary. Journey enum, outcome enum, bucketed duration, coarse cohort, instrumentation version, plus a random per-page-load id that exists only so the collector can dedup retries inside a 30-second window, and is dropped before rollup. No URL, no request payload, no account id, no absolute timestamp. Storage is per-tenant count buckets. Sampling is decided once per page load. And because a browser client cannot be authenticated, client events land in their own pipeline and never gate an error budget or an invoice without a server-side cross-check.

The event, traced

JavaScript
// ES2023, browser; Beacon and crypto.randomUUID are widely available
const EDGES = [100, 300, 1000, 3000, 10000];   // ms, upper edges
const bucketOf = ms => {
  for (let i = 0; i < EDGES.length; i++) if (ms < EDGES[i]) return i;
  return EDGES.length;                          // >= 10 s
};
const pageId = crypto.randomUUID();
const sampled = parseInt(pageId.slice(0, 8), 16) % 10 === 0;  // p = 0.1 per page load
const queue = [];

function emitJourney(journey, outcome, ms, cohort) {
  const body = JSON.stringify({
    j: journey, v: 'checkout-v3', o: outcome,
    b: bucketOf(ms), c: cohort, p: pageId, s: sampled ? 1 : 0
  });
  if (!navigator.sendBeacon('/t', body)) queue.push(body);
}
addEventListener('pagehide', () => queue.forEach(b => navigator.sendBeacon('/t', b)));

Trace emitJourney('checkout', 'ok', 420, 'mobile-4g') with pageId 4f2a9c11-…. bucketOf walks the edges: 420 < 100 false, 420 < 300 false, 420 < 1000 true, so it returns 2. The 300–1000 ms band. parseInt('4f2a9c11', 16) is 1328192529, and 1328192529 % 10 is 9, so s is 0. The body is {"j":"checkout","v":"checkout-v3","o":"ok","b":2,"c":"mobile-4g","p":"4f2a9c11-...","s":0}: about 115 bytes, so 20M journeys/day is 2.3 GB/day uncompressed. The mod-10 bias over the 32-bit space is under 1e-8.

One beacon per journey is wasteful; a one-second buffer cuts requests roughly 10x. The cost is whatever sits in the buffer when the tab dies, which is why the unload flush uses sendBeacon, and why a false return (UA refusing the request) pushes into a queue.

Why the schema stays this narrow

Series count is the product of the dimension cardinalities: 400 tenants * 12 journeys * 4 outcomes * 6 duration buckets * 6 cohorts = 691,200 series. Add a route-template dimension with 5,000 distinct paths and the ceiling becomes 691,200 * 5,000 = 3.46 billion: more than any time-series store will hold. The same dimension is the leak: query strings carry reset tokens and email addresses, so the URL is both the cardinality bomb and the PII.

Sampling

Sampling per page load rather than per event matters because the estimator is completions / starts. Sampling each event independently draws the numerator and denominator from different populations: a sampled completion whose start was not sampled reads as an abandonment, and completion rate is biased downward. A per-page-load draw keeps a journey wholly in or wholly out, and the denominator is reconstructed as count / 0.1. At p = 0.1 the standard error of the rate scales by 1 / sqrt(0.1) = 3.16, and quantiles get thin: a rule of thumb of at least 500 observations in the tail means 5,000 journeys per tenant-journey-window, so a tenant doing 800 journeys/day estimates p95 over a 7-day window or reports p75 instead.

DecisionFlip criterion
Ephemeral page-load id vs session idSession id (sessionStorage, 30-minute TTL, rotated on logout) only when the journey crosses route changes and needs stitching
Sample vs capture everythingSample when series or volume is over budget; capture errors at 100%, since an error rate of roughly 0.5–2% is cheap and preserves the tail
Ephemeral vs persistent pseudonymRetention analysis ("did users come back") needs a persistent id, which is personal data: DPIA, consent where consent is the basis, a retention cap, and a deletion path. A Sec-GPC: 1 opt-out signal is honored in the same path

Failure modes

Ad blockers drop beacons, so track the client/edge ratio per tenant: a fleet median near 0.92 against a tenant at 0.55 is blocking, not an outage, and it should never page on its own. A client can POST any tenant id, so client SLI stays out of billing entirely. Measure receivedTs minus clientTs and drop events older than 24h, alerting when p95 lag passes 5 minutes. Suppress dashboard cells under n = 50. Client telemetry is also the wrong instrument for third-party API availability: measure that server-side. The honest label for all of it: experience coverage, not user coverage. Cross-check against edge logs and publish the blind-spot ratio beside every client-side SLI.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-21

Use SLOs during canary and progressive delivery.

Answer

Core answer (first 90 seconds)

Clarify first: which SLO, on which user journey, and what the rollout mechanism can actually do. Pause, shift traffic, roll back. Then:

  1. Pick release-sensitive SLIs (availability and latency on the critical journey (checkout, login, search)) plus safety invariants that are not budgeted at all: data corruption, auth bypass, double-charge. One invariant event is a stop; no burn math applies.
  2. Run the canary as a controlled experiment against a concurrent baseline cohort, not against last week's numbers. Same region, same traffic mix, same window.
  3. Compute burn rate on the canary cohort itself, not on the aggregate. This is the part people get wrong.
  4. Gate each progressive stage (1% → 5% → 25% → 50% → 100%) on a pre-declared evidence floor and burn ceiling, with automated pause/rollback, a blast-radius cap, and a human override.

Why cohort burn, not aggregate

Burn rate = observed error rate / (1 − SLO). At 99.9% over 30 days the budget is 0.1% of requests, or 43.2 minutes of full-traffic failure.

Say the canary takes 5% of traffic and its error rate is 1%: 10x the 0.1% target. Canary burn = 10x. Aggregate error rate = 0.95×0.1% + 0.05×1% = 0.145%, so aggregate burn = 1.45x. A global fast-burn alert at 14.4x never fires. That dilution is the whole reason you compute per-cohort.

Sample size is the other half

To measure a 0.1% rate to ±20% relative precision you need n ≈ p(1−p)/SE² = 0.001 / 0.0002² ≈ 25,000 requests in the cohort. At 50 rps that is about 8 minutes; at 1 rps it is about 7 hours. Below that floor, a quiet canary is not evidence of health: it is absence of data. "No errors in 10 minutes" is not a pass.

Gate table (multiwindow multi-burn-rate, Google SRE Workbook ch. 5):

SignalWindowThresholdAction
Canary fast burn1h≥14.4x (2% of 30d budget)auto-rollback
Canary slow burn6h≥6x (5% of budget)auto-pause, page
Safety invariantany≥1 eventauto-rollback
Evidence floor—<25k canary requestshold, do not promote

Trade-offs

Canary size trades detection speed against blast radius: 1% of traffic is safer but needs a longer soak to clear the evidence floor; 10% gets you there faster and exposes more users. A tight SLO (99.99% → 4.32 min/month) makes the budget small in absolute terms, so you must alert on the cohort and roll back fast: a small canary slows budget consumption but also shrinks the sample, so you buy time at the cost of evidence. Budget policy caps total risk across releases; it does not tell you whether this release is bad.

Failure modes and how you see them

  • Bad release: canary burn spikes, baseline flat → cohort burn alert fires.
  • Dependency incident: both cohorts burn equally, ratio ≈ 1 → do not blame the release, but pause anyway to avoid adding load.
  • Biased routing: canary gets a different region/device/endpoint mix → compare request-mix distributions; if they diverge, the comparison is confounded.
  • Telemetry loss: canary event volume drops below expected → treat as no-data, never as healthy.
  • Rollback failure: burn stays elevated after rollback → needs a tested kill switch and a post-rollback burn check.
  • Repeated attempts: re-running the same canary unchanged reproduces the failure; require a change or a new hypothesis.

Keep observing after promotion: slow burn shows up over hours, not minutes.

Curated: · Written: · Reviewed:

Difficulty: Hard
Q&A-24

Review SLOs after an incident that did not breach them.

Answer

What I'd say in the first two minutes

An incident that hurt users but didn't burn the budget is a bug report about the SLO, not about the incident. The SLO did what it was defined to do, so the question is whether that definition still tracks user pain. I'd reconstruct the harm first, then ask which of four things failed: the SLI's definition, its population, its window, or a dimension it never covered. Then I'd change the smallest thing that would have flipped a decision, and backtest it before it pages anyone.

Assumptions I'd state up front: 28-day rolling window, 99.9% success SLO on checkout, error budget 40.3 minutes, multi-window burn-rate alerts at 14.4x (1h/5m), 6x (6h/30m) and 1x (3d/6h). The SRE Workbook defaults.

Worked example

Checkout SLO: 99.9% of requests succeed in under 500 ms, 28-day window, 40.3-minute budget. Traffic splits evenly across four cells.

One cell's primary database fails for 3 minutes. Requests to that cell fail 100%; the other three are fine.

  • Budget consumed: 0.25 × 3 min = 0.75 min = 1.9% of 40.3 min.
  • 1-hour burn rate: errors in the hour = 0.25 × 3/60 = 1.25%, so 1.25%/0.1% = 12.5x. Under the 14.4x page threshold.

No page. Every customer routed to that cell still got a hard failure for three minutes.

The fix, and why it's the smallest one

The aggregate SLI dilutes one cell's total outage by 4x. Two candidates:

  1. Per-cell SLO, 99.9% each. The same 3 minutes is 7.4% of that cell's budget, and the 1-hour burn is 50x: it pages in about two minutes. Cost: 4x the SLOs, and 4x the alert surface as cells and services multiply.
  2. A per-cell synthetic canary hitting checkout every 10 s, paging on 3 consecutive failures. Catches a total outage in ~30 s, one alert, no cardinality cost. It won't catch partial degradation.

I'd take the canary plus the aggregate SLO, and add per-cell SLOs only for cells that carry enough traffic to matter on their own.

Backtest and shadow

Replay 12 months of Prometheus data through the proposed rule and count pages. If the per-cell SLO would have fired 9 times with 4 real incidents, that's 5 pages of noise a year: too many. The canary firing 6 times with 5 real is acceptable. Then run it alert-only for 2–4 weeks alongside the existing alerts and compare.

Versioning and the old result

SLO specs live in git (Sloth or Pyrra generate the Prometheus rules), so the change is a reviewed diff. Keep the old aggregate SLO green and state its assurance limit on the SLO page: "cannot detect a single-cell outage shorter than about 4 minutes." That is the honest reading of what green meant.

Failure modes I'd watch

  • Cardinality: per-cell × per-endpoint SLIs explode Prometheus series; use recording rules and cap the label set.
  • Backtest bias: 12 months of history includes a traffic mix that no longer exists (a fifth cell, a different routing policy), so the replay misstates the new rule's page rate.
  • Dimensions a latency SLI can't see: a correctness or durability incident, a ledger write that succeeds but drops a row, never moves the success ratio. That needs a direct invariant: a nightly reconciliation comparing sum of debits to sum of credits, alerting on any nonzero delta.
  • Alert fatigue: 4 cells × 30 services = 120 SLOs nobody owns. Every new SLO needs a named owner and a runbook entry.

What would change my mind

If the backtest shows the new rule paging more than about twice a quarter without a real incident, I'd drop it and keep the aggregate SLO plus the canary. The goal isn't a stricter SLO: it's making the next incident visible.

Curated: · Written: · Reviewed:

Difficulty: Hard