Skip to content

[PS] Migrate Resource module Authorization part to autorest v4 #27902

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

JoyerJin
Copy link
Contributor

@JoyerJin JoyerJin commented Jun 9, 2025

Description

Mandatory Checklist

  • SHOULD update ChangeLog.md file(s) appropriately
    • Update src/{{SERVICE}}/{{SERVICE}}/ChangeLog.md.
      • A snippet outlining the change(s) made in the PR should be written under the ## Upcoming Release header in the past tense.
    • Should not change ChangeLog.md if no new release is required, such as fixing test case only.
  • SHOULD regenerate markdown help files if there is cmdlet API change. Instruction
  • SHOULD have proper test coverage for changes in pull request.
  • SHOULD NOT adjust version of module manually in pull request

@Copilot Copilot AI review requested due to automatic review settings June 9, 2025 09:45
Copy link

Thanks for your contribution! The pull request validation has started. Please revisit this comment for updated status.

Copy link
Contributor

@Copilot Copilot AI left a comment

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 migrates the Authorization cmdlet module to use AutoRest v4 by updating generated documentation, metadata, and assembly info to align with the new code generator and add JSON-based parameter sets.

  • Updated many cmdlet markdown files: removed outdated -InputObject sections, introduced CreateViaJsonFilePath/CreateViaJsonString parameter sets, adjusted Parameter Sets annotations, and standardized output model references.
  • Updated Az.Authorization.md and module metadata: bumped Module Guid, added new Update- cmdlets entries, and increased Az.Accounts dependency version.
  • Added a generated AssemblyInfo.cs for assembly metadata and versioning.

Reviewed Changes

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

Show a summary per file
File Description
docs/*.md Refactored cmdlet syntax blocks, parameter sets, types, and outputs
docs/Az.Authorization.md Updated help index entries, Module Guid, and dependency bump
README.md Adjusted AutoRest directives
Properties/AssemblyInfo.cs Added generated assembly metadata
Az.Authorization.nuspec Bumped Az.Accounts dependency version
Comments suppressed due to low confidence (2)

src/Resources/Authorization.Autorest/docs/New-AzRoleManagementPolicyAssignment.md:21

  • Consider adding or updating Pester tests to cover the new JsonFilePath and JsonString parameter sets for this cmdlet.
### CreateViaJsonFilePath

@JoyerJin
Copy link
Contributor Author

disable-table-view feature is missing, need confirm if this is expected.

@vidai-msft
Copy link
Contributor

disable-table-view feature is missing, need confirm if this is expected.

cc @dolauli

Copy link
Contributor

@vidai-msft vidai-msft left a comment

Choose a reason for hiding this comment

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

This PR contains breaking changes.

@@ -13,7 +13,7 @@
<copyright>Microsoft Corporation. All rights reserved.</copyright>
<tags>Azure ResourceManager ARM PSModule $(service-name)</tags>
<dependencies>
<dependency id="Az.Accounts" version="2.2.3" />
<dependency id="Az.Accounts" version="2.7.5" />
Copy link
Contributor

Choose a reason for hiding this comment

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

Any specific reason why the version should be 2.7.5?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

autogen, I will check

@@ -0,0 +1,12 @@
### Example 1: update role management policy assignment
Copy link
Contributor

Choose a reason for hiding this comment

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

Please remove this command if it is currently does not work.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

if the new command works, the update will be the same. But I cannot get a valid value to send request.

@vidai-msft vidai-msft added the Breaking Change Release This PR contains breaking change label Jun 12, 2025
Copy link

To the author of the pull request,
This PR was labeled "Breaking Change Release" because it contains breaking changes.

  • According to our policy, breaking changes can only take place during major release and they must be preannounced.
  • Please follow our guide on the detailed steps.
  • Required: Please fill in the task below to facilitate our contact,you will receive notifications related to breaking changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Breaking Change Release This PR contains breaking change
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants