go-events icon indicating copy to clipboard operation
go-events copied to clipboard

Close on Queue cannot close downstream

Open stevvooe opened this issue 7 years ago • 1 comments

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.

stevvooe avatar Jul 27 '17 21:07 stevvooe

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.

Adirio avatar May 03 '18 15:05 Adirio