BloombergLP::bdlmt::MultiQueueThreadPool::MultiQueueThreadPool

Constructors

Synopses

Declared in <bdlmt_multiqueuethreadpool.h>

Create a multi-queue thread pool that uses the specified threadPool.

explicit
MultiQueueThreadPool(
    ThreadPool* threadPool,
    bslma::Allocator* basicAllocator = 0);
» more...

Create a multi-queue thread pool with the given limits.

MultiQueueThreadPool(
    bslmt::ThreadAttributes const& threadAttributes,
    int minThreads,
    int maxThreads,
    int maxIdleTime,
    bslma::Allocator* basicAllocator = 0);
» more...

Parameters

NameDescription
threadPoolthread pool used to process queue jobs
basicAllocatormemory allocator; null uses the default
threadAttributesattributes used when creating worker threads
minThreadsminimum number of worker threads
maxThreadsmaximum number of worker threads
maxIdleTimeidle time in milliseconds before a thread may exit