Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Stop loading Extra Operator links in Scheduler #13932

Merged
merged 3 commits into from Jan 30, 2021

Conversation

kaxil
Copy link
Member

@kaxil kaxil commented Jan 27, 2021

closes #13099

Mutually exclusive with #13931


^ Add meaningful description above

Read the Pull Request Guidelines for more information.
In case of fundamental code change, 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 UPDATING.md.

@kaxil
Copy link
Member Author

kaxil commented Jan 27, 2021

#13931 is an alternative approach however we manage some sort of global state -- but we remove the env var before we exiting _do_scheduling

cc @ashb -- I will add tests once we decide on the approach Test added in 1ee706c

@kaxil kaxil force-pushed the fix-issue-plugins-alt1 branch 2 times, most recently from 6b3d134 to 8a91a4c Compare January 27, 2021 20:33
@github-actions
Copy link

The Workflow run is cancelling this PR. It has some failed jobs matching ^Pylint$,^Static checks,^Build docs$,^Spell check docs$,^Backport packages$,^Provider packages,^Checks: Helm tests$,^Test OpenAPI*.

@github-actions
Copy link

The Workflow run is cancelling this PR. Building image for the PR has been cancelled

@kaxil
Copy link
Member Author

kaxil commented Jan 28, 2021

@ephraimbuddy @jhtimmins Can you take a look and review too please

Copy link
Contributor

@jhtimmins jhtimmins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I prefer this approach to the global state of environment variables. Is it necessary to pass load_op_links to DagBag's constructor though?

I'm not super familiar with the how this is used, so it might not make sense, but could it be passed directly to deserialize_operator as an argument?

@kaxil
Copy link
Member Author

kaxil commented Jan 29, 2021

I prefer this approach to the global state of environment variables. Is it necessary to pass load_op_links to DagBag's constructor though?

I'm not super familiar with the how this is used, so it might not make sense, but could it be passed directly to deserialize_operator as an argument?

Mainly to reduce the places we need to pass the flag otherwise -- dab163e is my first commit where I tried something similar but its too ugly -- I passed it all the over the place

@kaxil kaxil marked this pull request as ready for review January 29, 2021 21:01
@kaxil kaxil changed the title Pass Flag to not load operator links for Scheduler Stop loading Extra Operator links in Scheduler Jan 29, 2021
@kaxil kaxil requested review from ashb, potiuk and XD-DENG January 30, 2021 19:50
@kaxil kaxil added this to the Airflow 2.0.1 milestone Jan 30, 2021
@github-actions github-actions bot added the full tests needed We need to run full set of tests for this PR to merge label Jan 30, 2021
@github-actions
Copy link

The PR most likely needs to run full matrix of tests because it modifies parts of the core of Airflow. However, committers might decide to merge it quickly and take the risk. If they don't merge it quickly - please rebase it to the latest master at your convenience, or amend the last commit of the PR, and push it with --force-with-lease.

@kaxil kaxil merged commit 7034529 into apache:master Jan 30, 2021
@kaxil kaxil deleted the fix-issue-plugins-alt1 branch January 30, 2021 20:32
kaxil added a commit that referenced this pull request Feb 1, 2021
kaxil added a commit that referenced this pull request Feb 4, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:Scheduler Scheduler or dag parsing Issues area:serialization full tests needed We need to run full set of tests for this PR to merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Unable to start scheduler after stopped
3 participants