You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Add support of max log length for OTEL task log event #43868
). However, there is a risk of log entry being extremely large, that it would easily produce message that may not fit into the span event. Also, there is a potential risk of halting scheduler from running as scheduler would be busy processing it.
What you think should happen instead?
OTEL_TASK_LOG_EVENT should support MAX length of the log entry, such that it should have a safe default value of the max length (e.g. 64k characters), which will effectively trim the task log once that max limit is reached, preventing any operational risk of scheduler if the log message is too large to be practical.
How to reproduce
Generate a huge log (hundreds of megabytes?) and observe scheduler to hang (or causing delay) processing the log as span event.
If you are talking about uploading task execution logs from the scheduler loop, this seems like still very much not a good idea. Even if just a snippet of logs, you don't want to be retrieving connections, reading from s3, etc. It's not the place to do that.
If you are talking about uploading task execution logs from the scheduler loop, this seems like still very much not a good idea. Even if just a snippet of logs, you don't want to be retrieving connections, reading from s3, etc. It's not the place to do that.
Who is talking about doing it from scheduler loop?
No, remove this feature entirely. Logs do not belong in Otel traces/spans. Use OTel logging and associate it with a span if that's what you want to do, but this code cannot exist in the scheduler.
Activity
potiuk commentedon Nov 11, 2024
+1
dstandish commentedon Nov 12, 2024
-1
If you are talking about uploading task execution logs from the scheduler loop, this seems like still very much not a good idea. Even if just a snippet of logs, you don't want to be retrieving connections, reading from s3, etc. It's not the place to do that.
potiuk commentedon Nov 12, 2024
Who is talking about doing it from scheduler loop?
dstandish commentedon Nov 12, 2024
that's where the code in question is right now and that's the context for this is it not?
dstandish commentedon Nov 12, 2024
look in the top of this issue @potiuk

dstandish commentedon Nov 12, 2024
so it sounds like this issue is just about reducing the size of the log message in the area where it's currently added.
but it cannot be added ther.
potiuk commentedon Nov 12, 2024
Oh, I have not seen that - this should be definitely done from task/worker..
dstandish commentedon Nov 12, 2024
😌 (relieved face)
ashb commentedon Nov 12, 2024
No, remove this feature entirely. Logs do not belong in Otel traces/spans. Use OTel logging and associate it with a span if that's what you want to do, but this code cannot exist in the scheduler.