Observability Fundamentals · Module 11 of 12

SLIs, SLOs and error budgets

Connect telemetry to reliability objectives by defining measurable indicators, explicit targets and an error budget that informs risk decisions.

Learning objectives

By the end of this module, you should be able to:

  • Define an SLI from user-relevant events.
  • Translate an SLO into an error budget.
  • Explain why an SLO is not the same as 100% uptime or an external SLA.

An SLI is a measurement

A service-level indicator quantifies a behavior users care about, such as successful checkout ratio or the proportion of requests below a latency threshold.

An SLO is a target over a window

A service-level objective states a target for an SLI over a defined period. It should be demanding enough to protect users but realistic enough to allow safe change.

Error budget turns reliability into a decision input

The gap between 100% and the SLO target defines tolerated unreliability for the window. Fast consumption can justify slowing releases or prioritizing reliability work.

Worked example

See the investigation idea in practice.

Error-budget arithmetic

SLO = 99.9% successful requests over 30 days
error budget = 0.1%
1,000,000 requests → 1,000 failed requests budget (for a request-based SLI)
  • Read the evidence before deciding what it means.
  • Prefer a hypothesis that explains multiple independent signals.
Core lab · account-free

Lab 11 — Calculate an error budget

Goal: Compute request-based SLI compliance and decide whether release risk should change.

Before you start

  • No cloud account required.
  • Core lab uses bash/Python 3 and local files only.
STEP 1

Calculate success ratio

python3 - <<'PY'
total=1_000_000; failed=1200; slo=.999
success=(total-failed)/total
budget=total*(1-slo)
print('success %',success*100)
print('allowed failures',round(budget))
print('budget consumed %',failed/budget*100)
PY
STEP 2

Interpret

Decide whether a 99.9% SLO is currently met and explain what 120% budget consumption means.

STEP 3

Choose response

Propose one reliability action and one release-policy implication.

Verify

  • Success is 99.88%, below a 99.9% target.
  • The request-based error budget is 1,000 failures and 1,200 means 120% consumed.

Expected outcome

  • You connect telemetry to an explicit reliability target and an engineering decision.

Diagnose / troubleshoot

  • If an SLI mixes different user journeys, split it before interpreting the SLO.
  • If an SLO is always trivially met, confirm it reflects user expectations rather than internal convenience.
Real-world connection

SLOs align product and engineering around measurable reliability rather than “never fail.”

Optional real-tool lab

Optional tool lab — express an SLI query

Query Prometheus and sketch the numerator/denominator for an availability SLI.

Resources created

  • Local containers/files only; no cloud resources.

Cost / risk

  • Expected cloud cost: none. Local CPU, memory and disk usage only.

Prerequisites

  • Docker Engine with Compose plugin for the optional shared stack.
  • Core course completion does not require Docker or external credentials.
TOOL 1
cd labs/observability-stack
TOOL 2
docker compose up -d
TOOL 3
curl -Gs 'http://127.0.0.1:9090/api/v1/query' --data-urlencode 'query=up'

Verify

  • You can explain which event population would form the SLI numerator and denominator for a real application.

Cleanup

  • Run `docker compose down -v` from `labs/observability-stack`.

Warnings

  • Optional only: not required by the account-free validator.
  • The bundled local stack is for training, not a production observability architecture.
Avoid these traps

Common mistakes

  • Calling every metric an SLI.
  • Setting 100% SLO without understanding cost/trade-offs.
  • Confusing an internal SLO with a contractual SLA.
Knowledge check

Can you reason from the signal?

Three concept checks plus one scenario check. Open each answer only after deciding first.

1What is an SLI?

A quantitative measure of service behavior that matters to users or reliability.

2What is an SLO?

A target value for an SLI over a defined time window.

3What is an error budget?

The amount of unreliability permitted by the SLO before the target is violated.

4Scenario: a 99.9% request SLO allows 1,000 failures in the window but 1,200 occur. What does that mean?

The SLO is missed and 120% of the request-based error budget has been consumed.

My Learning

Record your progress for this module.

Progress is saved in this browser immediately. When you sign in to My Learning, it can also sync across devices.

Not started

Attempt the core lab and knowledge checks before marking the module complete.