IQuotaOperations.BeginCreateOrUpdateWithHttpMessagesAsync 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.
public System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.Management.Quota.Models.CurrentQuotaLimitBase>> BeginCreateOrUpdateWithHttpMessagesAsync (string resourceName, string scope, Microsoft.Azure.Management.Quota.Models.QuotaProperties properties = default, System.Collections.Generic.Dictionary<string,System.Collections.Generic.List<string>> customHeaders = default, System.Threading.CancellationToken cancellationToken = default);
abstract member BeginCreateOrUpdateWithHttpMessagesAsync : string * string * Microsoft.Azure.Management.Quota.Models.QuotaProperties * System.Collections.Generic.Dictionary<string, System.Collections.Generic.List<string>> * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.Azure.AzureOperationResponse<Microsoft.Azure.Management.Quota.Models.CurrentQuotaLimitBase>>
Public Function BeginCreateOrUpdateWithHttpMessagesAsync (resourceName As String, scope As String, Optional properties As QuotaProperties = Nothing, Optional customHeaders As Dictionary(Of String, List(Of String)) = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of AzureOperationResponse(Of CurrentQuotaLimitBase))
Parameters
- 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.
- scope
- String
The target Azure resource URI. For example,
/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/qms-test/providers/Microsoft.Batch/batchAccounts/testAccount/
.
This is the target Azure resource URI for the List GET operation.
If a {resourceName}
is added after /quotas
, then it's the
target Azure resource URI in the GET operation for the specific
resource.
- properties
- QuotaProperties
Quota properties for the specified resource, based on the API called, Quotas or Usages.
- customHeaders
- Dictionary<String,List<String>>
The headers that will be added to request.
- cancellationToken
- CancellationToken
The cancellation token.
Returns
Exceptions
Thrown when the operation returned an invalid status code
Thrown when unable to deserialize the response
Thrown when a required parameter is null