go-events
go-events copied to clipboard
Close on Queue cannot close downstream
If you have a Queue writing to a Channel and call close on the Queue, Queue.Close will block on writing to Channel.Write. This is because the Close waits on the shutdown condition of the Queue.
Please see https://github.com/containerd/containerd/pull/1254 for the mitigation for this.
Should queues be able to drop the held messages when stopped if configured to do so? I mean, use an additional parameter that instructs the queues to drop their messages either instantly or after some time when they are closed so that the next sink in the pipeline can be closed in a "time-deterministic" fashion.