Conversation
JobID was used to uniquely identify jobs.
This ID used to allow us to cnacel a runner provisioning if the job is cancelled.
However, there are cases in which the JobID is not avaialble, but the RunnerRequestId is.
There are two main flows:
1. A job is assinged to the integration
- In this case there is a JobID, but the RunnerRequestId is not available.
2. A job is acquired by the integration
- In this case there is a RunnerRequestId, but the JobID is not available.
We now use a jobIdentity struct to uniquely identify a job.
This struct contains the JobID and the RunnerRequestId.
The decision to cancel a runner provisioning is now based on the jobIdentity struct.
In the case both IDs are not available, we will not cancel the runner provisioning.
spikeburton
approved these changes
Mar 12, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
JobID was used to uniquely identify jobs.
This ID used to allow us to cnacel a runner provisioning if the job is cancelled.
However, there are cases in which the JobID is not avaialble, but the RunnerRequestId is.
There are two main flows:
We now use a jobIdentity struct to uniquely identify a job.
This struct contains the JobID and the RunnerRequestId.
The decision to cancel a runner provisioning is now based on the jobIdentity struct.
In the case both IDs are not available, we will not cancel the runner provisioning.
Testing
Standard Run
Run a job and ensures it completes
Cancel Job
Ensure there are not enough resources on an env
Start a job
See that provisioning starts to fail
Cancel the job
Ensure the provisioning stops
Multiple Jobs
Ensure there are not enough resources on an env
Start a job
Start another job
Cancel one of the jobs
Free space in the env
The non-cancelled job should complete