Expand description
A tiny library offering a concurrent work queue for synchronous or asynchronous tasks, as well as an implementation of topological sort built on top of it
This crate contains two main components, each with their own (slightly different) use cases:
executorcontains the core logic for the work queue, as well as the necessary types and logic to initialize itgraphis a topological sort implementation for handling more complex cases with inter-task dependencies
The documentation for each of the above modules contains example code for each use case.
Modules§
- executor
- Functionality for constructing and running work-queue executors
- graph
- A concurrent implementation of topological sort (toposort, for short) for handling task dependencies
- prelude
- Common traits used when working with
topograph
Traits§
- Async
Handler - A trait to work around the inability to express async lifetimes with
Fn - Executor
Builder - Builder type for a work queue executor
- Executor
Builder Async - Helper trait for describing an
ExecutorBuilderthat can accept anyAsyncHandleras a synchronous task - Executor
Builder Core - Trait describing common types for both
ExecutorBuilderSyncandExecutorBuilderAsync - Executor
Builder Sync - Helper trait for describing an
ExecutorBuilderthat can accept anyFnas a synchronous task - Executor
Core - Abstraction over a concurrent work queue executor
- Executor
Handle - The smallest common abstraction over a work queue and associated
task handle, providing solely a
pushfunction