← Graph

Active Job Is A Poor Workflow Container

takeaway 2 connections

When using Active Job as a workflow container you inherit identity and queryability problems: the Active Job ID is a UUID but most queue adapters make it hard or impossible to query by; retries can replicate a job with the same ID under different execution instances; state lives in an opaque params bag inside the queue (e.g. SQS can't be queried at all; Solid Queue + Postgres lets you dig into a JSON column but with no guarantees of ease or accuracy). Use Active Job as a trigger, not a carrier.

type
lesson-learned
takeaway Active Job Is A Poor Workflow Container
about
Critiques the params-bag carrier approach used in Rails 8.1 continuation.
takeaway Active Job Is A Poor Workflow Container
from_talk
Drawn from Julik's critique of active_job-based workflow containers.

Provenance