Skip to content

{Cosmos DB} az cosmosdb: Add support for API version 2026-03-15(#33303) - #33942

Open
pjohari-ms wants to merge 1 commit into
Azure:devfrom
pjohari-ms:revert-33802-dev
Open

{Cosmos DB} az cosmosdb: Add support for API version 2026-03-15(#33303)#33942
pjohari-ms wants to merge 1 commit into
Azure:devfrom
pjohari-ms:revert-33802-dev

Conversation

@pjohari-ms

@pjohari-ms pjohari-ms commented Aug 20, 2026

Copy link
Copy Markdown
Member

🤖 PR Validation — ⚠️ Review suggested

Breaking Changes Tests
⚠️ None ️✔️ 130/130
⚠️AzureCLI-BreakingChangeTest
⚠️cosmosdb
rule cmd_name rule_message suggest_message
⚠️ 1004 - CmdPropRemove cosmosdb fleet create cmd cosmosdb fleet create removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleet delete cmd cosmosdb fleet delete removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleet list cmd cosmosdb fleet list removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleet show cmd cosmosdb fleet show removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace account create cmd cosmosdb fleetspace account create removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace account delete cmd cosmosdb fleetspace account delete removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace account list cmd cosmosdb fleetspace account list removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace account show cmd cosmosdb fleetspace account show removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace create cmd cosmosdb fleetspace create removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace delete cmd cosmosdb fleetspace delete removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace list cmd cosmosdb fleetspace list removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace show cmd cosmosdb fleetspace show removed property is_preview
⚠️ 1004 - CmdPropRemove cosmosdb fleetspace update cmd cosmosdb fleetspace update removed property is_preview
⚠️ 1006 - ParaAdd cosmosdb restore cmd cosmosdb restore added parameter disable_local_auth
⚠️postgresql
rule cmd_name rule_message suggest_message
⚠️ 1008 - ParaPropAdd postgres flexible-server maintenance-event list cmd postgres flexible-server maintenance-event list update parameter server_name: added property id_part=name

Related command

Description

Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change
[Component Name 2] az command b: Add some customer-facing feature


This checklist is used to make sure that common guidelines for a pull request are followed.

Copilot AI lite review requested due to automatic review settings August 20, 2026 16:30
@pjohari-ms
pjohari-ms requested review from a team as code owners August 20, 2026 16:30
@azure-client-tools-bot-prd

Copy link
Copy Markdown

Hi pjohari-ms,
Since the current milestone time is less than 7 days, this pr may not catch up with this release.

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
There may be pipelines that require an authorized user to comment /azp run to run.

@a0x1ab

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Pull request overview

This PR re-applies the Cosmos DB management-plane update that was previously reverted, aligning Azure CLI’s Cosmos DB module and its tests/recordings with a newer ARM API version and SDK behavior.

Changes:

  • Bump azure-mgmt-cosmosdb dependency to 10.0.0 across packaging/requirements.
  • Refresh Cosmos DB-related live test recordings to use api-version=2026-03-15 and update multiple tests to pass --disable-local-auth true.
  • Update Cosmos DB module implementation for newer SDK contracts (e.g., PBE field name, restore parameters, mongo role/user model conversions, transformer todict).

Reviewed changes

Copilot reviewed 25 out of 102 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
src/azure-cli/setup.py Updates Cosmos DB management SDK version used by the CLI.
src/azure-cli/requirements.py3.windows.txt Syncs Windows pinned dependency for azure-mgmt-cosmosdb.
src/azure-cli/requirements.py3.Linux.txt Syncs Linux pinned dependency for azure-mgmt-cosmosdb.
src/azure-cli/requirements.py3.Darwin.txt Syncs macOS pinned dependency for azure-mgmt-cosmosdb.
src/azure-cli/azure/cli/command_modules/network/tests/latest/recordings/test_private_endpoint_connection_cosmosdb.yaml Refreshes recording to the newer Cosmos DB ARM API version.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb-burst-capacity-scenario.py Updates test to create accounts with local auth disabled.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_prpp_autoscale_scenario.py Updates test to create accounts with local auth disabled.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_priority_based_execution_scenario.py Updates test to create accounts with local auth disabled.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_fleet_fleetspace_fleetspaceAccount_scenario.py Tightens Storage Account creation flags and disables local auth for Cosmos account.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_commands.py Updates many scenario tests for --disable-local-auth; adds skips for deprecated service behaviors.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_backuprestore_scenario.py Updates restore flows to pass --disable-local-auth and optimizes long sleeps during recording.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/recordings/test_cosmosdb_postgres_list_cluster.yaml Removes an unused/obsolete recording.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/recordings/test_cosmosdb_mongodb_container_backupinfo.yaml Removes an unused/obsolete recording.
src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/recordings/test_cosmosdb_locations.yaml Refreshes location recordings and bumps to api-version=2026-03-15.
src/azure-cli/azure/cli/command_modules/cosmosdb/custom.py Updates SDK parameter names, restore signature, restorable list calls, and mongo role/user body conversions for new models.
src/azure-cli/azure/cli/command_modules/cosmosdb/commands.py Removes preview flag from fleet-related command groups.
src/azure-cli/azure/cli/command_modules/cosmosdb/_transformers.py Switches to azure.cli.core.util.todict and adjusts vnet rule output rewriting safely.
src/azure-cli/azure/cli/command_modules/cosmosdb/_params.py Adds --disable-local-auth support to az cosmosdb restore.
Suppressed comments (2)

src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_commands.py:708

  • The @unittest.skip reason is time-bound ("next PR"), which will become stale and make it harder to understand why the test is skipped later. Please keep the skip message evergreen (and ideally track the longer-term follow-up elsewhere).
    src/azure-cli/azure/cli/command_modules/cosmosdb/tests/latest/test_cosmosdb_commands.py:770
  • The @unittest.skip reason is time-bound ("next PR"), which will become stale and make it harder to understand why the test is skipped later. Please keep the skip message evergreen (and ideally track the longer-term follow-up elsewhere).

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@pjohari-ms pjohari-ms changed the title Revert "{Cosmos DB} az cosmosdb: Revert Add support for API version 2026-03-15(#33303)" {Cosmos DB} az cosmosdb: Add support for API version 2026-03-15(#33303) Aug 20, 2026
@yonzhan

Copy link
Copy Markdown
Collaborator

Cosmos DB

@coopercox-ms

Copy link
Copy Markdown
Member

/azp run

@azure-pipelines

Copy link
Copy Markdown
Azure Pipelines:
Successfully started running 3 pipeline(s).

@coopercox-ms Cooper Cox (coopercox-ms) added the Azure Client Tools Agent Requested Request Azure Client Tools Agent testing and review label Aug 21, 2026

@azure-client-tools-agent azure-client-tools-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Live Test Result — 1 failed, 4 passed (infrastructure auth issue)

The live test run (Azure/issue-sentinel#32447848539) completed with 1 failure out of 5 tests after ~51 minutes.

CI checks: ✅ All passed (no failed check runs).

Failure summary

The single failing test hit an AuthenticationError raised from azure-cli-core/azure/cli/core/auth/util.py:61 — the test runner's service principal certificate credential expired mid-run. This is a transient infrastructure issue, not caused by code changes in this PR. Four tests passed successfully before the auth expiry occurred.

1 failed, 4 passed in 3090.92s (0:51:30)
AuthenticationError: ... certificate-credentials
Trace ID: 54e157bf-3a47-44ea-9945-e00947a21900
Timestamp: 2026-08-21 05:38:24Z

Recommendation

This failure is not attributable to the CosmosDB API 2026-03-15 changes in this PR. The live test can be re-triggered once the test runner credentials are refreshed. No code changes are needed based on this result.

@azure-client-tools-agent azure-client-tools-agent Bot added azure-client-tools-agent Pull request reviewed by Azure Client Tools Agent and removed Azure Client Tools Agent Requested Request Azure Client Tools Agent testing and review labels Aug 21, 2026
@coopercox-ms Cooper Cox (coopercox-ms) added Azure Client Tools Agent Requested Request Azure Client Tools Agent testing and review and removed azure-client-tools-agent Pull request reviewed by Azure Client Tools Agent labels Aug 21, 2026

@azure-client-tools-agent azure-client-tools-agent Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Automated Review Summary — Live Test Failed

PR: az cosmosdb: Add support for API version 2026-03-15 (#33303)

Live test result: ❌ Failed

CI check status: ✅ All required GitHub checks passed (0 failed, 0 pending).

Since the live regression test failed, please review the test run logs at the
link above, fix the failing test(s) or the underlying az cosmosdb API version
2026-03-15 changes, and push an update. The live test will be re-run
automatically against the new commit.

@azure-client-tools-agent azure-client-tools-agent Bot added the azure-client-tools-agent Pull request reviewed by Azure Client Tools Agent label Aug 21, 2026
@azure-client-tools-agent azure-client-tools-agent Bot removed the Azure Client Tools Agent Requested Request Azure Client Tools Agent testing and review label Aug 21, 2026
@microsoft-github-policy-service

Copy link
Copy Markdown
Contributor

🔔 Routing this PR to @Azure/act-codegen-extensibility-squad.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

act-codegen-extensibility-squad Auto-Assign Auto assign by bot azure-client-tools-agent Pull request reviewed by Azure Client Tools Agent CosmosDB az cosmosdb

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants