Phase 14: Parallel Phase Execution - 8 plans in 5 waves - 4 parallel in Wave 1, 3, 5 - Adds phase_dependencies schema (mirrors task_dependencies) - PhaseDispatchManager port and adapter - tRPC procedures and CLI commands - Unit tests and E2E tests
2.7 KiB
2.7 KiB
phase, plan, type, wave, depends_on, files_modified, autonomous
| phase | plan | type | wave | depends_on | files_modified | autonomous | |||||
|---|---|---|---|---|---|---|---|---|---|---|---|
| 14-parallel-phase-execution | 03 | execute | 2 |
|
|
true |
Purpose: Enable queuing and dispatching phases based on their dependencies. Output: PhaseDispatchManager interface with queue/dispatch operations.
<execution_context>
@/.claude/get-shit-done/workflows/execute-plan.md
@/.claude/get-shit-done/templates/summary.md
</execution_context>
Reference implementations:
@src/dispatch/types.ts @src/dispatch/manager.ts
Task 1: Define PhaseDispatchManager port interface src/dispatch/types.ts Add types for phase dispatch:QueuedPhase interface:
- phaseId: string
- initiativeId: string
- queuedAt: Date
- dependsOn: string[] (phase IDs)
PhaseDispatchResult interface:
- success: boolean
- phaseId: string
- reason?: string (failure reason)
PhaseDispatchManager port interface:
- queuePhase(phaseId: string): Promise
- getNextDispatchablePhase(): Promise<QueuedPhase | null>
- dispatchNextPhase(): Promise
- completePhase(phaseId: string): Promise
- blockPhase(phaseId: string, reason: string): Promise
- getPhaseQueueState(): Promise<{ queued: QueuedPhase[], ready: QueuedPhase[], blocked: Array<{phaseId: string, reason: string}> }>
Follow exact patterns from DispatchManager for tasks. npx tsc --noEmit passes PhaseDispatchManager interface defined with all methods
Task 2: Export phase dispatch types src/dispatch/index.ts Export new types from dispatch module: - QueuedPhase - PhaseDispatchResult - PhaseDispatchManager npx tsc --noEmit passes Phase dispatch types exported from dispatch module Before declaring plan complete: - [ ] `npm run build` succeeds without errors - [ ] `npm test` passes all tests - [ ] PhaseDispatchManager importable from src/dispatch<success_criteria>
- All tasks completed
- All verification checks pass
- Interface follows hexagonal architecture (port pattern)
- Methods mirror DispatchManager for consistency </success_criteria>