(workflowId: string, triggerBlockId?: string)
| 84 | } |
| 85 | |
| 86 | async execute(workflowId: string, triggerBlockId?: string): Promise<ExecutionResult> { |
| 87 | const savedIncomingEdges = this.contextExtensions.dagIncomingEdges |
| 88 | const dag = this.dagBuilder.build(this.workflow, { |
| 89 | triggerBlockId, |
| 90 | savedIncomingEdges, |
| 91 | includeAllBlocks: this.contextExtensions.resumeFromSnapshot === true, |
| 92 | }) |
| 93 | const restoredClonedSubflows = this.restoreSnapshotParallelBatches( |
| 94 | dag, |
| 95 | this.contextExtensions.snapshotState |
| 96 | ) |
| 97 | this.restoreSavedIncomingEdges(dag, savedIncomingEdges) |
| 98 | const { context, state } = this.createExecutionContext(workflowId, triggerBlockId) |
| 99 | context.subflowParentMap = this.buildSubflowParentMap(dag) |
| 100 | this.registerRestoredClonedSubflows(context.subflowParentMap, restoredClonedSubflows) |
| 101 | |
| 102 | const engine = this.buildExecutionPipeline(context, dag, state) |
| 103 | return await engine.run(triggerBlockId) |
| 104 | } |
| 105 | |
| 106 | async continueExecution( |
| 107 | _pendingBlocks: string[], |
nothing calls this directly
no test coverage detected