Quality SLAs vs Ops SLAs
The orchestration lessons treated an SLA as a promise that a run finishes on time. That is an operational SLA, a commitment about how the pipeline executes. A quality SLA is a commitment about the data a run publishes, and the 2 fail independently. During the EU currency incident every task succeeded and every table landed before 06:00, so the operational SLA held all day while consumers read wrong numbers. Treat them as 2 promises with separate measurements and separate owners, because fixing one does nothing for the other.
- Operational SLA
- Promises the partition is published by 06:00 UTC
- Measured from run records: start, end, status
- Broken by stuck tasks, slow inputs, cluster outages
- Improved by retries, concurrency, earlier upstream schedules
- Quality SLA
- Promises the published partition is correct
- Measured from check results and the corrections log
- Broken by wrong values, missing rows, broken joins
- Improved by contracts, producer-side checks, tuned thresholds
Writing each as a measurable commitment
A commitment names an indicator and sets a target for it over a window. The operational indicator is direct: was the partition of orders_curated published by 06:00 UTC the next day? For quality, passing checks is a weak indicator, because a check says nothing about defects it never tests for. A stronger one comes from the corrections log, a record written whenever anyone restates a published partition. The quality indicator becomes: was the published partition never corrected? A partition the gate holds back costs nothing on quality, since no consumer read it.
| Field | Operational SLA | Quality SLA |
|---|---|---|
| Indicator | published by 06:00 UTC the next day | published and never corrected |
| Target | 89 of 90 days | 88 of 90 partitions |
| Window | rolling 90 days | rolling 90 days |
| Source | `ops.runs` | `ops.corrections` |
| Fixed by | platform on-call | producer and table owner |
WITH corrected AS (
SELECT DISTINCT
partition_date
FROM ops.corrections
WHERE table_name = 'orders_curated'
)
SELECT
count(*) AS days,
count_if(r.published_at <= CAST(r.partition_date AS TIMESTAMP) + INTERVAL '30' HOUR) AS on_time_days,
count_if(c.partition_date IS NULL) AS never_corrected
FROM ops.runs AS r
LEFT JOIN corrected AS c
ON c.partition_date = r.partition_date
WHERE r.table_name = 'orders_curated'
AND r.status = 'published'
AND r.partition_date >= current_date - INTERVAL '90' DAYOn Oct 14 the gate blocks the orders_curated partition at 05:50 for duplicate order_id values. The owner fixes it and the partition publishes at 07:10. It is never corrected afterward. How does Oct 14 count?
- Late for the operational SLA and corrected for the quality SLA, because the gate found a defect in it.
- Late for the operational SLA and good for the quality SLA, because consumers never read the bad version.
- On time for the operational SLA, because the first run finished before 06:00, and good for quality.
- Excluded from both SLAs, because a day with a blocking failure is an incident and leaves the window.
- 90 of 90
- 84 of 90
The pipeline met its operational target with a day to spare and missed its quality target by 4 partitions. A blended health score would have averaged the 2 into a comfortable number and hidden the miss.
Every one of the 6 traces to a missing check or a check without blocking authority, and none shrinks with faster runs. Doubling retries lifts the operational number and leaves all 6 in place; a retry that reruns a bad batch sooner only publishes it sooner. The 2 SLAs also pull against each other. A blocking uniqueness check would have prevented 2 corrections, and every block holds a partition past 06:00 while someone fixes it. Write that tradeoff into the SLA on purpose: a held partition counts as late for operations and as protected for quality.
Over a quarter, payments_daily meets its operational SLA on 89 of 90 days and its quality SLA on 81 of 90. The team proposes doubling retries and adding a second cluster. What will that change?
- Both numbers, because retries rerun failed work and a rerun repairs the bad partitions too.
- Mostly the quality number, because more capacity lets the checks scan more rows each night.
- At most the operational number, from 89 toward 90, while the quality number stays at 81.
- Neither number, because both SLAs are already inside their targets for the quarter.
About this lesson
This section is part of the Data Quality: Advanced lesson on DataDriven, the home of data engineering. Lessons cover SQL, Python, Spark, data modeling and pipeline architecture, and each section pairs its explanation with worked examples and practice you run as you go.