Skip to content

Conversation

yifanz7
Copy link
Member

@yifanz7 yifanz7 commented Sep 1, 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 September 1, 2025 04:50
Copy link

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

Copy link

github-actions bot commented Sep 1, 2025

‼️ DO NOT MERGE THIS PR ‼️
This PR was labeled "Do Not Merge" because it contains code change that cannot be merged. Please contact the reviewer for more information.

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 updates the ElasticSan PowerShell module to test a newer version of the Elastic SAN service generated from TypeSpec (TSP). The changes encompass updates to generated help documentation, module manifests, and test configurations to support new API features and parameters.

Key changes include:

  • Addition of new cmdlets for volume backup/restore operations
  • Introduction of delete retention policy and auto-scaling parameters
  • Updates to API version from 2024-05-01 to 2024-07-01-preview
  • Module dependency updates and test environment configuration changes

Reviewed Changes

Copilot reviewed 61 out of 69 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
Update-AzElasticSanVolumeGroup.md Added new delete retention policy parameters to help documentation
Update-AzElasticSanVolume.md Fixed capitalization in SYNOPSIS and DESCRIPTION sections
Update-AzElasticSan.md Added auto-scaling and capacity management parameters, updated examples
Test-AzElasticSanVolumeRestore.md New cmdlet help file for volume restore validation
Test-AzElasticSanVolumeBackup.md New cmdlet help file for volume backup validation
Restore-AzElasticSanVolume.md New cmdlet help file for soft-deleted volume restoration
Remove-AzElasticSanVolume.md Added DeleteType parameter for permanent volume deletion
New-AzElasticSanVolumeSnapshot.md Fixed capitalization in SYNOPSIS and DESCRIPTION
New-AzElasticSanVolumeGroup.md Added delete retention policy parameters
New-AzElasticSanVolume.md Fixed capitalization in SYNOPSIS and DESCRIPTION
New-AzElasticSan.md Major parameter changes making BaseSizeTiB and ExtendedCapacitySizeTiB required, added auto-scaling parameters
Get-AzElasticSanVolumeGroup.md Added AccessSoftDeletedResource parameter
Get-AzElasticSanVolume.md Added AccessSoftDeletedResource parameter
Az.ElasticSan.md Added new cmdlets to module documentation
Az.ElasticSan.psd1 Updated module dependencies, generation date, and exported functions
ElasticSan.sln Updated project GUID reference
utils.ps1 Added availability zone parameter and disk snapshot ID for tests
localEnv.json Complete test environment configuration file
env.json Updated test environment with new resource identifiers
Update-AzElasticSanVolumeGroup.Recording.json Updated test recording with new API version and parameters

Comment on lines +278 to +279
### -DeleteRetentionPolicyState
.
Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The parameter description for DeleteRetentionPolicyState is incomplete. It only contains a period (.) which provides no useful information to users about what this parameter does or what values it accepts.

Suggested change
### -DeleteRetentionPolicyState
.
Specifies the state of the delete retention policy for the volume group. Possible values include 'Enabled' or 'Disabled'.

Copilot uses AI. Check for mistakes.

Comment on lines +275 to +276
### -DeleteRetentionPolicyState
.
Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The parameter description for DeleteRetentionPolicyState is incomplete. It only contains a period (.) which provides no useful information to users about what this parameter does or what values it accepts.

Suggested change
### -DeleteRetentionPolicyState
.
Specifies the state of the delete retention policy for the volume group. Possible values include 'Enabled' or 'Disabled'.

Copilot uses AI. Check for mistakes.

Comment on lines +76 to +89
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```

```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```

{{ Add description here }}

### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The help documentation contains placeholder text for examples. Replace '{{ Add title here }}' and '{{ Add code here }}' with actual example titles and PowerShell commands that demonstrate how to use this cmdlet.

Suggested change
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```
```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```
{{ Add description here }}
### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
### Example 1: Validate disk snapshot restore for an ElasticSan volume group
```powershell
Test-AzElasticSanVolumeRestore -ElasticSanName "myElasticSan" -ResourceGroupName "myResourceGroup" -VolumeGroupName "myVolumeGroup" -DiskSnapshotId @("/subscriptions/xxxx/resourceGroups/myResourceGroup/providers/Microsoft.Compute/snapshots/snapshot1", "/subscriptions/xxxx/resourceGroups/myResourceGroup/providers/Microsoft.Compute/snapshots/snapshot2")
True

This command validates whether the specified disk snapshots can be restored into the ElasticSan volume group named "myVolumeGroup" in the "myElasticSan" ElasticSan resource.

Example 2: Validate disk snapshot restore using a JSON file

Test-AzElasticSanVolumeRestore -ElasticSanName "myElasticSan" -ResourceGroupName "myResourceGroup" -VolumeGroupName "myVolumeGroup" -JsonFilePath "C:\snapshots\snapshotList.json"

Copilot uses AI. Check for mistakes.

Comment on lines +76 to +91
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```

```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```

{{ Add description here }}

### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
```

Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The help documentation contains placeholder text for examples. Replace '{{ Add title here }}' and '{{ Add code here }}' with actual example titles and PowerShell commands that demonstrate how to use this cmdlet.

Suggested change
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```
```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```
{{ Add description here }}
### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
```
### Example 1: Validate backup for specific volumes in a volume group
```powershell
Test-AzElasticSanVolumeBackup -ElasticSanName "myElasticSan" -ResourceGroupName "myResourceGroup" `
-VolumeGroupName "myVolumeGroup" -VolumeName "volume1","volume2"
True

This example validates whether a disk snapshot backup can be taken for the volumes "volume1" and "volume2" in the specified volume group of the ElasticSan resource.

Example 2: Validate backup using a JSON file containing volume names

Test-AzElasticSanVolumeBackup -ElasticSanName "myElasticSan" -ResourceGroupName "myResourceGroup" `
    -VolumeGroupName "myVolumeGroup" -JsonFilePath "C:\volumeNames.json"

This example validates whether a disk snapshot backup can be taken for the list of volumes specified in the JSON file "C:\volumeNames.json" for the given volume group.

Copilot uses AI. Check for mistakes.

Comment on lines +49 to +63
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```

```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```

{{ Add description here }}

### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
```
Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The help documentation contains placeholder text for examples. Replace '{{ Add title here }}' and '{{ Add code here }}' with actual example titles and PowerShell commands that demonstrate how to use this cmdlet.

Suggested change
### Example 1: {{ Add title here }}
```powershell
{{ Add code here }}
```
```output
{{ Add output here (remove the output block if the example doesn't have an output) }}
```
{{ Add description here }}
### Example 2: {{ Add title here }}
```powershell
{{ Add code here }}
```
### Example 1: Restore a soft deleted volume by specifying names
```powershell
Restore-AzElasticSanVolume -ElasticSanName "myElasticSan" -VolumeGroupName "myVolumeGroup" -Name "myVolume" -ResourceGroupName "myResourceGroup"
Volume 'myVolume' has been successfully restored in volume group 'myVolumeGroup' of ElasticSan 'myElasticSan'.

This example restores a soft deleted volume named 'myVolume' in the volume group 'myVolumeGroup' of the ElasticSan resource 'myElasticSan' within the resource group 'myResourceGroup'.

Example 2: Restore a soft deleted volume using identity object

$volGroup = Get-AzElasticSanVolumeGroup -ElasticSanName "myElasticSan" -ResourceGroupName "myResourceGroup" -Name "myVolumeGroup"
Restore-AzElasticSanVolume -Name "myVolume" -VolumegroupInputObject $volGroup

Copilot uses AI. Check for mistakes.

Comment on lines +39 to +56
### Example 1: {{ Add title here }}
```powershell
New-AzElasticSan -ResourceGroupName myresourcegroup -Name myelasticsan -BaseSizeTib 1 -ExtendedCapacitySizeTib 6 -Location eastus -SkuName 'Premium_LRS' -Tag @{tag1="value1";tag2="value2"}
{{ Add code here }}
```

```output
AvailabilityZone :
BaseSizeTiB : 1
ExtendedCapacitySizeTiB : 6
Id : /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myresourcegroup/providers/Microsoft.ElasticSan/elasticSans/myelasticsan
Location : eastus
Name : myelasticsan
ProvisioningState : Succeeded
SkuName : Premium_LRS
SkuTier :
SystemDataCreatedAt : 9/19/2022 9:47:26 AM
SystemDataCreatedBy : yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy
SystemDataCreatedByType : Application
SystemDataLastModifiedAt : 9/19/2022 9:47:26 AM
SystemDataLastModifiedBy : yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy
SystemDataLastModifiedByType : Application
Tag : Microsoft.Azure.PowerShell.Cmdlets.ElasticSan.Models.Api20211120Preview.ResourceTags
TotalIops : 5000
TotalMBps : 80
TotalSizeTiB : 7
TotalVolumeSizeGiB : 0
Type : Microsoft.ElasticSan/ElasticSans
VolumeGroupCount : 0
{{ Add output here (remove the output block if the example doesn't have an output) }}
```

This command creates an Elastic SAN.
{{ Add description here }}

### Example 2: Create an Elastic SAN with default base size and extended capacity size
### Example 2: {{ Add title here }}
```powershell
New-AzElasticSan -ResourceGroupName myresourcegroup -Name myelasticsan -Location eastus -SkuName 'Premium_LRS' -Tag @{tag1="value1";tag2="value2"}
{{ Add code here }}
```

```output
AvailabilityZone :
BaseSizeTiB : 1
ExtendedCapacitySizeTiB : 6
Id : /subscriptions/xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx/resourceGroups/myresourcegroup/providers/Microsoft.ElasticSan/elasticSans/myelasticsan
Location : eastus
Name : myelasticsan
ProvisioningState : Succeeded
SkuName : Premium_LRS
SkuTier :
SystemDataCreatedAt : 9/19/2022 9:47:26 AM
SystemDataCreatedBy : yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy
SystemDataCreatedByType : Application
SystemDataLastModifiedAt : 9/19/2022 9:47:26 AM
SystemDataLastModifiedBy : yyyyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy
SystemDataLastModifiedByType : Application
Tag : Microsoft.Azure.PowerShell.Cmdlets.ElasticSan.Models.Api20211120Preview.ResourceTags
TotalIops : 5000
TotalMBps : 80
TotalSizeTiB : 20
TotalVolumeSizeGiB : 0
Type : Microsoft.ElasticSan/ElasticSans
VolumeGroupCount : 0
{{ Add output here (remove the output block if the example doesn't have an output) }}
Copy link
Preview

Copilot AI Sep 1, 2025

Choose a reason for hiding this comment

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

The help documentation contains placeholder text for examples. Replace '{{ Add title here }}' and '{{ Add code here }}' with actual example titles and PowerShell commands that demonstrate how to use this cmdlet.

Copilot uses AI. Check for mistakes.

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

Successfully merging this pull request may close these issues.

1 participant