-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement graceful shutdown with pipeline draining #483
Comments
I may be misunderstanding the need, but except for the processors this appears to be done: opentelemetry-collector/service/service.go Lines 304 to 317 in b468dee
|
Yes, this is the missing part. Processors support partially coming in #488 We still need to implement draining in processors (particularly in batch and queue). |
Hi! Can i work on this? After quick look at queued_processor, this is a rough idea to fix - On shutdown have a deadline of 5s or until queue is emptied(whichever happens first). Also, We can have stats on how many spans were flushed and dropped during shutdown process. WDYT? I see there is Similar idea can be applied to batch_processor too. |
@jan25 do you still want to work on this? We will need to drain the pipeline by first stopping receivers, then stopping processors in the right order, then stop exporters. When stopping we will need to wait for up to certain max time, you are right. It needs to be done for all components, not just certain processors. |
@tigrannajaryan Sure, I'll start the work and open a PR soon |
@jan25 I will remove this from 1.0 milestone, since it is not a must-have, but feel free to work on it. We will accept it when it is ready. |
@tigrannajaryan Is there a suggested workaround to avoid dropping messages during collector upgrades? |
There is no known workaround. |
@tigrannajaryan in that case, I feel like this should be added back to the GA milestone? Dropping things on the floor during upgrades is not great... |
@kamalmarhubi Help is wanted on this one. If there are contributors who can submit a PR before GA, we will be happy to review it. |
I think this is done correct? |
…lNewPipeline (open-telemetry#483) Co-authored-by: Rahul Patel <rghetia@yahoo.com>
* Bump version to 0.1.0 * Remove redundant info from README.md
Signed-off-by: birca <Allex21ro@yahoo.com>
Is graceful shutdown actually implemented/supported? The docs say it is not: opentelemetry-collector/CONTRIBUTING.md Lines 493 to 500 in ba4ab80
|
These docs seem to indicate that it has been implemented: https://pkg.go.dev/go.opentelemetry.io/collector/otelcol#CollectorSettings |
Currently when shutting down any data that is in the pipeline is lost. We need to drain the pipeline during shutdown. First we need to shutdown receivers, then processors (and implement draining in processors that stores data), then exporters.
The text was updated successfully, but these errors were encountered: