Skip to content

Commit ba0319a

Browse files
authored
Merge pull request Azure#9133 from niander/docsmonitor
Fixed Monitor help examples with incorrect parameter names (plural)
2 parents 43a0091 + 95cef7e commit ba0319a

File tree

54 files changed

+309
-226
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+309
-226
lines changed

src/Monitor/Monitor/ChangeLog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
- Additional information about change #1
1919
-->
2020
## Upcoming Release
21+
* Fixed incorrect parameter names in help examples
2122

2223
## Version 1.2.0
2324
* New cmdlets for SQR API (Scheduled Query Rule)

src/Monitor/Monitor/help/Add-AzAutoscaleSetting.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: 7436F31F-9DCB-4365-BA6D-41BDB5D7FCB6
@@ -42,11 +42,11 @@ PS C:\>$Rule1 = New-AzAutoscaleRule -MetricName "Requests" -MetricResourceId "/s
4242
4343
PS C:\> $Rule2 = New-AzAutoscaleRule -MetricName "Requests" -MetricResourceId "/subscriptions/b93fb07a-6f93-30be-bf3e-4f0deca15f4f/resourceGroups/Default-Web-EastUS/providers/microsoft.web/sites/mywebsite" -Operator GreaterThan -MetricStatistic Average -Threshold 10 -TimeGrain 00:01:00 -ScaleActionCooldown 00:10:00 -ScaleActionDirection Increase -ScaleActionScaleType ChangeCount -ScaleActionValue "2"
4444
45-
PS C:\> $Profile1 = New-AzAutoscaleProfile -DefaultCapacity "1" -MaximumCapacity "10" -MinimumCapacity "1" -StartTimeWindow 2015-03-05T14:00:00 -EndTimeWindow 2015-03-05T14:30:00 -TimeWindowTimeZone GMT -Rules $Rule1, $Rule2 -Name "adios"
45+
PS C:\> $Profile1 = New-AzAutoscaleProfile -DefaultCapacity "1" -MaximumCapacity "10" -MinimumCapacity "1" -StartTimeWindow 2015-03-05T14:00:00 -EndTimeWindow 2015-03-05T14:30:00 -TimeWindowTimeZone GMT -Rule $Rule1, $Rule2 -Name "adios"
4646
47-
PS C:\> $Profile2 = New-AzAutoscaleProfile -DefaultCapacity "1" -MaximumCapacity "10" -MinimumCapacity "1" -Rules $Rule1, $Rule2 -Name "SecondProfileName" -RecurrenceFrequency Minute -ScheduleDays "1", "2", "3" -ScheduleHours 5, 10, 15 -ScheduleMinutes 15, 30, 45 -ScheduleTimeZone GMT
47+
PS C:\> $Profile2 = New-AzAutoscaleProfile -DefaultCapacity "1" -MaximumCapacity "10" -MinimumCapacity "1" -Rule $Rule1, $Rule2 -Name "SecondProfileName" -RecurrenceFrequency Minute -ScheduleDay "1", "2", "3" -ScheduleHour 5, 10, 15 -ScheduleMinute 15, 30, 45 -ScheduleTimeZone GMT
4848
49-
PS C:\> Add-AzAutoscaleSetting -Location "East US" -Name "MySetting" -ResourceGroupName "Default-Web-EastUS" -TargetResourceId "/subscriptions/b93fb07a-6f93-30be-bf3e-4f0deca15f4f/resourceGroups/Default-Web-EastUS/providers/microsoft.web/serverFarms/DefaultServerFarm" -AutoscaleProfiles $Profile1, $Profile2
49+
PS C:\> Add-AzAutoscaleSetting -Location "East US" -Name "MySetting" -ResourceGroupName "Default-Web-EastUS" -TargetResourceId "/subscriptions/b93fb07a-6f93-30be-bf3e-4f0deca15f4f/resourceGroups/Default-Web-EastUS/providers/microsoft.web/serverFarms/DefaultServerFarm" -AutoscaleProfile $Profile1, $Profile2
5050
```
5151

5252
The first two commands use New-AzAutoscaleRule to create two Autoscale rules, $Rule1 and $Rule2.
@@ -221,7 +221,7 @@ Accept wildcard characters: False
221221
```
222222
223223
### CommonParameters
224-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
224+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
225225
226226
## INPUTS
227227

src/Monitor/Monitor/help/Add-AzLogProfile.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: 18D5B95E-4CF1-4C79-AE8B-9F4DA49B46A9
@@ -176,7 +176,7 @@ Accept wildcard characters: False
176176
```
177177
178178
### CommonParameters
179-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
179+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
180180
181181
## INPUTS
182182

src/Monitor/Monitor/help/Add-AzMetricAlertRule.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: A90564B5-57D7-48EB-976D-38C03D930289
@@ -297,7 +297,7 @@ Accept wildcard characters: False
297297
```
298298
299299
### CommonParameters
300-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
300+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
301301
302302
## INPUTS
303303

src/Monitor/Monitor/help/Add-AzMetricAlertRuleV2.md

Lines changed: 40 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -136,19 +136,19 @@ Name : AlertWithDim
136136
Type : Microsoft.Insights/metricAlerts
137137
Location : global
138138
Tags :
139-
140139
```
141140

142141
To create a more complex metric alert rule like the ones that involve selecting dimension values or have multiple criteria, you can use the helper cmdlets New-AzMetricAlertRuleV2DimensionSelection and New-AzMetricAlertRuleV2Criteria.
143142

144143
Above set of cmdlets will create a metric alert rule with dimensions.
144+
145145
## PARAMETERS
146146

147147
### -ActionGroup
148148
The Action Group for rule
149149

150150
```yaml
151-
Type: ActivityLogAlertActionGroup[]
151+
Type: Microsoft.Azure.Management.Monitor.Models.ActivityLogAlertActionGroup[]
152152
Parameter Sets: (All)
153153
Aliases: Actions
154154

@@ -174,26 +174,11 @@ Accept pipeline input: True (ByPropertyName, ByValue)
174174
Accept wildcard characters: False
175175
```
176176
177-
### -Confirm
178-
Prompts you for confirmation before running the cmdlet.
179-
180-
```yaml
181-
Type: SwitchParameter
182-
Parameter Sets: (All)
183-
Aliases: cf
184-
185-
Required: False
186-
Position: Named
187-
Default value: None
188-
Accept pipeline input: False
189-
Accept wildcard characters: False
190-
```
191-
192177
### -DefaultProfile
193178
The credentials, account, tenant, and subscription used for communication with Azure.
194179
195180
```yaml
196-
Type: IAzureContextContainer
181+
Type: Microsoft.Azure.Commands.Common.Authentication.Abstractions.Core.IAzureContextContainer
197182
Parameter Sets: (All)
198183
Aliases: AzContext, AzureRmContext, AzureCredential
199184

@@ -208,7 +193,7 @@ Accept wildcard characters: False
208193
The description of the metric alert rule
209194
210195
```yaml
211-
Type: String
196+
Type: System.String
212197
Parameter Sets: (All)
213198
Aliases:
214199

@@ -223,7 +208,7 @@ Accept wildcard characters: False
223208
The disable rule (status) flag
224209
225210
```yaml
226-
Type: SwitchParameter
211+
Type: System.Management.Automation.SwitchParameter
227212
Parameter Sets: (All)
228213
Aliases:
229214

@@ -238,7 +223,7 @@ Accept wildcard characters: False
238223
The evaluation frequency for rule
239224
240225
```yaml
241-
Type: TimeSpan
226+
Type: System.TimeSpan
242227
Parameter Sets: (All)
243228
Aliases: EvaluationFrequency
244229

@@ -253,7 +238,7 @@ Accept wildcard characters: False
253238
The name of metric alert rule
254239
255240
```yaml
256-
Type: String
241+
Type: System.String
257242
Parameter Sets: (All)
258243
Aliases:
259244

@@ -268,7 +253,7 @@ Accept wildcard characters: False
268253
The Resource Group Name
269254
270255
```yaml
271-
Type: String
256+
Type: System.String
272257
Parameter Sets: (All)
273258
Aliases: ResourceGroup
274259

@@ -283,7 +268,7 @@ Accept wildcard characters: False
283268
The severity for the metric alert rule
284269
285270
```yaml
286-
Type: Int32
271+
Type: System.Int32
287272
Parameter Sets: (All)
288273
Aliases:
289274

@@ -298,7 +283,7 @@ Accept wildcard characters: False
298283
The target resource id for rule
299284
300285
```yaml
301-
Type: String
286+
Type: System.String
302287
Parameter Sets: CreateAlertByResourceId
303288
Aliases:
304289

@@ -313,7 +298,7 @@ Accept wildcard characters: False
313298
The target resource region for rule
314299
315300
```yaml
316-
Type: String
301+
Type: System.String
317302
Parameter Sets: CreateAlertByScopes
318303
Aliases:
319304

@@ -328,7 +313,7 @@ Accept wildcard characters: False
328313
The target resource scope for rule
329314
330315
```yaml
331-
Type: String[]
316+
Type: System.String[]
332317
Parameter Sets: CreateAlertByScopes
333318
Aliases: Scopes
334319

@@ -343,7 +328,7 @@ Accept wildcard characters: False
343328
The target resource type for rule
344329
345330
```yaml
346-
Type: String
331+
Type: System.String
347332
Parameter Sets: CreateAlertByScopes
348333
Aliases:
349334

@@ -354,14 +339,28 @@ Accept pipeline input: True (ByPropertyName)
354339
Accept wildcard characters: False
355340
```
356341
357-
### -WhatIf
358-
Shows what would happen if the cmdlet runs.
359-
The cmdlet is not run.
342+
### -WindowSize
343+
The window size for rule
360344
361345
```yaml
362-
Type: SwitchParameter
346+
Type: System.TimeSpan
363347
Parameter Sets: (All)
364-
Aliases: wi
348+
Aliases:
349+
350+
Required: True
351+
Position: Named
352+
Default value: None
353+
Accept pipeline input: True (ByPropertyName)
354+
Accept wildcard characters: False
355+
```
356+
357+
### -Confirm
358+
Prompts you for confirmation before running the cmdlet.
359+
360+
```yaml
361+
Type: System.Management.Automation.SwitchParameter
362+
Parameter Sets: (All)
363+
Aliases: cf
365364

366365
Required: False
367366
Position: Named
@@ -370,24 +369,24 @@ Accept pipeline input: False
370369
Accept wildcard characters: False
371370
```
372371
373-
### -WindowSize
374-
The window size for rule
372+
### -WhatIf
373+
Shows what would happen if the cmdlet runs.
374+
The cmdlet is not run.
375375
376376
```yaml
377-
Type: TimeSpan
377+
Type: System.Management.Automation.SwitchParameter
378378
Parameter Sets: (All)
379-
Aliases:
379+
Aliases: wi
380380

381-
Required: True
381+
Required: False
382382
Position: Named
383383
Default value: None
384-
Accept pipeline input: True (ByPropertyName)
384+
Accept pipeline input: False
385385
Accept wildcard characters: False
386386
```
387387
388388
### CommonParameters
389-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable.
390-
For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
389+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
391390
392391
## INPUTS
393392

src/Monitor/Monitor/help/Add-AzWebtestAlertRule.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: FBAE5F75-1E28-4F1C-A9ED-20075FFD4AC7
@@ -253,7 +253,7 @@ Accept wildcard characters: False
253253
```
254254
255255
### CommonParameters
256-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
256+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
257257
258258
## INPUTS
259259

src/Monitor/Monitor/help/Az.Monitor.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ Gets a log profile.
6363
Gets the metric values of a resource.
6464

6565
### [Get-AzMetricAlertRuleV2](Get-AzMetricAlertRuleV2.md)
66-
Gets V2 (non-classic) metric alert rules.
66+
Gets V2 (non-classic) metric alert rules
6767

6868
### [Get-AzMetricDefinition](Get-AzMetricDefinition.md)
6969
Gets metric definitions.
@@ -99,7 +99,7 @@ Creates an Autoscale rule.
9999
Creates an Autoscale webhook.
100100

101101
### [New-AzMetricAlertRuleV2Criteria](New-AzMetricAlertRuleV2Criteria.md)
102-
Creates a local criteria object that can be used to create a new metric alert.
102+
Creates a local criteria object that can be used to create a new metric alert
103103

104104
### [New-AzMetricAlertRuleV2DimensionSelection](New-AzMetricAlertRuleV2DimensionSelection.md)
105105
Creates a local dimension selection object that can be used to construct a metric alert criteria.

src/Monitor/Monitor/help/Disable-AzActivityLogAlert.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: B5F2388E-0136-4F8A-8577-67CE2A45671E
@@ -55,7 +55,7 @@ This command disables an activity log alert called alert1. For this it uses a PS
5555

5656
### Example 3: Disable the ActivityLogAlert using the ResourceId parameter
5757
```
58-
PS C:\>Find-AzResource -ResourceGroupEquals "myResourceGroup" -ResourceNameEquals "myLogAlert" | Disable-AzActivityLogAlert
58+
PS C:\>Get-AzResource -ResourceGroupName "myResourceGroup" -Name "myLogAlert" | Disable-AzActivityLogAlert
5959
```
6060

6161
This command disables the ActivityLogAlert using the ResourceId parameter from the pipe.
@@ -168,7 +168,7 @@ Accept wildcard characters: False
168168
```
169169
170170
### CommonParameters
171-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
171+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
172172
173173
## INPUTS
174174

src/Monitor/Monitor/help/Enable-AzActivityLogAlert.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: B5F2388E-0136-4F8A-8577-67CE2A45671E
@@ -54,7 +54,7 @@ This command enables an activity log alert called alert1. For this it uses a PSA
5454

5555
### Example 3: Enable the ActivityLogAlert using the ResourceId parameter
5656
```
57-
PS C:\>Find-AzResource -ResourceGroupEquals "myResourceGroup" -ResourceNameEquals "myLogAlert" | Enable-AzActivityLogAlert
57+
PS C:\>Get-AzResource -ResourceGroupName "myResourceGroup" -Name "myLogAlert" | Enable-AzActivityLogAlert
5858
```
5959

6060
This command enables the ActivityLogAlert using the ResourceId parameter from the pipe.
@@ -167,7 +167,7 @@ Accept wildcard characters: False
167167
```
168168
169169
### CommonParameters
170-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
170+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
171171
172172
## INPUTS
173173

src/Monitor/Monitor/help/Get-AzActionGroup.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: 1CA26790-C791-4BFD-B986-70F28E3B095B
@@ -110,7 +110,7 @@ Accept wildcard characters: False
110110
```
111111
112112
### CommonParameters
113-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
113+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
114114
115115
## INPUTS
116116

src/Monitor/Monitor/help/Get-AzActivityLogAlert.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
---
1+
---
22
external help file: Microsoft.Azure.PowerShell.Cmdlets.Monitor.dll-Help.xml
33
Module Name: Az.Monitor
44
ms.assetid: 85492E00-3776-4F20-A444-9C28CC6154B7
@@ -112,7 +112,7 @@ Accept wildcard characters: False
112112
```
113113
114114
### CommonParameters
115-
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see about_CommonParameters (http://go.microsoft.com/fwlink/?LinkID=113216).
115+
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable, -InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose, -WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](http://go.microsoft.com/fwlink/?LinkID=113216).
116116
117117
## INPUTS
118118

0 commit comments

Comments
 (0)