vandonr-amz commented on code in PR #31786:
URL: https://github.com/apache/airflow/pull/31786#discussion_r1231303536
##########
airflow/providers/amazon/aws/hooks/ecs.py:
##########
@@ -198,7 +196,18 @@ def _event_to_str(self, event: dict) -> str:
return f"[{formatted_event_dt}] {message}"
def get_last_log_messages(self, number_messages) -> list:
- return [log["message"] for log in deque(self._get_log_events(),
maxlen=number_messages)]
+ """
+ Gets the last logs messages in one single request, so restrictions
apply:
+ - if logs are too old, the response will be empty
Review Comment:
well that's a question for cloudwatch teams, but somehow the older the last
event in the log stream, the more empty requests you have to pull before you
start getting results.
I guess maybe they try to answer within a certain time SLA ? And that
doesn't give them enough time to get it from semi-hot storage ? Or like they
start searching in chronological order, and the older it is, the more records
they need to go through before getting hits ?
--
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]