Skip to content

Enable Helix queue stats logging for Arcade unit tests#17018

Open
chcosta wants to merge 5 commits into
dotnet:mainfrom
chcosta:dev/chcosta/enable-helix-queue-stats
Open

Enable Helix queue stats logging for Arcade unit tests#17018
chcosta wants to merge 5 commits into
dotnet:mainfrom
chcosta:dev/chcosta/enable-helix-queue-stats

Conversation

@chcosta

@chcosta chcosta commented Jun 17, 2026

Copy link
Copy Markdown
Member

Enables the new opt-in Helix queue health summary (added in #16922) for Arcade's own tests/UnitTests.proj.

Adds <EnableShowHelixQueueStats>true</EnableShowHelixQueueStats> so that every Helix job submitted by the Arcade unit-test pipeline logs the queue health summary at submit time. This dogfoods the feature and gives FRs immediate signal on Helix queue conditions when Arcade's own CI submits work.

Depends on #16922 having shipped through Arcade.

Copilot AI review requested due to automatic review settings June 17, 2026 16:35

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

Enables Helix queue health summary logging for Arcade’s own Helix-submitted unit test jobs by opting in via MSBuild property, so Arcade CI “dogfoods” the feature and emits queue condition signal at job submission time.

Changes:

  • Set EnableShowHelixQueueStats to true in tests/UnitTests.proj so Helix submissions from Arcade unit tests log the queue health summary.

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

Default CI verbosity is Minimal, which filters out MessageImportance.Normal
messages. When EnableShowHelixQueueStats is opted in, route SendAsync log
output (including the queue-health summary) at High importance so it
survives the default verbosity.
@chcosta

chcosta commented Jun 17, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@chcosta

chcosta commented Jun 19, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@chcosta

chcosta commented Jun 22, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

ISentJob job = await def.SendAsync(msg => Log.LogMessageFromText(msg, MessageImportance.Normal), cancellationToken);
// LogMessageFromText will take any string formatted as a canonical error or warning and convert the type of log to this.
// When queue-stats logging is opted in, elevate to High importance so the summary survives the default 'Minimal' build verbosity.
MessageImportance sendAsyncImportance = EnableShowHelixQueueStats ? MessageImportance.High : MessageImportance.Normal;

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

The comment suggests that Minimal should be the important when not enabled?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

that's what it was, yes. which meant queue stat logging wasn't visible.

chcosta added 2 commits June 22, 2026 18:22
Add WithAzureDevOpsOrganization() and WithAzureDevOpsProject() fluent builder
methods to JobDefinition to allow callers (especially public pipelines) to
specify which Azure DevOps organization/project is requesting queue stats.
These parameters are passed through JobCreationRequest to Helix API.

Fixes: Arcade PR for enabling queue stats support with org/project scoping
Queue names are globally unique across all organizations and projects, so
the Helix API does not need org/project context to return stats. These
parameters only serve as optional audit context on the public Helix Observer
endpoint for external callers to declare their scope.

Reverts the org/project fluent builder methods since:
1. They are unused in the codebase
2. Queue stats are queried and returned by queue name globally
3. Org/project scoping is only relevant on the public HTTP endpoint
@chcosta

chcosta commented Jun 23, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@chcosta

chcosta commented Jun 23, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

@chcosta

chcosta commented Jun 24, 2026

Copy link
Copy Markdown
Member Author

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines successfully started running 1 pipeline(s).

Copilot AI review requested due to automatic review settings June 24, 2026 18:23
@chcosta

chcosta commented Jun 24, 2026

Copy link
Copy Markdown
Member Author

The service issues seem to be resolved now and this is ready for review. queue wait time estimates / stats are being shown in the Test SubmitHelixTests steps.

@chcosta chcosta marked this pull request as ready for review June 24, 2026 18:24

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

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

Comment on lines +58 to +62
[JsonProperty("AzureDevOpsOrganization")]
public string AzureDevOpsOrganization { get; set; }

[JsonProperty("AzureDevOpsProject")]
public string AzureDevOpsProject { get; set; }
Comment on lines +270 to +272
// LogMessageFromText will take any string formatted as a canonical error or warning and convert the type of log to this.
// When queue-stats logging is opted in, elevate to High importance so the summary survives the default 'Minimal' build verbosity.
MessageImportance sendAsyncImportance = EnableShowHelixQueueStats ? MessageImportance.High : MessageImportance.Normal;
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