Skip to content

Stress | Move to ci/stress and build against sqlclient-ci-package output - #4456

Merged
paulmedynski merged 2 commits into
mainfrom
dev/paul/sqlcliet-ci-stress
Jul 21, 2026
Merged

Stress | Move to ci/stress and build against sqlclient-ci-package output#4456
paulmedynski merged 2 commits into
mainfrom
dev/paul/sqlcliet-ci-stress

Conversation

@paulmedynski

@paulmedynski paulmedynski commented Jul 17, 2026

Copy link
Copy Markdown
Contributor

Summary

Relocates and reworks the stress test pipeline so it validates the packaged driver produced by the sqlclient-ci-package pipeline, and converts the stress projects to the standard ReferenceType Package/Project pattern used by the other SqlClient test projects.

Pipeline

  • Move eng/pipelines/stress/*eng/pipelines/ci/stress/ and rename the pipeline/stage/job to sqlclient-ci-stress-*.yml.
  • Trigger on completion of sqlclient-ci-package, scoped to the current project. A single pipeline resource omits project (so it resolves to the current ADO project) and references the pipeline by its bare source name, so the Public registration is triggered only by Public's sqlclient-ci-package and the ADO.Net registration only by ADO.Net's — no cross-project triggering. (This requires the sqlclient-ci-package name to be unique within each project so the folder can be omitted from source; variables/System.TeamProject can't be used in the resources block.)
  • Download the SqlClient-Driver-Packages artifact into the local NuGet feed (packages/) and resolve the exact MDS/Azure versions from the .nupkg filenames.
  • Build and run the stress tests in Package mode (ReferenceType=Package) against those versions.
  • Pool selection is driven by a single isInternalBuild variable and the requested image: macOS images run on the Microsoft-hosted Azure Pipelines pool; all other images run on the 1ES pool for the current project (ADO-1ES-Pool/ADO-CI-1ES-Pool) matched via imageOverride. The old threaded poolName parameter is removed.
  • Jobs: Linux (ADO-UB22-SQL22), Windows (ADO-MMS22-SQL22), and macOS (macos-latest).

Projects

  • Add the standard ReferenceType Package/Project toggle to the three stress projects that reference MDS (SqlClient.Stress.Framework also toggles the Azure extension), defaulting to Project for local/IDE builds.
  • Declare Microsoft.Data.SqlClient and Microsoft.Data.SqlClient.Extensions.Azure PackageVersion entries (Package mode) in the stress Directory.Packages.props.

Docs

  • Update pipeline path references in the instructions/prompt files and drop the now-redundant eng/pipelines/stress/* exclusion from the PR pipelines (covered by eng/pipelines/ci/*).

Tests

  • Public project pipeline run: 19802
  • ADO.Net project pipeline run: 19802

Notes for Reviewers

  • No effort was made to identify common/shared stages, jobs, or steps between this pipeline and sqlclient-ci-package and sqlclient-pr. I want to wait for a few of the new pipelines to exist before identifying emergent commonalities to factor out.
  • The stress tests themselves are still failing. That is a separate concern.

Copilot AI review requested due to automatic review settings July 17, 2026 19:27
@github-project-automation github-project-automation Bot moved this to To triage in SqlClient Board Jul 17, 2026
@paulmedynski paulmedynski added the Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems. label Jul 17, 2026
@paulmedynski paulmedynski moved this from To triage to In progress in SqlClient Board Jul 17, 2026
@paulmedynski paulmedynski added this to the 7.1.0-preview3 milestone Jul 17, 2026

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

Relocates the stress test pipeline under eng/pipelines/ci/stress/ and updates stress test projects so they can build either against in-repo project references (local/IDE) or against produced NuGet packages (CI), aligning stress coverage with the standard Package/Project ReferenceType pattern used elsewhere in SqlClient.

Changes:

  • Moved/reworked the stress pipeline to trigger from sqlclient-ci-package and run stress tests in ReferenceType=Package mode.
  • Added ReferenceType-based conditional ProjectReference vs PackageReference wiring to the stress test projects, plus stress-local CPM entries for SqlClient/Azure package versions.
  • Updated docs/prompts and PR pipeline path exclusions to reflect the new stress pipeline location under eng/pipelines/ci/.

Reviewed changes

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

Show a summary per file
File Description
src/Microsoft.Data.SqlClient/tests/StressTests/SqlClient.Stress.Tests/SqlClient.Stress.Tests.csproj Conditional MDS project/package reference based on ReferenceType.
src/Microsoft.Data.SqlClient/tests/StressTests/SqlClient.Stress.Runner/SqlClient.Stress.Runner.csproj Conditional MDS project/package reference based on ReferenceType.
src/Microsoft.Data.SqlClient/tests/StressTests/SqlClient.Stress.Framework/SqlClient.Stress.Framework.csproj Conditional MDS + Azure extension project/package references based on ReferenceType.
src/Microsoft.Data.SqlClient/tests/StressTests/Directory.Packages.props Defaults ReferenceType to Project; in Package mode wires PackageVersion to pipeline-supplied versions.
eng/pipelines/sqlclient-pr-project-ref-pipeline.yml Removes redundant exclusion for the old eng/pipelines/stress/* path.
eng/pipelines/sqlclient-pr-package-ref-pipeline.yml Removes redundant exclusion for the old eng/pipelines/stress/* path.
eng/pipelines/ci/stress/sqlclient-ci-stress-stage.yml Switches stage to new stress job template and removes threaded pool parameter.
eng/pipelines/ci/stress/sqlclient-ci-stress-pipeline.yml Updates pipeline resource triggers to run from sqlclient-ci-package and points at new stage template path.
eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml Downloads packaged outputs, stages packages into local feed, resolves versions, and runs stress tests in Package mode; adjusts pool selection logic.
.github/prompts/update-build-pipelines.prompt.md Updates stress pipeline reference path in maintainer prompt.
.github/instructions/ado-pipelines.instructions.md Updates stress pipeline reference path in ADO pipeline guidance.
Comments suppressed due to low confidence (3)

eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:109

  • The job expects the downloaded artifact to be under .../SqlClient-Driver-Packages, but the sqlclient-ci-package pipeline publishes its NuGet packages artifact as Packages (see eng/pipelines/ci/package/sqlclient-package.yml, PublishPipelineArtifact artifactName: Packages). As written, $(packageArtifactDir) will point to a non-existent folder and the staging step will fail.
    eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:218
  • The download: steps request an artifact named SqlClient-Driver-Packages, but the sqlclient-ci-package pipeline publishes the packages artifact as Packages (see eng/pipelines/ci/package/sqlclient-package.yml). This will cause the download step to fail because the artifact name won't be found.
    eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:150
  • referenceArgs embeds $(mdsPackageVersion) / $(azurePackageVersion) inside another variable. If Azure Pipelines does not recursively expand nested macros, dotnet build/dotnet run will receive MSBuild properties like -p:SqlClientPackageVersion=$(mdsPackageVersion), which MSBuild will treat as an (undefined) MSBuild property expression and resolve to empty. Passing the pipeline variables directly in the DotNetCoreCLI arguments avoids this nested-expansion ambiguity.

Copilot AI review requested due to automatic review settings July 17, 2026 19: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

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

Comments suppressed due to low confidence (2)

eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:105

  • The pipeline resource download is wired to an artifact named SqlClient-Driver-Packages, but the sqlclient-ci-package pipeline currently publishes its .nupkg/.snupkg output under the artifact name Packages. As written, packageArtifactDir will point at a non-existent folder and the staging step will fail to copy packages.
    eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:211
  • This job downloads artifact SqlClient-Driver-Packages, but sqlclient-ci-package publishes its NuGet output as artifact Packages. The download step will fail (or download nothing) and the later staging/restore will break.

@paulmedynski
paulmedynski marked this pull request as ready for review July 17, 2026 22:07
@paulmedynski
paulmedynski requested a review from a team July 17, 2026 22:07
@paulmedynski paulmedynski moved this from In progress to In review in SqlClient Board Jul 17, 2026
Comment thread eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml
Relocate and rework the stress test pipeline so it validates the packaged
driver produced by the sqlclient-ci-package pipeline.

Pipeline:
- Move eng/pipelines/stress/* to eng/pipelines/ci/stress/ and rename the
  pipeline/stage/job to sqlclient-ci-stress-*.yml.
- Trigger on successful completion of sqlclient-ci-package (Public and
  ADO.Net projects) instead of the legacy PR/CI pipelines.
- Download the SqlClient-Driver-Packages artifact into the local NuGet feed
  and resolve the exact MDS/Azure versions from the .nupkg filenames.
- Build and run the stress tests in Package mode (ReferenceType=Package)
  against those versions.
- Derive the pool from a single isInternalBuild variable; route macOS images
  to the Microsoft-hosted 'Azure Pipelines' pool and other images to the 1ES
  pool via imageOverride. Remove the threaded poolName parameter.

Projects:
- Add the standard ReferenceType Package/Project toggle to the three stress
  projects that reference MDS (Framework also toggles the Azure extension),
  defaulting to Project for local/IDE builds.
- Declare MDS and Azure PackageVersion entries (Package mode) in the stress
  Directory.Packages.props.

Docs:
- Update pipeline path references and drop the now-redundant stress path
  exclusion from the PR pipelines.
Replace the two explicit sqlclient-ci-package pipeline resources with a single
resource that omits 'project' (resolving to the current project) and references
the pipeline by its bare 'source' name.  This scopes the completion trigger per
project automatically, so the Public registration is triggered only by Public's
sqlclient-ci-package and the ADO.Net registration only by ADO.Net's, without
using variables in the resources block (which the compiler rejects).

Collapse the job back to the single 'sqlclient-ci-package' resource alias for
the artifact download and packageArtifactDir.

Note: this requires the sqlclient-ci-package name to be unique within both
projects so the folder path can be omitted from 'source'.
Copilot AI review requested due to automatic review settings July 20, 2026 13:36
@paulmedynski
paulmedynski force-pushed the dev/paul/sqlcliet-ci-stress branch from 5cc0897 to 5255a4f Compare July 20, 2026 13:36

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 11 out of 11 changed files in this pull request and generated no new comments.

Comments suppressed due to low confidence (2)

eng/pipelines/ci/stress/sqlclient-ci-stress-pipeline.yml:8

  • The header comment still says the stress pipeline builds the SqlClient projects transitively, but the pipeline now downloads and tests the packaged driver from sqlclient-ci-package. Updating this avoids confusion for future maintainers.
    eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml:234
  • The version-resolution step searches the local feed directory and picks the first matching .nupkg. On self-hosted agents, packages/ can contain stale files from earlier runs, which can make the resolved version non-deterministic (or wrong) when multiple matches exist. Resolve from the downloaded artifact directory and fail if the match is not exactly one package.

Comment thread eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml
Comment thread eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml
Comment thread eng/pipelines/ci/stress/sqlclient-ci-stress-job.yml
@codecov

codecov Bot commented Jul 20, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 65.26%. Comparing base (fdebcd2) to head (5255a4f).
⚠️ Report is 18 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #4456      +/-   ##
==========================================
- Coverage   65.83%   65.26%   -0.58%     
==========================================
  Files         287      285       -2     
  Lines       43763    66887   +23124     
==========================================
+ Hits        28812    43651   +14839     
- Misses      14951    23236    +8285     
Flag Coverage Δ
CI-SqlClient ?
PR-SqlClient-Project 65.26% <ø> (?)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@paulmedynski
paulmedynski merged commit 45f000a into main Jul 21, 2026
359 checks passed
@paulmedynski
paulmedynski deleted the dev/paul/sqlcliet-ci-stress branch July 21, 2026 10:39
@github-project-automation github-project-automation Bot moved this from In review to Done in SqlClient Board Jul 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area\Engineering Use this for issues that are targeted for changes in the 'eng' folder or build systems.

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants