1.0.0 • Published 4 years ago
uiworkqueue v1.0.0
WorkQueue
A lightweight library for executing simple asynchronous workqueues with tree structured dependencies.
NOTE: more complex DAG like dependency structures can be constructed programatically and are supported but are not the primary goal of this library.
const pool = new WorkQueue(newLambdaTask(async (worker) => {
// step 1: construct some set of child tasks
// step 2: get results of those tasks with worker.getResults()
// step 3: evaluate the results and return
}));
TODO
- split out lib/queue and lib/semaphore into a separate package for synchronization
1.0.0
4 years ago