You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[StorageMover] Upgrade API version to 2026-05-01 - #30308
Upgrades Az.StorageMover to the Storage Mover 2026-05-01 stable API (Azure/azure-rest-api-specs#44795, pinned to commit f89d3d95044e14c679785fa9e0d28c7c97af870a), regenerated on the existing AutoRest PowerShell v4 base.
New cmdlet
Invoke-AzStorageMoverReconcileJobDefinition for the new POST .../jobDefinitions/{jobDefinitionName}/reconcileJob action, which reconciles the running job and returns its job run resource ID. It is renamed from the AutoRest default Invoke-AzStorageMoverReconcileJobDefinitionJob to match Start-/Stop-AzStorageMoverJobDefinition.
New parameters
-EndpointKind (Source/Target) on all New-AzStorageMover*Endpoint cmdlets.
-EnableCrossTenantTransfer and -AllowedStorageAccount on New-/Update-AzStorageMoverAzStorageContainerEndpoint and New-/Update-AzStorageMoverAzSmbFileShareEndpoint.
-SourceType on New-AzStorageMoverNfsEndpoint (NfsMount/FSX-EFS) and New-AzStorageMoverSmbEndpoint (SmbMount/FSX-SMB); NFSv4_1 added to the -NfsVersion completer.
Generated from the spec: -IsCrossTenantJob, -CrossTenantEndpointTenantId and -CrossTenantEndpointResourceId on New-AzStorageMoverJobDefinition; -SyncMode, -MoverSyncedUntil and -ScheduleRepeatInterval on New-/Update-AzStorageMoverJobDefinition; the Hourly schedule frequency and OnPremToCloudAgentLess job type.
Other changes
A README directive rewrites the Connections_Delete description to one line, so the generated help for Remove-AzStorageMoverConnection no longer shows a literal \n.
Regenerated docs and markdown help; added examples for the new cmdlet and for the cross-tenant and FSX scenarios; updated ChangeLog.md.
New tests, added to the matching per-cmdlet test files:
Live-recorded scenarios: CreateExpandedCrossTenant (New-AzStorageMoverAzStorageContainerEndpoint), UpdateExpandedCrossTenant (Update-AzStorageMoverAzStorageContainerEndpoint), CreateExpandedWithEndpointKind (New-AzStorageMoverAzSmbFileShareEndpoint), CreateExpandedFsxEfs (New-AzStorageMoverNfsEndpoint), CreateExpandedFsxSmb (New-AzStorageMoverSmbEndpoint), and CreateCrossTenant (New-AzStorageMoverJobDefinition), which targets a real partner-tenant endpoint.
Offline request checks, using a mocked service call or the request model, for what the service can't confirm today: Azure SMB file share cross-tenant settings, the sourceType and NFSv4_1 payloads, -EndpointKind on the remaining endpoint types, hourly and sync job settings, and the reconcile cmdlet's parameter sets.
env.json gains keys for the new scenarios' resources (existing keys are unchanged). setupEnv and cleanupEnv create and remove them for future re-recordings, and the partner tenant details come from the SM_XT_PARTNER_* environment variables (CreateCrossTenant is skipped without them). Partner tenant and subscription IDs are placeholders in env.json and the recordings.
Service behavior observed with API 2026-05-01
The service currently rejects enableCrossTenantTransfer/allowedStorageAccounts on AzureStorageSmbFileShare endpoints (InvalidRequestPropertyValue), although the spec declares them. The parameters follow the spec and are covered by the offline tests only.
The service accepts sourceType on NFS and SMB mount endpoints but does not return it in responses.
reconcileJob returned 404 for every job state we tried, so the generated Invoke-AzStorageMoverReconcileJobDefinition test stubs stay skipped.
./artifacts/Debug/Az.StorageMover/StorageMover.Autorest/test-module.ps1 -Playback (Pester 4.10.1): passed, 69 passed, 0 failed, 10 skipped (6 existing skips and the 4 generated reconcile stubs).
Live recording of the new scenarios against API 2026-05-01 in eastus2euap and eastus: passed. The scenarios were recorded in one live run, and each scenario's request and response sequence is stored under its test name in the cmdlet's recording file.
./tools/ExecuteCIStep.ps1 -StaticAnalysis -Configuration Debug -TargetModule StorageMover: passed with exit code 0; no breaking changes, only existing severity-2 signature warnings on the Get-* cmdlets.
Mandatory Checklist
Please choose the target release of Azure PowerShell. (⚠️Target release is a different concept from API readiness. Please click below links for details.)
- Regenerated Az.StorageMover from the 2026-05-01 stable spec (Azure/azure-rest-api-specs f89d3d95)
- Added Invoke-AzStorageMoverReconcileJobDefinition for the new reconcileJob action
- Added EndpointKind, cross-tenant transfer and SourceType parameters to the endpoint cmdlets
- Updated docs, help, examples, ChangeLog, test recordings, and added offline and live-recorded tests
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Moved the live scenarios into the matching cmdlet test files and their recordings
- Moved the offline request checks into the matching cmdlet test files
- Added the scenario resources to env.json, setupEnv and cleanupEnv
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Regeneration reset Properties/AssemblyInfo.cs to the AutoRest placeholder 0.1.0.0; restore the version from main.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
When SM_XT_PARTNER_STORAGE_ACCOUNT_ID is unset, this stores null, but UpdateExpandedCrossTenant still runs and includes it alongside CrossTenantStorageAccountId in -AllowedStorageAccount. That sends an invalid storage-account resource ID to the service, so recording without the optional partner configuration fails rather than just skipping CreateCrossTenant. Please supply valid standalone allow-list test data when no partner is configured, or skip all scenarios that require that configuration.
CI is green, but one confirmed regression-test finding remains at d6ba77d9eda1409f0541cdf7cb633f6cb9eb76c2.
Copilot feedback assessment
Assembly-version comment 4313459390 is resolved in this revision: src/StorageMover/StorageMover.Autorest/Properties/AssemblyInfo.cs:23-24 sets both file and assembly versions to 2.0.0; this file is absent from the current diff. No version change is requested.
Reconcile-test comment 4313702157 is confirmed; it is consolidated below rather than duplicated.
Upstream CI
The supplied snapshot reports 13 passed checks and zero failed or pending checks. There are no CI failures to attribute. No checks were rerun for this review.
Test validation
Agent live test: Not run; this is a review-only PR. Check author-provided test evidence and upstream CI separately.
Regression coverage: Not applicable to the changed files.
That last line is the supplied coverage helper's applicability result, not proof of the new PowerShell scenarios. Independent inspection finds the execution gap below. Additional limits: the new hourly/sync cases in src/StorageMover/StorageMover.Autorest/test/New-AzStorageMoverJobDefinition.Tests.ps1:116-130 and src/StorageMover/StorageMover.Autorest/test/Update-AzStorageMoverJobDefinition.Tests.ps1:27-37 serialize models without invoking the cmdlets, so they do not establish runtime parameter binding, service acceptance, or output. The update recording src/StorageMover/StorageMover.Autorest/test/Update-AzStorageMoverJobDefinition.Recording.json contains only the existing UpdateExpanded scenario. Before merge, request focused cmdlet-level coverage for Hourly/PT1H, SyncMode and MoverSyncedUntil, including recorded request/response assertions where service support is available. The large new-job recording was truncated by the governed reader; its complete scenario coverage was not independently verified.
The blob update recording src/StorageMover/StorageMover.Autorest/test/Update-AzStorageMoverAzStorageContainerEndpoint.Recording.json does exercise preserving an omitted enable flag, replacing the allowed-account list, and explicitly sending false plus an empty list. In contrast, the SMB cross-tenant tests in src/StorageMover/StorageMover.Autorest/test/New-AzStorageMoverAzSmbFileShareEndpoint.Tests.ps1 and src/StorageMover/StorageMover.Autorest/test/Update-AzStorageMoverAzSmbFileShareEndpoint.Tests.ps1 mock the underlying endpoint cmdlet. Their serialization assertions do not prove SMB service support; the changed src/StorageMover/StorageMover.Autorest/test/New-AzStorageMoverAzSmbFileShareEndpoint.Recording.json exercises EndpointKind, not enabling cross-tenant transfer. Obtain a focused service-backed recording when supported; do not treat the offline checks as an end-to-end transfer test.
Confirmed finding
Medium — Reconcile execution is never exercised. In src/StorageMover/StorageMover.Autorest/test/Invoke-AzStorageMoverReconcileJobDefinition.Tests.ps1:18-39, all four execution cases are skipped placeholders and the sole active case checks parameter-set names and output-type metadata. The corresponding src/StorageMover/StorageMover.Autorest/test/Invoke-AzStorageMoverReconcileJobDefinition.Recording.json is absent at this head. Incorrect POST routing or returned job-run ID mapping can therefore pass this suite, unlike the existing Start/Stop tests that invoke their actions.
Implement the named and identity-based cases using recorded exchanges or a mocked HTTP pipeline through the actual cmdlet, not only command metadata or a model. Verify POST to the selected job definition's /reconcileJob route with API 2026-05-01, assert the returned job-run resource ID, and assert failed responses propagate. Rerun this focused test file with execution cases enabled; for recorded playback, add its matching recording. This is a test-strength finding, not a claim that the cmdlet currently misroutes requests.
The API source pin, rename directive, public export and upcoming-release notes align with the advertised additions. Full Codegen provenance, service execution and sovereign-cloud availability were not independently verified.
Risk assessment — 41/100 · Medium
The Medium rating is driven by security-sensitive behavior.
Change scope: 102 changed files, 4400 changed lines (+3771 / -629), including 9 production files.
Affected components:storagemover
Risk drivers: security-sensitive behavior (+28)
Regression evidence: Changed regression tests are included, reducing risk.
Confidence: High because changed-line patches were available for every production file.
Required review: Owning-squad review is required for storagemover before merge.
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
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.
🤖 PR Validation —⚠️ Review suggested
️✔️Az.Accounts
Description
Upgrades
Az.StorageMoverto the Storage Mover2026-05-01stable API (Azure/azure-rest-api-specs#44795, pinned to commitf89d3d95044e14c679785fa9e0d28c7c97af870a), regenerated on the existing AutoRest PowerShell v4 base.New cmdlet
Invoke-AzStorageMoverReconcileJobDefinitionfor the newPOST .../jobDefinitions/{jobDefinitionName}/reconcileJobaction, which reconciles the running job and returns its job run resource ID. It is renamed from the AutoRest defaultInvoke-AzStorageMoverReconcileJobDefinitionJobto matchStart-/Stop-AzStorageMoverJobDefinition.New parameters
-EndpointKind(Source/Target) on allNew-AzStorageMover*Endpointcmdlets.-EnableCrossTenantTransferand-AllowedStorageAccountonNew-/Update-AzStorageMoverAzStorageContainerEndpointandNew-/Update-AzStorageMoverAzSmbFileShareEndpoint.-SourceTypeonNew-AzStorageMoverNfsEndpoint(NfsMount/FSX-EFS) andNew-AzStorageMoverSmbEndpoint(SmbMount/FSX-SMB);NFSv4_1added to the-NfsVersioncompleter.-IsCrossTenantJob,-CrossTenantEndpointTenantIdand-CrossTenantEndpointResourceIdonNew-AzStorageMoverJobDefinition;-SyncMode,-MoverSyncedUntiland-ScheduleRepeatIntervalonNew-/Update-AzStorageMoverJobDefinition; theHourlyschedule frequency andOnPremToCloudAgentLessjob type.Other changes
Connections_Deletedescription to one line, so the generated help forRemove-AzStorageMoverConnectionno longer shows a literal\n.ChangeLog.md.2025-12-01to2026-05-01, the same approach as Storage mover api version 2025-12-01 #29446.CreateExpandedCrossTenant(New-AzStorageMoverAzStorageContainerEndpoint),UpdateExpandedCrossTenant(Update-AzStorageMoverAzStorageContainerEndpoint),CreateExpandedWithEndpointKind(New-AzStorageMoverAzSmbFileShareEndpoint),CreateExpandedFsxEfs(New-AzStorageMoverNfsEndpoint),CreateExpandedFsxSmb(New-AzStorageMoverSmbEndpoint), andCreateCrossTenant(New-AzStorageMoverJobDefinition), which targets a real partner-tenant endpoint.sourceTypeandNFSv4_1payloads,-EndpointKindon the remaining endpoint types, hourly and sync job settings, and the reconcile cmdlet's parameter sets.env.jsongains keys for the new scenarios' resources (existing keys are unchanged).setupEnvandcleanupEnvcreate and remove them for future re-recordings, and the partner tenant details come from theSM_XT_PARTNER_*environment variables (CreateCrossTenantis skipped without them). Partner tenant and subscription IDs are placeholders inenv.jsonand the recordings.Service behavior observed with API 2026-05-01
enableCrossTenantTransfer/allowedStorageAccountsonAzureStorageSmbFileShareendpoints (InvalidRequestPropertyValue), although the spec declares them. The parameters follow the spec and are covered by the offline tests only.sourceTypeon NFS and SMB mount endpoints but does not return it in responses.reconcileJobreturned 404 for every job state we tried, so the generatedInvoke-AzStorageMoverReconcileJobDefinitiontest stubs stay skipped.Validation
./tools/BuildScripts/BuildModules.ps1 -Configuration Debug -TargetModule StorageMover: succeeded, 0 errors../artifacts/Debug/Az.StorageMover/StorageMover.Autorest/test-module.ps1 -Playback(Pester 4.10.1): passed, 69 passed, 0 failed, 10 skipped (6 existing skips and the 4 generated reconcile stubs)../tools/ExecuteCIStep.ps1 -StaticAnalysis -Configuration Debug -TargetModule StorageMover: passed with exit code 0; no breaking changes, only existing severity-2 signature warnings on theGet-*cmdlets.Mandatory Checklist
Please choose the target release of Azure PowerShell. (⚠️ Target release is a different concept from API readiness. Please click below links for details.)
Check this box to confirm: I have read the Submitting Changes section of
CONTRIBUTING.mdand reviewed the following information:ChangeLog.mdfile(s) appropriatelysrc/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.## Upcoming Releaseheader in the past tense.ChangeLog.mdif no new release is required, such as fixing test case only.