getCriticalPath()
getCriticalPath(
graph):ExecutionNode[]
Defined in: graph-query.ts:99
Find the critical path: the longest-duration path from the root to any leaf node.
Uses node duration (endTime - startTime) as the weight.
Running nodes use Date.now() as a provisional endTime.
Parameters
| Parameter | Type | Description |
|---|---|---|
graph | ExecutionGraph | The execution graph to analyse. |
Returns
Nodes ordered from root to the deepest leaf on the longest path.