Surface durable execution badge in Airflow Registry#69651
Merged
Conversation
potiuk
approved these changes
Jul 9, 2026
Contributor
Backport successfully created: v3-3-testNote: As of Merging PRs targeted for Airflow 3.X In matter of doubt please ask in #release-management Slack channel.
|
github-actions Bot
pushed a commit
to aws-mwaa/upstream-to-airflow
that referenced
this pull request
Jul 9, 2026
aws-airflow-bot
pushed a commit
to aws-mwaa/upstream-to-airflow
that referenced
this pull request
Jul 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Was generative AI tooling used to co-author this PR?
closes: #67236
What
Through this PR, I am trying to surface which operators can survive a worker crash/retry (aka durable execution) without redoing expensive work on Airflow Registry.
ResumableJobMixinalready provides this capability (Spark, Databricks, so far, Snowflake and other operators in progress), but nothing in the registry's extraction pipeline or UI could distinguish an operator that genuinely implements it from one that merely inherits it, and the Registry itself (registry/+dev/registry/, in this repo) had no capability concept at all, only type classification (operator/hook/sensor/etc).Current behaviour
Today, browsing a provider page in the Registry shows every operator/hook/sensor with no indication of crash-recovery support. Inheriting
ResumableJobMixinis not proof an operator is crash safe on its own. A subclass can leave the mixin's methods unimplemented, implement them but never callexecute_resumable()fromexecute()(dead capability), or, as inSparkSubmitOperator, only reach it under specific hook configuration.Proposed change
The change is a 3 step process
dev/registry/extract_parameters.py):is_durable_capable()checks three things: the class inheritsResumableJobMixin, none of its abstract methods are left unimplemented (viainspect.isabstract(), now that the mixin's 6 crash-recovery methods are real@abstractmethods as of Making ResumableJobMixin a abstract class and its methods abstractmethods #69607, already merged), andexecute_resumableis reachable fromexecute()'s source.load_resumable_job_mixin()imports the mixin once and is threaded down throughdiscover_classes_from_provider()andmake_entry(), mirroring the existingbase_classesinjection pattern.registry_contract_models.py):supports_durable_execution: bool = Falseadded toModuleContract.registry/src/provider-version.njk,main.css): a small teal "Durable" badge on module cards whensupports_durable_executionis true, with a tooltip pointing at the caveats (durable=Truedefault, config-dependent, no per-run guarantee).User implications / backcompat
New field defaults to
False; no schema break. NoteModuleContractvalidation usesexclude_unsetsemantics: the field is simply absent (not present-and-false) on payloads that never set it, e.g. legacy per-version data from older extraction runs.Testing
Non UI surface testing
extract-dataworks fine for databricks as well as spark:Spark:
Result:
{ "id": "apache-spark-spark_submit-SparkSubmitOperator", "name": "SparkSubmitOperator", "type": "operator", "import_path": "airflow.providers.apache.spark.operators.spark_submit.SparkSubmitOperator", "module_path": "airflow.providers.apache.spark.operators.spark_submit", "short_description": "Wrap the spark-submit binary to kick off a spark-submit job; requires \"spark-submit\" binary in the PATH.", "docs_url": "https://airflow.apache.org/docs/apache-airflow-providers-apache-spark/stable/_api/airflow/providers/apache/spark/operators/spark_submit/index.html#airflow.providers.apache.spark.operators.spark_submit.SparkSubmitOperator", "source_url": "https://github.com/apache/airflow/blob/providers-apache-spark/6.2.0/providers/apache/spark/src/airflow/providers/apache/spark/operators/spark_submit.py#L69", "category": "apache-spark", "provider_id": "apache-spark", "provider_name": "Apache Spark", "supports_durable_execution": true },Databricks:
Output:
UI Testing
Build the UI with
pnpm install,pnpm devand visit the registry page locally buillt.This is how it looks for spark:
What's next
durable-executionfilter was considered and dropped for now in favor of just the badge; revisit once more providers adopt the mixin.{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.