ores.workflow.workflow_step
Table of Contents
- 1. Flags
- 2. Natural keys
- 3. Columns
- 3.1. id
- 3.2. workflow_id
- 3.3. step_index
- 3.4. name
- 3.5. state_id
- 3.6. request_json
- 3.7. response_json
- 3.8. error
- 3.9. step_log_json
- 3.10. command_subject
- 3.11. command_json
- 3.12. command_published_at
- 3.13. idempotency_key
- 3.14. compensation_subject
- 3.15. compensation_json
- 3.16. started_at
- 3.17. completed_at
- 4. SQL
- 5. Foreign keys
- 6. Indexes
- 7. C++
- 8. See also
Records the execution of one step in a saga workflow, including the step index, name, status, request/response payloads, and timing. Steps reference their parent workflow instance via workflow_id.
1. Flags
2. Natural keys
3. Columns
3.1. id
UUID primary key for the workflow step.
3.2. workflow_id
FK reference to the parent workflow instance.
3.3. step_index
Zero-based ordinal position of this step within the workflow. Negative values denote compensation steps.
3.4. name
Human-readable step name, e.g. 'save_party'.
3.5. state_id
FK to the FSM state record (ores_workflow_fsm_states_tbl) for this step.
3.6. request_json
Serialised JSON payload sent to the downstream service for this step.
3.7. response_json
Serialised JSON response received from the downstream service.
3.8. error
Human-readable error message if the step failed.
3.9. step_log_json
Opaque log entries emitted while the step ran, held as serialised JSON. The query surface returns them beside the step's result.
3.10. command_subject
NATS subject to which the step command was published.
3.11. command_json
Serialised JSON command payload published to the domain service.
3.12. command_published_at
Timestamp when the step command was published to NATS.
3.13. idempotency_key
Idempotency key (echoes the step UUID) sent as X-Workflow-Step-Id header.
3.14. compensation_subject
NATS subject for the compensation command. Empty if this step has no compensation.
3.15. compensation_json
Serialised JSON compensation command payload, populated when compensation is triggered.
3.16. started_at
Timestamp when the step began executing.
3.17. completed_at
Timestamp when the step reached a terminal state.
4. SQL
4.1. Flags
5. Foreign keys
5.1. workflow_id
6. Indexes
Every step read is scoped by its workflow, which is also the generated parent-scoped list's filter, so this index is its hot path.
6.1. workflow_id
7. C++
7.1. Flags
7.2. Repository
7.3. Domain includes
#include <chrono> #include <optional> #include <string> #include <boost/uuid/uuid.hpp>
7.4. Conventions
7.5. Custom repository methods
8. See also
- ores.workflow — component group overview.