m1racoli opened a new issue, #47312: URL: https://github.com/apache/airflow/issues/47312
### Apache Airflow Provider(s) amazon ### Versions of Apache Airflow Providers ```txt apache-airflow-providers-amazon==9.4.0 apache-airflow-providers-common-compat==1.3.0 apache-airflow-providers-common-io==1.5.0 apache-airflow-providers-common-sql==1.21.0 apache-airflow-providers-fab==1.5.2 apache-airflow-providers-ftp==3.12.0 apache-airflow-providers-http==4.13.3 apache-airflow-providers-imap==3.8.0 apache-airflow-providers-postgres==6.0.0 apache-airflow-providers-smtp==1.9.0 apache-airflow-providers-snowflake==6.0.0 apache-airflow-providers-sqlite==3.9.1 ``` ### Apache Airflow version 2.10.5 ### Operating System Debian GNU/Linux 12 (bookworm) ### Deployment Astronomer ### Deployment details _No response_ ### What happened We observe the following message with values of 2-11 seconds in frequency of 10-19 times per minute. ``` Triggerer's async thread was blocked for 8.11 seconds, likely by a badly-written trigger. Set PYTHONASYNCIODEBUG=1 to get more information on overrunning coroutines. ``` using only EcsRunTaskOperator in deferrable mode. ### What you think should happen instead _No response_ ### How to reproduce Run `EcsRunTaskOperator` in deferrable mode. ### Anything else I've traced the calling sequence of TaskDoneTrigger to a potentially blocking network call. 1. [EcsHook().async_conn and AwsLogsHook.async_conn](https://github.com/apache/airflow/blob/4651ccce787b33af9ea03f43a876538d806ac68a/providers/amazon/src/airflow/providers/amazon/aws/triggers/ecs.py#L170-L171) 2. [AwsGenericHook.async_conn](https://github.com/apache/airflow/blob/077984c4a29416247882c0742d8f286a869f8d92/providers/amazon/src/airflow/providers/amazon/aws/hooks/base_aws.py#L749) 3. [AwsGenericHook.get_client_type()](https://github.com/apache/airflow/blob/077984c4a29416247882c0742d8f286a869f8d92/providers/amazon/src/airflow/providers/amazon/aws/hooks/base_aws.py#L697) 4. [AwsGenericHook.get_session()](https://github.com/apache/airflow/blob/077984c4a29416247882c0742d8f286a869f8d92/providers/amazon/src/airflow/providers/amazon/aws/hooks/base_aws.py#L673) 5. [AwsGenericHook.conn_config](https://github.com/apache/airflow/blob/077984c4a29416247882c0742d8f286a869f8d92/providers/amazon/src/airflow/providers/amazon/aws/hooks/base_aws.py#L601) 6. [BaseHook.get_connection()](https://github.com/apache/airflow/blob/201baf902abbdb392f86d0c65e0def6d2fc1783b/airflow/hooks/base.py#L56) Basically any use of `async_conn` in an async environment (for example in [AwsBaseWaiterTrigger](https://github.com/apache/airflow/blob/201baf902abbdb392f86d0c65e0def6d2fc1783b/providers/amazon/src/airflow/providers/amazon/aws/triggers/base.py#L142)) results in blocking code execution. ### Are you willing to submit PR? - [ ] Yes I am willing to submit a PR! ### Code of Conduct - [x] I agree to follow this project's [Code of Conduct](https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md) -- 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. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
