A runtime job description, never a persisted representation.
A new struct has no ID, lifecycle state, or timestamps. Constructing one
neither inserts a job nor marks it available for execution. new/3 constructs
a validated immutable definition and ID but does not access storage.
Only the independent Event v1 schema defines persistence. The definition
field is the immutable insertion intent used for reconciliation; editing
presentation fields does not create a new definition. Construct a new job
explicitly to change that intent. Recovered views can lack runtime mappings.
Summary
Types
@type t() :: %Tay.Job{ args: map(), attempt: non_neg_integer(), attempted_at: DateTime.t() | non_neg_integer() | nil, completed_at: DateTime.t() | non_neg_integer() | nil, definition: map() | nil, errors: [term()], id: binary() | nil, inserted_at: DateTime.t() | non_neg_integer() | nil, max_attempts: pos_integer(), queue: atom() | String.t(), revision: term(), scheduled_at: DateTime.t() | non_neg_integer() | nil, state: atom() | nil, timeout_ms: pos_integer(), worker: module() | nil, worker_key: String.t() | nil }