Struct bastion_executor::run_queue::Injector [−][src]
pub struct Injector<T> { /* fields omitted */ }
Expand description
An injector queue.
This is a FIFO queue that can be shared among multiple threads. Task schedulers typically have a single injector queue, which is the entry point for new tasks.
Implementations
Steals a batch of tasks and pushes them into a worker.
How many tasks exactly will be stolen is not specified. That said, this method will try to steal around half of the tasks in the queue, but also not more than some constant limit.
Steals a batch of tasks, pushes them into a worker, and pops a task from that worker.
How many tasks exactly will be stolen is not specified. That said, this method will try to steal around half of the tasks in the queue, but also not more than some constant limit.
Trait Implementations
Auto Trait Implementations
impl<T> RefUnwindSafe for Injector<T> where
T: RefUnwindSafe,
impl<T> !UnwindSafe for Injector<T>
Blanket Implementations
Mutably borrows from an owned value. Read more
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more