Skip to content

Commit

Permalink
[Network] New-AzNetworkWatcherPacketCapture - TotalBytesPerSession wi…
Browse files Browse the repository at this point in the history
…th incorrect data type (#20504)

* resolved the TotalBytesPerSession limit issue

* suppress the warning messages of the breaking change analyzer by adding all the error in BreakingChangeIssues.csv file

* Update ChangeLog.md

Co-authored-by: Yeming Liu <[email protected]>
  • Loading branch information
v-sapanchal and isra-fel authored Jan 11, 2023
1 parent 9a3ae62 commit 7ff173a
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 6 deletions.
1 change: 1 addition & 0 deletions src/Network/Network/ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
--->

## Upcoming Release
* Fixed the incorrect type of `-TotalBytesPerSession` in `New-AzNetworkWatcherPacketCapture`

## Version 5.3.0
* Added samples for retrieving Private Link IP Configuration using 'New-AzApplicationGatewayPrivateLinkIpConfiguration' with fix [#20440]
Expand Down
2 changes: 1 addition & 1 deletion src/Network/Network/Models/PSGetPacketCaptureResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ public class PSGetPacketCaptureResult : PSChildResource
public int? BytesToCapturePerPacket { get; set; }

[Ps1Xml(Target = ViewControl.Table)]
public int? TotalBytesPerSession { get; set; }
public uint? TotalBytesPerSession { get; set; }

[Ps1Xml(Target = ViewControl.Table)]
public int? TimeLimitInSeconds { get; set; }
Expand Down
2 changes: 1 addition & 1 deletion src/Network/Network/Models/PSPacketCaptureResult.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ public class PSPacketCaptureResult : PSChildResource
public int? BytesToCapturePerPacket { get; set; }

[Ps1Xml(Target = ViewControl.Table)]
public int? TotalBytesPerSession { get; set; }
public uint? TotalBytesPerSession { get; set; }

[Ps1Xml(Target = ViewControl.Table)]
public int? TimeLimitInSeconds { get; set; }
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ public class NewAzureNetworkWatcherPacketCaptureCommand : PacketCaptureBaseCmdle
ValueFromPipelineByPropertyName = true,
HelpMessage = "Total bytes per session.")]
[ValidateNotNull]
[ValidateRange(1, int.MaxValue)]
public int? TotalBytesPerSession { get; set; }
[ValidateRange(1, uint.MaxValue)]
public uint? TotalBytesPerSession { get; set; }

[Parameter(
Mandatory = false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -111,8 +111,8 @@ public class NewAzureNetworkWatcherPacketCaptureCommandV2 : PacketCaptureBaseCmd
ValueFromPipelineByPropertyName = true,
HelpMessage = "Total bytes per session.")]
[ValidateNotNull]
[ValidateRange(1, int.MaxValue)]
public int? TotalBytesPerSession { get; set; }
[ValidateRange(1, uint.MaxValue)]
public uint? TotalBytesPerSession { get; set; }

[Parameter(
Mandatory = false,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,8 @@
"Az.Network","Microsoft.Azure.Commands.Network.Automation.GetAzureRmDdosProtectionPlan","Get-AzDdosProtectionPlan","0","3010","The property 'PublicIpAddressesText' of type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan' has been removed.","Add the property 'PublicIpAddressesText' back to type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureRmDdosProtectionPlan","New-AzDdosProtectionPlan","0","3010","The property 'PublicIpAddresses' of type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan' has been removed.","Add the property 'PublicIpAddresses' back to type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureRmDdosProtectionPlan","New-AzDdosProtectionPlan","0","3010","The property 'PublicIpAddressesText' of type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan' has been removed.","Add the property 'PublicIpAddressesText' back to type 'Microsoft.Azure.Commands.Network.Models.PSDdosProtectionPlan'."
"Az.Network","Microsoft.Azure.Commands.Network.GetAzureNetworkWatcherPacketCaptureCommand","Get-AzNetworkWatcherPacketCapture","0","3030","The generic type for 'property TotalBytesPerSession' has been changed from 'System.Nullable`1[System.Int32]' to 'System.Nullable`1[System.UInt32]'. ","Change the generic type for 'property TotalBytesPerSession' back to 'System.Nullable`1[System.Int32]'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureNetworkWatcherPacketCaptureCommand","New-AzNetworkWatcherPacketCapture","0","3030","The generic type for 'property TotalBytesPerSession' has been changed from 'System.Nullable`1[System.Int32]' to 'System.Nullable`1[System.UInt32]'. ","Change the generic type for 'property TotalBytesPerSession' back to 'System.Nullable`1[System.Int32]'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureNetworkWatcherPacketCaptureCommand","New-AzNetworkWatcherPacketCapture","0","3030","The generic type for 'parameter TotalBytesPerSession' has been changed from 'System.Nullable`1[System.Int32]' to 'System.Nullable`1[System.UInt32]'. ","Change the generic type for 'parameter TotalBytesPerSession' back to 'System.Nullable`1[System.Int32]'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureNetworkWatcherPacketCaptureCommandV2","New-AzNetworkWatcherPacketCaptureV2","0","3030","The generic type for 'property TotalBytesPerSession' has been changed from 'System.Nullable`1[System.Int32]' to 'System.Nullable`1[System.UInt32]'. ","Change the generic type for 'property TotalBytesPerSession' back to 'System.Nullable`1[System.Int32]'."
"Az.Network","Microsoft.Azure.Commands.Network.NewAzureNetworkWatcherPacketCaptureCommandV2","New-AzNetworkWatcherPacketCaptureV2","0","3030","The generic type for 'parameter TotalBytesPerSession' has been changed from 'System.Nullable`1[System.Int32]' to 'System.Nullable`1[System.UInt32]'. ","Change the generic type for 'parameter TotalBytesPerSession' back to 'System.Nullable`1[System.Int32]'."

0 comments on commit 7ff173a

Please sign in to comment.