⌽ Thread Manager
Thread Manager is a streamlined Rust library for efficient thread pooling and parallel job execution, designed for simplicity, flexibility, and performance.
It is designed to abstract away the complexities of thread management and provides a convenient interface for parallelizing workloads and retrieving results.
Add to Cargo.toml
thread-manager = "1.0"
➢ Features
-
Job Submission: Easily submit jobs for parallel execution, which are then efficiently distributed among worker threads for optimal performance.
-
Result Retrieval: You can retrieve results during execution by either immediately fetching the available results or yielding them as each job completes. This process also allows for the submission of additional jobs while iterating over the results!
-
Pool Resizing: Offers the capability to resize the thread manager during execution, to optimize resource allocation according to the current workload.
-
Thread Monitoring: Keep track of your thread manager with detailed insights, including thread activity, workload distribution, and more.
-
Graceful Termination: Supports graceful termination of worker threads, ensuring that currently executing jobs are concluded before shutting down.
➢ Usage
⤷ Basic Usage
use ThreadManager;
⤷ Retrieving Results
use ThreadManager;
⤷ Monitoring Status And Job Information
use ThreadManager;
➢ To-Do
- — Add documentation
➢ License
This project is licensed under the MIT License.
See the LICENSE file for more information.