const classafConcurrent::WorkerPool
sys::Obj afConcurrent::WorkerPool
Lets you perform concurrent units of work.
- make
new make(Int maxWorkers, Str name := "WorkerPool")
Create a new
WorkerPool
with the given number of workers.- name
Str name()
Name used by pool and associated threads.
- numWorkers
Int numWorkers
Max number of threads used by this pool for concurrent actor execution.
May be updated.
- pool
ActorPool pool()
The wrapped
ActorPool
.- work
Runs the given func asynchronously.
The given func and return value must be immutable.
- workLater
Future workLater(Duration d, |->Obj? f)
Runs the given func asynchronously, after the given duration has elapsed.
The given func and return value must be immutable.