Skip to main content

Module job

Module job 

Source
Expand description

Jobs — the Job contract, the serialised QueuedJob payload, and the JobRegistry that turns one back into the other.

A queued job crosses a process boundary: it is written by a web request and read, perhaps minutes later, by a worker that may be a different process on a different machine. So a job is defined by two things — a payload that serialises, and a name that survives serialisation.

The name is explicit rather than derived from the Rust type path, because the type path is not a stable identifier: renaming a struct or moving it between modules would strand every job already in the queue.

Structs§

JobContext
What a job can reach while it runs.
JobRegistry
Maps a job’s wire name back to code that can run it.
QueuedJob
A job serialised for the queue.

Traits§

Job
Work to be done later.