From 10098c6e4aaf814e2cf217e1f0327f64e85a5164 Mon Sep 17 00:00:00 2001 From: Shaun McDonald Date: Tue, 24 Sep 2024 18:54:24 +0100 Subject: [PATCH] #42442 Make the AWS logging faster by reducing the amount of sleep Longer running tasks with lots of logs were slow to write all of the logs to AWS. This reduces the sleep delay to prevent the issue. --- airflow/providers/amazon/aws/utils/task_log_fetcher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/airflow/providers/amazon/aws/utils/task_log_fetcher.py b/airflow/providers/amazon/aws/utils/task_log_fetcher.py index 83c42f685792..5a344b507e8c 100644 --- a/airflow/providers/amazon/aws/utils/task_log_fetcher.py +++ b/airflow/providers/amazon/aws/utils/task_log_fetcher.py @@ -70,7 +70,7 @@ def run(self) -> None: # timestamp) # When a slight delay is added before logging the event, that solves the issue # See https://github.com/apache/airflow/issues/40875 - time.sleep(0.1) + time.sleep(0.001) self.logger.info(self.event_to_str(log_event)) prev_timestamp_event = current_timestamp_event