SquidMesh.Runtime.DispatchProtocol.ActionAttempt (squid_mesh v0.1.0-alpha.7)

Copy Markdown View Source

Rebuildable projection of one dispatch attempt.

This is not mutable runtime state. It is the compact read model obtained by replaying journal entries for one runnable key.

Summary

Types

status()

@type status() :: :available | :retry_scheduled | :claimed | :completed | :failed

t()

@type t() :: %SquidMesh.Runtime.DispatchProtocol.ActionAttempt{
  applied?: boolean(),
  attempt_number: pos_integer(),
  claim_id: String.t() | nil,
  claim_token_hash: String.t() | nil,
  error: map() | nil,
  idempotency_key: String.t(),
  input: map(),
  lease_until: DateTime.t() | nil,
  owner_id: String.t() | nil,
  result: map() | nil,
  run_id: String.t(),
  runnable_key: String.t(),
  status: status(),
  step: String.t(),
  visible_at: DateTime.t(),
  wakeup_emitted?: boolean()
}