Skip to content

Commit 80f64e8

Browse files
authored
Merge pull request Azure#3321 from Azure/richrundmsft-patch-1
Update SetAzureRmDiagnosticSettingCommand.cs to better describe workspaceid parameter
2 parents 7c7c90e + 3a7e2fd commit 80f64e8

File tree

2 files changed

+24
-4
lines changed

2 files changed

+24
-4
lines changed

src/ResourceManager/Insights/Commands.Insights/Diagnostics/SetAzureRmDiagnosticSettingCommand.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ public class SetAzureRmDiagnosticSettingCommand : ManagementCmdletBase
8585
/// <summary>
8686
/// Gets or sets the OMS workspace Id
8787
/// </summary>
88-
[Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The OMS workspace Id")]
88+
[Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The resource Id of the Log Analytics workspace to send logs/metrics to")]
8989
[ValidateNotNullOrEmpty]
9090
public string WorkspaceId { get; set; }
9191

src/ResourceManager/Insights/Commands.Insights/Microsoft.Azure.Commands.Insights.dll-Help.xml

Lines changed: 23 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7047,7 +7047,7 @@ $rule2 = New-AzureRmAutoscaleRule -MetricName Requests -MetricResourceId &quot;/
70477047
<command:parameter required="false" variableLength="false" globbing="false" pipelineInput="true (ByPropertyName)" position="named">
70487048
<maml:name>WorkspaceId</maml:name>
70497049
<maml:description>
7050-
<maml:para>The Id of the workspace</maml:para>
7050+
<maml:para>The resource Id of the Log Analytics workspace to send logs/metrics to.</maml:para>
70517051
</maml:description>
70527052
<command:parameterValue required="true" variableLength="false">String</command:parameterValue>
70537053
</command:parameter>
@@ -7162,7 +7162,7 @@ $rule2 = New-AzureRmAutoscaleRule -MetricName Requests -MetricResourceId &quot;/
71627162
<command:parameter required="false" variableLength="false" globbing="false" pipelineInput="true (ByPropertyName)" position="named">
71637163
<maml:name>WorkspaceId</maml:name>
71647164
<maml:description>
7165-
<maml:para>The Id of the workspace</maml:para>
7165+
<maml:para>The resource Id of the Log Analytics workspace to send logs/metrics to.</maml:para>
71667166
</maml:description>
71677167
<command:parameterValue required="true" variableLength="false">String</command:parameterValue>
71687168
<dev:type>
@@ -7323,6 +7323,26 @@ $rule2 = New-AzureRmAutoscaleRule -MetricName Requests -MetricResourceId &quot;/
73237323
</command:commandLine>
73247324
</command:commandLines>
73257325
</command:example>
7326+
<command:example>
7327+
<maml:title>-------------------------- Enabling logs and metrics to go to a Log Analytics workspace --------------------------</maml:title>
7328+
<maml:introduction>
7329+
<maml:paragraph>PS C:\&gt;</maml:paragraph>
7330+
</maml:introduction>
7331+
<dev:code>Set-AzureRmDiagnosticSetting -ResourceId &lt;resourceId&gt; --WorkspaceId $workspaceResourceId -Enable $true</dev:code>
7332+
<dev:remarks>
7333+
<maml:para>This will enable all logs and metrics for the resource to be sent to a Log Analytics workspace. You can get the resource Id for a workspace using (Get-AzureRmOperationalInsightsWorkspace).ResourceId .</maml:para>
7334+
<maml:para />
7335+
<maml:para />
7336+
<maml:para></maml:para>
7337+
</dev:remarks>
7338+
<command:commandLines>
7339+
<command:commandLine>
7340+
<command:commandText>
7341+
<maml:para />
7342+
</command:commandText>
7343+
</command:commandLine>
7344+
</command:commandLines>
7345+
</command:example>
73267346
</command:examples>
73277347
<maml:relatedLinks>
73287348
<maml:navigationLink>
@@ -7331,4 +7351,4 @@ $rule2 = New-AzureRmAutoscaleRule -MetricName Requests -MetricResourceId &quot;/
73317351
</maml:navigationLink>
73327352
</maml:relatedLinks>
73337353
</command:command>
7334-
</helpItems>
7354+
</helpItems>

0 commit comments

Comments
 (0)