/// <summary> /// Regenerates the shared keys for a Log Analytics Workspace. These keys are /// used to connect Microsoft Operational Insights agents to the workspace. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> /// <param name='cancellationToken'> /// The cancellation token. /// </param> public static async Task <SharedKeys> RegenerateAsync(this ISharedKeysOperations operations, string resourceGroupName, string workspaceName, CancellationToken cancellationToken = default(CancellationToken)) { using (var _result = await operations.RegenerateWithHttpMessagesAsync(resourceGroupName, workspaceName, null, cancellationToken).ConfigureAwait(false)) { return(_result.Body); } }
/// <summary> /// Regenerates the shared keys for a Log Analytics Workspace. These keys are /// used to connect Microsoft Operational Insights agents to the workspace. /// </summary> /// <param name='operations'> /// The operations group for this extension method. /// </param> /// <param name='resourceGroupName'> /// The name of the resource group. The name is case insensitive. /// </param> /// <param name='workspaceName'> /// The name of the workspace. /// </param> public static SharedKeys Regenerate(this ISharedKeysOperations operations, string resourceGroupName, string workspaceName) { return(operations.RegenerateAsync(resourceGroupName, workspaceName).GetAwaiter().GetResult()); }