Skip to content

Use Helix JobDetails QueueAlias/DockerTag for resubmission#17017

Merged
mmitche merged 1 commit into
dotnet:mainfrom
mmitche:mmitche/helix-jobmonitor-resubmit-queue-fields
Jun 17, 2026
Merged

Use Helix JobDetails QueueAlias/DockerTag for resubmission#17017
mmitche merged 1 commit into
dotnet:mainfrom
mmitche:mmitche/helix-jobmonitor-resubmit-queue-fields

Conversation

@mmitche

@mmitche mmitche commented Jun 17, 2026

Copy link
Copy Markdown
Member

Summary

The Helix service now returns QueueAlias and DockerTag directly on JobDetails (dotnet-helix-service 2a5f5fe, now in production). This PR removes the temporary workaround in the JobMonitor that recovered the resubmission target queue by re-parsing the verbatim (alias)queueId@dockerTag string out of the operatingSystem property (tracked by #16964).

Changes

  • JobMonitor/Services/HelixService.cs: resubmission now reads details.QueueId / details.QueueAlias / details.DockerTag directly; removed ResolveTargetQueueSpec, TargetQueueSpec, ParseQueueId, the s_queueAliasRegex field, and the now-unused System.Text.RegularExpressions import.
  • Client/.../generated-code/Models/JobDetails.cs: added the QueueAlias and DockerTag properties now exposed by the service API.
  • Sdk.Tests/.../HelixServiceTests.cs: replaced the four operatingSystem-parsing tests with pass-through tests for the new fields.

Notes

  • The JobDetails fields were added by hand rather than via dotnet build /t:GenerateSwaggerCode because the in-tree SwaggerGenerator currently fails against the live OpenAPI doc (Microsoft.OpenApi 3.6.0 nullability NREs plus a Handlebars.Net 1.x→2.x templating incompatibility). Fixing the generator will be handled in a separate PR.

All HelixServiceTests (9) pass.

The Helix service now returns QueueAlias and DockerTag directly on
JobDetails (dotnet-helix-service commit 2a5f5fe, now in production).
Replace the temporary operatingSystem-property parsing workaround in the
JobMonitor with direct reads of these fields, and remove the now-unused
ParseQueueId/regex helpers. Add the regenerated QueueAlias/DockerTag
properties to the generated Helix client model.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 17, 2026 15:53

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates Helix JobMonitor resubmission to use the newly exposed JobDetails.QueueAlias and JobDetails.DockerTag fields from the Helix service, removing the prior workaround that re-parsed the operatingSystem property to reconstruct resubmission queue targeting.

Changes:

  • Removed the JobMonitor “operatingSystem parsing” workaround and now pass through details.QueueId, details.QueueAlias, and details.DockerTag directly when resubmitting jobs.
  • Extended the generated Helix client JobDetails model to include QueueAlias and DockerTag.
  • Updated HelixServiceTests to validate the new pass-through behavior instead of operatingSystem parsing behavior.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

File Description
src/Microsoft.DotNet.Helix/JobMonitor/Services/HelixService.cs Removes the temporary resubmission target-queue parsing logic and uses JobDetails.QueueAlias/DockerTag directly.
src/Microsoft.DotNet.Helix/Client/CSharp/generated-code/Models/JobDetails.cs Adds QueueAlias and DockerTag properties to match the updated service response.
src/Microsoft.DotNet.Helix/Sdk.Tests/Microsoft.DotNet.Helix.Sdk.Tests/HelixServiceTests.cs Replaces operatingSystem-based tests with tests asserting the new JobDetails fields are passed through to JobCreationRequest.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@mmitche

mmitche commented Jun 17, 2026

Copy link
Copy Markdown
Member Author

The generated files do need to be re-generated rather than edited by hand. However, there are issues with the generator due to upgrades to various packages in the repo. Will be resolved in a separate PR.

@mmitche
mmitche merged commit 5653903 into dotnet:main Jun 17, 2026
10 checks passed
@dotnet-milestone-bot dotnet-milestone-bot Bot added this to the 11.0-preview7 milestone Jun 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants