The Util.Executors.Stop procedure does not always stop correctly the worker tasks.
It looks at the tasks and enqueue a stop work to tell each active task to stop.
The issue is that it enqueue such stop work while checking and iterating over the list of tasks.
As soon as it enqueue a stop work, it is possible that a running task, not yet checked as par of the iteration, dequeues the stop job and stops immediately.
Then, at the next iteration that task is seen as terminated and no stop work is enqueue.
We therefore miss one (or more) stop job.
The
Util.Executors.Stop
procedure does not always stop correctly the worker tasks.It looks at the tasks and enqueue a stop work to tell each active task to stop. The issue is that it enqueue such stop work while checking and iterating over the list of tasks. As soon as it enqueue a stop work, it is possible that a running task, not yet checked as par of the iteration, dequeues the stop job and stops immediately. Then, at the next iteration that task is seen as terminated and no stop work is enqueue. We therefore miss one (or more) stop job.