Share via


MonitorWorkspaceResourceCollection.CreateOrUpdate Method

Definition

Create or update a workspace

  • Request Path: /subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Monitor/accounts/{azureMonitorWorkspaceName}
  • Operation Id: AzureMonitorWorkspaces_Create
  • Default Api Version: 2023-04-03
  • Resource: MonitorWorkspaceResource
public virtual Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Monitor.MonitorWorkspaceResource> CreateOrUpdate (Azure.WaitUntil waitUntil, string azureMonitorWorkspaceName, Azure.ResourceManager.Monitor.MonitorWorkspaceResourceData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.Monitor.MonitorWorkspaceResourceData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Monitor.MonitorWorkspaceResource>
override this.CreateOrUpdate : Azure.WaitUntil * string * Azure.ResourceManager.Monitor.MonitorWorkspaceResourceData * System.Threading.CancellationToken -> Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Monitor.MonitorWorkspaceResource>
Public Overridable Function CreateOrUpdate (waitUntil As WaitUntil, azureMonitorWorkspaceName As String, data As MonitorWorkspaceResourceData, Optional cancellationToken As CancellationToken = Nothing) As ArmOperation(Of MonitorWorkspaceResource)

Parameters

waitUntil
WaitUntil

Completed if the method should wait to return until the long-running operation has completed on the service; Started if it should return after starting the operation. For more information on long-running operations, please see Azure.Core Long-Running Operation samples.

azureMonitorWorkspaceName
String

The name of the Azure Monitor workspace. The name is case insensitive.

data
MonitorWorkspaceResourceData

Properties that need to be specified to create a new workspace.

cancellationToken
CancellationToken

The cancellation token to use.

Returns

Exceptions

azureMonitorWorkspaceName is an empty string, and was expected to be non-empty.

azureMonitorWorkspaceName or data is null.

Applies to