ThreadPool::Stop

Stop all worker threads and wait for them to exit.

Synopsis

Declared in <util/threadpool.h>

[[requires_capability(0x7f2e2046a288)]]
void
Stop();

Description

Sets the interrupt flag, wakes all waiting workers, and joins them. Any remaining tasks in the queue will be processed before returning.

Must be called from a controller (non-worker) thread. Concurrent calls to Start() will be rejected while Stop() is in progress.