Expand description
Durable, at-least-once application jobs. Handlers must be idempotent.
Jobs use stable explicit names and versions, JSON payloads and the application’s native SeaORM connection/transaction. No worker runs inside HTTP implicitly.
Modules§
- migration
- Conventional queue schema. Register
JobsMigrationin your SeaORM migrator.
Structs§
- Failed
Job - Safe operational failure listing. Payloads are deliberately absent.
- JobContext
- Application services and safe reservation metadata supplied to a handler.
- JobError
- A safe failure summary. Never put secrets, payloads or raw provider errors here.
- JobObservation
- Payload-free metadata suitable for counters, duration histograms and logs.
- Jobs
- Explicit handler registry; duplicate names/versions are rejected by validation.
- Jobs
Settings - Durable worker policy. Jobs are activated by
App::jobs, never implicitly. - Queue
- Durable dispatcher. Cloning retains the native connection pool and queue name.
- Queue
Name - Validated logical queue identifier, reusable by dispatchers and workers.
- Transactional
Queue - Queue bound to an existing transaction. Cannot acquire a pool connection or accidentally dispatch work outside the enclosing business transaction.
- Worker
- Bounded worker using the same application context as HTTP, in a separate process.
Enums§
- JobEvent
- Safe lifecycle event. Enqueue within a transaction is only an insertion intent.
Traits§
- Job
- An application-owned job. Persisted names and versions are compatibility APIs.
- JobDispatch
- Dispatch access without changing the application’s shared context layout.
- JobObserver
- Application-owned, nonblocking metrics/telemetry callback.
- Transactional
JobDispatch - Transaction-bound job access for lifecycle listeners. Import alongside
JobDispatch(both are in Capy’s prelude); the receiver selects the safe API.
Type Aliases§
- JobResult
- Handler result with explicit retry/permanent classification.