Skip to content

Conversation

@dabla
Copy link
Contributor

@dabla dabla commented Oct 10, 2024

Today I've discovered that the conn id parameters (source_conn_id and destination_conn_id) aren't templated in the GenericTransfer. This PR will also allow passing hook parameters like in BaseSQLOperator. Refactored the get_hook method in BaseOperator so that in the future it can be used in a generic way, added tests to remove backward compatibility code for Airflow 2.8.x once min version of provider is Aiflow 3.0.0 or higher.


^ 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 newsfragments.

…conn_id's for GenericTransfer and also allow passing hook params for each connection in GenericTransfer
@potiuk
Copy link
Member

potiuk commented Oct 14, 2024

Looks like there is some problem with minimum version of one of microsoft dependencies. Bringing it down, brings opentelemetry dependency down and this seems to break imports. Unfold the failng test output for microsoft.azure and you will see it:

https://github.com/apache/airflow/actions/runs/11299097052/job/31429704576?pr=42891#step:7:6196

@dabla
Copy link
Contributor Author

dabla commented Oct 14, 2024

Looks like there is some problem with minimum version of one of microsoft dependencies. Bringing it down, brings opentelemetry dependency down and this seems to break imports. Unfold the failng test output for microsoft.azure and you will see it:

https://github.com/apache/airflow/actions/runs/11299097052/job/31429704576?pr=42891#step:7:6196

Seems to be fine now after I updated the branch

@potiuk
Copy link
Member

potiuk commented Oct 14, 2024

There are some compatibility Airflow 3 / Airflow 2 issues that need to be addressed :)

@dabla
Copy link
Contributor Author

dabla commented Oct 17, 2024

There are some compatibility Airflow 3 / Airflow 2 issues that need to be addressed :)

All issues fixed

@dabla dabla requested a review from potiuk October 23, 2024 18:51
Copy link
Member

@potiuk potiuk left a comment

Choose a reason for hiding this comment

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

NICE!

@potiuk potiuk merged commit 4d54cda into apache:main Oct 24, 2024
@dabla dabla deleted the feature/templated_conn_id_generic_transfer branch October 24, 2024 11:17
ellisms pushed a commit to ellisms/airflow that referenced this pull request Nov 13, 2024
…assing hook parameters like in BaseSQLOperator (apache#42891)

* refactored: Added hook_params to get_hook BaseHook method, templated conn_id's for GenericTransfer and also allow passing hook params for each connection in GenericTransfer


---------

Co-authored-by: David Blain <david.blain@infrabel.be>
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.

3 participants