Skip to content

Fix default parameter sets for HubBgpConnection cmdlets. Minor fixes to the help files for HubBgpConnection. #15929

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

Merged
merged 1 commit into from
Sep 23, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ namespace Microsoft.Azure.Commands.Network

[Cmdlet(VerbsCommon.New,
ResourceManager.Common.AzureRMConstants.AzurePrefix + "VirtualHubBgpConnection",
DefaultParameterSetName = CortexParameterSetNames.ByVirtualHubName,
DefaultParameterSetName = CortexParameterSetNames.ByVirtualHubName + CortexParameterSetNames.ByHubVirtualNetworkConnectionObject,
SupportsShouldProcess = true),
OutputType(typeof(PSBgpConnection))]
public class NewAzVirtualHubBgpConnectionCommand : HubBgpConnectionBaseCmdlet
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ namespace Microsoft.Azure.Commands.Network

[Cmdlet("Update",
ResourceManager.Common.AzureRMConstants.AzurePrefix + "VirtualHubBgpConnection",
DefaultParameterSetName = CortexParameterSetNames.ByVirtualHubName,
DefaultParameterSetName = CortexParameterSetNames.ByVirtualHubName + CortexParameterSetNames.ByHubVirtualNetworkConnectionObject,
SupportsShouldProcess = true),
OutputType(typeof(PSBgpConnection))]
public class UpdateAzVirtualHubBgpConnectionCommand : HubBgpConnectionBaseCmdlet
Expand Down
10 changes: 5 additions & 5 deletions src/Network/Network/help/Get-AzVirtualHubBgpConnection.md
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ This cmdlet lists all the Virtual WAN Hub BGP Connections starting with "test" u
The credentials, account, tenant, and subscription used for communication with Azure.

```yaml
Type: IAzureContextContainer
Type: Microsoft.Azure.Commands.Common.Authentication.Abstractions.Core.IAzureContextContainer
Parameter Sets: (All)
Aliases: AzContext, AzureRmContext, AzureCredential

Expand All @@ -101,7 +101,7 @@ Accept wildcard characters: False
The resource name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName, ByVirtualHubObject
Aliases: ResourceName, BgpConnectionName

Expand All @@ -116,7 +116,7 @@ Accept wildcard characters: True
The resource group name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName
Aliases:

Expand All @@ -131,7 +131,7 @@ Accept wildcard characters: False
The resource id.

```yaml
Type: String
Type: System.String
Parameter Sets: ByHubBgpConnectionResourceId
Aliases: BgpConnectionId

Expand Down Expand Up @@ -161,7 +161,7 @@ Accept wildcard characters: False
The virtual hub name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName
Aliases: ParentResourceName, ParentVirtualHubName

Expand Down
8 changes: 1 addition & 7 deletions src/Network/Network/help/New-AzVirtualHubBgpConnection.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,7 @@ The New-AzVirtualHubBgpConnection cmdlet creates a HubBgpConnection resource tha

## SYNTAX

### ByVirtualHubName (Default)
```
New-AzVirtualHubBgpConnection -PeerIp <String> -PeerAsn <UInt32> -Name <String> [-AsJob]
[-DefaultProfile <IAzureContextContainer>] [-WhatIf] [-Confirm] [<CommonParameters>]
```

### ByVirtualHubNameByHubVirtualNetworkConnectionObject
### ByVirtualHubNameByHubVirtualNetworkConnectionObject (Default)
```
New-AzVirtualHubBgpConnection -ResourceGroupName <String> -VirtualHubName <String> -PeerIp <String>
-PeerAsn <UInt32> -Name <String> -VirtualHubVnetConnection <PSHubVirtualNetworkConnection> [-AsJob]
Expand Down
50 changes: 25 additions & 25 deletions src/Network/Network/help/Remove-AzVirtualHubBgpConnection.md
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ The above will remove a Virtual WAN Hub BGP Connection using the BGP Connection
Run cmdlet in the background

```yaml
Type: SwitchParameter
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Expand All @@ -80,26 +80,11 @@ Accept pipeline input: False
Accept wildcard characters: False
```

### -Confirm
Prompts you for confirmation before running the cmdlet.

```yaml
Type: SwitchParameter
Parameter Sets: (All)
Aliases: cf

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -DefaultProfile
The credentials, account, tenant, and subscription used for communication with Azure.

```yaml
Type: IAzureContextContainer
Type: Microsoft.Azure.Commands.Common.Authentication.Abstractions.Core.IAzureContextContainer
Parameter Sets: (All)
Aliases: AzContext, AzureRmContext, AzureCredential

Expand All @@ -114,7 +99,7 @@ Accept wildcard characters: False
Do not ask for confirmation if you want to overwrite a resource

```yaml
Type: SwitchParameter
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Expand All @@ -129,7 +114,7 @@ Accept wildcard characters: False
The virtual hub bgp connection resource.

```yaml
Type: PSBgpConnection
Type: Microsoft.Azure.Commands.Network.Models.PSBgpConnection
Parameter Sets: ByHubBgpConnectionObject
Aliases: VirtualHubBgpConnection

Expand All @@ -144,7 +129,7 @@ Accept wildcard characters: False
The resource name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName, ByVirtualHubObject
Aliases: ResourceName, BgpConnectionName

Expand All @@ -159,7 +144,7 @@ Accept wildcard characters: False
Returns an object representing the item on which this operation is being performed.

```yaml
Type: SwitchParameter
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases:

Expand All @@ -174,7 +159,7 @@ Accept wildcard characters: False
The resource group name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName
Aliases:

Expand All @@ -189,7 +174,7 @@ Accept wildcard characters: False
The resource id.

```yaml
Type: String
Type: System.String
Parameter Sets: ByHubBgpConnectionResourceId
Aliases: BgpConnectionId

Expand Down Expand Up @@ -219,7 +204,7 @@ Accept wildcard characters: False
The virtual hub name.

```yaml
Type: String
Type: System.String
Parameter Sets: ByVirtualHubName
Aliases: ParentResourceName, ParentVirtualHubName

Expand All @@ -230,12 +215,27 @@ Accept pipeline input: False
Accept wildcard characters: False
```

### -Confirm
Prompts you for confirmation before running the cmdlet.

```yaml
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases: cf

Required: False
Position: Named
Default value: None
Accept pipeline input: False
Accept wildcard characters: False
```

### -WhatIf
Shows what would happen if the cmdlet runs.
The cmdlet is not run.

```yaml
Type: SwitchParameter
Type: System.Management.Automation.SwitchParameter
Parameter Sets: (All)
Aliases: wi

Expand Down
Loading