Skip to content

Commit 836320b

Browse files
authored
Revert [Compute] Support new ElasticSan parameters in DiskRP cmdlets (#23094) (#23274)
1 parent 4d5d02f commit 836320b

File tree

6 files changed

+5
-90
lines changed

6 files changed

+5
-90
lines changed

src/Compute/Compute/ChangeLog.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,6 @@
2525
* [Breaking change] Removed unversioned and outdated linux image aliases of `CentOS`, `RHEL`, `UbuntuLTS` and `Debian`.
2626
* [Breaking Change] Added defaulting logic for VM and VMSS creation to set SecurityType to TrustedLaunch and SecureBootEnabled and VTpmEnalbed to true when those are not set by the user.
2727
* [Breaking Change] Added defaulting logic for Disk creation to default to TrustedLaunch when able. Allows the user to turn this off by setting the SecurityType to Standard.
28-
* Added new parameters `-ElasticSanResourceId` and `-OptimizedForFrequentAttach` to `New-AzDiskConfig` cmdlet.
29-
* Added new parameter `-ElasticSanResourceId` to `New-AzSnapshotConfig` cmdlet.
3028
* Fixed `New-AzVmss` and `New-Azvm` to use `SharedGalleryImageId` parameter.
3129

3230
## Version 6.3.0

src/Compute/Compute/Generated/Disk/Config/NewAzureRmDiskConfigCommand.cs

Lines changed: 1 addition & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -248,18 +248,6 @@ public partial class NewAzureRmDiskConfigCommand : Microsoft.Azure.Commands.Reso
248248
HelpMessage = "Set this flag to true to get a boost on the performance target of the disk deployed, see here on the respective performance target. This flag can only be set on disk creation time and cannot be disabled after enabled.")]
249249
public bool? PerformancePlus { get; set; }
250250

251-
[Parameter(
252-
Mandatory = false,
253-
ValueFromPipelineByPropertyName = true,
254-
HelpMessage = "Required if createOption is CopyFromSanSnapshot. this is the ARM id of the source elastic san volume snapshot.")]
255-
public string ElasticSanResourceId { get; set; }
256-
257-
[Parameter(
258-
Mandatory = false,
259-
ValueFromPipelineByPropertyName = true,
260-
HelpMessage = "Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.")]
261-
public bool? OptimizedForFrequentAttach { get; set; }
262-
263251
protected override void ProcessRecord()
264252
{
265253
if (ShouldProcess("Disk", "New"))
@@ -351,15 +339,6 @@ private void Run()
351339
vCreationData.SourceResourceId = this.SourceResourceId;
352340
}
353341

354-
if (this.IsParameterBound(c => c.ElasticSanResourceId))
355-
{
356-
if (vCreationData == null)
357-
{
358-
vCreationData = new CreationData();
359-
}
360-
vCreationData.ElasticSanResourceId = this.ElasticSanResourceId;
361-
}
362-
363342
if (this.IsParameterBound(c => c.UploadSizeInBytes))
364343
{
365344
if (vCreationData == null)
@@ -503,8 +482,7 @@ private void Run()
503482
SupportsHibernation = this.IsParameterBound(c => c.SupportsHibernation) ? SupportsHibernation : null,
504483
SupportedCapabilities = vSupportedCapabilities,
505484
PublicNetworkAccess = this.IsParameterBound(c => c.PublicNetworkAccess) ? PublicNetworkAccess : null,
506-
DataAccessAuthMode = this.IsParameterBound(c => c.DataAccessAuthMode) ? DataAccessAuthMode : null,
507-
OptimizedForFrequentAttach = this.IsParameterBound(c => c.OptimizedForFrequentAttach) ? OptimizedForFrequentAttach : null
485+
DataAccessAuthMode = this.IsParameterBound(c => c.DataAccessAuthMode) ? DataAccessAuthMode : null
508486
};
509487

510488
WriteObject(vDisk);

src/Compute/Compute/Generated/Models/PSDisk.cs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,5 @@ public string ResourceGroupName
7878
public SupportedCapabilities SupportedCapabilities { get; set; }
7979
public string DataAccessAuthMode { get; set; }
8080
public double? CompletionPercent { get; set; }
81-
public bool? OptimizedForFrequentAttach { get; set; }
8281
}
8382
}

src/Compute/Compute/Generated/Snapshot/Config/NewAzureRmSnapshotConfigCommand.cs

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -186,12 +186,6 @@ public partial class NewAzureRmSnapshotConfigCommand : Microsoft.Azure.Commands.
186186
[PSArgumentCompleter("X64", "Arm64")]
187187
public string Architecture { get; set; }
188188

189-
[Parameter(
190-
Mandatory = false,
191-
ValueFromPipelineByPropertyName = true,
192-
HelpMessage = "Required if createOption is CopyFromSanSnapshot. this is the ARM id of the source elastic san volume snapshot.")]
193-
public string ElasticSanResourceId { get; set; }
194-
195189
protected override void ProcessRecord()
196190
{
197191
if (ShouldProcess("Snapshot", "New"))
@@ -274,15 +268,6 @@ private void Run()
274268
vCreationData.SourceResourceId = this.SourceResourceId;
275269
}
276270

277-
if (this.IsParameterBound(c => c.ElasticSanResourceId))
278-
{
279-
if (vCreationData == null)
280-
{
281-
vCreationData = new CreationData();
282-
}
283-
vCreationData.ElasticSanResourceId = this.ElasticSanResourceId;
284-
}
285-
286271
if (this.IsParameterBound(c => c.EncryptionSettingsEnabled))
287272
{
288273
if (vEncryptionSettingsCollection == null)

src/Compute/Compute/help/New-AzDiskConfig.md

Lines changed: 2 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -25,8 +25,8 @@ New-AzDiskConfig [[-SkuName] <String>] [-Tier <String>] [-LogicalSectorSize <Int
2525
[-DiskEncryptionSetId <String>] [-EncryptionType <String>] [-DiskAccessId <String>]
2626
[-NetworkAccessPolicy <String>] [-BurstingEnabled <Boolean>] [-PublicNetworkAccess <String>]
2727
[-AcceleratedNetwork <Boolean>] [-DataAccessAuthMode <String>] [-Architecture <String>]
28-
[-PerformancePlus <Boolean>] [-ElasticSanResourceId <String>] [-OptimizedForFrequentAttach <Boolean>]
29-
[-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
28+
[-PerformancePlus <Boolean>] [-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm]
29+
[<CommonParameters>]
3030
```
3131

3232
## DESCRIPTION
@@ -313,21 +313,6 @@ Accept pipeline input: True (ByPropertyName)
313313
Accept wildcard characters: False
314314
```
315315
316-
### -ElasticSanResourceId
317-
Required if createOption is CopyFromSanSnapshot. this is the ARM id of the source elastic san volume snapshot.
318-
319-
```yaml
320-
Type: System.String
321-
Parameter Sets: (All)
322-
Aliases:
323-
324-
Required: False
325-
Position: Named
326-
Default value: None
327-
Accept pipeline input: True (ByPropertyName)
328-
Accept wildcard characters: False
329-
```
330-
331316
### -EncryptionSettingsEnabled
332317
Enable encryption settings.
333318
@@ -484,21 +469,6 @@ Accept pipeline input: True (ByPropertyName)
484469
Accept wildcard characters: False
485470
```
486471
487-
### -OptimizedForFrequentAttach
488-
Setting this property to true improves reliability and performance of data disks that are frequently (more than 5 times a day) by detached from one virtual machine and attached to another. This property should not be set for disks that are not detached and attached frequently as it causes the disks to not align with the fault domain of the virtual machine.
489-
490-
```yaml
491-
Type: System.Nullable`1[System.Boolean]
492-
Parameter Sets: (All)
493-
Aliases:
494-
495-
Required: False
496-
Position: Named
497-
Default value: None
498-
Accept pipeline input: True (ByPropertyName)
499-
Accept wildcard characters: False
500-
```
501-
502472
### -OsType
503473
Specifies the OS type.
504474

src/Compute/Compute/help/New-AzSnapshotConfig.md

Lines changed: 2 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@ New-AzSnapshotConfig [[-SkuName] <String>] [[-OsType] <OperatingSystemTypes>] [[
2121
[-DiskEncryptionKey <KeyVaultAndSecretReference>] [-KeyEncryptionKey <KeyVaultAndKeyReference>]
2222
[-DiskEncryptionSetId <String>] [-EncryptionType <String>] [-DiskAccessId <String>]
2323
[-NetworkAccessPolicy <String>] [-PublicNetworkAccess <String>] [-AcceleratedNetwork <Boolean>]
24-
[-DataAccessAuthMode <String>] [-Architecture <String>] [-ElasticSanResourceId <String>]
25-
[-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
24+
[-DataAccessAuthMode <String>] [-Architecture <String>] [-DefaultProfile <IAzureContextContainer>] [-WhatIf]
25+
[-Confirm] [<CommonParameters>]
2626
```
2727

2828
## DESCRIPTION
@@ -209,21 +209,6 @@ Accept pipeline input: True (ByPropertyName)
209209
Accept wildcard characters: False
210210
```
211211
212-
### -ElasticSanResourceId
213-
Required if createOption is CopyFromSanSnapshot. this is the ARM id of the source elastic san volume snapshot.
214-
215-
```yaml
216-
Type: System.String
217-
Parameter Sets: (All)
218-
Aliases:
219-
220-
Required: False
221-
Position: Named
222-
Default value: None
223-
Accept pipeline input: True (ByPropertyName)
224-
Accept wildcard characters: False
225-
```
226-
227212
### -EncryptionSettingsEnabled
228213
Enable encryption settings.
229214

0 commit comments

Comments
 (0)