pub trait QueueExt: Queue {
// Provided methods
fn dispatch_chain<'a>(
&'a self,
chain: Chain,
) -> BoxFuture<'a, Result<String>> { ... }
fn dispatch<'a, J: Job>(
&'a self,
job: &'a J,
) -> BoxFuture<'a, Result<String>> { ... }
fn dispatch_on<'a, J: Job>(
&'a self,
queue: &'a str,
job: &'a J,
) -> BoxFuture<'a, Result<String>> { ... }
fn dispatch_later<'a, J: Job>(
&'a self,
delay: Duration,
job: &'a J,
) -> BoxFuture<'a, Result<String>> { ... }
}Expand description
The conveniences that take a concrete job type, and so cannot live on a
dyn-compatible trait. Blanket-implemented, including for dyn Queue.
Provided Methods§
Sourcefn dispatch_chain<'a>(&'a self, chain: Chain) -> BoxFuture<'a, Result<String>>
fn dispatch_chain<'a>(&'a self, chain: Chain) -> BoxFuture<'a, Result<String>>
dispatch(SendWelcomeEmail { user_id }) — the everyday call.
Push the first step of a chain; the worker pushes each next step as
the one before it succeeds. Returns the first step’s id.
fn dispatch<'a, J: Job>(&'a self, job: &'a J) -> BoxFuture<'a, Result<String>>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".