You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2020/08/03 15:55:05 UTC

[GitHub] [airflow] mik-laj opened a new issue #10135: Deprecate BaseHook.get_connections method

mik-laj opened a new issue #10135:
URL: https://github.com/apache/airflow/issues/10135


   Hello,
   
   Previously, Airflow allowed users to add more than one connection with the same `conn_id` and on access, it would choose one connection randomly Now, we marked field `conn_id` in table `Connection` as unique.
   More information:
   https://github.com/apache/airflow/pull/9067/files
   
   For this reason, the `airflow.hooks.base_hook.BaseHook.get_connections` method is no longer applicable, because we have `airflow.hooks.base_hook.BaseHook.get_connection` method that returns only one connection. I think, we should mark it as deprecated to be able to delete it in the distant future. We also update the use of this method.
   
   Best regards,
   Kamil


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] Hasan-J commented on issue #10135: Deprecate BaseHook.get_connections method

Posted by GitBox <gi...@apache.org>.
Hasan-J commented on issue #10135:
URL: https://github.com/apache/airflow/issues/10135#issuecomment-668190509


   Hey, I will open a PR soon.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] ashb closed issue #10135: Deprecate BaseHook.get_connections method

Posted by GitBox <gi...@apache.org>.
ashb closed issue #10135:
URL: https://github.com/apache/airflow/issues/10135


   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] Hasan-J commented on issue #10135: Deprecate BaseHook.get_connections method

Posted by GitBox <gi...@apache.org>.
Hasan-J commented on issue #10135:
URL: https://github.com/apache/airflow/issues/10135#issuecomment-669459186


   I opened a draft and need some confirmations. Please check the PR conversation when you have time :)   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [airflow] potiuk commented on issue #10135: Deprecate BaseHook.get_connections method

Posted by GitBox <gi...@apache.org>.
potiuk commented on issue #10135:
URL: https://github.com/apache/airflow/issues/10135#issuecomment-668139000


   It will work fine without it (get_connections() returns [connection] but I agree it would be nice to remove the usage of it and replace it with get_connection - it might also simplify some of the code.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
users@infra.apache.org