1.9 KiB
1.9 KiB
id, title, status, wave, depends_on, plan, spec
| id | title | status | wave | depends_on | plan | spec | ||
|---|---|---|---|---|---|---|---|---|
| 03-orchestrator-trigger-dispatch | Orchestrator trigger dispatch | done | 2 |
|
plan.md | ../../specs/tasks/requirements/subtask-completion-trigger.md |
Task 03: Orchestrator trigger dispatch
Acceptance
- A child task state transition from non-terminal to terminal evaluates the parent only when every active direct child is terminal.
- The parent receives exactly one
engine.TriggerOnChildrenCompletedfor the same completed child set. - Transition actions from
on_children_completedapply the normal workflow lifecycle:on_exit, persisted parent step change, data patch persistence, andon_enter.
Verification
go test ./internal/orchestrator/...
Files Likely Touched
apps/backend/internal/orchestrator/service.goapps/backend/internal/orchestrator/event_handlers_children_completed.goapps/backend/internal/orchestrator/event_handlers_children_completed_test.goapps/backend/internal/orchestrator/event_handlers_workflow.goapps/backend/internal/orchestrator/workflow_store.go
Dependencies
01-backend-child-completion-repository02-workflow-event-contracts
Inputs
- Spec:
docs/specs/tasks/requirements/subtask-completion-trigger.md, sectionsState machine,Failure modes,Persistence guarantees,Scenarios. - Plan: Backend
Workflow Trigger Dispatch. - Existing patterns:
processOnTurnCompleteViaEngine,applyEngineTransition,office/engine_dispatcher.Dispatcher, and watcher task event subscription wiring.
Output Contract
When finished, update this task frontmatter to status: done, update the
checkbox in plan.md, and report:
- Summary of trigger dispatch and idempotency behavior.
- Files changed.
- Tests run and their result.
- Any blockers or follow-up risks.