Airflow Data Quality Provider#69413
Conversation
0432ee7 to
6acc4da
Compare
5c4aff2 to
f32940b
Compare
a8c6dfd to
e0f7ff9
Compare
o-nikolas
left a comment
There was a problem hiding this comment.
This first version is intentionally small.
I'm not so sure that it is 😅 This is an absolutely enormous PR, 11.8k lines added across 143 files. This is quite difficult to review. Is it possible to ship this in smaller pieces?
hehe it has both UI and backend shipped thats the reason it looks like big.. and some docs 😄 I am happy to ship this into two separate PR's one with UI and another backend provider specific.. |
|
@o-nikolas here is the part 1 #69575 hope its fine 😄 now.. as this is provider starting so it has autogenrated breeze docs and content in documentation .. |




Adds a new
apache-airflow-providers-dqprovider,DbApiHook-based data quality checks.Airflow already has SQL check operators, and many users rely on them for data
quality today. This provider does not replace that path; it adds a small
DQRule/RuleSetlayer for checks that need stable rule identity, persistedhistory, and a connection to Airflow assets. That makes quality results easier
to inspect over time, lets downstream asset consumers gate on recent quality,
and also gives LLM-assisted workflows one schema to generate when proposing
checks from table context. Execution still goes through existing
DbApiHookconnections.
Ships:
DQRuleandRuleSetmodels for named data quality rules.common.sql/DbApiHook, pluscustom_sqlfor database-specific or morecomplex checks.
DQCheckOperatorand the@task.dq_checkTaskFlow decorator.[dq] results_pathfor task, run, andrule-level history.
history.
asset_quality()andrequire_quality(), thatattach provider-owned quality metadata to assets without changing Airflow
core.
LLM-generated rules.
This first version is intentionally small. It focuses on a deterministic rule
shape, SQL execution through
common.sql, persisted results, and lightweightvisibility in the Airflow UI.
Design decisions:
adding new metadata DB tables in the first provider drop. This keeps the
provider self-contained, avoids Airflow core migrations, and lets deployments
choose a durable store such as S3/GCS/local files via
[dq] results_path.The backend stores keyed JSON records for task runs, task instances, and
per-rule history so the UI can read common views without scanning unrelated
runs.
not by changing Airflow core. Static quality configuration is attached to
Asset.extra["airflow.dq"]; runtime summaries are attached to asset eventsunder
extra["airflow.dq.result"]. This lets users try asset quality gatingnow, while leaving room to discuss deeper asset integration later if the
provider gets traction.
DbApiHook/ SQL execution because Airflowalready has strong provider coverage through
common.sql. File andobject-store data checks are left for a later iteration.
later iteration:
files or other object stores and runs quality rules directly against that
data. This PR deliberately starts with the
DbApiHookpath first.Was generative AI tooling used to co-author this PR?
Generated-by: following the guidelines
{pr_number}.significant.rst, in airflow-core/newsfragments. You can add this file in a follow-up commit after the PR is created so you know the PR number.