Skip to content

Optimize DAG serialization by excluding schema default values#55849

Merged
kaxil merged 2 commits intoapache:mainfrom
astronomer:dag-defaults
Sep 18, 2025
Merged

Optimize DAG serialization by excluding schema default values#55849
kaxil merged 2 commits intoapache:mainfrom
astronomer:dag-defaults

Conversation

@kaxil
Copy link
Copy Markdown
Member

@kaxil kaxil commented Sep 18, 2025

This change reduces serialized DAG size by automatically excluding fields that match their schema default values, similar to how operator serialization works. Fields like catchup=False, max_active_runs=16, and fail_fast=False are no longer stored when they have default values.

Follow-up of #54569


^ Add meaningful description above
Read the Pull Request Guidelines for more information.
In case of fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in a newsfragment file, named {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

This change reduces serialized DAG size by automatically excluding fields
that match their schema default values, similar to how operator serialization
works. Fields like `catchup=False`, `max_active_runs=16`, and `fail_fast=False`
are no longer stored when they have default values.

Follow-up of apache#54569
@kaxil kaxil added this to the Airflow 3.1.0 milestone Sep 18, 2025
@kaxil kaxil merged commit a582464 into apache:main Sep 18, 2025
105 checks passed
@kaxil kaxil deleted the dag-defaults branch September 18, 2025 18:42
kaxil added a commit that referenced this pull request Sep 18, 2025
This change reduces serialized DAG size by automatically excluding fields
that match their schema default values, similar to how operator serialization
works. Fields like `catchup=False`, `max_active_runs=16`, and `fail_fast=False`
are no longer stored when they have default values.

Follow-up of #54569

(cherry picked from commit a582464)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants