Skip to content

Fix Managed CI Managed Identity User ID - #5122

Merged
benrr101 merged 1 commit into
mainfrom
dev/russellben/ci-mi-useridentity
Nov 20, 2026
Merged

benrr101 merged 1 commit into
mainfrom
dev/russellben/ci-mi-useridentity

Conversation

@benrr101

Copy link
Copy Markdown
Contributor

Description

Fix Managed Instance CI authentication following the test-harness changes in #4390.

The harness now acquires Azure SQL tokens using UserManagedIdentityClientId, rather than the connection string’s UID. This pipeline still disabled managed identity support and did not supply the separate client-ID setting, causing connections to fail with “An access token is required to connect to Azure SQL.”

This change:

  • Enables ManagedIdentitySupported.
  • Supplies the dedicated SqlMiUserManagedIdentityClientId library variable.
  • Corrects misleading comments about managed identity support.

The library configuration has already been updated: the dedicated variable contains the existing Managed Instance identity, and SQL_MI_TCP_CONN_STRING references it through UID=$(SqlMiUserManagedIdentityClientId). This preserves compatibility with older harnesses without maintaining two independent client-ID values.

No product code, public APIs, or test implementations changed.

Issues

Related to #4390 and #4482.

Addresses the authentication failures in [Managed Instance CI run 193421](https://dev.azure.com/SqlClientDrivers/ADO.Net/_build/results?buildId=193421&view=results).

Testing

@benrr101 benrr101 added this to the 8.1.0-preview1 milestone Nov 19, 2026
@benrr101
benrr101 requested a review from a team as a code owner November 19, 2026 20:02
@benrr101 benrr101 added Hotfix 8.0.0 PRs that must be backported to release/8.0 Hotfix 7.1.3 PRs targeting main that should be backported to release/7.1 for 7.1.3. labels Nov 19, 2026
Copilot AI balanced review requested due to automatic review settings November 19, 2026 20:02
@github-project-automation github-project-automation Bot moved this to To triage in SqlClient Board Nov 19, 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.

🟢 Approval recommended

There are no active review issues for the pipeline-only Managed Instance CI authentication update.

No open issues 🎉

What changed in this PR

Updates Managed Instance CI authentication to match the token-based test harness introduced in #4390. The change is limited to pipeline configuration; product code, public APIs, and test implementations are unchanged.

Changes:

  • Enables managed identity support and supplies SqlMiUserManagedIdentityClientId to the harness.
  • Corrects comments to explain shared identity usage and connection-string compatibility with older harnesses.
File Description
eng/​pipelines/​ci/​managed-instance/​sqlclient-ci-managed-instance-job.yml Enables managed identity authentication, passes the dedicated client ID, and clarifies configuration comments.

Review effort: Balanced

@benrr101
benrr101 merged commit 091d505 into main Nov 20, 2026
18 of 19 checks passed
@github-project-automation github-project-automation Bot moved this from To triage to Done in SqlClient Board Nov 20, 2026
@benrr101
benrr101 deleted the dev/russellben/ci-mi-useridentity branch November 20, 2026 00:53
benrr101 added a commit that referenced this pull request Nov 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Hotfix 7.1.3 PRs targeting main that should be backported to release/7.1 for 7.1.3. Hotfix 8.0.0 PRs that must be backported to release/8.0

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

5 participants