Expand description
exec_core trait-method family — Postgres impls.
RFC-v0.7 Wave 4 (Agent A). Implements the five exec-core write
- read methods for the Postgres backend:
- [
create_execution_impl] — inherent entry onsuper::PostgresBackend. Replaces the Valkeyff_create_executionFCALL with a singleINSERT ... ON CONFLICT DO NOTHINGfor idempotency (idempotency-key replay mirrors the FCALL’sDuplicateoutcome). Also seeds the global [ff_lane_registry] row on first sight of a lane (Q6 adjudication — dynamic lanes get a registry entry here as well as at server-boot seeding). - [
describe_execution_impl] — single-rowSELECTagainstff_exec_core, decoded intoExecutionSnapshotvia the sharedff_core::contracts::decode::build_execution_snapshothelper so the snapshot shape matches the Valkey backend bit-for-bit. - [
list_executions_impl] — cursor-paginated forward scan over onepartition_key,ORDER BY execution_id ASC. Uses the N+1 trick (fetchlimit+1rows) to decidenext_cursor. - [
cancel_impl] — transactionalSELECT ... FOR UPDATE+UPDATEto transition the exec row topublic_state='cancelled',lifecycle_phase='terminal', settingterminal_at_ms+cancellation_reason. Per Q11 the default READ COMMITTED isolation suffices; the row lock narrows the RMW to one writer. - [
resolve_execution_flow_id_impl] — one-column lookup byexecution_id(the unique index lets pg skip partition pruning for this admin-tooling path).
Spec authority: rfcs/drafts/v0.7-migration-master.md Q5 (partition
math), Q11 (isolation), Q14 (dual-backend — no cross-backend
fields).