Repository navigation
Update HotChocolate packages to 16.7.3 - #3902
Merged
RubenCerna2079 merged 2 commits intoNov 9, 2026
Merged
Conversation
Tobias Tengler (tobias-tengler)
requested review from
Alekhya-Polavarapu,
Aniruddh Munde (Aniruddh25),
RubenCerna2079,
aaronburtle,
cwebb-msft,
Mohit G (gmohit21),
mhyon,
rusamant,
Sourabh Jain (sourabh1007),
Souvik Ghosh (souvikghosh04),
Stuart Padley (stuartpa) and
vadeveka
as code owners
November 6, 2026 20:26
|
Azure Pipelines: There may be pipelines that require an authorized user to comment /azp run to run. |
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
There are no active review issues for the HotChocolate dependency update.
No open issues 🎉
What changed in this PR
Updates DAB’s HotChocolate dependencies to 16.7.3 to incorporate upstream security fixes in its GraphQL stack.
Changes:
- Upgrades all six centrally managed HotChocolate packages from 16.6.4 to 16.7.3, keeping their versions aligned.
| File | Description |
|---|---|
src/Directory.Packages.props |
Updates the six HotChocolate package versions to 16.7.3. |
Review effort: Balanced
Aniruddh Munde (Aniruddh25)
approved these changes
Nov 6, 2026
Collaborator
|
/azp run |
|
Azure Pipelines: Successfully started running 6 pipeline(s). |
RubenCerna2079
approved these changes
Nov 9, 2026
RubenCerna2079
enabled auto-merge (squash)
November 9, 2026 22:08
Contributor
|
/azp run |
|
Azure Pipelines: Successfully started running 6 pipeline(s). |
2 tasks done
Scot Murphy (scoizzle)
added a commit
to scoizzle/data-api-builder
that referenced
this pull request
Nov 20, 2026
* Fix NuGet audit failures blocking CI restore (#3870)
## Why make this change?
- Closes #3871
- New NuGet advisories for System.Security.Cryptography.Pkcs,
MessagePack and Microsoft.OpenApi.Readers make the implicit restore in
the Unit Tests pipeline's "Check formatting" step fail with 22 audit
errors, blocking every PR to `main`.
- Related: draft #3867 (overlapping version bumps).
## What is this change?
- `Directory.Packages.props`: pin `System.Security.Cryptography.Pkcs`
9.0.21, bump `MessagePack` 2.5.301 -> 2.5.307, and bump
`Microsoft.OpenApi` and `Microsoft.OpenApi.Readers` 1.6.14 -> 1.6.31
together.
- Pkcs is only a transitive dependency, and central package management
does not pin transitive versions without a reference. It is referenced
from `Config` and `Core`, where `Microsoft.Data.SqlClient` enters the
graph (`Core` also so the packed library declares it), and from
`Aspire.AppHost`, whose restore graph does not include its project
references.
- No audit warnings are suppressed.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
Locally with the CI SDK (10.0.402) and real NuGet vulnerability data:
replaying CI's restore and `dotnet format --verify-no-changes`
reproduces the 22 errors on `main` and passes on this branch (0 audit
errors, 0 of 791 files changed). Full solution Release and Debug builds,
including Aspire.AppHost, have 0 warnings; the Release pack succeeds;
the CI unit test filter passes (Service.Tests 3254/3254, Cli.Tests 629
passed, 3 ignored in source).
## Sample Request(s)
- N/A (package versions only).
* Fix: Surface SQL Server runtime errors hidden by HasRows instead of returning empty 200 (#3859) (#3864)
## Why make this change?
- Closes #3859
- When SQL Server raises a runtime error while a query is being read
(for example a divide by zero in a view, or a row-level-security
predicate that throws), DAB returned an empty result with HTTP 200 on
REST and GraphQL. Nothing was logged, so clients could not tell a failed
query from a query that matched no rows.
## What is this change?
- `QueryExecutor.GetJsonResultAsync` only read the `DbDataReader` when
`HasRows` was true. For a query that fails, SqlClient reports `HasRows
== false` and raises the error only when the reader is read. DAB skipped
the read, so the error was dropped.
- The `HasRows` check is removed, and the method always reads through
the existing `ReadAsync` loop. A genuinely empty result still produces
an empty string, then null, then an empty list, as before. Errors now go
through the existing `ReadAsync` handling, which logs and converts them
to `DatabaseOperationFailed`.
- Error messages are unchanged: the raw database message appears only in
development mode.
- The method is shared by the PostgreSQL, MySQL and DWSQL executors. I
only ran the MSSQL tests locally; CI should cover the others.
### How was this tested?
- [x] Integration Tests
- [x] Unit Tests
**Unit test**:
`SqlQueryExecutorUnitTests.TestGetJsonResultAsyncSurfacesErrorHiddenByHasRows`
Uses a mocked data reader to cover two cases:
1. The reader reports no rows, but reading it throws a database error.
The error is returned as a 500 `DataApiBuilderException`
(`DatabaseOperationFailed`) instead of an empty result.
2. The reader reports no rows and reading it succeeds. The result is
still `null` (genuinely empty), so empty tables behave as before.
**Integration tests (SQL Server)**: use a table with a computed column
`100 / divisor` and one row where `divisor = 0`, plus an empty table.
- `MsSqlMidStreamErrorTests` (REST and GraphQL): REST (with and without
`$first`) and GraphQL return an error; the empty table still returns
`[]`.
- `ReadRecordsToolMidStreamErrorMsSqlTests` (MCP): `read_records` (with
and without `first`) returns an error result; the empty table still
returns an empty list.
Without the fix, the error tests return an empty success response. With
the fix, they return the database error.
## Sample Request(s)
Using the table and view from the issue:
- `GET /api/ItemRatio`
- Before: `{"value":[]}`, HTTP 200
- After: HTTP 500, `DatabaseOperationFailed`
- `GET /api/ItemRatio?$first=2`: same as above
- GraphQL `{ itemRatios { items { id ratio } } }`
- Before: `{"data":{"itemRatios":{"items":[]}}}`
- After: an `errors` entry with `DatabaseOperationFailed`
- `GET /api/Empty` (a table with no rows): still `{"value":[]}`, HTTP
200
* Throw Error for Empty Database Policies (#3865)
## Why make this change?
-
https://msdata.visualstudio.com/Database%20Systems/_workitems/edit/5597851
## What is this change?
Checks that the database policy didn't compile to an empty predicate, in
case that it does it will send a log warning message in development mode
or throw an error in production mode.
Created the new `AuditDatabasePolicyFailOpen` function to create the log
message and throw an error in case DAB is in production mode.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
Added tests to ensure that an empty policy will return the expected log
message and throw an error only if it is in production mode.
## Sample Request(s)
<img width="413" height="178" alt="image"
src="https://github.com/user-attachments/assets/b6562d40-3aad-4149-8965-8b45e6fe8741"
/>
<img width="1786" height="67" alt="image"
src="https://github.com/user-attachments/assets/7142a769-fdec-47f3-9979-9544cc57e39f"
/>
* Bump dotnet-sdk from 10.0.302 to 10.0.402 (#3872)
Bumps [dotnet-sdk](https://github.com/dotnet/sdk) from 10.0.302 to
10.0.402.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/dotnet/sdk/releases">dotnet-sdk's
releases</a>.</em></p>
<blockquote>
<h2>.NET 10.0.13</h2>
<p><a
href="https://github.com/dotnet/core/releases/tag/v10.0.13">Release</a></p>
<h2>What's Changed</h2>
<ul>
<li>Fix internal feed auth in unofficial CI pipeline by <a
href="https://github.com/marcpopMSFT"><code>@marcpopMSFT</code></a> in
<a
href="https://redirect.github.com/dotnet/sdk/pull/54362">dotnet/sdk#54362</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54364">dotnet/sdk#54364</a></li>
<li>[release/8.0.4xx] Fix internal feed auth in unofficial CI pipeline
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54363">dotnet/sdk#54363</a></li>
<li>Update branding to 8.0.129 by <a
href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54561">dotnet/sdk#54561</a></li>
<li>Update branding to 8.0.423 by <a
href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54562">dotnet/sdk#54562</a></li>
<li>[release/8.0.1xx] Update dependencies from dotnet/roslyn-analyzers
by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54421">dotnet/sdk#54421</a></li>
<li>[release/8.0.4xx] Update dependencies from
dotnet/source-build-externals by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54549">dotnet/sdk#54549</a></li>
<li>[release/8.0.4xx] Update dependencies from dotnet/arcade by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54480">dotnet/sdk#54480</a></li>
<li>[release/8.0.1xx] Update dependencies from dotnet/arcade by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54479">dotnet/sdk#54479</a></li>
<li>[release/8.0.1xx] Update dependencies from
dotnet/source-build-externals by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54531">dotnet/sdk#54531</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54568">dotnet/sdk#54568</a></li>
<li>[release/8.0.1xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54571">dotnet/sdk#54571</a></li>
<li>[release/8.0.1xx] Update dependencies from
dotnet/source-build-assets by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54548">dotnet/sdk#54548</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54572">dotnet/sdk#54572</a></li>
<li>[release/8.0.4xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54588">dotnet/sdk#54588</a></li>
<li>[release/9.0.1xx] Update dependencies from
dotnet/source-build-assets by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54406">dotnet/sdk#54406</a></li>
<li>[release/9.0.1xx] Update dependencies from dotnet/scenario-tests by
<a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54465">dotnet/sdk#54465</a></li>
<li>[release/9.0.1xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54569">dotnet/sdk#54569</a></li>
<li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54381">dotnet/sdk#54381</a></li>
<li>Merging internal commits for release/9.0.1xx by <a
href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54665">dotnet/sdk#54665</a></li>
<li>Merging internal commits for release/8.0.4xx by <a
href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54666">dotnet/sdk#54666</a></li>
<li>[release/9.0.1xx] Do not synchronize docx from the AAD submodule by
<a href="https://github.com/premun"><code>@premun</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/54678">dotnet/sdk#54678</a></li>
<li>[release/8.0.4xx] Update dependencies from dotnet/format by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54697">dotnet/sdk#54697</a></li>
<li>Merging internal commits for release/8.0.1xx by <a
href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54667">dotnet/sdk#54667</a></li>
<li>.NET Source-Build 9.0.118 June 2026 Updates by <a
href="https://github.com/dotnet-sb-bot"><code>@dotnet-sb-bot</code></a>
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54670">dotnet/sdk#54670</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54721">dotnet/sdk#54721</a></li>
<li>Avoid possible test timeout due to very verbose output by <a
href="https://github.com/dsplaisted"><code>@dsplaisted</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/54642">dotnet/sdk#54642</a></li>
<li>[release/9.0.1xx] Update dependencies from
dotnet/source-build-assets by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54674">dotnet/sdk#54674</a></li>
<li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54671">dotnet/sdk#54671</a></li>
<li>Use truncating logger by default for all tests by <a
href="https://github.com/dsplaisted"><code>@dsplaisted</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/54795">dotnet/sdk#54795</a></li>
<li>[release/8.0.4xx] Update branding to 8.0.424 by <a
href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/55149">dotnet/sdk#55149</a></li>
<li>[release/8.0.1xx] Update branding to 8.0.130 by <a
href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/55150">dotnet/sdk#55150</a></li>
<li>[release/9.0.1xx] Update branding to 9.0.120 by <a
href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/55152">dotnet/sdk#55152</a></li>
<li>[release/9.0.3xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54570">dotnet/sdk#54570</a></li>
<li>[automated] Merge branch 'release/9.0.1xx' => 'release/9.0.3xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54750">dotnet/sdk#54750</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/55168">dotnet/sdk#55168</a></li>
<li>Replace ubuntu22 VM and Helix images with Azure Linux 3 by <a
href="https://github.com/marcpopMSFT"><code>@marcpopMSFT</code></a> in
<a
href="https://redirect.github.com/dotnet/sdk/pull/53792">dotnet/sdk#53792</a></li>
<li>[release/9.0.3xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/55210">dotnet/sdk#55210</a></li>
<li>Work around license scan timeout by scanning source-build-assets
serially by <a
href="https://github.com/mthalman"><code>@mthalman</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/55219">dotnet/sdk#55219</a></li>
<li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/55158">dotnet/sdk#55158</a></li>
<li>[release/9.0.1xx] Update dependencies from dotnet/arcade by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54054">dotnet/sdk#54054</a></li>
<li>Fix VMR sync: update aspire remote name by <a
href="https://github.com/mthalman"><code>@mthalman</code></a> in <a
href="https://redirect.github.com/dotnet/sdk/pull/55234">dotnet/sdk#55234</a></li>
<li>[release/9.0.1xx] Update dependencies from
dotnet/source-build-assets by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54911">dotnet/sdk#54911</a></li>
<li>[release/8.0.1xx] Update dependencies from dotnet/templating by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/55183">dotnet/sdk#55183</a></li>
<li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx'
by <a
href="https://github.com/github-actions"><code>@github-actions</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/55207">dotnet/sdk#55207</a></li>
<li>[release/9.0.3xx] Update dependencies from dotnet/msbuild by <a
href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot]
in <a
href="https://redirect.github.com/dotnet/sdk/pull/54912">dotnet/sdk#54912</a></li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="https://github.com/dotnet/sdk/commit/d037e5f857b35e7260f575ae026ef30511776c0f"><code>d037e5f</code></a>
[release/10.0.4xx] Decode captured test output as UTF-8 (<a
href="https://redirect.github.com/dotnet/sdk/issues/56181">#56181</a>)</li>
<li><a
href="https://github.com/dotnet/sdk/commit/a8c0e609ea1ac8d3ef1877adedbecba457211d36"><code>a8c0e60</code></a>
[release/10.0.4xx] Add new NuGet cert hash (<a
href="https://redirect.github.com/dotnet/sdk/issues/56262">#56262</a>)</li>
<li><a
href="https://github.com/dotnet/sdk/commit/22d65a8151eb822b1782aedd949339eac5e63ba0"><code>22d65a8</code></a>
Merge branch 'release/10.0.4xx' into
backport-utf8-test-output-release-10.0.4xx</li>
<li><a
href="https://github.com/dotnet/sdk/commit/aadbc13abbcf165e4239c56a5baf1b734938e0e3"><code>aadbc13</code></a>
Merge branch 'release/10.0.4xx' into
backport/pr-56242-to-release/10.0.4xx</li>
<li><a
href="https://github.com/dotnet/sdk/commit/f7f4499ad13792b473ac0c70d2ab3bff118ff799"><code>f7f4499</code></a>
[release/10.0.4xx] Restore generated assets in
Microsoft.CodeAnalysis.NetAnal...</li>
<li><a
href="https://github.com/dotnet/sdk/commit/700cf0cfed2dfda8d40f85bfe096b09f16f1f451"><code>700cf0c</code></a>
[release/10.0.4xx] Source code updates from dotnet/dotnet (<a
href="https://redirect.github.com/dotnet/sdk/issues/56324">#56324</a>)</li>
<li><a
href="https://github.com/dotnet/sdk/commit/e1f83298a64db2f4966efd9838e09f8c39ad73d8"><code>e1f8329</code></a>
Update dependencies from build 332297</li>
<li><a
href="https://github.com/dotnet/sdk/commit/002ac71bfdf0d553405fa25beea757687d8fa986"><code>002ac71</code></a>
[release/10.0.4xx] Source code updates from dotnet/dotnet (<a
href="https://redirect.github.com/dotnet/sdk/issues/56293">#56293</a>)</li>
<li><a
href="https://github.com/dotnet/sdk/commit/e62be12ba59b6592c58f83d6d0ea294f0e546746"><code>e62be12</code></a>
Merge branch 'release/10.0.4xx' into
backport-utf8-test-output-release-10.0.4xx</li>
<li><a
href="https://github.com/dotnet/sdk/commit/be62162fdf1ee09b38e0944f6f1bbcb4047545c5"><code>be62162</code></a>
Use established NetAnalyzers pack hook</li>
<li>Additional commits viewable in <a
href="https://github.com/dotnet/sdk/compare/v10.0.302...v10.0.402">compare
view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
</details>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Mohit G <97188780+gmohit21@users.noreply.github.com>
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
* Upgrade failing packages (#3892)
## Why make this change?
- Fixes issue #3891
## What is this change?
Upgrades the package version of `MySqlConnector` as the current version
we were using has a vulnerability issue.
## How was this tested?
- [ ] Integration Tests
- [ ] Unit Tests
Pipeline passing is enough to show the issue is fixed.
## Sample Request(s)
N/A
* This is important: Updating default image configuration (#3900)
This pull request makes a small configuration change to the
`dab-config.json` file. The change adds an `allowed-hosts` setting to
the `mcp` service configuration, allowing all hosts to access it.
*
[`src/Service/dab-config.json`](diffhunk://#diff-1419093a1971fc58ad92a1d189020545ab9ac30f7a2143c5c74acf6b9bde266dL23-R24):
Added `"allowed-hosts": ["*"]` to the `mcp` service configuration to
permit access from any host.
## Why this change?
The new allow list defaults to empty. This invalidates the default
configuration in our image for development purposes. This configuration
must be updated to default to `[*]` in order to support testing
scenarios. Right now, this use case is broken with this new feature. The
default configuration in the image is **important** and only for
development and testing purposes, and needs to be reenabled as quickly
as possible.
* Enable secretless OBO authentication in DAB using Workload Identity Federation (#3880)
## Why make this change?
Related to #3641.
Existing Azure SQL On-Behalf-Of (OBO) authentication requires an
application client secret. This change adds a secretless alternative
using managed identity federation, reducing secret-management overhead
while preserving the caller's delegated SQL identity and existing
client-secret configurations.
## What is this change?
- Add `DAB_OBO_MANAGED_IDENTITY_CLIENT_ID` to select a user-assigned
managed identity as the OBO application credential.
- Introduce `OboCredentialFactory`, which acquires a managed-identity
token for `api://AzureADTokenExchange/.default` and supplies it through
MSAL's asynchronous client-assertion callback. The caller's access token
remains the separate OBO user assertion.
- Share credential validation between startup and runtime configuration
validation. When OBO is enabled, require the API application/tenant IDs
and exactly one credential method: client secret or managed identity
federation.
- Reuse the credential and confidential client, support fresh assertion
acquisition, preserve cancellation, and sanitize managed-identity
acquisition errors without credential fallback.
- Add credential-factory, configuration and startup tests, together with
federation configuration and troubleshooting documentation.
The federation option uses a same-tenant user-assigned managed identity
on Azure public cloud, with a federated identity credential configured
on the API app registration. Existing client-secret deployments remain
supported. No new JSON configuration properties or CLI flags are
introduced, and the existing SQL permissions/RLS model is unchanged.
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
**Manual Azure integration validation**
- Deployed the feature build to Azure App Service backed by Azure SQL
using a Visual Studio subscription, and verified the deployed binaries
against the feature build.
- Configured and exercised managed-identity federation without an
application client secret.
- Completed real browser testing with two separate users. Each user
could retrieve their own salary data, while SQL RLS prevented access to
the other user's data.
**Local automated validation**
The focused unit/regression suite passed **142 tests**, with **0
failures and 0 skipped tests**. Coverage includes credential selection,
missing/conflicting configuration, separate application and user
assertions, assertion reacquisition, cancellation, sanitized failures,
startup registration and existing OBO regressions.
The full solution build passed with **0 warnings and 0 errors**.
Commands executed from the repository root:
```powershell
# PASSED: 0 warnings, 0 errors.
dotnet build .\src\Azure.DataApiBuilder.sln --no-restore --verbosity
minimal
# PASSED: 142 tests; 0 failed; 0 skipped.
dotnet test
.\src\Service.Tests\Azure.DataApiBuilder.Service.Tests.csproj
--no-restore --filter
"FullyQualifiedName~OboCredentialFactoryTests|FullyQualifiedName~OboSqlTokenProviderUnitTests|(FullyQualifiedName~ConfigValidationUnitTests&FullyQualifiedName~UserDelegatedAuth)|FullyQualifiedName~StartupTests.RegisterOboServices|FullyQualifiedName~SqlQueryExecutorUnitTests.SetManagedIdentityAccessToken_Obo"
--logger "console;verbosity=minimal"
```
## Sample Request(s)
On an Azure host with the user-assigned managed identity attached,
federated trust configured, and the existing OBO configuration and SQL
permissions in place:
```powershell
$env:DAB_OBO_CLIENT_ID = "<api-app-client-id>"
$env:DAB_OBO_TENANT_ID = "<tenant-id>"
$env:DAB_OBO_MANAGED_IDENTITY_CLIENT_ID =
"<user-assigned-managed-identity-client-id>"
Remove-Item Env:\DAB_OBO_CLIENT_SECRET -ErrorAction SilentlyContinue
dab start
```
The API request contract is unchanged. For an existing configured
`Salary` entity:
```http
GET /api/Salary
```
Authenticate the request using the caller's DAB-audience access token
with bearer authentication. Federation changes how DAB authenticates its
application identity during the OBO exchange; SQL access continues to
use the delegated user's identity and permissions.
* Fix protected-field leaks in SQL pagination cursors (#3898)
## Why make this change?
SQL pagination cursors can expose excluded primary-key values as Base64
JSON, bypassing field-level read permissions across REST, GraphQL, and
MCP.
## What is this change?
- Check read permissions for every cursor field, including
implicit/composite keys and sort fields.
- Reject unauthorized cursor generation; MCP returns `PermissionDenied`.
- Preserve reads without cursors and pagination using readable fields
omitted only from the projection.
- Add regression tests and document the behavior change. Cursor encoding
is unchanged.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
**Passed:** 105 focused tests and affected-project builds on the new
main-based branch:
```powershell
dotnet test src\Service.Tests\Azure.DataApiBuilder.Service.Tests.csproj --no-restore -p:BaseOutputPath=C:\Users\sogh\.copilot\session-state\8f3619d8-cd04-4773-ab2d-a3a849d89683\files\cursor-validation\ --filter "FullyQualifiedName~SqlPaginationUtilUnitTests|FullyQualifiedName~SqlResponseHelpersUnitTests|FullyQualifiedName~SqlQueryStructureHelperTests|FullyQualifiedName~RestServiceUnitTests|FullyQualifiedName~MultiSourceQueryExecutionUnitTests" --verbosity minimal
```
**Passed:** Formatting verification for modified C# files before
committing:
```powershell
$changedCs = @(git --no-pager diff --name-only -- '*.cs')
dotnet format whitespace src\Azure.DataApiBuilder.sln --no-restore --include $changedCs --verify-no-changes --verbosity quiet
```
**Not run:** Database integration tests, the full suite, or
hosted-service reproduction.
## Sample Request(s)
```http
GET /api/PublicRecords?$first=1&$select=PublicLabel
```
If pagination requires an excluded `OwnerToken` key, return an
authorization error instead of a cursor exposing its value. Equivalent
checks apply to MCP `read_records` and GraphQL `endCursor`.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* Update HotChocolate packages to 16.7.3 (#3902)
## Why make this change?
Harden against vulnerabilities we've recently fixed and released
[advisories](https://github.com/ChilliCream/graphql-platform/security/advisories)
for.
## What is this change?
Updates HotChocolate packages to 16.7.3
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
* Bump dotnet-sdk from 10.0.402 to 10.0.403 (#3886)
Bumps [dotnet-sdk](https://github.com/dotnet/sdk) from 10.0.402 to
10.0.403.
<details>
<summary>Commits</summary>
<ul>
<li>See full diff in <a
href="https://github.com/dotnet/sdk/compare/v10.0.402...v10.0.403">compare
view</a></li>
</ul>
</details>
<br />
[](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)
Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.
[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)
---
<details>
<summary>Dependabot commands and options</summary>
<br />
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)
</details>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
* Update aspire packages (#3913)
## Why make this change?
- Solves issue #3915
## What is this change?
The current packages we use for `Aspire.Hosting` have vulnerabilities.
We updated to a new version that solves them.
## How was this tested?
- [ ] Integration Tests
- [ ] Unit Tests
Pipeline succeeding is proof that the version update works.
## Sample Request(s)
N/A
* Support XML data type for MSSQL (#3006)
## Why make this change?
SQL Server's `XML` data type (supported since SQL Server 2005) was not
recognized by DAB, preventing use of tables with XML columns.
## What is this change?
Treat `XML` as a string type, consistent with how SQL Server emits it
via `FOR JSON`:
- **SqlTypeConstants.cs**: Mark `xml` as supported (`true`)
- **TypeHelper.cs**: Map `SqlDbType.Xml` → `typeof(string)`
- **DatabaseSchema-MsSql.sql**: Add `xml_types` column to `type_table`
with test data for integration testing
- **MsSqlDbExceptionParser.cs**: Add `xml` parsing errors that come from
SQL
DAB passes XML as string in both directions; SQL Server handles
validation.
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
Existing `CLRtoJsonValueTypeUnitTests` now validates `(xml,True)` test
case passes. Added `xml_types xml` column to `type_table` in the MsSql
test database schema with various XML test data to enable integration
testing of XML data type operations.
Added tests to ensure all types of operations, work on the new `xml`
data type for REST, GraphQL, & MCP.
## Sample Request(s)
```http
POST /documents
Content-Type: application/json
{
"id": 1,
"metadata": "<author>admin</author>"
}
```
Response:
```json
{
"value": [
{
"id": 1,
"metadata": "<author>admin</author>"
}
]
}
```
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: JerryNixon <1749983+JerryNixon@users.noreply.github.com>
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
Co-authored-by: aaronburtle <93220300+aaronburtle@users.noreply.github.com>
Co-authored-by: Ruben Cerna <rcernaserna@microsoft.com>
* Populate OpenAPI description from MCP configuration (#3885)
## Why make this change?
Generated OpenAPI documents omitted `info.description` even when
`runtime.mcp.description` was configured. The document should use the
top-level description, including when multiple configuration files are
combined.
## What is this change?
- Set `OpenApiInfo.Description` from the resolved runtime MCP
description in `BuildOpenApiDocument`.
- Add unit coverage for the serialized OpenAPI description.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
## Sample Request(s)
Configure the server description:
```json
{
"runtime": {
"mcp": {
"description": "This server provides access to the company database."
}
}
}
```
The generated OpenAPI document includes:
```json
{
"info": {
"description": "This server provides access to the company database."
}
}
```
<!-- START COPILOT CODING AGENT SUFFIX -->
- Fixes #3702
---------
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
Co-authored-by: souvikghosh04 <210500244+souvikghosh04@users.noreply.github.com>
Co-authored-by: Mohit G <97188780+gmohit21@users.noreply.github.com>
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
Co-authored-by: Souvik Ghosh <souvikofficial04@gmail.com>
* Add General properties to Application Name Telemetry (#3826)
**Suggested title:** Add general settings to application-name telemetry
## Why make this change?
Closes https://github.com/Azure/data-api-builder/issues/3792.
The application-name telemetry format reserved a General section but was
initially empty. We populate it with the agreed host and data-source
characteristics to improve aggregate usage visibility without collecting
identifiers or secrets.
## What is this change?
Adds six positional fields using the existing shared encoder/decoder
design:
| Position | Field | Values |
|---|---|---|
| 1 | Operating system | Windows, Linux, macOS, Other, Unknown |
| 2 | Running in container | No, Yes, Missing |
| 3 | Hosting environment | Local, Azure, AWS, GCP, Other, Missing |
| 4 | Azure hosting service | Container Apps, AKS, App Service, ACI,
Other, Not Azure, Missing |
| 5 | Multiple parsed data sources | No, Yes, Missing |
| 6 | Managed identity | No, Yes, Missing |
The format remains:
`<marker><version>+<context>|<general>|<runtime>|<entity>+`
- **Preserves compatibility:** fills the reserved section without
shifting Runtime or Entity positions. Older empty-General tokens,
truncated tokens, hosted markers, and the existing opt-out remain
supported.
- **Uses offline, conservative detection:** reads OS APIs and known
runtime environment signals. `DAB_HOSTING_ENVIRONMENT` and
`DAB_AZURE_HOSTING_SERVICE` provide explicit overrides. Detection
performs no metadata requests or credential acquisition.
- **Reports MI per data source:** inspects the effective connection
string, including overrides. The CLI uses the default source. Ambiguous
credential chains and mixed OBO/metadata authentication report `M`;
`DefaultAzureCredential` availability is not treated as proof of MI use.
- **Protects connection behavior:** bounds the SQL telemetry suffix to
the available application-name budget while preserving the existing
custom name and OBO isolation prefix. PostgreSQL normalization remains
server-side.
- **Keeps CLI inspection offline:** recursively loads configurations
using existing property converters without resolving Key Vault secrets
or starting runtime watchers. Adds cycle/depth protection.
- Updates the existing design documentation and adds regression coverage
for detection, compatibility, authentication, privacy, and
provider-specific boundaries.
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
## Sample Request(s)
Inspect the telemetry for a configuration:
```console
dab appname --config dab-config.json
```
Decode an illustrative token:
```console
dab appname --decode "dab_oss_1.2.3+XXSX|L1AC01|MMMM00MMM00MMMMMMMMM|MMM?MMMMMMMMM?+"
```
The General section, `L1AC01`, represents **Linux, running in a
container, Azure Container Apps, one data source, and explicitly
configured managed identity**.
* Add Engine Telemetry - Phase 1 (#3825)
## Why make this change?
Closes #3215
Add engine-owned telemetry for runtime context, configured capabilities,
lifecycle, and aggregate usage across REST, GraphQL, and MCP without
relying on customer diagnostic pipelines. This establishes a
**default-off, synthetic-validation implementation**, not production
collection.
Set these variables **before starting DAB** in a dedicated process using
synthetic test data.
| Environment variable | Value | Purpose |
|---|---|---|
| `DAB_PRODUCT_TELEMETRY_TEST_MODE` | `1` or `true` | Explicitly enables
synthetic telemetry validation. |
| `DAB_PRODUCT_TELEMETRY_CONNECTION_STRING` | Full connection string for
the selected test Application Insights resource | Selects the product
telemetry destination, independently of customer-configured
observability. A destination alone does not enable collection. |
| `APPLICATIONINSIGHTS_STATSBEAT_DISABLED` | `true` | Required for this
validation phase; disables the SDK's separate Microsoft health/usage
stream. |
| `APPLICATIONINSIGHTS_SDKSTATS_DISABLED` | `true` | Required for this
validation phase; disables SDK delivery-statistics collection and its
metadata detection. |
| `DAB_TELEMETRY_OPT_OUT` | Leave unset for collection; `1` or `true`
disables it | Optional override that takes precedence over all product
telemetry enablement. |
The two SDK statistics flags require literal `true` (case-insensitive,
without surrounding whitespace). They are process-wide settings; DAB
checks them but never changes them.
Test mode does not generate synthetic data or anonymize real traffic.
Use an isolated test workload and destination, and do not commit
connection strings.
## What is this change?
- Adds per-engine lifecycle events for startup, readiness, configuration
changes/rejections, first served/successful requests, heartbeats, and
shutdown.
- Captures immutable, categorical runtime context and configuration
snapshots, preserving configured versus effective settings and
configuration epochs across reloads.
- Measures requests, logical operations, SQL attempts/retries, per-layer
cache lookups, embeddings, HTTP outcomes, and request latency as
separate units.
- Integrates protocol-aware completion for REST, GraphQL, MCP HTTP/SSE,
and MCP stdio. GraphQL eligibility respects conditional selections and
individual variable-batch members; discovery and health traffic are
excluded.
- Adds random API identity with safe best-effort persistence and
explicit per-run fallback. No configuration hashes, request contents, or
customer-defined names are collected.
- Aggregates usage into six-hour UTC windows with bounded counters,
explicit loss indicators, and bounded memory-only delivery. There is no
event disk spool or telemetry network wait in request processing.
- Uses `Azure.Monitor.OpenTelemetry.Exporter` 1.9.0 through a dedicated
custom-event pipeline, with explicit destination selection, payload
guards, and source-IP suppression. Updates compatible
Azure/OpenTelemetry dependencies.
- Adds the umbrella `DAB_TELEMETRY_OPT_OUT`, including suppression of
the DAB-added Application Name/version segment while preserving customer
content and legacy-switch behavior.
- Documents enablement, collected fields, identity reset, validation,
and known SDK limitations.
**Scope:** Collection remains off by default in every build. CLI command
telemetry, installation-profile identity, CLI-to-engine linkage, and
production activation remain separate work. Arbitrary
embedded/customer-exporter coexistence is not claimed.
Note: The Azure.Identity compatibility update replaces the obsolete
no-argument credential call with `new
ManagedIdentityCredential(ManagedIdentityId.SystemAssigned)` for Log
Analytics. This preserves the previous default system-assigned identity
selection.
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
## Sample Request(s)
For a dedicated synthetic fixture, configure these **before process
startup**:
- `DAB_PRODUCT_TELEMETRY_TEST_MODE=1`
- `DAB_PRODUCT_TELEMETRY_CONNECTION_STRING` pointing to the selected
test destination
- `APPLICATIONINSIGHTS_STATSBEAT_DISABLED=true`
- `APPLICATIONINSIGHTS_SDKSTATS_DISABLED=true`
Launch with `dab start`, or `dab start --mcp-stdio anonymous` for MCP
stdio. Setting `DAB_TELEMETRY_OPT_OUT=1` overrides enablement.
With a configured `Books` entity, `GET /api/Books` or this GraphQL query
exercises eligible data usage:
```graphql
{
books {
items { id title }
}
}
```
This query must **not** establish data usage or first-success telemetry
because its data selection is excluded:
```graphql
{
__typename
books @skip(if: true) {
items { id }
}
}
```
---------
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
* Add ASP.NET Core instrumentation to OpenTelemetry tracing (#3823)
## Why make this change?
- Closes #3559
- When OpenTelemetry is enabled, DAB exports no span for inbound REST,
GraphQL or MCP requests. The `TracerProvider` only registers
`HttpClientInstrumentation`, so the only exported spans are outbound
calls DAB makes itself (schema download, health self-checks). An
incoming `traceparent` is also not continued, which breaks distributed
traces going through DAB.
## What is this change?
- Registers `.AddAspNetCoreInstrumentation()` in the `WithTracing` block
of `Startup.cs`.
- The `OpenTelemetry.Instrumentation.AspNetCore` package (1.12.0) is
already referenced by `Azure.DataApiBuilder.Service.csproj` and
`Directory.Packages.props`, but it was never used. **No new dependency
and no version change.**
- ASP.NET Core already creates an activity for every request on the
`Microsoft.AspNetCore` activity source; without this call the
OpenTelemetry SDK does not subscribe to it, so those activities are
never sampled or exported.
- Existing DAB spans (`DABActivitySource`, e.g. `GET {entity}` / `QUERY
{entity}` in `RestController`) and HotChocolate spans now become
children of the server span, and the incoming W3C `traceparent` is
honored.
- SQL client spans (also mentioned in the issue) are intentionally left
out of this PR: `OpenTelemetry.Instrumentation.SqlClient` is not
available on the `data_api_builder_build_packages` feed, so adding it
would fail restore (`NU1301`) until a maintainer adds it to the feed.
Version `1.15.2` would be the compatible one (depends on
`OpenTelemetry.Api.ProviderBuilderExtensions >= 1.15.3`, matching the
current `OpenTelemetry.Exporter.OpenTelemetryProtocol` 1.15.3). Happy to
follow up in a separate PR.
## How was this tested?
- [x] Integration Tests
- Added
`OpenTelemetryTests.TestOpenTelemetryRecordsInboundHttpRequestSpan`. It
registers an `ActivityListener` on the `Microsoft.AspNetCore` source
that never samples by itself, sends a request to the `TestServer`, and
asserts that the server activity for that request path is `Recorded`.
The activity can only be recorded if the OpenTelemetry `TracerProvider`
subscribes to ASP.NET Core, so the test fails without the fix.
- [ ] Unit Tests
- Manual: the same one-line change applied on top of `v2.0.12`, running
against SQL Server with OTLP gRPC export to Grafana Alloy → Tempo.
Before: the OTEL SDK self-diagnostics log shows `Instrumentations added
= "HttpClientInstrumentation"` and no request spans. After: one `Server`
span per REST request is visible in Tempo.
## Sample Request(s)
With `runtime.telemetry.open-telemetry.enabled: true`:
```
GET http://localhost:5000/api/Book
```
now exports a `Server` span (`http.request.method=GET`,
`url.path=/api/Book`, `http.response.status_code=200`), with the
existing DAB spans for the request (`GET Book`, `QUERY Book`) nested
under it.
---------
Co-authored-by: clempiq <104780066+clementpiquin@users.noreply.github.com>
* Centralize `LogBuffer` Class to a Single Instance (#3914)
## Why make this change?
- Solves issue #3494
## What is this change?
It changes the `LogBuffer` class so that there only exists one instance
in all of DAB. This allows us to publish all the logs in the correct
sequence instead of only publishing the logs inside one class all at
once, which messed with the order of the logs.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
Edited current tests related to `LogBuffer` to ensure it applies to the
new one instance change.
Added new test to ensure that the sequence of the logs is in the correct
sequence.
## Sample Request(s)
N/A
* Add support for CLI Telemetry (#3857)
## Why make this change?
Closes https://github.com/Azure/data-api-builder/issues/3214
## What is this change?
Adds phase-1 CLI product telemetry, integrating and reusing the engine
telemetry foundation rather than introducing a separate collection or
delivery pipeline.
**Product telemetry remains off by default.** Collection is limited to
explicitly enabled synthetic validation with a configured test
destination. Production enablement remains outside this PR.
- Adds three CLI events:
- `dab/cli.first_run`: emitted only when a new installation identity is
successfully persisted.
- `dab/cli.command`: records command completion, outcome, failure
category, duration, and approved option-presence flags.
- `dab/cli.engine_launch`: records an actual preflight-approved engine
handoff, including web, MCP stdio, and export-helper launches.
- Adds a persistent per-user-profile installation identity and reuses
the existing API identity sidecar format. Explicit parent/child session
IDs correlate CLI launches with engine telemetry without combining their
lifetimes.
- Includes `database_type` and a bounded `configuration_context` on
command events so successes and failures can be analyzed without
requiring an API identity or a later engine launch. Configuration
breakdowns include endpoint enablement, entity-count buckets, cache,
authentication, MCP tools, relationships, and other applicable settings.
- Preserves configured/effective distinctions and explicit
missing/unknown states. Context comes from normally loaded or
successfully written configuration; failed writes retain the loaded
context. No additional configuration discovery or file reads are
introduced.
- Reuses the shared exporter, privacy safeguards, bounded memory-only
delivery, and opt-out policy. Raw arguments, configuration contents,
connection strings, customer names, and diagnostic messages are not
exported.
- Preserves command return codes, output, cancellation, and serving
behavior. Export telemetry distinguishes terminal failure from eventual
retry success without changing legacy exit codes.
- Includes integration fixes for atomic Linux identity publication,
unambiguous host-builder discovery, and MCP stdio readiness after
deferred metadata/tool initialization.
Host lifetime ownership is explicit: the web runner and stdio helper
each dispose their host exactly once; the outer bootstrap does not
dispose it again.
Customer-configured observability remains separate from product
telemetry.
## How was this tested?
- [x] Integration Tests
- [x] Unit Tests
## Sample Request(s)
Using an isolated database fixture, with synthetic telemetry explicitly
enabled according to the documented validation prerequisites:
```powershell
dab init --database-type mssql --connection-string "@env('MSSQL_CONNECTION_STRING')"
dab add Books --source dbo.Books --permissions "anonymous:read"
dab validate
dab start
```
Alternatively, launch MCP over stdio:
```powershell
dab start --mcp-stdio
```
Each invocation records one command-completion event. A
preflight-approved start additionally records an engine-launch event;
first-run is emitted only when installation identity is newly persisted.
Opt-out continues to suppress product telemetry:
```powershell
$env:DAB_TELEMETRY_OPT_OUT = "1"
dab validate
```
---------
Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com>
* Preserve inner exception when a mutation transaction fails (#3906)
## Why make this change?
When a mutation's `TransactionScope` fails, `SqlMutationEngine` catches
the `TransactionException` and rethrows one shared static
`DataApiBuilderException` ("An unexpected error occurred during the
transaction execution", 500, `UnexpectedError`). Two problems follow:
- **The cause is lost.** The `TransactionException`, and the database
error it carries, are dropped, so logs and any host-side error handling
cannot tell a database-side failure (for example a snapshot isolation
write-write conflict, SQL 24556/24706, which the database reports at
commit and asks the caller to retry) from a genuine service fault. Every
such failure looks like an unclassified 500.
- **A single exception instance is thrown from every request.** Throwing
the same object concurrently from different requests overwrites its
stack trace and `Data`, so even the outer frames in logs can belong to a
different request.
## What is this change?
- `SqlMutationEngine`: replace the static
`_dabExceptionWithTransactionErrorMessage` with
`CreateTransactionFailedException(TransactionException)`, which creates
a new `DataApiBuilderException` per failure with the caught exception as
`innerException`. All five `catch (TransactionException)` sites (GraphQL
mutation, stored procedure, REST delete, REST upsert, REST
insert/update) use it.
- The message, HTTP status code (500) and sub-status code
(`UnexpectedError`) returned to clients are unchanged. Only the
exception chain available to logging and host-side handling changes.
Mapping specific database errors (such as SQL 24556/24706) to a 409 or
retryable status through `DbExceptionParser` would be a natural
follow-up, but is out of scope here to keep this change behavior-neutral
for clients.
## How was this tested?
- [ ] Integration Tests
- [x] Unit Tests
New `SqlMutationEngineTransactionUnitTests`:
- the transaction exception and its inner database error are preserved,
with message, status and sub-status unchanged;
- each failure gets its own exception instance.
`dotnet test src/Service.Tests --filter
"FullyQualifiedName~SqlMutationEngineTransactionUnitTests|FullyQualifiedName~DbExceptionParserUnitTests"`:
16 passed.
## Sample Request(s)
No request or response change. Two concurrent GraphQL `update` mutations
that conflict at commit still return `An unexpected error occurred
during the transaction execution`. The server-side exception now carries
the `TransactionAbortedException` and the underlying database error as
inner exceptions.
Co-authored-by: Amritesh Singh <amritesingh@microsoft.com>
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
* Skip unsupported column data types during schema discovery (#3802)
## Why make this change?
- Closes [[Bug]: Table with a geometry column fails schema discovery
("GetFieldType returned null") even when fields.include excludes it
#3801](https://github.com/Azure/data-api-builder/issues/3801)
A table holding a `geometry` column cannot be exposed at all.
`FillSchemaForTableAsync` reads the
object shape with `SELECT *`, and `DbDataAdapter.FillSchema` needs a CLR
type for every column in
the projection. For a SQL Server CLR user-defined type the reader
reports no CLR type, so
`SchemaMapping` fails with `DataReader.GetFieldType(N) returned null`
and takes the whole object
down. DAB does not reference `Microsoft.SqlServer.Types`. The entity
never loads, and there is no
configuration-side workaround — excluding the column through permissions
does not help, because
discovery runs before authorization is consulted.
## What is this change?
Schema discovery leaves out columns whose data type the provider cannot
map to a CLR type, so the
rest of the object stays reachable.
`SqlMetadataProvider` gains a virtual `UnsupportedColumnDataTypes`,
empty by default. When it is
empty the projection stays `SELECT *`, so PostgreSQL, MySQL and Cosmos
are untouched.
`MsSqlMetadataProvider` overrides it with the three SQL Server CLR
user-defined types:
`geometry`, `geography`, `hierarchyid`.
When a provider declares such types, the projection is built from the
catalog and names the
remaining columns. Identifiers come from the catalog's own
`COLUMN_NAME`, so casing and quoting
match the database rather than the config. The catalog is read once per
object and shared with
column definition population, instead of being queried twice.
The projection reproduces the set of columns `SELECT *` exposes before
subtracting the
unsupported types. This matters because the catalog also reports columns
declared
`GENERATED ALWAYS AS ROW START/END HIDDEN`, which `SELECT *` does not
return: naming them would
widen the exposed contract rather than preserve it, and since the
read-only classification does
not recognize generated-always period columns, an overwriting PUT would
target them. They are
excluded through `sys.columns.is_hidden`, and they are not reported as
skipped — they were never
part of the object's shape as the engine sees it.
When — and only when — the projection is narrowed, the shape is read
with
`CommandBehavior.SchemaOnly` rather than through
`DbDataAdapter.FillSchema`. `FillSchema` runs
with `KeyInfo`, under which the provider performs its own key discovery
and returns key columns
absent from the `SELECT` list as hidden reader columns; an unsupported
type among them
reintroduces `DataReader.GetFieldType(N) returned null` even though the
projection excluded it.
That is reachable through the object's own primary key and through any
unique index, including
when a supported key is configured through `source.key-fields`. Without
`KeyInfo` the projection
is authoritative, and the primary key comes from the catalog instead.
When nothing is skipped,
`FillSchema` still runs with `KeyInfo` exactly as before, so ordinary
primary-key inference is
untouched for every object that works today.
The primary key comes from the object's own key when it has one. Absent
a primary key, the first
unique index whose every key column is non-nullable and readable is
used, in index order — which
is what the data adapter reports as `DataTable.PrimaryKey` on the
unnarrowed path, so the two
paths agree and the narrowed one does not start demanding
`source.key-fields` for an object the
other resolves on its own.
### Keys of a view
A view has no index of its own, so `sys.indexes` holds nothing for it
and the narrowed path has
no catalog key to fall back to. An earlier revision took the key from
`is_part_of_unique_key` in
`sys.dm_exec_describe_first_result_set`. That flag is wrong for this
purpose: it is a per-column
union across every unique key of the underlying object and cannot be
split back into one key. A
view exposing one column of a two-column key would have that single
column inferred as the key,
and a partial key silently matches more than one row on an update or a
delete.
Browse mode on the same procedure also reports `source_schema`,
`source_table` and
`source_column` for each column. The narrowed path resolves the
projection's source object from
those, requires a single source object — a projection over a join yields
nothing and the missing
primary key is reported exactly as before — reads that object's primary
key and non-nullable
unique candidates from the catalog it already caches, and accepts the
first key the projection
exposes in full.
Every row browse mode returns counts toward the single-source check, the
hidden ones included.
Browse mode reports the key columns of each participating object, so an
object whose every
selected column was dropped from the projection survives in hidden rows
alone: a view
`select a.id, a.name, b.geom from A a join B b on ...` narrows to `[id],
[name]`, and without
counting the hidden row for `B`'s key the result would read as a single
object and be keyed by
`A`'s primary key — which does not identify a row, because the join can
duplicate `A`'s rows.
Only a column the projection selects can carry a key, so the hidden rows
are excluded from the
key mapping itself.
A self-join gets past that check, because browse mode reports the
physical table and not the
alias, so both instances look like one object. What gives it away is a
source column reported
twice, since each instance contributes the key. Inference is declined
when one repeats. The rule
is conservative: a projection that selects a single column twice under
different names is
declined too, and simply needs `source.key-fields`, as it did before
this change.
When no key qualifies, the reason is returned rather than thrown, and
reported only if the object
ends up with no key at all. The schema read runs for every object while
the answer matters only
for one that is keyless, so an object whose `source.key-fields` is
configured must not be
rejected over a key it was told not to use — failing there would
recommend precisely what was
configured. When the object is keyless, the error names the key column
the projection leaves out,
which is more useful than the generic missing-primary-key one.
### Identity, unreadable keys, stale references
Identity columns are carried from `sys.columns.is_identity` rather than
through
`DataColumn.AutoIncrement`. That setter coerces a DataType it cannot
increment to `Int32`, and SQL
Server allows identity on `tinyint`, `numeric` and `decimal`, so using
it as the transport would
report the wrong `SystemType` and reach parameter typing and the
generated API schemas.
A primary key that cannot be read is rejected at initialization, with
the column and its data
type named. This covers a key configured over such a column, and the
object's own database key
when no key is configured — single column or one member of a composite
key. Omitting it would
leave the key in `SourceDefinition.PrimaryKey` while absent from
`SourceDefinition.Columns`, and
that inconsistency surfaces much later as a lookup failure. The generic
"primary key not
configured" error is not used for these, because it reads as something
the user forgot to
configure even though no configuration can express that key.
Configuration naming a column left out of the projection also fails
initialization. The exposed
and backing column maps are built from entity fields and mappings
without requiring the column to
exist in `SourceDefinition.Columns`, and the authorization resolver
accepts explicitly included
field names, so such a reference keeps resolving after the column is
gone and then fails per
request rather than at startup. `mappings`, `fields`, a permission's
`fields.include` and a
database policy are all rejected; `exclude` is left alone, since it asks
for what already
happened. The policy case matters for the same reason the
field-permission approach was withdrawn:
a policy is parsed per request against the OData model, which
`EdmModelBuilder` builds from
`SourceDefinition.Columns`, so one naming an absent column returns 400
on every request for that
role.
Policy field references are found by scanning the expression and
skipping single-quoted literals,
with `''` treated as an escaped quote, so a literal that happens to read
like a column name is
not mistaken for one. Aliases resolve through `fields` before
`mappings`, matching the precedence
`GenerateExposedToBackingColumnMapUtil` already applies.
A configured relationship's `source.fields` and `target.fields` are
rejected on the same grounds,
and `MultipleCreateOrderHelper` is the path that would otherwise fail
per request, since it
indexes `SourceDefinition.Columns` by each relationship field. That
check runs after every object
definition is populated rather than alongside the others, because a
relationship's
`target.fields` belong to the other entity's object, which may not have
been read yet. Foreign
keys inferred from the catalog and `linking.*` fields are deliberately
left alone: there is no
configuration to correct for an inferred key, so refusing to start would
punish the database's
shape rather than the configuration, and the relationship simply not
forming is the proportionate
outcome.
### Catalog access
The catalog facts that the `Columns` schema collection does not carry —
which columns the
database hides from `SELECT *`, and which columns form the object's
primary key — come from a new
provider hook, `GetObjectCatalogMetadataAsync`, which returns null in
the base class. Only
`MsSqlMetadataProvider` implements it, reading `sys.columns` joined to
`sys.indexes` /
`sys.index_columns`, cached once per object for the duration of
initialization. Providers that
declare no unsupported types never call it, and neither does an object
that holds none: the
classification runs first over the `Columns` schema collection, which is
read for every object
anyway, so only an object whose projection must be narrowed pays the
additional query. Both the
catalog read and the browse-mode describe are resolved before the
object's connection is opened,
so nothing nests a second connection inside an open scope.
If nothing unsupported is present, or the catalog cannot be read, or it
does not report a usable
type name, the projection falls back to `SELECT *` and behavior is
exactly what it is today. That
last case includes an engine without `sys.columns.is_hidden`, which
exists from SQL Server 2016
on, and a login without `VIEW DEFINITION`. When every column of an
object is unsupported it fails
with a clear initialization error instead, since falling back there
would re-issue the projection
that cannot be read.
Skipped columns are logged once per object at Warning level, naming each
column and its type, so
the omission is discoverable rather than silent.
### Deliberately limited to three types
`MsSqlQueryBuilder`'s autoentity discovery skips objects containing
`geography`, `geometry`,
`hierarchyid`, `sql_variant`, `xml`, `rowversion` or `vector`. That list
is intentionally not
reused here: `SqlTypeConstants.SupportedSqlDbTypes` marks `timestamp`
and `vector` as supported,
and there are dedicated `vector` tests, so excluding them would regress
shipped behavior. This
change is scoped to the CLR user-defined types, which are the ones whose
CLR type the provider
does not report.
### Why not honor `fields.include` instead
An earlier revision of this PR narrowed the projection to the columns
the permissions allow to be
read. I withdrew it: read permission and physical existence are
different things, and several
paths need a column to be in `SourceDefinition.Columns` without needing
it to be readable. A
database policy on an excluded column stops parsing against the EDM
model (`EdmModelBuilder`
iterates `Columns`) and returns 400 on every request in that role;
entities sharing a
`source.object` share one `SourceDefinition`, so a per-entity filter
cannot isolate anything;
multiple-create indexes `Columns` by relationship column name; REST PUT
stops nulling the hidden
columns. Skipping by type has none of that blast radius, because a
column the provider cannot
type was never usable in any of those paths.
## Compatibility impact
Skipping is provider-wide and driven by the column's data type alone, so
it does not consult
permissions: a `geometry`, `geography` or `hierarchyid` column is left
out even for a role that
grants unrestricted read, and `fields.include` / `fields.exclude` no
longer narrow discovery.
They are not ignored either — naming one of these columns in `fields`,
`mappings` or a
permission's `fields.include` now fails initialization, because the
reference cannot be honored
once the column is not part of the exposed contract.
That is a deliberate widening, and it takes nothing away in practice.
Those three types cannot be
read today at all — the object fails discovery and the entity never
loads, which is #3801. The
observable change is that such an entity now loads with the column
absent, instead of not
loading. No column that previously reached `SourceDefinition.Columns`
stops reaching it, so REST,
GraphQL, OpenAPI, MCP and database policies see exactly what they see
today for every object that
works today.
Objects that fail today now fail with a specific reason instead of the
provider's opaque error:
one whose configured or database primary key is of an unsupported type,
and one whose every
column is. Providers other than MSSQL and DWSQL declare no unsupported…
Scot Murphy (scoizzle)
added a commit
to scoizzle/data-api-builder
that referenced
this pull request
Nov 20, 2026
…mit") (#79) * Fix NuGet audit failures blocking CI restore (#3870) ## Why make this change? - Closes #3871 - New NuGet advisories for System.Security.Cryptography.Pkcs, MessagePack and Microsoft.OpenApi.Readers make the implicit restore in the Unit Tests pipeline's "Check formatting" step fail with 22 audit errors, blocking every PR to `main`. - Related: draft #3867 (overlapping version bumps). ## What is this change? - `Directory.Packages.props`: pin `System.Security.Cryptography.Pkcs` 9.0.21, bump `MessagePack` 2.5.301 -> 2.5.307, and bump `Microsoft.OpenApi` and `Microsoft.OpenApi.Readers` 1.6.14 -> 1.6.31 together. - Pkcs is only a transitive dependency, and central package management does not pin transitive versions without a reference. It is referenced from `Config` and `Core`, where `Microsoft.Data.SqlClient` enters the graph (`Core` also so the packed library declares it), and from `Aspire.AppHost`, whose restore graph does not include its project references. - No audit warnings are suppressed. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests Locally with the CI SDK (10.0.402) and real NuGet vulnerability data: replaying CI's restore and `dotnet format --verify-no-changes` reproduces the 22 errors on `main` and passes on this branch (0 audit errors, 0 of 791 files changed). Full solution Release and Debug builds, including Aspire.AppHost, have 0 warnings; the Release pack succeeds; the CI unit test filter passes (Service.Tests 3254/3254, Cli.Tests 629 passed, 3 ignored in source). ## Sample Request(s) - N/A (package versions only). * Fix: Surface SQL Server runtime errors hidden by HasRows instead of returning empty 200 (#3859) (#3864) ## Why make this change? - Closes #3859 - When SQL Server raises a runtime error while a query is being read (for example a divide by zero in a view, or a row-level-security predicate that throws), DAB returned an empty result with HTTP 200 on REST and GraphQL. Nothing was logged, so clients could not tell a failed query from a query that matched no rows. ## What is this change? - `QueryExecutor.GetJsonResultAsync` only read the `DbDataReader` when `HasRows` was true. For a query that fails, SqlClient reports `HasRows == false` and raises the error only when the reader is read. DAB skipped the read, so the error was dropped. - The `HasRows` check is removed, and the method always reads through the existing `ReadAsync` loop. A genuinely empty result still produces an empty string, then null, then an empty list, as before. Errors now go through the existing `ReadAsync` handling, which logs and converts them to `DatabaseOperationFailed`. - Error messages are unchanged: the raw database message appears only in development mode. - The method is shared by the PostgreSQL, MySQL and DWSQL executors. I only ran the MSSQL tests locally; CI should cover the others. ### How was this tested? - [x] Integration Tests - [x] Unit Tests **Unit test**: `SqlQueryExecutorUnitTests.TestGetJsonResultAsyncSurfacesErrorHiddenByHasRows` Uses a mocked data reader to cover two cases: 1. The reader reports no rows, but reading it throws a database error. The error is returned as a 500 `DataApiBuilderException` (`DatabaseOperationFailed`) instead of an empty result. 2. The reader reports no rows and reading it succeeds. The result is still `null` (genuinely empty), so empty tables behave as before. **Integration tests (SQL Server)**: use a table with a computed column `100 / divisor` and one row where `divisor = 0`, plus an empty table. - `MsSqlMidStreamErrorTests` (REST and GraphQL): REST (with and without `$first`) and GraphQL return an error; the empty table still returns `[]`. - `ReadRecordsToolMidStreamErrorMsSqlTests` (MCP): `read_records` (with and without `first`) returns an error result; the empty table still returns an empty list. Without the fix, the error tests return an empty success response. With the fix, they return the database error. ## Sample Request(s) Using the table and view from the issue: - `GET /api/ItemRatio` - Before: `{"value":[]}`, HTTP 200 - After: HTTP 500, `DatabaseOperationFailed` - `GET /api/ItemRatio?$first=2`: same as above - GraphQL `{ itemRatios { items { id ratio } } }` - Before: `{"data":{"itemRatios":{"items":[]}}}` - After: an `errors` entry with `DatabaseOperationFailed` - `GET /api/Empty` (a table with no rows): still `{"value":[]}`, HTTP 200 * Throw Error for Empty Database Policies (#3865) ## Why make this change? - https://msdata.visualstudio.com/Database%20Systems/_workitems/edit/5597851 ## What is this change? Checks that the database policy didn't compile to an empty predicate, in case that it does it will send a log warning message in development mode or throw an error in production mode. Created the new `AuditDatabasePolicyFailOpen` function to create the log message and throw an error in case DAB is in production mode. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests Added tests to ensure that an empty policy will return the expected log message and throw an error only if it is in production mode. ## Sample Request(s) <img width="413" height="178" alt="image" src="https://github.com/user-attachments/assets/b6562d40-3aad-4149-8965-8b45e6fe8741" /> <img width="1786" height="67" alt="image" src="https://github.com/user-attachments/assets/7142a769-fdec-47f3-9979-9544cc57e39f" /> * Bump dotnet-sdk from 10.0.302 to 10.0.402 (#3872) Bumps [dotnet-sdk](https://github.com/dotnet/sdk) from 10.0.302 to 10.0.402. <details> <summary>Release notes</summary> <p><em>Sourced from <a href="https://github.com/dotnet/sdk/releases">dotnet-sdk's releases</a>.</em></p> <blockquote> <h2>.NET 10.0.13</h2> <p><a href="https://github.com/dotnet/core/releases/tag/v10.0.13">Release</a></p> <h2>What's Changed</h2> <ul> <li>Fix internal feed auth in unofficial CI pipeline by <a href="https://github.com/marcpopMSFT"><code>@marcpopMSFT</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54362">dotnet/sdk#54362</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54364">dotnet/sdk#54364</a></li> <li>[release/8.0.4xx] Fix internal feed auth in unofficial CI pipeline by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54363">dotnet/sdk#54363</a></li> <li>Update branding to 8.0.129 by <a href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54561">dotnet/sdk#54561</a></li> <li>Update branding to 8.0.423 by <a href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54562">dotnet/sdk#54562</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/roslyn-analyzers by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54421">dotnet/sdk#54421</a></li> <li>[release/8.0.4xx] Update dependencies from dotnet/source-build-externals by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54549">dotnet/sdk#54549</a></li> <li>[release/8.0.4xx] Update dependencies from dotnet/arcade by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54480">dotnet/sdk#54480</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/arcade by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54479">dotnet/sdk#54479</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/source-build-externals by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54531">dotnet/sdk#54531</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54568">dotnet/sdk#54568</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54571">dotnet/sdk#54571</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/source-build-assets by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54548">dotnet/sdk#54548</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54572">dotnet/sdk#54572</a></li> <li>[release/8.0.4xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54588">dotnet/sdk#54588</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/source-build-assets by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54406">dotnet/sdk#54406</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/scenario-tests by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54465">dotnet/sdk#54465</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54569">dotnet/sdk#54569</a></li> <li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54381">dotnet/sdk#54381</a></li> <li>Merging internal commits for release/9.0.1xx by <a href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54665">dotnet/sdk#54665</a></li> <li>Merging internal commits for release/8.0.4xx by <a href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54666">dotnet/sdk#54666</a></li> <li>[release/9.0.1xx] Do not synchronize docx from the AAD submodule by <a href="https://github.com/premun"><code>@premun</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54678">dotnet/sdk#54678</a></li> <li>[release/8.0.4xx] Update dependencies from dotnet/format by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54697">dotnet/sdk#54697</a></li> <li>Merging internal commits for release/8.0.1xx by <a href="https://github.com/vseanreesermsft"><code>@vseanreesermsft</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54667">dotnet/sdk#54667</a></li> <li>.NET Source-Build 9.0.118 June 2026 Updates by <a href="https://github.com/dotnet-sb-bot"><code>@dotnet-sb-bot</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54670">dotnet/sdk#54670</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54721">dotnet/sdk#54721</a></li> <li>Avoid possible test timeout due to very verbose output by <a href="https://github.com/dsplaisted"><code>@dsplaisted</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54642">dotnet/sdk#54642</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/source-build-assets by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54674">dotnet/sdk#54674</a></li> <li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54671">dotnet/sdk#54671</a></li> <li>Use truncating logger by default for all tests by <a href="https://github.com/dsplaisted"><code>@dsplaisted</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/54795">dotnet/sdk#54795</a></li> <li>[release/8.0.4xx] Update branding to 8.0.424 by <a href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/55149">dotnet/sdk#55149</a></li> <li>[release/8.0.1xx] Update branding to 8.0.130 by <a href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/55150">dotnet/sdk#55150</a></li> <li>[release/9.0.1xx] Update branding to 9.0.120 by <a href="https://github.com/dotnet-bot"><code>@dotnet-bot</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/55152">dotnet/sdk#55152</a></li> <li>[release/9.0.3xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54570">dotnet/sdk#54570</a></li> <li>[automated] Merge branch 'release/9.0.1xx' => 'release/9.0.3xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54750">dotnet/sdk#54750</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/55168">dotnet/sdk#55168</a></li> <li>Replace ubuntu22 VM and Helix images with Azure Linux 3 by <a href="https://github.com/marcpopMSFT"><code>@marcpopMSFT</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/53792">dotnet/sdk#53792</a></li> <li>[release/9.0.3xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/55210">dotnet/sdk#55210</a></li> <li>Work around license scan timeout by scanning source-build-assets serially by <a href="https://github.com/mthalman"><code>@mthalman</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/55219">dotnet/sdk#55219</a></li> <li>[automated] Merge branch 'release/8.0.4xx' => 'release/9.0.1xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/55158">dotnet/sdk#55158</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/arcade by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54054">dotnet/sdk#54054</a></li> <li>Fix VMR sync: update aspire remote name by <a href="https://github.com/mthalman"><code>@mthalman</code></a> in <a href="https://redirect.github.com/dotnet/sdk/pull/55234">dotnet/sdk#55234</a></li> <li>[release/9.0.1xx] Update dependencies from dotnet/source-build-assets by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54911">dotnet/sdk#54911</a></li> <li>[release/8.0.1xx] Update dependencies from dotnet/templating by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/55183">dotnet/sdk#55183</a></li> <li>[automated] Merge branch 'release/8.0.1xx' => 'release/8.0.4xx' by <a href="https://github.com/github-actions"><code>@github-actions</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/55207">dotnet/sdk#55207</a></li> <li>[release/9.0.3xx] Update dependencies from dotnet/msbuild by <a href="https://github.com/dotnet-maestro"><code>@dotnet-maestro</code></a>[bot] in <a href="https://redirect.github.com/dotnet/sdk/pull/54912">dotnet/sdk#54912</a></li> </ul> <!-- raw HTML omitted --> </blockquote> <p>... (truncated)</p> </details> <details> <summary>Commits</summary> <ul> <li><a href="https://github.com/dotnet/sdk/commit/d037e5f857b35e7260f575ae026ef30511776c0f"><code>d037e5f</code></a> [release/10.0.4xx] Decode captured test output as UTF-8 (<a href="https://redirect.github.com/dotnet/sdk/issues/56181">#56181</a>)</li> <li><a href="https://github.com/dotnet/sdk/commit/a8c0e609ea1ac8d3ef1877adedbecba457211d36"><code>a8c0e60</code></a> [release/10.0.4xx] Add new NuGet cert hash (<a href="https://redirect.github.com/dotnet/sdk/issues/56262">#56262</a>)</li> <li><a href="https://github.com/dotnet/sdk/commit/22d65a8151eb822b1782aedd949339eac5e63ba0"><code>22d65a8</code></a> Merge branch 'release/10.0.4xx' into backport-utf8-test-output-release-10.0.4xx</li> <li><a href="https://github.com/dotnet/sdk/commit/aadbc13abbcf165e4239c56a5baf1b734938e0e3"><code>aadbc13</code></a> Merge branch 'release/10.0.4xx' into backport/pr-56242-to-release/10.0.4xx</li> <li><a href="https://github.com/dotnet/sdk/commit/f7f4499ad13792b473ac0c70d2ab3bff118ff799"><code>f7f4499</code></a> [release/10.0.4xx] Restore generated assets in Microsoft.CodeAnalysis.NetAnal...</li> <li><a href="https://github.com/dotnet/sdk/commit/700cf0cfed2dfda8d40f85bfe096b09f16f1f451"><code>700cf0c</code></a> [release/10.0.4xx] Source code updates from dotnet/dotnet (<a href="https://redirect.github.com/dotnet/sdk/issues/56324">#56324</a>)</li> <li><a href="https://github.com/dotnet/sdk/commit/e1f83298a64db2f4966efd9838e09f8c39ad73d8"><code>e1f8329</code></a> Update dependencies from build 332297</li> <li><a href="https://github.com/dotnet/sdk/commit/002ac71bfdf0d553405fa25beea757687d8fa986"><code>002ac71</code></a> [release/10.0.4xx] Source code updates from dotnet/dotnet (<a href="https://redirect.github.com/dotnet/sdk/issues/56293">#56293</a>)</li> <li><a href="https://github.com/dotnet/sdk/commit/e62be12ba59b6592c58f83d6d0ea294f0e546746"><code>e62be12</code></a> Merge branch 'release/10.0.4xx' into backport-utf8-test-output-release-10.0.4xx</li> <li><a href="https://github.com/dotnet/sdk/commit/be62162fdf1ee09b38e0944f6f1bbcb4047545c5"><code>be62162</code></a> Use established NetAnalyzers pack hook</li> <li>Additional commits viewable in <a href="https://github.com/dotnet/sdk/compare/v10.0.302...v10.0.402">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Mohit G <97188780+gmohit21@users.noreply.github.com> Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> * Upgrade failing packages (#3892) ## Why make this change? - Fixes issue #3891 ## What is this change? Upgrades the package version of `MySqlConnector` as the current version we were using has a vulnerability issue. ## How was this tested? - [ ] Integration Tests - [ ] Unit Tests Pipeline passing is enough to show the issue is fixed. ## Sample Request(s) N/A * This is important: Updating default image configuration (#3900) This pull request makes a small configuration change to the `dab-config.json` file. The change adds an `allowed-hosts` setting to the `mcp` service configuration, allowing all hosts to access it. * [`src/Service/dab-config.json`](diffhunk://#diff-1419093a1971fc58ad92a1d189020545ab9ac30f7a2143c5c74acf6b9bde266dL23-R24): Added `"allowed-hosts": ["*"]` to the `mcp` service configuration to permit access from any host. ## Why this change? The new allow list defaults to empty. This invalidates the default configuration in our image for development purposes. This configuration must be updated to default to `[*]` in order to support testing scenarios. Right now, this use case is broken with this new feature. The default configuration in the image is **important** and only for development and testing purposes, and needs to be reenabled as quickly as possible. * Enable secretless OBO authentication in DAB using Workload Identity Federation (#3880) ## Why make this change? Related to #3641. Existing Azure SQL On-Behalf-Of (OBO) authentication requires an application client secret. This change adds a secretless alternative using managed identity federation, reducing secret-management overhead while preserving the caller's delegated SQL identity and existing client-secret configurations. ## What is this change? - Add `DAB_OBO_MANAGED_IDENTITY_CLIENT_ID` to select a user-assigned managed identity as the OBO application credential. - Introduce `OboCredentialFactory`, which acquires a managed-identity token for `api://AzureADTokenExchange/.default` and supplies it through MSAL's asynchronous client-assertion callback. The caller's access token remains the separate OBO user assertion. - Share credential validation between startup and runtime configuration validation. When OBO is enabled, require the API application/tenant IDs and exactly one credential method: client secret or managed identity federation. - Reuse the credential and confidential client, support fresh assertion acquisition, preserve cancellation, and sanitize managed-identity acquisition errors without credential fallback. - Add credential-factory, configuration and startup tests, together with federation configuration and troubleshooting documentation. The federation option uses a same-tenant user-assigned managed identity on Azure public cloud, with a federated identity credential configured on the API app registration. Existing client-secret deployments remain supported. No new JSON configuration properties or CLI flags are introduced, and the existing SQL permissions/RLS model is unchanged. ## How was this tested? - [x] Integration Tests - [x] Unit Tests **Manual Azure integration validation** - Deployed the feature build to Azure App Service backed by Azure SQL using a Visual Studio subscription, and verified the deployed binaries against the feature build. - Configured and exercised managed-identity federation without an application client secret. - Completed real browser testing with two separate users. Each user could retrieve their own salary data, while SQL RLS prevented access to the other user's data. **Local automated validation** The focused unit/regression suite passed **142 tests**, with **0 failures and 0 skipped tests**. Coverage includes credential selection, missing/conflicting configuration, separate application and user assertions, assertion reacquisition, cancellation, sanitized failures, startup registration and existing OBO regressions. The full solution build passed with **0 warnings and 0 errors**. Commands executed from the repository root: ```powershell # PASSED: 0 warnings, 0 errors. dotnet build .\src\Azure.DataApiBuilder.sln --no-restore --verbosity minimal # PASSED: 142 tests; 0 failed; 0 skipped. dotnet test .\src\Service.Tests\Azure.DataApiBuilder.Service.Tests.csproj --no-restore --filter "FullyQualifiedName~OboCredentialFactoryTests|FullyQualifiedName~OboSqlTokenProviderUnitTests|(FullyQualifiedName~ConfigValidationUnitTests&FullyQualifiedName~UserDelegatedAuth)|FullyQualifiedName~StartupTests.RegisterOboServices|FullyQualifiedName~SqlQueryExecutorUnitTests.SetManagedIdentityAccessToken_Obo" --logger "console;verbosity=minimal" ``` ## Sample Request(s) On an Azure host with the user-assigned managed identity attached, federated trust configured, and the existing OBO configuration and SQL permissions in place: ```powershell $env:DAB_OBO_CLIENT_ID = "<api-app-client-id>" $env:DAB_OBO_TENANT_ID = "<tenant-id>" $env:DAB_OBO_MANAGED_IDENTITY_CLIENT_ID = "<user-assigned-managed-identity-client-id>" Remove-Item Env:\DAB_OBO_CLIENT_SECRET -ErrorAction SilentlyContinue dab start ``` The API request contract is unchanged. For an existing configured `Salary` entity: ```http GET /api/Salary ``` Authenticate the request using the caller's DAB-audience access token with bearer authentication. Federation changes how DAB authenticates its application identity during the OBO exchange; SQL access continues to use the delegated user's identity and permissions. * Fix protected-field leaks in SQL pagination cursors (#3898) ## Why make this change? SQL pagination cursors can expose excluded primary-key values as Base64 JSON, bypassing field-level read permissions across REST, GraphQL, and MCP. ## What is this change? - Check read permissions for every cursor field, including implicit/composite keys and sort fields. - Reject unauthorized cursor generation; MCP returns `PermissionDenied`. - Preserve reads without cursors and pagination using readable fields omitted only from the projection. - Add regression tests and document the behavior change. Cursor encoding is unchanged. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests **Passed:** 105 focused tests and affected-project builds on the new main-based branch: ```powershell dotnet test src\Service.Tests\Azure.DataApiBuilder.Service.Tests.csproj --no-restore -p:BaseOutputPath=C:\Users\sogh\.copilot\session-state\8f3619d8-cd04-4773-ab2d-a3a849d89683\files\cursor-validation\ --filter "FullyQualifiedName~SqlPaginationUtilUnitTests|FullyQualifiedName~SqlResponseHelpersUnitTests|FullyQualifiedName~SqlQueryStructureHelperTests|FullyQualifiedName~RestServiceUnitTests|FullyQualifiedName~MultiSourceQueryExecutionUnitTests" --verbosity minimal ``` **Passed:** Formatting verification for modified C# files before committing: ```powershell $changedCs = @(git --no-pager diff --name-only -- '*.cs') dotnet format whitespace src\Azure.DataApiBuilder.sln --no-restore --include $changedCs --verify-no-changes --verbosity quiet ``` **Not run:** Database integration tests, the full suite, or hosted-service reproduction. ## Sample Request(s) ```http GET /api/PublicRecords?$first=1&$select=PublicLabel ``` If pagination requires an excluded `OwnerToken` key, return an authorization error instead of a cursor exposing its value. Equivalent checks apply to MCP `read_records` and GraphQL `endCursor`. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> * Update HotChocolate packages to 16.7.3 (#3902) ## Why make this change? Harden against vulnerabilities we've recently fixed and released [advisories](https://github.com/ChilliCream/graphql-platform/security/advisories) for. ## What is this change? Updates HotChocolate packages to 16.7.3 ## How was this tested? - [x] Integration Tests - [x] Unit Tests * Bump dotnet-sdk from 10.0.402 to 10.0.403 (#3886) Bumps [dotnet-sdk](https://github.com/dotnet/sdk) from 10.0.402 to 10.0.403. <details> <summary>Commits</summary> <ul> <li>See full diff in <a href="https://github.com/dotnet/sdk/compare/v10.0.402...v10.0.403">compare view</a></li> </ul> </details> <br /> [](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores) Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting `@dependabot rebase`. [//]: # (dependabot-automerge-start) [//]: # (dependabot-automerge-end) --- <details> <summary>Dependabot commands and options</summary> <br /> You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot show <dependency name> ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) </details> Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> * Update aspire packages (#3913) ## Why make this change? - Solves issue #3915 ## What is this change? The current packages we use for `Aspire.Hosting` have vulnerabilities. We updated to a new version that solves them. ## How was this tested? - [ ] Integration Tests - [ ] Unit Tests Pipeline succeeding is proof that the version update works. ## Sample Request(s) N/A * Support XML data type for MSSQL (#3006) ## Why make this change? SQL Server's `XML` data type (supported since SQL Server 2005) was not recognized by DAB, preventing use of tables with XML columns. ## What is this change? Treat `XML` as a string type, consistent with how SQL Server emits it via `FOR JSON`: - **SqlTypeConstants.cs**: Mark `xml` as supported (`true`) - **TypeHelper.cs**: Map `SqlDbType.Xml` → `typeof(string)` - **DatabaseSchema-MsSql.sql**: Add `xml_types` column to `type_table` with test data for integration testing - **MsSqlDbExceptionParser.cs**: Add `xml` parsing errors that come from SQL DAB passes XML as string in both directions; SQL Server handles validation. ## How was this tested? - [x] Integration Tests - [x] Unit Tests Existing `CLRtoJsonValueTypeUnitTests` now validates `(xml,True)` test case passes. Added `xml_types xml` column to `type_table` in the MsSql test database schema with various XML test data to enable integration testing of XML data type operations. Added tests to ensure all types of operations, work on the new `xml` data type for REST, GraphQL, & MCP. ## Sample Request(s) ```http POST /documents Content-Type: application/json { "id": 1, "metadata": "<author>admin</author>" } ``` Response: ```json { "value": [ { "id": 1, "metadata": "<author>admin</author>" } ] } ``` --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: JerryNixon <1749983+JerryNixon@users.noreply.github.com> Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> Co-authored-by: aaronburtle <93220300+aaronburtle@users.noreply.github.com> Co-authored-by: Ruben Cerna <rcernaserna@microsoft.com> * Populate OpenAPI description from MCP configuration (#3885) ## Why make this change? Generated OpenAPI documents omitted `info.description` even when `runtime.mcp.description` was configured. The document should use the top-level description, including when multiple configuration files are combined. ## What is this change? - Set `OpenApiInfo.Description` from the resolved runtime MCP description in `BuildOpenApiDocument`. - Add unit coverage for the serialized OpenAPI description. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests ## Sample Request(s) Configure the server description: ```json { "runtime": { "mcp": { "description": "This server provides access to the company database." } } } ``` The generated OpenAPI document includes: ```json { "info": { "description": "This server provides access to the company database." } } ``` <!-- START COPILOT CODING AGENT SUFFIX --> - Fixes #3702 --------- Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: souvikghosh04 <210500244+souvikghosh04@users.noreply.github.com> Co-authored-by: Mohit G <97188780+gmohit21@users.noreply.github.com> Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> Co-authored-by: Souvik Ghosh <souvikofficial04@gmail.com> * Add General properties to Application Name Telemetry (#3826) **Suggested title:** Add general settings to application-name telemetry ## Why make this change? Closes https://github.com/Azure/data-api-builder/issues/3792. The application-name telemetry format reserved a General section but was initially empty. We populate it with the agreed host and data-source characteristics to improve aggregate usage visibility without collecting identifiers or secrets. ## What is this change? Adds six positional fields using the existing shared encoder/decoder design: | Position | Field | Values | |---|---|---| | 1 | Operating system | Windows, Linux, macOS, Other, Unknown | | 2 | Running in container | No, Yes, Missing | | 3 | Hosting environment | Local, Azure, AWS, GCP, Other, Missing | | 4 | Azure hosting service | Container Apps, AKS, App Service, ACI, Other, Not Azure, Missing | | 5 | Multiple parsed data sources | No, Yes, Missing | | 6 | Managed identity | No, Yes, Missing | The format remains: `<marker><version>+<context>|<general>|<runtime>|<entity>+` - **Preserves compatibility:** fills the reserved section without shifting Runtime or Entity positions. Older empty-General tokens, truncated tokens, hosted markers, and the existing opt-out remain supported. - **Uses offline, conservative detection:** reads OS APIs and known runtime environment signals. `DAB_HOSTING_ENVIRONMENT` and `DAB_AZURE_HOSTING_SERVICE` provide explicit overrides. Detection performs no metadata requests or credential acquisition. - **Reports MI per data source:** inspects the effective connection string, including overrides. The CLI uses the default source. Ambiguous credential chains and mixed OBO/metadata authentication report `M`; `DefaultAzureCredential` availability is not treated as proof of MI use. - **Protects connection behavior:** bounds the SQL telemetry suffix to the available application-name budget while preserving the existing custom name and OBO isolation prefix. PostgreSQL normalization remains server-side. - **Keeps CLI inspection offline:** recursively loads configurations using existing property converters without resolving Key Vault secrets or starting runtime watchers. Adds cycle/depth protection. - Updates the existing design documentation and adds regression coverage for detection, compatibility, authentication, privacy, and provider-specific boundaries. ## How was this tested? - [x] Integration Tests - [x] Unit Tests ## Sample Request(s) Inspect the telemetry for a configuration: ```console dab appname --config dab-config.json ``` Decode an illustrative token: ```console dab appname --decode "dab_oss_1.2.3+XXSX|L1AC01|MMMM00MMM00MMMMMMMMM|MMM?MMMMMMMMM?+" ``` The General section, `L1AC01`, represents **Linux, running in a container, Azure Container Apps, one data source, and explicitly configured managed identity**. * Add Engine Telemetry - Phase 1 (#3825) ## Why make this change? Closes #3215 Add engine-owned telemetry for runtime context, configured capabilities, lifecycle, and aggregate usage across REST, GraphQL, and MCP without relying on customer diagnostic pipelines. This establishes a **default-off, synthetic-validation implementation**, not production collection. Set these variables **before starting DAB** in a dedicated process using synthetic test data. | Environment variable | Value | Purpose | |---|---|---| | `DAB_PRODUCT_TELEMETRY_TEST_MODE` | `1` or `true` | Explicitly enables synthetic telemetry validation. | | `DAB_PRODUCT_TELEMETRY_CONNECTION_STRING` | Full connection string for the selected test Application Insights resource | Selects the product telemetry destination, independently of customer-configured observability. A destination alone does not enable collection. | | `APPLICATIONINSIGHTS_STATSBEAT_DISABLED` | `true` | Required for this validation phase; disables the SDK's separate Microsoft health/usage stream. | | `APPLICATIONINSIGHTS_SDKSTATS_DISABLED` | `true` | Required for this validation phase; disables SDK delivery-statistics collection and its metadata detection. | | `DAB_TELEMETRY_OPT_OUT` | Leave unset for collection; `1` or `true` disables it | Optional override that takes precedence over all product telemetry enablement. | The two SDK statistics flags require literal `true` (case-insensitive, without surrounding whitespace). They are process-wide settings; DAB checks them but never changes them. Test mode does not generate synthetic data or anonymize real traffic. Use an isolated test workload and destination, and do not commit connection strings. ## What is this change? - Adds per-engine lifecycle events for startup, readiness, configuration changes/rejections, first served/successful requests, heartbeats, and shutdown. - Captures immutable, categorical runtime context and configuration snapshots, preserving configured versus effective settings and configuration epochs across reloads. - Measures requests, logical operations, SQL attempts/retries, per-layer cache lookups, embeddings, HTTP outcomes, and request latency as separate units. - Integrates protocol-aware completion for REST, GraphQL, MCP HTTP/SSE, and MCP stdio. GraphQL eligibility respects conditional selections and individual variable-batch members; discovery and health traffic are excluded. - Adds random API identity with safe best-effort persistence and explicit per-run fallback. No configuration hashes, request contents, or customer-defined names are collected. - Aggregates usage into six-hour UTC windows with bounded counters, explicit loss indicators, and bounded memory-only delivery. There is no event disk spool or telemetry network wait in request processing. - Uses `Azure.Monitor.OpenTelemetry.Exporter` 1.9.0 through a dedicated custom-event pipeline, with explicit destination selection, payload guards, and source-IP suppression. Updates compatible Azure/OpenTelemetry dependencies. - Adds the umbrella `DAB_TELEMETRY_OPT_OUT`, including suppression of the DAB-added Application Name/version segment while preserving customer content and legacy-switch behavior. - Documents enablement, collected fields, identity reset, validation, and known SDK limitations. **Scope:** Collection remains off by default in every build. CLI command telemetry, installation-profile identity, CLI-to-engine linkage, and production activation remain separate work. Arbitrary embedded/customer-exporter coexistence is not claimed. Note: The Azure.Identity compatibility update replaces the obsolete no-argument credential call with `new ManagedIdentityCredential(ManagedIdentityId.SystemAssigned)` for Log Analytics. This preserves the previous default system-assigned identity selection. ## How was this tested? - [x] Integration Tests - [x] Unit Tests ## Sample Request(s) For a dedicated synthetic fixture, configure these **before process startup**: - `DAB_PRODUCT_TELEMETRY_TEST_MODE=1` - `DAB_PRODUCT_TELEMETRY_CONNECTION_STRING` pointing to the selected test destination - `APPLICATIONINSIGHTS_STATSBEAT_DISABLED=true` - `APPLICATIONINSIGHTS_SDKSTATS_DISABLED=true` Launch with `dab start`, or `dab start --mcp-stdio anonymous` for MCP stdio. Setting `DAB_TELEMETRY_OPT_OUT=1` overrides enablement. With a configured `Books` entity, `GET /api/Books` or this GraphQL query exercises eligible data usage: ```graphql { books { items { id title } } } ``` This query must **not** establish data usage or first-success telemetry because its data selection is excluded: ```graphql { __typename books @skip(if: true) { items { id } } } ``` --------- Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> * Add ASP.NET Core instrumentation to OpenTelemetry tracing (#3823) ## Why make this change? - Closes #3559 - When OpenTelemetry is enabled, DAB exports no span for inbound REST, GraphQL or MCP requests. The `TracerProvider` only registers `HttpClientInstrumentation`, so the only exported spans are outbound calls DAB makes itself (schema download, health self-checks). An incoming `traceparent` is also not continued, which breaks distributed traces going through DAB. ## What is this change? - Registers `.AddAspNetCoreInstrumentation()` in the `WithTracing` block of `Startup.cs`. - The `OpenTelemetry.Instrumentation.AspNetCore` package (1.12.0) is already referenced by `Azure.DataApiBuilder.Service.csproj` and `Directory.Packages.props`, but it was never used. **No new dependency and no version change.** - ASP.NET Core already creates an activity for every request on the `Microsoft.AspNetCore` activity source; without this call the OpenTelemetry SDK does not subscribe to it, so those activities are never sampled or exported. - Existing DAB spans (`DABActivitySource`, e.g. `GET {entity}` / `QUERY {entity}` in `RestController`) and HotChocolate spans now become children of the server span, and the incoming W3C `traceparent` is honored. - SQL client spans (also mentioned in the issue) are intentionally left out of this PR: `OpenTelemetry.Instrumentation.SqlClient` is not available on the `data_api_builder_build_packages` feed, so adding it would fail restore (`NU1301`) until a maintainer adds it to the feed. Version `1.15.2` would be the compatible one (depends on `OpenTelemetry.Api.ProviderBuilderExtensions >= 1.15.3`, matching the current `OpenTelemetry.Exporter.OpenTelemetryProtocol` 1.15.3). Happy to follow up in a separate PR. ## How was this tested? - [x] Integration Tests - Added `OpenTelemetryTests.TestOpenTelemetryRecordsInboundHttpRequestSpan`. It registers an `ActivityListener` on the `Microsoft.AspNetCore` source that never samples by itself, sends a request to the `TestServer`, and asserts that the server activity for that request path is `Recorded`. The activity can only be recorded if the OpenTelemetry `TracerProvider` subscribes to ASP.NET Core, so the test fails without the fix. - [ ] Unit Tests - Manual: the same one-line change applied on top of `v2.0.12`, running against SQL Server with OTLP gRPC export to Grafana Alloy → Tempo. Before: the OTEL SDK self-diagnostics log shows `Instrumentations added = "HttpClientInstrumentation"` and no request spans. After: one `Server` span per REST request is visible in Tempo. ## Sample Request(s) With `runtime.telemetry.open-telemetry.enabled: true`: ``` GET http://localhost:5000/api/Book ``` now exports a `Server` span (`http.request.method=GET`, `url.path=/api/Book`, `http.response.status_code=200`), with the existing DAB spans for the request (`GET Book`, `QUERY Book`) nested under it. --------- Co-authored-by: clempiq <104780066+clementpiquin@users.noreply.github.com> * Centralize `LogBuffer` Class to a Single Instance (#3914) ## Why make this change? - Solves issue #3494 ## What is this change? It changes the `LogBuffer` class so that there only exists one instance in all of DAB. This allows us to publish all the logs in the correct sequence instead of only publishing the logs inside one class all at once, which messed with the order of the logs. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests Edited current tests related to `LogBuffer` to ensure it applies to the new one instance change. Added new test to ensure that the sequence of the logs is in the correct sequence. ## Sample Request(s) N/A * Add support for CLI Telemetry (#3857) ## Why make this change? Closes https://github.com/Azure/data-api-builder/issues/3214 ## What is this change? Adds phase-1 CLI product telemetry, integrating and reusing the engine telemetry foundation rather than introducing a separate collection or delivery pipeline. **Product telemetry remains off by default.** Collection is limited to explicitly enabled synthetic validation with a configured test destination. Production enablement remains outside this PR. - Adds three CLI events: - `dab/cli.first_run`: emitted only when a new installation identity is successfully persisted. - `dab/cli.command`: records command completion, outcome, failure category, duration, and approved option-presence flags. - `dab/cli.engine_launch`: records an actual preflight-approved engine handoff, including web, MCP stdio, and export-helper launches. - Adds a persistent per-user-profile installation identity and reuses the existing API identity sidecar format. Explicit parent/child session IDs correlate CLI launches with engine telemetry without combining their lifetimes. - Includes `database_type` and a bounded `configuration_context` on command events so successes and failures can be analyzed without requiring an API identity or a later engine launch. Configuration breakdowns include endpoint enablement, entity-count buckets, cache, authentication, MCP tools, relationships, and other applicable settings. - Preserves configured/effective distinctions and explicit missing/unknown states. Context comes from normally loaded or successfully written configuration; failed writes retain the loaded context. No additional configuration discovery or file reads are introduced. - Reuses the shared exporter, privacy safeguards, bounded memory-only delivery, and opt-out policy. Raw arguments, configuration contents, connection strings, customer names, and diagnostic messages are not exported. - Preserves command return codes, output, cancellation, and serving behavior. Export telemetry distinguishes terminal failure from eventual retry success without changing legacy exit codes. - Includes integration fixes for atomic Linux identity publication, unambiguous host-builder discovery, and MCP stdio readiness after deferred metadata/tool initialization. Host lifetime ownership is explicit: the web runner and stdio helper each dispose their host exactly once; the outer bootstrap does not dispose it again. Customer-configured observability remains separate from product telemetry. ## How was this tested? - [x] Integration Tests - [x] Unit Tests ## Sample Request(s) Using an isolated database fixture, with synthetic telemetry explicitly enabled according to the documented validation prerequisites: ```powershell dab init --database-type mssql --connection-string "@env('MSSQL_CONNECTION_STRING')" dab add Books --source dbo.Books --permissions "anonymous:read" dab validate dab start ``` Alternatively, launch MCP over stdio: ```powershell dab start --mcp-stdio ``` Each invocation records one command-completion event. A preflight-approved start additionally records an engine-launch event; first-run is emitted only when installation identity is newly persisted. Opt-out continues to suppress product telemetry: ```powershell $env:DAB_TELEMETRY_OPT_OUT = "1" dab validate ``` --------- Co-authored-by: RubenCerna2079 <32799214+RubenCerna2079@users.noreply.github.com> * Preserve inner exception when a mutation transaction fails (#3906) ## Why make this change? When a mutation's `TransactionScope` fails, `SqlMutationEngine` catches the `TransactionException` and rethrows one shared static `DataApiBuilderException` ("An unexpected error occurred during the transaction execution", 500, `UnexpectedError`). Two problems follow: - **The cause is lost.** The `TransactionException`, and the database error it carries, are dropped, so logs and any host-side error handling cannot tell a database-side failure (for example a snapshot isolation write-write conflict, SQL 24556/24706, which the database reports at commit and asks the caller to retry) from a genuine service fault. Every such failure looks like an unclassified 500. - **A single exception instance is thrown from every request.** Throwing the same object concurrently from different requests overwrites its stack trace and `Data`, so even the outer frames in logs can belong to a different request. ## What is this change? - `SqlMutationEngine`: replace the static `_dabExceptionWithTransactionErrorMessage` with `CreateTransactionFailedException(TransactionException)`, which creates a new `DataApiBuilderException` per failure with the caught exception as `innerException`. All five `catch (TransactionException)` sites (GraphQL mutation, stored procedure, REST delete, REST upsert, REST insert/update) use it. - The message, HTTP status code (500) and sub-status code (`UnexpectedError`) returned to clients are unchanged. Only the exception chain available to logging and host-side handling changes. Mapping specific database errors (such as SQL 24556/24706) to a 409 or retryable status through `DbExceptionParser` would be a natural follow-up, but is out of scope here to keep this change behavior-neutral for clients. ## How was this tested? - [ ] Integration Tests - [x] Unit Tests New `SqlMutationEngineTransactionUnitTests`: - the transaction exception and its inner database error are preserved, with message, status and sub-status unchanged; - each failure gets its own exception instance. `dotnet test src/Service.Tests --filter "FullyQualifiedName~SqlMutationEngineTransactionUnitTests|FullyQualifiedName~DbExceptionParserUnitTests"`: 16 passed. ## Sample Request(s) No request or response change. Two concurrent GraphQL `update` mutations that conflict at commit still return `An unexpected error occurred during the transaction execution`. The server-side exception now carries the `TransactionAbortedException` and the underlying database error as inner exceptions. Co-authored-by: Amritesh Singh <amritesingh@microsoft.com> Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> * Skip unsupported column data types during schema discovery (#3802) ## Why make this change? - Closes [[Bug]: Table with a geometry column fails schema discovery ("GetFieldType returned null") even when fields.include excludes it #3801](https://github.com/Azure/data-api-builder/issues/3801) A table holding a `geometry` column cannot be exposed at all. `FillSchemaForTableAsync` reads the object shape with `SELECT *`, and `DbDataAdapter.FillSchema` needs a CLR type for every column in the projection. For a SQL Server CLR user-defined type the reader reports no CLR type, so `SchemaMapping` fails with `DataReader.GetFieldType(N) returned null` and takes the whole object down. DAB does not reference `Microsoft.SqlServer.Types`. The entity never loads, and there is no configuration-side workaround — excluding the column through permissions does not help, because discovery runs before authorization is consulted. ## What is this change? Schema discovery leaves out columns whose data type the provider cannot map to a CLR type, so the rest of the object stays reachable. `SqlMetadataProvider` gains a virtual `UnsupportedColumnDataTypes`, empty by default. When it is empty the projection stays `SELECT *`, so PostgreSQL, MySQL and Cosmos are untouched. `MsSqlMetadataProvider` overrides it with the three SQL Server CLR user-defined types: `geometry`, `geography`, `hierarchyid`. When a provider declares such types, the projection is built from the catalog and names the remaining columns. Identifiers come from the catalog's own `COLUMN_NAME`, so casing and quoting match the database rather than the config. The catalog is read once per object and shared with column definition population, instead of being queried twice. The projection reproduces the set of columns `SELECT *` exposes before subtracting the unsupported types. This matters because the catalog also reports columns declared `GENERATED ALWAYS AS ROW START/END HIDDEN`, which `SELECT *` does not return: naming them would widen the exposed contract rather than preserve it, and since the read-only classification does not recognize generated-always period columns, an overwriting PUT would target them. They are excluded through `sys.columns.is_hidden`, and they are not reported as skipped — they were never part of the object's shape as the engine sees it. When — and only when — the projection is narrowed, the shape is read with `CommandBehavior.SchemaOnly` rather than through `DbDataAdapter.FillSchema`. `FillSchema` runs with `KeyInfo`, under which the provider performs its own key discovery and returns key columns absent from the `SELECT` list as hidden reader columns; an unsupported type among them reintroduces `DataReader.GetFieldType(N) returned null` even though the projection excluded it. That is reachable through the object's own primary key and through any unique index, including when a supported key is configured through `source.key-fields`. Without `KeyInfo` the projection is authoritative, and the primary key comes from the catalog instead. When nothing is skipped, `FillSchema` still runs with `KeyInfo` exactly as before, so ordinary primary-key inference is untouched for every object that works today. The primary key comes from the object's own key when it has one. Absent a primary key, the first unique index whose every key column is non-nullable and readable is used, in index order — which is what the data adapter reports as `DataTable.PrimaryKey` on the unnarrowed path, so the two paths agree and the narrowed one does not start demanding `source.key-fields` for an object the other resolves on its own. ### Keys of a view A view has no index of its own, so `sys.indexes` holds nothing for it and the narrowed path has no catalog key to fall back to. An earlier revision took the key from `is_part_of_unique_key` in `sys.dm_exec_describe_first_result_set`. That flag is wrong for this purpose: it is a per-column union across every unique key of the underlying object and cannot be split back into one key. A view exposing one column of a two-column key would have that single column inferred as the key, and a partial key silently matches more than one row on an update or a delete. Browse mode on the same procedure also reports `source_schema`, `source_table` and `source_column` for each column. The narrowed path resolves the projection's source object from those, requires a single source object — a projection over a join yields nothing and the missing primary key is reported exactly as before — reads that object's primary key and non-nullable unique candidates from the catalog it already caches, and accepts the first key the projection exposes in full. Every row browse mode returns counts toward the single-source check, the hidden ones included. Browse mode reports the key columns of each participating object, so an object whose every selected column was dropped from the projection survives in hidden rows alone: a view `select a.id, a.name, b.geom from A a join B b on ...` narrows to `[id], [name]`, and without counting the hidden row for `B`'s key the result would read as a single object and be keyed by `A`'s primary key — which does not identify a row, because the join can duplicate `A`'s rows. Only a column the projection selects can carry a key, so the hidden rows are excluded from the key mapping itself. A self-join gets past that check, because browse mode reports the physical table and not the alias, so both instances look like one object. What gives it away is a source column reported twice, since each instance contributes the key. Inference is declined when one repeats. The rule is conservative: a projection that selects a single column twice under different names is declined too, and simply needs `source.key-fields`, as it did before this change. When no key qualifies, the reason is returned rather than thrown, and reported only if the object ends up with no key at all. The schema read runs for every object while the answer matters only for one that is keyless, so an object whose `source.key-fields` is configured must not be rejected over a key it was told not to use — failing there would recommend precisely what was configured. When the object is keyless, the error names the key column the projection leaves out, which is more useful than the generic missing-primary-key one. ### Identity, unreadable keys, stale references Identity columns are carried from `sys.columns.is_identity` rather than through `DataColumn.AutoIncrement`. That setter coerces a DataType it cannot increment to `Int32`, and SQL Server allows identity on `tinyint`, `numeric` and `decimal`, so using it as the transport would report the wrong `SystemType` and reach parameter typing and the generated API schemas. A primary key that cannot be read is rejected at initialization, with the column and its data type named. This covers a key configured over such a column, and the object's own database key when no key is configured — single column or one member of a composite key. Omitting it would leave the key in `SourceDefinition.PrimaryKey` while absent from `SourceDefinition.Columns`, and that inconsistency surfaces much later as a lookup failure. The generic "primary key not configured" error is not used for these, because it reads as something the user forgot to configure even though no configuration can express that key. Configuration naming a column left out of the projection also fails initialization. The exposed and backing column maps are built from entity fields and mappings without requiring the column to exist in `SourceDefinition.Columns`, and the authorization resolver accepts explicitly included field names, so such a reference keeps resolving after the column is gone and then fails per request rather than at startup. `mappings`, `fields`, a permission's `fields.include` and a database policy are all rejected; `exclude` is left alone, since it asks for what already happened. The policy case matters for the same reason the field-permission approach was withdrawn: a policy is parsed per request against the OData model, which `EdmModelBuilder` builds from `SourceDefinition.Columns`, so one naming an absent column returns 400 on every request for that role. Policy field references are found by scanning the expression and skipping single-quoted literals, with `''` treated as an escaped quote, so a literal that happens to read like a column name is not mistaken for one. Aliases resolve through `fields` before `mappings`, matching the precedence `GenerateExposedToBackingColumnMapUtil` already applies. A configured relationship's `source.fields` and `target.fields` are rejected on the same grounds, and `MultipleCreateOrderHelper` is the path that would otherwise fail per request, since it indexes `SourceDefinition.Columns` by each relationship field. That check runs after every object definition is populated rather than alongside the others, because a relationship's `target.fields` belong to the other entity's object, which may not have been read yet. Foreign keys inferred from the catalog and `linking.*` fields are deliberately left alone: there is no configuration to correct for an inferred key, so refusing to start would punish the database's shape rather than the configuration, and the relationship simply not forming is the proportionate outcome. ### Catalog access The catalog facts that the `Columns` schema collection does not carry — which columns the database hides from `SELECT *`, and which columns form the object's primary key — come from a new provider hook, `GetObjectCatalogMetadataAsync`, which returns null in the base class. Only `MsSqlMetadataProvider` implements it, reading `sys.columns` joined to `sys.indexes` / `sys.index_columns`, cached once per object for the duration of initialization. Providers that declare no unsupported types never call it, and neither does an object that holds none: the classification runs first over the `Columns` schema collection, which is read for every object anyway, so only an object whose projection must be narrowed pays the additional query. Both the catalog read and the browse-mode describe are resolved before the object's connection is opened, so nothing nests a second connection inside an open scope. If nothing unsupported is present, or the catalog cannot be read, or it does not report a usable type name, the projection falls back to `SELECT *` and behavior is exactly what it is today. That last case includes an engine without `sys.columns.is_hidden`, which exists from SQL Server 2016 on, and a login without `VIEW DEFINITION`. When every column of an object is unsupported it fails with a clear initialization error instead, since falling back there would re-issue the projection that cannot be read. Skipped columns are logged once per object at Warning level, naming each column and its type, so the omission is discoverable rather than silent. ### Deliberately limited to three types `MsSqlQueryBuilder`'s autoentity discovery skips objects containing `geography`, `geometry`, `hierarchyid`, `sql_variant`, `xml`, `rowversion` or `vector`. That list is intentionally not reused here: `SqlTypeConstants.SupportedSqlDbTypes` marks `timestamp` and `vector` as supported, and there are dedicated `vector` tests, so excluding them would regress shipped behavior. This change is scoped to the CLR user-defined types, which are the ones whose CLR type the provider does not report. ### Why not honor `fields.include` instead An earlier revision of this PR narrowed the projection to the columns the permissions allow to be read. I withdrew it: read permission and physical existence are different things, and several paths need a column to be in `SourceDefinition.Columns` without needing it to be readable. A database policy on an excluded column stops parsing against the EDM model (`EdmModelBuilder` iterates `Columns`) and returns 400 on every request in that role; entities sharing a `source.object` share one `SourceDefinition`, so a per-entity filter cannot isolate anything; multiple-create indexes `Columns` by relationship column name; REST PUT stops nulling the hidden columns. Skipping by type has none of that blast radius, because a column the provider cannot type was never usable in any of those paths. ## Compatibility impact Skipping is provider-wide and driven by the column's data type alone, so it does not consult permissions: a `geometry`, `geography` or `hierarchyid` column is left out even for a role that grants unrestricted read, and `fields.include` / `fields.exclude` no longer narrow discovery. They are not ignored either — naming one of these columns in `fields`, `mappings` or a permission's `fields.include` now fails initialization, because the reference cannot be honored once the column is not part of the exposed contract. That is a deliberate widening, and it takes nothing away in practice. Those three types cannot be read today at all — the object fails discovery and the entity never loads, which is #3801. The observable change is that such an entity now loads with the column absent, instead of not loading. No column that previously reached `SourceDefinition.Columns` stops reaching it, so REST, GraphQL, OpenAPI, MCP and database policies see exactly what they see today for every object that works today. Objects that fail today now fail with a specific reason instead of the provider's opaque error: one whose configured or database primary key is of an unsupported type, and one whose every column is. Providers other than MSSQL and DWSQL declare no un…
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.
Why make this change?
Harden against vulnerabilities we've recently fixed and released advisories for.
What is this change?
Updates HotChocolate packages to 16.7.3
How was this tested?