basalt / queue/src / JobSummary
Interface: JobSummary
Defined in: queue/src/driver.ts:87
A driver-neutral view of ONE job. Drivers must return this — never their backend's own job object (a BullMQ Job, an amqplib message, …). Leaking that would invert the coupling this API exists to remove: the app would be back to writing broker-specific code, just through a Basalt method.
Properties
attemptsMade
> attemptsMade: number
Defined in: queue/src/driver.ts:95
Attempts made so far (0 before the first run).
context?
> optional context?: RequestContext
Defined in: queue/src/driver.ts:101
The request context captured at dispatch (requestId, tenantId, …), if any.
failedReason?
> optional failedReason?: string
Defined in: queue/src/driver.ts:103
Why it failed — only meaningful for state: 'failed'.
id
> id: string
Defined in: queue/src/driver.ts:89
Backend-assigned job id, as a string.
name
> name: string
Defined in: queue/src/driver.ts:91
The job name — what defineJob({ name }) declared.
payload
> payload: unknown
Defined in: queue/src/driver.ts:99
The APP's payload — unwrapped from the dispatch envelope.
state
> state: JobState
Defined in: queue/src/driver.ts:93
Which state the job was found in.
timestamp
> timestamp: number
Defined in: queue/src/driver.ts:97
When the job was created, epoch milliseconds.