Skip to content

Conversation

@o-nikolas
Copy link
Contributor

@o-nikolas o-nikolas commented Jan 27, 2026

in #56791 async connection generation was moved to a common module which uses the BaseHook's implementation of get_connection which will obviously not include any implementation that the child classes have in their get_connection methods. The kubernetes hook has some special handling in it's get_connection method. This handling is added one layer higher so that it is still present in the new call path.


Was generative AI tooling used to co-author this PR?
  • Yes (please specify the tool below)

  • Read the Pull Request Guidelines for more information. Note: commit author/co-author name and email in commits become permanently public when merged.
  • For fundamental code changes, an Airflow Improvement Proposal (AIP) is needed.
  • When adding dependency, check compliance with the ASF 3rd Party License Policy.
  • For significant user-facing changes create newsfragment: {pr_number}.significant.rst or {issue_number}.significant.rst, in airflow-core/newsfragments.

async connection generation was moved to a common module which uses
the BaseHook's implementation of get_connection which will obviously
not include any implementation that the child classes have in their
get_connection methods. The kubernetes hook has some special handling
in it's get_connection method. This handling is added one layer higher
so that it is still present in the new call path.
@o-nikolas
Copy link
Contributor Author

CC @ramitkataria

Copy link
Contributor

@vincbeck vincbeck left a comment

Choose a reason for hiding this comment

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

Nice!

Copy link
Contributor

@ramitkataria ramitkataria left a comment

Choose a reason for hiding this comment

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

Thanks! Should we add a unit test? Otherwise looks good to me

@vincbeck vincbeck merged commit 1f0c2c1 into apache:main Jan 27, 2026
104 checks passed
@vincbeck vincbeck deleted the onikolas/fix_kubernetes_async_conn branch January 27, 2026 20:10
shreyas-dev pushed a commit to shreyas-dev/airflow that referenced this pull request Jan 29, 2026
async connection generation was moved to a common module which uses
the BaseHook's implementation of get_connection which will obviously
not include any implementation that the child classes have in their
get_connection methods. The kubernetes hook has some special handling
in it's get_connection method. This handling is added one layer higher
so that it is still present in the new call path.
shashbha14 pushed a commit to shashbha14/airflow that referenced this pull request Feb 2, 2026
async connection generation was moved to a common module which uses
the BaseHook's implementation of get_connection which will obviously
not include any implementation that the child classes have in their
get_connection methods. The kubernetes hook has some special handling
in it's get_connection method. This handling is added one layer higher
so that it is still present in the new call path.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:providers provider:cncf-kubernetes Kubernetes (k8s) provider related issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants