CurrentQuotaLimitBaseCollection.CreateOrUpdateAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Create or update the quota limit for the specified resource with the requested value. To update the quota, follow these steps:
- Use the GET operation for quotas and usages to determine how much quota remains for the specific resource and to calculate the new quota limit. These steps are detailed in this example.
- Use this PUT operation to update the quota limit. Please check the URI in location header for the detailed status of the request.
- Request Path: /{scope}/providers/Microsoft.Quota/quotas/{resourceName}
- Operation Id: Quota_CreateOrUpdate
- Default Api Version: 2023-06-01-preview
- Resource: CurrentQuotaLimitBaseResource
public virtual System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Quota.CurrentQuotaLimitBaseResource>> CreateOrUpdateAsync (Azure.WaitUntil waitUntil, string resourceName, Azure.ResourceManager.Quota.CurrentQuotaLimitBaseData data, System.Threading.CancellationToken cancellationToken = default);
abstract member CreateOrUpdateAsync : Azure.WaitUntil * string * Azure.ResourceManager.Quota.CurrentQuotaLimitBaseData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Quota.CurrentQuotaLimitBaseResource>>
override this.CreateOrUpdateAsync : Azure.WaitUntil * string * Azure.ResourceManager.Quota.CurrentQuotaLimitBaseData * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Azure.ResourceManager.ArmOperation<Azure.ResourceManager.Quota.CurrentQuotaLimitBaseResource>>
Public Overridable Function CreateOrUpdateAsync (waitUntil As WaitUntil, resourceName As String, data As CurrentQuotaLimitBaseData, Optional cancellationToken As CancellationToken = Nothing) As Task(Of ArmOperation(Of CurrentQuotaLimitBaseResource))
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.
- resourceName
- String
Resource name for a given resource provider. For example:
- SKU name for Microsoft.Compute
- SKU or TotalLowPriorityCores for Microsoft.MachineLearningServices For Microsoft.Network PublicIPAddresses.
Quota request payload.
- cancellationToken
- CancellationToken
The cancellation token to use.
Returns
Exceptions
resourceName
is an empty string, and was expected to be non-empty.
resourceName
or data
is null.
Applies to
Azure SDK for .NET