diff --git a/common/tasks/fifo_scheduler.go b/common/tasks/fifo_scheduler.go index 9b640efd90c..19296d27b74 100644 --- a/common/tasks/fifo_scheduler.go +++ b/common/tasks/fifo_scheduler.go @@ -206,6 +206,12 @@ func (f *FIFOScheduler[T]) processTask( return } + select { + case <-shutdownCh: + return + default: + } + select { case task := <-f.tasksChan: f.executeTask(task)