# SLOs & error budgets

A service level objective says what share of events must be good over a rolling
window: "99.9% of checkout requests without a 5xx over 30 days". The rest, 0.1%,
is the **error budget**: how much may go wrong before you have broken the promise.
Tailcove counts the events, shows how much budget is left and how fast it is
being spent, and can open an incident when it burns too fast.

Open **SLOs** in the sidebar (members restricted to client groups don't see them,
as with incidents).

## What an SLO can measure

| Measures                   | An event is                                                         | Bad when                          |
| -------------------------- | ------------------------------------------------------------------- | --------------------------------- |
| **Good lines (logs)**      | a line of a source matching _Lines that count_ (all lines if empty) | it matches _Bad lines_            |
| **Uptime (monitor)**       | a check of a monitor                                                | the check failed                  |
| **Fast requests (traces)** | a request: a root span of a source, optionally only one name        | it took longer than the threshold |

Both queries use the [query language](https://tailcove.dev/docs/query-language), so
`path:/checkout` and `status>=500` work as they do in search. Keep the bad lines
inside the lines that count; a bad query that matches more never makes more than
every event bad.

## The numbers

- **Now** is the share of good events over the window (7, 28 or 30 days).
- **Budget left** is how much of the window's error budget is unspent: 100% when
  nothing went wrong, 0% when exactly the allowed share was bad, below 0 when
  overspent.
- **Burn rate** compares the last hour with what the budget allows: 1× spends it
  exactly over the window, 14.4× spends 2% of a 30-day budget in one hour.

The last hour is counted every five minutes, the whole window once an hour.

| Status           | When                                                                     |
| ---------------- | ------------------------------------------------------------------------ |
| **Burning fast** | the last hour burns 14.4× or faster, over at least 20 events             |
| **Budget spent** | nothing left of the window's budget                                      |
| **Burning**      | the last hour burns 2× or faster, or less than 25% of the budget is left |
| **Healthy**      | none of the above                                                        |
| **No data yet**  | no event has been counted yet                                            |

## Incidents on a fast burn

Tick **Open an incident on a fast burn** and pick an escalation policy (or page
the team once). When the SLO starts burning fast, an incident opens; when the
burn falls below 1×, Tailcove resolves it, unless a person already did. Each
episode is its own incident.

## On the dashboard

The **SLOs and error budget** card shows the three SLOs most in need of attention,
and the **Health score** counts the mean budget left as one of its parts.

## Limits

Free plans have 1 SLO, Pro 10, Business 50.
