Investigating bottlenecks
Which time components explain increased total build duration?
The failure sequence shows where load and retries interact. The diagnostic plan treats measured waiting time, processing duration and business conflicts separately.
Starting point Check artifact completeness and provenance completeness separately.
Assumptions for the example case
A fictional example design with one repository, a precisely specified build job, an isolated worker, an immutable artifact identified by digest and explicit release approval. Figures and quality goals are illustrative test assumptions. Full software supply-chain certification, production orchestration and arbitrary privileged builds are outside the scope.
Diagnose the limiting resource
Worker backlog and lease conflict
Ten fully utilised workers explain waiting time; stale_generation correctly rejects an old completion.
From signal to action
| Signal | Validation | Reaction |
|---|---|---|
| Break down waiting time | Builds take longer despite free CPU. | Measure queue time, source retrieval and build time separately. |
| Conflicts on the shared entity | Two workers claim B-151. In either commit order, one receives current execution authorisation. After expiry, a new attempt may start; the old worker can no longer publish a valid completion. | Count expected conflicts separately from technical errors. |
| Peak test profile exceeded | 120 builds in 60 min × 5 min = 600 worker minutes; at least 10 fully utilized workers without reserve | A common cache becomes a hotspot. |
Break down waiting time
- Validation
- Builds take longer despite free CPU.
- Reaction
- Measure queue time, source retrieval and build time separately.
Conflicts on the shared entity
- Validation
- Two workers claim B-151. In either commit order, one receives current execution authorisation. After expiry, a new attempt may start; the old worker can no longer publish a valid completion.
- Reaction
- Count expected conflicts separately from technical errors.
Peak test profile exceeded
- Validation
- 120 builds in 60 min × 5 min = 600 worker minutes; at least 10 fully utilized workers without reserve
- Reaction
- A common cache becomes a hotspot.
Break down waiting time
Measure queue time, source retrieval and build time separately.
Builds take longer despite free CPU.
More workers only help with queue bottlenecks.
- Alternative considered
- Total duration alone hides a slow dependency.
- Trade-off
- Additional measurement points are needed.
- Reassess
- A common cache becomes a hotspot.
Terms in this step
- Break down waiting time
- More workers only help with queue bottlenecks.
Try it yourself
Total duration rises despite available CPU. Name three time components and an action supported by them.
A hint for your attempt
Use the specific entities and conditions from this step. The two solution parts distinguish the decision from its evidenced outcome.
Compare with a possible solution
- First part of the solution
- Measure queue time, source retrieval time and actual build duration separately.
- Second part of the solution
- High source-retrieval time calls for investigating the source connection; additional workers help only when worker capacity is the queue bottleneck.
Apply to your project
Which corresponding assumption would you test first in your project? Consider this trigger: A common cache becomes a hotspot.