Skip to content

Conversation

afurche
Copy link
Contributor

@afurche afurche commented Jan 20, 2025

Currently report_event() and report_log_event() methods in PythonSDK schedule each log to be send in a separate request to EEC.
This causes problems due to EEC’s insufficient log ingest performance → 200-300ms request response time on average, which can cause significant problems when there are hundreds and thousands of requests in a single interval.

To minimize the impact of the subpar efficiency, the goal is to batch reported logs and send them in a single message once per interval.
Similar mechanism is currently implemented for metrics ingest.

What is important is that the change must not change the interface, so that no changes are required for all built-in and custom Python extensions.

What could be worth implementing however, is an optional parameter which would give the possibility to also send logs in the “old way”. This could be useful for performance testing in the future and in this case logs should arrive earlier on the server, hence it could be useful in a production environment.

@afurche afurche requested a review from dlopes7 January 20, 2025 08:29
@afurche afurche force-pushed the batch-logs-before-sending branch from f8b81de to d5ff640 Compare January 20, 2025 09:47
Copy link
Member

@dlopes7 dlopes7 left a comment

Choose a reason for hiding this comment

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

Thanks, this was much needed

@dlopes7 dlopes7 merged commit 944a135 into main Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants