From 1339c694cb2ac7addb13fbcc0d1371460a042d55 Mon Sep 17 00:00:00 2001
From: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com>
Date: Tue, 21 Jan 2025 23:24:09 -0800
Subject: [PATCH] [Automation] Generate Fluent Lite from Swagger
quota#package-2024-12-18-preview (#43867)
---
.../azure-resourcemanager-quota/CHANGELOG.md | 216 ++-
.../azure-resourcemanager-quota/README.md | 4 +-
.../azure-resourcemanager-quota/SAMPLE.md | 433 +----
sdk/quota/azure-resourcemanager-quota/pom.xml | 2 +-
.../resourcemanager/quota/QuotaManager.java | 65 +-
.../quota/fluent/AzureQuotaExtensionApi.java | 26 +-
.../quota/fluent/GroupQuotaLimitsClient.java | 103 +-
.../GroupQuotaLimitsRequestsClient.java | 162 +-
.../GroupQuotaLocationSettingsClient.java | 339 ----
...aSubscriptionAllocationRequestsClient.java | 245 +--
...oupQuotaSubscriptionAllocationsClient.java | 105 +-
.../quota/fluent/GroupQuotaUsagesClient.java | 55 -
.../fluent/models/GroupQuotaLimitInner.java | 166 --
...ner.java => GroupQuotaLimitListInner.java} | 48 +-
.../models/GroupQuotaUsagesBaseName.java | 110 --
.../fluent/models/GroupQuotasEntityInner.java | 18 +-
.../SubscriptionQuotaAllocationsInner.java | 170 --
...ubscriptionQuotaAllocationsListInner.java} | 44 +-
.../AzureQuotaExtensionApiImpl.java | 62 +-
...Impl.java => GroupQuotaLimitListImpl.java} | 17 +-
.../GroupQuotaLimitsClientImpl.java | 461 +-----
.../implementation/GroupQuotaLimitsImpl.java | 39 +-
.../GroupQuotaLimitsRequestsClientImpl.java | 671 ++------
.../GroupQuotaLimitsRequestsImpl.java | 37 +-
.../GroupQuotaLocationSettingsClientImpl.java | 1440 -----------------
.../GroupQuotaLocationSettingsImpl.java | 112 --
...scriptionAllocationRequestsClientImpl.java | 1131 +++++--------
...otaSubscriptionAllocationRequestsImpl.java | 75 +-
...uotaSubscriptionAllocationsClientImpl.java | 463 +-----
...GroupQuotaSubscriptionAllocationsImpl.java | 41 +-
.../GroupQuotaUsagesClientImpl.java | 319 ----
.../implementation/GroupQuotaUsagesImpl.java | 49 -
.../GroupQuotasEnforcementResponseImpl.java | 50 -
.../implementation/GroupQuotasEntityImpl.java | 4 +-
.../implementation/ResourceUsagesImpl.java | 49 -
...SubscriptionQuotaAllocationsListImpl.java} | 16 +-
.../quota/models/AdditionalAttributes.java | 133 --
.../models/AdditionalAttributesPatch.java | 126 --
.../quota/models/EnforcementState.java | 56 -
.../quota/models/EnvironmentType.java | 51 -
.../quota/models/GroupQuotaDetails.java | 101 +-
.../quota/models/GroupQuotaLimit.java | 89 +-
.../quota/models/GroupQuotaLimitList.java | 107 +-
...ava => GroupQuotaLimitListProperties.java} | 64 +-
.../models/GroupQuotaLimitProperties.java | 199 +++
.../quota/models/GroupQuotaLimits.java | 99 +-
.../models/GroupQuotaLimitsRequests.java | 79 +-
.../models/GroupQuotaLocationSettings.java | 208 ---
...upQuotaSubscriptionAllocationRequests.java | 160 +-
.../GroupQuotaSubscriptionAllocations.java | 100 +-
.../GroupQuotaSubscriptionIdProperties.java | 16 +-
.../quota/models/GroupQuotaUsages.java | 50 -
.../quota/models/GroupQuotaUsagesBase.java | 197 ---
.../GroupQuotasEnforcementListResponse.java | 117 --
.../GroupQuotasEnforcementResponse.java | 55 -
...upQuotasEnforcementResponseProperties.java | 130 --
.../quota/models/GroupQuotasEntity.java | 5 +-
.../quota/models/GroupQuotasEntityBase.java | 40 +-
.../models/GroupQuotasEntityBasePatch.java | 41 +-
.../quota/models/GroupQuotasEntityPatch.java | 16 +-
.../GroupQuotasEntityPatchProperties.java | 96 ++
.../models/GroupQuotasEntityProperties.java | 95 ++
.../quota/models/GroupingId.java | 124 --
.../quota/models/GroupingIdType.java | 51 -
.../quota/models/ResourceUsages.java | 55 -
.../models/SubscriptionQuotaAllocations.java | 92 +-
.../SubscriptionQuotaAllocationsList.java | 108 +-
...riptionQuotaAllocationsListProperties.java | 134 ++
...ubscriptionQuotaAllocationsProperties.java | 150 ++
.../models/SubscriptionQuotaDetails.java | 51 +-
.../proxy-config.json | 2 +-
.../generated/GroupQuotaLimitsGetSamples.java | 26 -
.../GroupQuotaLimitsListSamples.java | 8 +-
...otaLimitsRequestCreateOrUpdateSamples.java | 26 -
.../GroupQuotaLimitsRequestGetSamples.java | 2 +-
.../GroupQuotaLimitsRequestListSamples.java | 2 +-
.../GroupQuotaLimitsRequestUpdateSamples.java | 22 +-
...LocationSettingsCreateOrUpdateSamples.java | 51 -
.../GroupQuotaLocationSettingsGetSamples.java | 26 -
...GroupQuotaLocationSettingsListSamples.java | 26 -
...oupQuotaLocationSettingsUpdateSamples.java | 32 -
...QuotaSubscriptionAllocationGetSamples.java | 26 -
...uotaSubscriptionAllocationListSamples.java | 6 +-
...llocationRequestCreateOrUpdateSamples.java | 32 -
...bscriptionAllocationRequestGetSamples.java | 4 +-
...scriptionAllocationRequestListSamples.java | 2 +-
...riptionAllocationRequestUpdateSamples.java | 21 +-
...upQuotaSubscriptionRequestsGetSamples.java | 2 +-
...pQuotaSubscriptionRequestsListSamples.java | 2 +-
...otaSubscriptionsCreateOrUpdateSamples.java | 2 +-
.../GroupQuotaSubscriptionsDeleteSamples.java | 2 +-
.../GroupQuotaSubscriptionsGetSamples.java | 2 +-
.../GroupQuotaSubscriptionsListSamples.java | 2 +-
.../GroupQuotaSubscriptionsUpdateSamples.java | 2 +-
.../GroupQuotaUsagesListSamples.java | 26 -
.../GroupQuotasCreateOrUpdateSamples.java | 16 +-
.../generated/GroupQuotasDeleteSamples.java | 2 +-
.../generated/GroupQuotasGetSamples.java | 2 +-
.../generated/GroupQuotasListSamples.java | 2 +-
.../generated/GroupQuotasUpdateSamples.java | 15 +-
.../generated/QuotaCreateOrUpdateSamples.java | 8 +-
.../quota/generated/QuotaGetSamples.java | 4 +-
.../quota/generated/QuotaListSamples.java | 6 +-
.../generated/QuotaOperationListSamples.java | 2 +-
.../QuotaRequestStatusGetSamples.java | 6 +-
.../QuotaRequestStatusListSamples.java | 2 +-
.../quota/generated/QuotaUpdateSamples.java | 4 +-
.../quota/generated/UsagesGetSamples.java | 4 +-
.../quota/generated/UsagesListSamples.java | 6 +-
.../AdditionalAttributesPatchTests.java | 35 -
.../generated/AdditionalAttributesTests.java | 35 -
...AllocatedQuotaToSubscriptionListTests.java | 16 +-
.../AllocatedToSubscriptionTests.java | 12 +-
.../CurrentQuotaLimitBaseInnerTests.java | 16 +-
.../CurrentUsagesBaseInnerTests.java | 22 +-
.../generated/GroupQuotaDetailsNameTests.java | 2 +-
.../generated/GroupQuotaDetailsTests.java | 19 +-
.../generated/GroupQuotaLimitInnerTests.java | 34 -
.../GroupQuotaLimitListInnerTests.java | 47 +
.../GroupQuotaLimitListPropertiesTests.java | 36 +
.../generated/GroupQuotaLimitListTests.java | 37 -
.../GroupQuotaLimitPropertiesTests.java | 32 +
.../quota/generated/GroupQuotaLimitTests.java | 34 +
...upQuotaLimitsGetWithResponseMockTests.java | 42 -
.../GroupQuotaLimitsListMockTests.java | 41 -
...pQuotaLimitsListWithResponseMockTests.java | 41 +
...oupQuotaLimitsRequestsUpdateMockTests.java | 53 +
.../quota/generated/GroupQuotaListTests.java | 59 +-
...upQuotaRequestBasePropertiesNameTests.java | 2 +-
.../GroupQuotaRequestBasePropertiesTests.java | 20 +-
.../generated/GroupQuotaRequestBaseTests.java | 19 +-
...tionAllocationRequestsUpdateMockTests.java | 58 +
...aSubscriptionAllocationsListMockTests.java | 40 -
...AllocationsListWithResponseMockTests.java} | 16 +-
.../GroupQuotaSubscriptionIdInnerTests.java | 9 +-
.../GroupQuotaSubscriptionIdListTests.java | 10 +-
...oupQuotaSubscriptionIdPropertiesTests.java | 8 +-
...taSubscriptionRequestStatusInnerTests.java | 14 +-
...otaSubscriptionRequestStatusListTests.java | 25 +-
...scriptionRequestStatusPropertiesTests.java | 14 +-
...ptionRequestsGetWithResponseMockTests.java | 8 +-
...uotaSubscriptionRequestsListMockTests.java | 8 +-
...aSubscriptionsCreateOrUpdateMockTests.java | 4 +-
...SubscriptionsGetWithResponseMockTests.java | 6 +-
.../GroupQuotaSubscriptionsListMockTests.java | 6 +-
...roupQuotaSubscriptionsUpdateMockTests.java | 6 +-
.../GroupQuotaUsagesBaseNameTests.java | 25 -
.../generated/GroupQuotaUsagesBaseTests.java | 32 -
.../GroupQuotaUsagesListMockTests.java | 41 -
.../GroupQuotasCreateOrUpdateMockTests.java | 21 +-
.../GroupQuotasEntityBasePatchTests.java | 27 +-
.../generated/GroupQuotasEntityBaseTests.java | 27 +-
.../GroupQuotasEntityInnerTests.java | 25 +-
...GroupQuotasEntityPatchPropertiesTests.java | 27 +
.../GroupQuotasEntityPatchTests.java | 27 +-
.../GroupQuotasEntityPropertiesTests.java | 26 +
.../GroupQuotasGetWithResponseMockTests.java | 15 +-
.../generated/GroupQuotasListMockTests.java | 15 +-
.../generated/GroupQuotasUpdateMockTests.java | 23 +-
.../quota/generated/GroupingIdTests.java | 28 -
.../quota/generated/LimitObjectTests.java | 8 +-
.../generated/LroResponseInnerTests.java | 2 +-
.../generated/LroResponsePropertiesTests.java | 2 +-
.../generated/OperationDisplayTests.java | 29 +-
.../quota/generated/OperationListTests.java | 63 +-
.../OperationResponseInnerTests.java | 38 +-
...ocationRequestBasePropertiesNameTests.java | 2 +-
...aAllocationRequestBasePropertiesTests.java | 12 +-
.../QuotaAllocationRequestBaseTests.java | 12 +-
.../quota/generated/QuotaLimitsTests.java | 36 +-
.../QuotaOperationsListMockTests.java | 14 +-
.../quota/generated/QuotaPropertiesTests.java | 16 +-
.../QuotasCreateOrUpdateMockTests.java | 16 +-
.../QuotasGetWithResponseMockTests.java | 11 +-
.../quota/generated/QuotasListMockTests.java | 8 +-
.../quota/generated/ResourceNameTests.java | 8 +-
.../generated/ResourceUsageListTests.java | 39 -
.../generated/ResourceUsagesInnerTests.java | 34 -
.../quota/generated/SubRequestTests.java | 14 +-
...ubscriptionQuotaAllocationsInnerTests.java | 30 -
...riptionQuotaAllocationsListInnerTests.java | 42 +
...onQuotaAllocationsListPropertiesTests.java | 41 +
...SubscriptionQuotaAllocationsListTests.java | 37 -
...iptionQuotaAllocationsPropertiesTests.java | 30 +
.../SubscriptionQuotaAllocationsTests.java | 30 +
.../SubscriptionQuotaDetailsNameTests.java | 5 +-
.../SubscriptionQuotaDetailsTests.java | 12 +-
.../UsagesGetWithResponseMockTests.java | 12 +-
.../quota/generated/UsagesLimitsTests.java | 50 +-
.../quota/generated/UsagesListMockTests.java | 12 +-
.../quota/generated/UsagesObjectTests.java | 8 +-
.../generated/UsagesPropertiesTests.java | 22 +-
192 files changed, 3391 insertions(+), 9524 deletions(-)
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLocationSettingsClient.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaUsagesClient.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitInner.java
rename sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/{ResourceUsagesInner.java => GroupQuotaLimitListInner.java} (66%)
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaUsagesBaseName.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsInner.java
rename sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/{GroupQuotasEnforcementResponseInner.java => SubscriptionQuotaAllocationsListInner.java} (66%)
rename sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/{GroupQuotaLimitImpl.java => GroupQuotaLimitListImpl.java} (65%)
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsClientImpl.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsImpl.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaUsagesClientImpl.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaUsagesImpl.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotasEnforcementResponseImpl.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/ResourceUsagesImpl.java
rename sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/{SubscriptionQuotaAllocationsImpl.java => SubscriptionQuotaAllocationsListImpl.java} (68%)
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/AdditionalAttributes.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/AdditionalAttributesPatch.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/EnforcementState.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/EnvironmentType.java
rename sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/{ResourceUsageList.java => GroupQuotaLimitListProperties.java} (50%)
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotaLimitProperties.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotaLocationSettings.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotaUsages.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotaUsagesBase.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotasEnforcementListResponse.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotasEnforcementResponse.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotasEnforcementResponseProperties.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotasEntityPatchProperties.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupQuotasEntityProperties.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupingId.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/GroupingIdType.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/ResourceUsages.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/SubscriptionQuotaAllocationsListProperties.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/models/SubscriptionQuotaAllocationsProperties.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsGetSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsRequestCreateOrUpdateSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLocationSettingsCreateOrUpdateSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLocationSettingsGetSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLocationSettingsListSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaLocationSettingsUpdateSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaSubscriptionAllocationGetSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaSubscriptionAllocationRequestCreateOrUpdateSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/samples/java/com/azure/resourcemanager/quota/generated/GroupQuotaUsagesListSamples.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/AdditionalAttributesPatchTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/AdditionalAttributesTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitInnerTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitListInnerTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitListPropertiesTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitListTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitPropertiesTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsGetWithResponseMockTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsListMockTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsListWithResponseMockTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaLimitsRequestsUpdateMockTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaSubscriptionAllocationRequestsUpdateMockTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaSubscriptionAllocationsListMockTests.java
rename sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/{GroupQuotaSubscriptionAllocationsGetWithResponseMockTests.java => GroupQuotaSubscriptionAllocationsListWithResponseMockTests.java} (58%)
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaUsagesBaseNameTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaUsagesBaseTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotaUsagesListMockTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotasEntityPatchPropertiesTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupQuotasEntityPropertiesTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/GroupingIdTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/ResourceUsageListTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/ResourceUsagesInnerTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsInnerTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsListInnerTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsListPropertiesTests.java
delete mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsListTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsPropertiesTests.java
create mode 100644 sdk/quota/azure-resourcemanager-quota/src/test/java/com/azure/resourcemanager/quota/generated/SubscriptionQuotaAllocationsTests.java
diff --git a/sdk/quota/azure-resourcemanager-quota/CHANGELOG.md b/sdk/quota/azure-resourcemanager-quota/CHANGELOG.md
index e4427ad61abd4..41aa9bfa30d2c 100644
--- a/sdk/quota/azure-resourcemanager-quota/CHANGELOG.md
+++ b/sdk/quota/azure-resourcemanager-quota/CHANGELOG.md
@@ -1,14 +1,222 @@
# Release History
-## 1.1.0-beta.3 (Unreleased)
+## 1.1.0-beta.3 (2025-01-22)
-### Features Added
+- Azure Resource Manager quota client library for Java. This package contains Microsoft Azure SDK for quota Management SDK. Microsoft Azure Quota Resource Provider. This Swagger is for Azure Group Quota using GroupQuota Entity. Package tag package-2024-12-18-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
### Breaking Changes
-### Bugs Fixed
+#### `models.GroupingId` was removed
+
+#### `models.EnforcementState` was removed
+
+#### `models.GroupQuotasEnforcementResponse` was removed
+
+#### `models.ResourceUsages` was removed
+
+#### `models.AdditionalAttributes` was removed
+
+#### `models.GroupingIdType` was removed
+
+#### `models.GroupQuotasEnforcementListResponse` was removed
+
+#### `models.EnvironmentType` was removed
+
+#### `models.GroupQuotasEnforcementResponseProperties` was removed
+
+#### `models.GroupQuotaLocationSettings` was removed
+
+#### `models.ResourceUsageList` was removed
+
+#### `models.AdditionalAttributesPatch` was removed
+
+#### `models.GroupQuotaUsages` was removed
+
+#### `models.GroupQuotaUsagesBase` was removed
+
+#### `models.GroupQuotasEntityBase` was modified
+
+* `withAdditionalAttributes(models.AdditionalAttributes)` was removed
+* `additionalAttributes()` was removed
+
+#### `models.GroupQuotasEntityPatch` was modified
+
+* `models.GroupQuotasEntityBasePatch properties()` -> `models.GroupQuotasEntityPatchProperties properties()`
+* `withProperties(models.GroupQuotasEntityBasePatch)` was removed
+
+#### `models.GroupQuotaLimits` was modified
+
+* `get(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String)` was removed
+* `com.azure.core.http.rest.PagedIterable list(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` -> `models.GroupQuotaLimitList list(java.lang.String,java.lang.String,java.lang.String,java.lang.String)`
+* `list(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
+* `getWithResponse(java.lang.String,java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
+
+#### `models.GroupQuotaLimitList` was modified
+
+* `value()` was removed
+* `toJson(com.azure.json.JsonWriter)` was removed
+* `nextLink()` was removed
+* `withValue(java.util.List)` was removed
+* `validate()` was removed
+* `fromJson(com.azure.json.JsonReader)` was removed
+
+#### `models.GroupQuotasEntity` was modified
+
+* `models.GroupQuotasEntityBase properties()` -> `models.GroupQuotasEntityProperties properties()`
+
+#### `models.GroupQuotasEntityBasePatch` was modified
+
+* `withAdditionalAttributes(models.AdditionalAttributesPatch)` was removed
+* `additionalAttributes()` was removed
+
+#### `models.SubscriptionQuotaDetails` was modified
+
+* `region()` was removed
+* `withRegion(java.lang.String)` was removed
+
+#### `models.SubscriptionQuotaAllocations` was modified
+
+* `innerModel()` was removed
+* `name()` was removed
+* `type()` was removed
+* `id()` was removed
+* `systemData()` was removed
+* `models.SubscriptionQuotaDetails properties()` -> `models.SubscriptionQuotaAllocationsProperties properties()`
+
+#### `models.SubscriptionQuotaAllocationsList` was modified
+
+* `value()` was removed
+* `validate()` was removed
+* `toJson(com.azure.json.JsonWriter)` was removed
+* `withValue(java.util.List)` was removed
+* `fromJson(com.azure.json.JsonReader)` was removed
+* `nextLink()` was removed
+
+#### `QuotaManager` was modified
+
+* `groupQuotaLocationSettings()` was removed
+* `groupQuotaUsages()` was removed
+
+#### `models.GroupQuotaSubscriptionAllocationRequests` was modified
+
+* `getWithResponse(java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
+* `get(java.lang.String,java.lang.String,java.lang.String)` was removed
+* `createOrUpdate(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.QuotaAllocationRequestStatusInner,com.azure.core.util.Context)` was removed
+* `createOrUpdate(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.QuotaAllocationRequestStatusInner)` was removed
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.QuotaAllocationRequestStatusInner)` was removed
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.QuotaAllocationRequestStatusInner,com.azure.core.util.Context)` was removed
+
+#### `models.GroupQuotaLimitsRequests` was modified
+
+* `createOrUpdate(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` was removed
+* `createOrUpdate(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.SubmittedResourceRequestStatusInner,com.azure.core.util.Context)` was removed
+* `models.SubmittedResourceRequestStatus update(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` -> `models.GroupQuotaLimitList update(java.lang.String,java.lang.String,java.lang.String,java.lang.String)`
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.SubmittedResourceRequestStatusInner,com.azure.core.util.Context)` was removed
+
+#### `models.GroupQuotaLimit` was modified
+
+* `type()` was removed
+* `innerModel()` was removed
+* `name()` was removed
+* `systemData()` was removed
+* `id()` was removed
+* `models.GroupQuotaDetails properties()` -> `models.GroupQuotaLimitProperties properties()`
+
+#### `models.GroupQuotaDetails` was modified
+
+* `withRegion(java.lang.String)` was removed
+* `region()` was removed
+
+#### `models.GroupQuotaSubscriptionAllocations` was modified
+
+* `get(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` was removed
+* `getWithResponse(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
+* `list(java.lang.String,java.lang.String,java.lang.String)` was removed
+* `list(java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was removed
+
+### Features Added
+
+* `models.SubscriptionQuotaAllocationsProperties` was added
+
+* `models.GroupQuotasEntityPatchProperties` was added
+
+* `models.GroupQuotasEntityProperties` was added
+
+* `models.GroupQuotaLimitProperties` was added
+
+* `models.GroupQuotaLimitListProperties` was added
+
+* `models.SubscriptionQuotaAllocationsListProperties` was added
+
+#### `models.GroupQuotasEntityPatch` was modified
+
+* `withProperties(models.GroupQuotasEntityPatchProperties)` was added
+
+#### `models.GroupQuotaLimits` was modified
+
+* `listWithResponse(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
+
+#### `models.GroupQuotaLimitList` was modified
+
+* `systemData()` was added
+* `innerModel()` was added
+* `id()` was added
+* `name()` was added
+* `type()` was added
+* `properties()` was added
+
+#### `models.SubscriptionQuotaDetails` was modified
+
+* `resourceName()` was added
+* `withResourceName(java.lang.String)` was added
+
+#### `models.SubscriptionQuotaAllocations` was modified
+
+* `validate()` was added
+* `withProperties(models.SubscriptionQuotaAllocationsProperties)` was added
+* `toJson(com.azure.json.JsonWriter)` was added
+* `fromJson(com.azure.json.JsonReader)` was added
+
+#### `models.GroupQuotaSubscriptionIdProperties` was modified
+
+* `withSubscriptionId(java.lang.String)` was added
+
+#### `models.SubscriptionQuotaAllocationsList` was modified
+
+* `properties()` was added
+* `innerModel()` was added
+* `name()` was added
+* `type()` was added
+* `systemData()` was added
+* `id()` was added
+
+#### `models.GroupQuotaSubscriptionAllocationRequests` was modified
+
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.SubscriptionQuotaAllocationsListInner,com.azure.core.util.Context)` was added
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.SubscriptionQuotaAllocationsListInner)` was added
+* `getWithResponse(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
+* `get(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` was added
+
+#### `models.GroupQuotaLimitsRequests` was modified
+
+* `update(java.lang.String,java.lang.String,java.lang.String,java.lang.String,fluent.models.GroupQuotaLimitListInner,com.azure.core.util.Context)` was added
+
+#### `models.GroupQuotaLimit` was modified
+
+* `validate()` was added
+* `withProperties(models.GroupQuotaLimitProperties)` was added
+* `fromJson(com.azure.json.JsonReader)` was added
+* `toJson(com.azure.json.JsonWriter)` was added
+
+#### `models.GroupQuotaDetails` was modified
+
+* `withResourceName(java.lang.String)` was added
+* `resourceName()` was added
+
+#### `models.GroupQuotaSubscriptionAllocations` was modified
-### Other Changes
+* `listWithResponse(java.lang.String,java.lang.String,java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
+* `list(java.lang.String,java.lang.String,java.lang.String,java.lang.String)` was added
## 1.1.0-beta.2 (2024-12-04)
diff --git a/sdk/quota/azure-resourcemanager-quota/README.md b/sdk/quota/azure-resourcemanager-quota/README.md
index 5ad19112c221e..f7d3d11215576 100644
--- a/sdk/quota/azure-resourcemanager-quota/README.md
+++ b/sdk/quota/azure-resourcemanager-quota/README.md
@@ -2,7 +2,7 @@
Azure Resource Manager quota client library for Java.
-This package contains Microsoft Azure SDK for quota Management SDK. Microsoft Azure Quota Resource Provider. This Swagger is for Azure Group Quota using GroupQuota Entity. Package tag package-2023-06-01-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
+This package contains Microsoft Azure SDK for quota Management SDK. Microsoft Azure Quota Resource Provider. This Swagger is for Azure Group Quota using GroupQuota Entity. Package tag package-2024-12-18-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## We'd love to hear your feedback
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanager
azure-resourcemanager-quota
- 1.1.0-beta.2
+ 1.1.0-beta.3
```
[//]: # ({x-version-update-end})
diff --git a/sdk/quota/azure-resourcemanager-quota/SAMPLE.md b/sdk/quota/azure-resourcemanager-quota/SAMPLE.md
index 0bbb13249f627..f5fa1c5123573 100644
--- a/sdk/quota/azure-resourcemanager-quota/SAMPLE.md
+++ b/sdk/quota/azure-resourcemanager-quota/SAMPLE.md
@@ -3,31 +3,20 @@
## GroupQuotaLimits
-- [Get](#groupquotalimits_get)
- [List](#groupquotalimits_list)
## GroupQuotaLimitsRequest
-- [CreateOrUpdate](#groupquotalimitsrequest_createorupdate)
- [Get](#groupquotalimitsrequest_get)
- [List](#groupquotalimitsrequest_list)
- [Update](#groupquotalimitsrequest_update)
-## GroupQuotaLocationSettings
-
-- [CreateOrUpdate](#groupquotalocationsettings_createorupdate)
-- [Get](#groupquotalocationsettings_get)
-- [List](#groupquotalocationsettings_list)
-- [Update](#groupquotalocationsettings_update)
-
## GroupQuotaSubscriptionAllocation
-- [Get](#groupquotasubscriptionallocation_get)
- [List](#groupquotasubscriptionallocation_list)
## GroupQuotaSubscriptionAllocationRequest
-- [CreateOrUpdate](#groupquotasubscriptionallocationrequest_createorupdate)
- [Get](#groupquotasubscriptionallocationrequest_get)
- [List](#groupquotasubscriptionallocationrequest_list)
- [Update](#groupquotasubscriptionallocationrequest_update)
@@ -45,10 +34,6 @@
- [List](#groupquotasubscriptions_list)
- [Update](#groupquotasubscriptions_update)
-## GroupQuotaUsages
-
-- [List](#groupquotausages_list)
-
## GroupQuotas
- [CreateOrUpdate](#groupquotas_createorupdate)
@@ -77,31 +62,6 @@
- [Get](#usages_get)
- [List](#usages_list)
-### GroupQuotaLimits_Get
-
-```java
-/**
- * Samples for GroupQuotaLimits Get.
- */
-public final class GroupQuotaLimitsGetSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimits/
- * GetGroupQuotaLimits-Compute.json
- */
- /**
- * Sample code: GroupQuotaLimits_Get_Request_ForCompute.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotaLimitsGetRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLimits()
- .getWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "cores",
- "location eq westus", com.azure.core.util.Context.NONE);
- }
-}
-```
-
### GroupQuotaLimits_List
```java
@@ -111,48 +71,22 @@ public final class GroupQuotaLimitsGetSamples {
public final class GroupQuotaLimitsListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimits/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotaLimits/
* ListGroupQuotaLimits-Compute.json
*/
/**
- * Sample code: GroupQuotaLimits_List_Request_ForCompute.
+ * Sample code: GroupQuotaLimits_Get_Request_ForCompute.
*
* @param manager Entry point to QuotaManager.
*/
- public static void groupQuotaLimitsListRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
+ public static void groupQuotaLimitsGetRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager.groupQuotaLimits()
- .list("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "location eq westus",
+ .listWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "westus",
com.azure.core.util.Context.NONE);
}
}
```
-### GroupQuotaLimitsRequest_CreateOrUpdate
-
-```java
-
-/**
- * Samples for GroupQuotaLimitsRequest CreateOrUpdate.
- */
-public final class GroupQuotaLimitsRequestCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimitsRequests
- * /PutGroupQuotaLimitsRequests-Compute.json
- */
- /**
- * Sample code: GroupQuotaLimitsRequests_CreateOrUpdate.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotaLimitsRequestsCreateOrUpdate(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLimitsRequests()
- .createOrUpdate("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute",
- "standardav2family", null, com.azure.core.util.Context.NONE);
- }
-}
-```
-
### GroupQuotaLimitsRequest_Get
```java
@@ -162,7 +96,7 @@ public final class GroupQuotaLimitsRequestCreateOrUpdateSamples {
public final class GroupQuotaLimitsRequestGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimitsRequests
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotaLimitsRequests
* /GroupQuotaLimitsRequests_Get.json
*/
/**
@@ -187,7 +121,7 @@ public final class GroupQuotaLimitsRequestGetSamples {
public final class GroupQuotaLimitsRequestListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimitsRequests
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotaLimitsRequests
* /GroupQuotaLimitsRequests_List.json
*/
/**
@@ -206,6 +140,11 @@ public final class GroupQuotaLimitsRequestListSamples {
### GroupQuotaLimitsRequest_Update
```java
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimit;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitListProperties;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitProperties;
+import java.util.Arrays;
/**
* Samples for GroupQuotaLimitsRequest Update.
@@ -213,7 +152,7 @@ public final class GroupQuotaLimitsRequestListSamples {
public final class GroupQuotaLimitsRequestUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaLimitsRequests
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotaLimitsRequests
* /PatchGroupQuotaLimitsRequests-Compute.json
*/
/**
@@ -223,168 +162,22 @@ public final class GroupQuotaLimitsRequestUpdateSamples {
*/
public static void groupQuotaLimitsRequestsUpdate(com.azure.resourcemanager.quota.QuotaManager manager) {
manager.groupQuotaLimitsRequests()
- .update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "standardav2family",
- null, com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### GroupQuotaLocationSettings_CreateOrUpdate
-
-```java
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEnforcementResponseInner;
-import com.azure.resourcemanager.quota.models.EnforcementState;
-import com.azure.resourcemanager.quota.models.GroupQuotasEnforcementResponseProperties;
-
-/**
- * Samples for GroupQuotaLocationSettings CreateOrUpdate.
- */
-public final class GroupQuotaLocationSettingsCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasEnforcement/
- * PutGroupQuotaEnforcement.json
- */
- /**
- * Sample code: GroupQuotaLocationSettings_CreateOrUpdate.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotaLocationSettingsCreateOrUpdate(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLocationSettings()
- .createOrUpdate("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "eastus",
- new GroupQuotasEnforcementResponseInner().withProperties(
- new GroupQuotasEnforcementResponseProperties().withEnforcementEnabled(EnforcementState.ENABLED)),
- com.azure.core.util.Context.NONE);
- }
-
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasEnforcement/
- * PutGroupQuotaEnforcementFailed.json
- */
- /**
- * Sample code: GroupQuotaLocationSettings_CreateOrUpdate_Failed.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void
- groupQuotaLocationSettingsCreateOrUpdateFailed(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLocationSettings()
- .createOrUpdate("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "eastus",
- new GroupQuotasEnforcementResponseInner().withProperties(
- new GroupQuotasEnforcementResponseProperties().withEnforcementEnabled(EnforcementState.ENABLED)),
- com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### GroupQuotaLocationSettings_Get
-
-```java
-/**
- * Samples for GroupQuotaLocationSettings Get.
- */
-public final class GroupQuotaLocationSettingsGetSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasEnforcement/
- * GetGroupQuotaEnforcement.json
- */
- /**
- * Sample code: GroupQuotasEnforcement_Get.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotasEnforcementGet(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLocationSettings()
- .getWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "eastus",
- com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### GroupQuotaLocationSettings_List
-
-```java
-/**
- * Samples for GroupQuotaLocationSettings List.
- */
-public final class GroupQuotaLocationSettingsListSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasEnforcement/
- * ListGroupQuotaEnforcement.json
- */
- /**
- * Sample code: GroupQuotaEnforcement_List.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotaEnforcementList(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLocationSettings()
- .list("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute",
- com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### GroupQuotaLocationSettings_Update
-
-```java
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEnforcementResponseInner;
-import com.azure.resourcemanager.quota.models.EnforcementState;
-import com.azure.resourcemanager.quota.models.GroupQuotasEnforcementResponseProperties;
-
-/**
- * Samples for GroupQuotaLocationSettings Update.
- */
-public final class GroupQuotaLocationSettingsUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasEnforcement/
- * PatchGroupQuotaEnforcement.json
- */
- /**
- * Sample code: GroupQuotaLocationSettings_Patch.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotaLocationSettingsPatch(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaLocationSettings()
- .update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "eastus",
- new GroupQuotasEnforcementResponseInner().withProperties(
- new GroupQuotasEnforcementResponseProperties().withEnforcementEnabled(EnforcementState.ENABLED)),
+ .update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "westus",
+ new GroupQuotaLimitListInner()
+ .withProperties(new GroupQuotaLimitListProperties().withValue(Arrays.asList(
+ new GroupQuotaLimit()
+ .withProperties(new GroupQuotaLimitProperties().withResourceName("standardddv4family")
+ .withLimit(110L)
+ .withComment("Contoso requires more quota.")),
+ new GroupQuotaLimit()
+ .withProperties(new GroupQuotaLimitProperties().withResourceName("standardav2family")
+ .withLimit(110L)
+ .withComment("Contoso requires more quota."))))),
com.azure.core.util.Context.NONE);
}
}
```
-### GroupQuotaSubscriptionAllocation_Get
-
-```java
-/**
- * Samples for GroupQuotaSubscriptionAllocation Get.
- */
-public final class GroupQuotaSubscriptionAllocationGetSamples {
- /*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
- * SubscriptionQuotaAllocation/SubscriptionQuotaAllocation_Get-Compute.json
- */
- /**
- * Sample code: SubscriptionQuotaAllocation_Get_Request_ForCompute.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void
- subscriptionQuotaAllocationGetRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaSubscriptionAllocations()
- .getWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "standardav2family",
- "provider eq Microsoft.Compute & location eq westus", com.azure.core.util.Context.NONE);
- }
-}
-```
-
### GroupQuotaSubscriptionAllocation_List
```java
@@ -393,7 +186,7 @@ public final class GroupQuotaSubscriptionAllocationGetSamples {
*/
public final class GroupQuotaSubscriptionAllocationListSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* SubscriptionQuotaAllocation/SubscriptionQuotaAllocation_List-Compute.json
*/
/**
@@ -403,38 +196,7 @@ public final class GroupQuotaSubscriptionAllocationListSamples {
*/
public static void subscriptionQuotaAllocationListForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager.groupQuotaSubscriptionAllocations()
- .list("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1",
- "provider eq Microsoft.Compute & location eq westus", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### GroupQuotaSubscriptionAllocationRequest_CreateOrUpdate
-
-```java
-import com.azure.resourcemanager.quota.fluent.models.QuotaAllocationRequestStatusInner;
-import com.azure.resourcemanager.quota.models.QuotaAllocationRequestBase;
-
-/**
- * Samples for GroupQuotaSubscriptionAllocationRequest CreateOrUpdate.
- */
-public final class GroupQuotaSubscriptionAllocationRequestCreateOrUpdateSamples {
- /*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
- * SubscriptionQuotaAllocationRequests/PutSubscriptionQuotaAllocationRequest-Compute.json
- */
- /**
- * Sample code: SubscriptionQuotaAllocation_Put_Request_ForCompute.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void
- subscriptionQuotaAllocationPutRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaSubscriptionAllocationRequests()
- .createOrUpdate("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute",
- "standardav2family",
- new QuotaAllocationRequestStatusInner()
- .withRequestedResource(new QuotaAllocationRequestBase().withLimit(10L).withRegion("westus")),
+ .listWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "westus",
com.azure.core.util.Context.NONE);
}
}
@@ -448,7 +210,7 @@ public final class GroupQuotaSubscriptionAllocationRequestCreateOrUpdateSamples
*/
public final class GroupQuotaSubscriptionAllocationRequestGetSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* SubscriptionQuotaAllocationRequests/SubscriptionQuotaAllocationRequests_Get-Compute.json
*/
/**
@@ -459,7 +221,7 @@ public final class GroupQuotaSubscriptionAllocationRequestGetSamples {
public static void
subscriptionQuotaAllocationRequestsGetRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager.groupQuotaSubscriptionAllocationRequests()
- .getWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1",
+ .getWithResponse("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute",
"AE000000-0000-0000-0000-00000000000A", com.azure.core.util.Context.NONE);
}
}
@@ -473,7 +235,7 @@ public final class GroupQuotaSubscriptionAllocationRequestGetSamples {
*/
public final class GroupQuotaSubscriptionAllocationRequestListSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* SubscriptionQuotaAllocationRequests/SubscriptionQuotaAllocationRequests_List-Compute.json
*/
/**
@@ -493,15 +255,18 @@ public final class GroupQuotaSubscriptionAllocationRequestListSamples {
### GroupQuotaSubscriptionAllocationRequest_Update
```java
-import com.azure.resourcemanager.quota.fluent.models.QuotaAllocationRequestStatusInner;
-import com.azure.resourcemanager.quota.models.QuotaAllocationRequestBase;
+import com.azure.resourcemanager.quota.fluent.models.SubscriptionQuotaAllocationsListInner;
+import com.azure.resourcemanager.quota.models.SubscriptionQuotaAllocations;
+import com.azure.resourcemanager.quota.models.SubscriptionQuotaAllocationsListProperties;
+import com.azure.resourcemanager.quota.models.SubscriptionQuotaAllocationsProperties;
+import java.util.Arrays;
/**
* Samples for GroupQuotaSubscriptionAllocationRequest Update.
*/
public final class GroupQuotaSubscriptionAllocationRequestUpdateSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* SubscriptionQuotaAllocationRequests/PatchSubscriptionQuotaAllocationRequest-Compute.json
*/
/**
@@ -512,9 +277,15 @@ public final class GroupQuotaSubscriptionAllocationRequestUpdateSamples {
public static void
subscriptionQuotaAllocationPatchRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager.groupQuotaSubscriptionAllocationRequests()
- .update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "standardav2family",
- new QuotaAllocationRequestStatusInner()
- .withRequestedResource(new QuotaAllocationRequestBase().withLimit(10L).withRegion("westus")),
+ .update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "westus",
+ new SubscriptionQuotaAllocationsListInner()
+ .withProperties(new SubscriptionQuotaAllocationsListProperties().withValue(Arrays.asList(
+ new SubscriptionQuotaAllocations().withProperties(
+ new SubscriptionQuotaAllocationsProperties().withResourceName("standardddv4family")
+ .withLimit(110L)),
+ new SubscriptionQuotaAllocations().withProperties(
+ new SubscriptionQuotaAllocationsProperties().withResourceName("standardav2family")
+ .withLimit(110L))))),
com.azure.core.util.Context.NONE);
}
}
@@ -529,7 +300,7 @@ public final class GroupQuotaSubscriptionAllocationRequestUpdateSamples {
public final class GroupQuotaSubscriptionRequestsGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/SubscriptionRequests/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/SubscriptionRequests/
* SubscriptionRequests_Get.json
*/
/**
@@ -554,7 +325,7 @@ public final class GroupQuotaSubscriptionRequestsGetSamples {
public final class GroupQuotaSubscriptionRequestsListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/SubscriptionRequests/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/SubscriptionRequests/
* SubscriptionRequests_List.json
*/
/**
@@ -578,7 +349,7 @@ public final class GroupQuotaSubscriptionRequestsListSamples {
public final class GroupQuotaSubscriptionsCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasSubscriptions
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotasSubscriptions
* /PutGroupQuotasSubscription.json
*/
/**
@@ -602,7 +373,7 @@ public final class GroupQuotaSubscriptionsCreateOrUpdateSamples {
public final class GroupQuotaSubscriptionsDeleteSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasSubscriptions
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotasSubscriptions
* /DeleteGroupQuotaSubscriptions.json
*/
/**
@@ -627,7 +398,7 @@ public final class GroupQuotaSubscriptionsDeleteSamples {
public final class GroupQuotaSubscriptionsGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasSubscriptions
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotasSubscriptions
* /GetGroupQuotaSubscriptions.json
*/
/**
@@ -651,7 +422,7 @@ public final class GroupQuotaSubscriptionsGetSamples {
public final class GroupQuotaSubscriptionsListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasSubscriptions
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotasSubscriptions
* /ListGroupQuotaSubscriptions.json
*/
/**
@@ -675,7 +446,7 @@ public final class GroupQuotaSubscriptionsListSamples {
public final class GroupQuotaSubscriptionsUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotasSubscriptions
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotasSubscriptions
* /PatchGroupQuotasSubscription.json
*/
/**
@@ -690,40 +461,11 @@ public final class GroupQuotaSubscriptionsUpdateSamples {
}
```
-### GroupQuotaUsages_List
-
-```java
-/**
- * Samples for GroupQuotaUsages List.
- */
-public final class GroupQuotaUsagesListSamples {
- /*
- * x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotaUsages/
- * GetGroupQuotaUsages.json
- */
- /**
- * Sample code: GroupQuotasUsages_List.
- *
- * @param manager Entry point to QuotaManager.
- */
- public static void groupQuotasUsagesList(com.azure.resourcemanager.quota.QuotaManager manager) {
- manager.groupQuotaUsages()
- .list("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1", "Microsoft.Compute", "westus",
- com.azure.core.util.Context.NONE);
- }
-}
-```
-
### GroupQuotas_CreateOrUpdate
```java
import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEntityInner;
-import com.azure.resourcemanager.quota.models.AdditionalAttributes;
-import com.azure.resourcemanager.quota.models.EnvironmentType;
-import com.azure.resourcemanager.quota.models.GroupQuotasEntityBase;
-import com.azure.resourcemanager.quota.models.GroupingId;
-import com.azure.resourcemanager.quota.models.GroupingIdType;
+import com.azure.resourcemanager.quota.models.GroupQuotasEntityProperties;
/**
* Samples for GroupQuotas CreateOrUpdate.
@@ -731,7 +473,7 @@ import com.azure.resourcemanager.quota.models.GroupingIdType;
public final class GroupQuotasCreateOrUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotas/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotas/
* PutGroupQuotas.json
*/
/**
@@ -743,13 +485,7 @@ public final class GroupQuotasCreateOrUpdateSamples {
manager.groupQuotas()
.createOrUpdate("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1",
new GroupQuotasEntityInner()
- .withProperties(
- new GroupQuotasEntityBase().withDisplayName("GroupQuota1")
- .withAdditionalAttributes(
- new AdditionalAttributes()
- .withGroupId(new GroupingId().withGroupingIdType(GroupingIdType.SERVICE_TREE_ID)
- .withValue("yourServiceTreeIdHere"))
- .withEnvironment(EnvironmentType.PRODUCTION))),
+ .withProperties(new GroupQuotasEntityProperties().withDisplayName("GroupQuota1")),
com.azure.core.util.Context.NONE);
}
}
@@ -764,7 +500,7 @@ public final class GroupQuotasCreateOrUpdateSamples {
public final class GroupQuotasDeleteSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotas/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotas/
* DeleteGroupQuotas.json
*/
/**
@@ -788,7 +524,7 @@ public final class GroupQuotasDeleteSamples {
public final class GroupQuotasGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotas/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotas/
* GetGroupQuotas.json
*/
/**
@@ -812,7 +548,7 @@ public final class GroupQuotasGetSamples {
public final class GroupQuotasListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotas/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotas/
* GetGroupQuotasList.json
*/
/**
@@ -829,12 +565,8 @@ public final class GroupQuotasListSamples {
### GroupQuotas_Update
```java
-import com.azure.resourcemanager.quota.models.AdditionalAttributesPatch;
-import com.azure.resourcemanager.quota.models.EnvironmentType;
-import com.azure.resourcemanager.quota.models.GroupQuotasEntityBasePatch;
import com.azure.resourcemanager.quota.models.GroupQuotasEntityPatch;
-import com.azure.resourcemanager.quota.models.GroupingId;
-import com.azure.resourcemanager.quota.models.GroupingIdType;
+import com.azure.resourcemanager.quota.models.GroupQuotasEntityPatchProperties;
/**
* Samples for GroupQuotas Update.
@@ -842,7 +574,7 @@ import com.azure.resourcemanager.quota.models.GroupingIdType;
public final class GroupQuotasUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GroupQuotas/
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GroupQuotas/
* PatchGroupQuotas.json
*/
/**
@@ -854,12 +586,7 @@ public final class GroupQuotasUpdateSamples {
manager.groupQuotas()
.update("E7EC67B3-7657-4966-BFFC-41EFD36BAA09", "groupquota1",
new GroupQuotasEntityPatch()
- .withProperties(
- new GroupQuotasEntityBasePatch().withDisplayName("UpdatedGroupQuota1")
- .withAdditionalAttributes(new AdditionalAttributesPatch()
- .withGroupId(new GroupingId().withGroupingIdType(GroupingIdType.SERVICE_TREE_ID)
- .withValue("UpdatedServiceTreeIdHere"))
- .withEnvironment(EnvironmentType.PRODUCTION))),
+ .withProperties(new GroupQuotasEntityPatchProperties().withDisplayName("UpdatedGroupQuota1")),
com.azure.core.util.Context.NONE);
}
}
@@ -877,7 +604,7 @@ import com.azure.resourcemanager.quota.models.ResourceName;
*/
public final class QuotaCreateOrUpdateSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* putMachineLearningServicesQuotaRequestLowPriority.json
*/
/**
@@ -898,7 +625,7 @@ public final class QuotaCreateOrUpdateSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* putNetworkOneSkuQuotaRequestStandardSkuPublicIpAddresses.json
*/
/**
@@ -919,7 +646,7 @@ public final class QuotaCreateOrUpdateSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* putComputeOneSkuQuotaRequest.json
*/
/**
@@ -938,7 +665,7 @@ public final class QuotaCreateOrUpdateSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* putNetworkOneSkuQuotaRequest.json
*/
/**
@@ -967,7 +694,7 @@ public final class QuotaCreateOrUpdateSamples {
*/
public final class QuotaGetSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getNetworkOneSkuQuotaLimit.json
*/
/**
@@ -983,7 +710,7 @@ public final class QuotaGetSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getComputeOneSkuQuotaLimit.json
*/
/**
@@ -1008,7 +735,7 @@ public final class QuotaGetSamples {
*/
public final class QuotaListSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getMachineLearningServicesQuotaLimits.json
*/
/**
@@ -1026,7 +753,7 @@ public final class QuotaListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getComputeQuotaLimits.
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getComputeQuotaLimits.
* json
*/
/**
@@ -1042,7 +769,7 @@ public final class QuotaListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getNetworkQuotaLimits.
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getNetworkQuotaLimits.
* json
*/
/**
@@ -1072,7 +799,7 @@ import com.azure.resourcemanager.quota.models.ResourceName;
public final class QuotaUpdateSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/patchComputeQuotaRequest
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/patchComputeQuotaRequest
* .json
*/
/**
@@ -1093,7 +820,7 @@ public final class QuotaUpdateSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* patchNetworkOneSkuQuotaRequest.json
*/
/**
@@ -1125,7 +852,7 @@ public final class QuotaUpdateSamples {
public final class QuotaOperationListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/GetOperations.json
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/GetOperations.json
*/
/**
* Sample code: GetOperations.
@@ -1146,7 +873,7 @@ public final class QuotaOperationListSamples {
*/
public final class QuotaRequestStatusGetSamples {
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getQuotaRequestStatusFailed.json
*/
/**
@@ -1162,7 +889,7 @@ public final class QuotaRequestStatusGetSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getQuotaRequestStatusById.json
*/
/**
@@ -1178,7 +905,7 @@ public final class QuotaRequestStatusGetSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getQuotaRequestStatusInProgress.json
*/
/**
@@ -1204,7 +931,7 @@ public final class QuotaRequestStatusGetSamples {
public final class QuotaRequestStatusListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getQuotaRequestsHistory.
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getQuotaRequestsHistory.
* json
*/
/**
@@ -1229,7 +956,7 @@ public final class QuotaRequestStatusListSamples {
public final class UsagesGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getNetworkOneSkuUsages.
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getNetworkOneSkuUsages.
* json
*/
/**
@@ -1246,7 +973,7 @@ public final class UsagesGetSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getComputeOneSkuUsages.
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getComputeOneSkuUsages.
* json
*/
/**
@@ -1272,7 +999,7 @@ public final class UsagesGetSamples {
public final class UsagesListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getComputeUsages.json
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getComputeUsages.json
*/
/**
* Sample code: Quotas_listUsagesForCompute.
@@ -1287,7 +1014,7 @@ public final class UsagesListSamples {
/*
* x-ms-original-file:
- * specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/getNetworkUsages.json
+ * specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/getNetworkUsages.json
*/
/**
* Sample code: Quotas_listUsagesForNetwork.
@@ -1301,7 +1028,7 @@ public final class UsagesListSamples {
}
/*
- * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2023-06-01-preview/examples/
+ * x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2024-12-18-preview/examples/
* getMachineLearningServicesUsages.json
*/
/**
diff --git a/sdk/quota/azure-resourcemanager-quota/pom.xml b/sdk/quota/azure-resourcemanager-quota/pom.xml
index a567a58cdbece..353a3519749d2 100644
--- a/sdk/quota/azure-resourcemanager-quota/pom.xml
+++ b/sdk/quota/azure-resourcemanager-quota/pom.xml
@@ -18,7 +18,7 @@
jar
Microsoft Azure SDK for quota Management
- This package contains Microsoft Azure SDK for quota Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Microsoft Azure Quota Resource Provider. This Swagger is for Azure Group Quota using GroupQuota Entity. Package tag package-2023-06-01-preview.
+ This package contains Microsoft Azure SDK for quota Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Microsoft Azure Quota Resource Provider. This Swagger is for Azure Group Quota using GroupQuota Entity. Package tag package-2024-12-18-preview.
https://github.com/Azure/azure-sdk-for-java
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/QuotaManager.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/QuotaManager.java
index 2ad7d787c26fd..be941b94099b5 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/QuotaManager.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/QuotaManager.java
@@ -27,12 +27,10 @@
import com.azure.resourcemanager.quota.implementation.AzureQuotaExtensionApiBuilder;
import com.azure.resourcemanager.quota.implementation.GroupQuotaLimitsImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotaLimitsRequestsImpl;
-import com.azure.resourcemanager.quota.implementation.GroupQuotaLocationSettingsImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotaSubscriptionAllocationRequestsImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotaSubscriptionAllocationsImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotaSubscriptionRequestsImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotaSubscriptionsImpl;
-import com.azure.resourcemanager.quota.implementation.GroupQuotaUsagesImpl;
import com.azure.resourcemanager.quota.implementation.GroupQuotasImpl;
import com.azure.resourcemanager.quota.implementation.QuotaOperationsImpl;
import com.azure.resourcemanager.quota.implementation.QuotaRequestStatusImpl;
@@ -40,12 +38,10 @@
import com.azure.resourcemanager.quota.implementation.UsagesImpl;
import com.azure.resourcemanager.quota.models.GroupQuotaLimits;
import com.azure.resourcemanager.quota.models.GroupQuotaLimitsRequests;
-import com.azure.resourcemanager.quota.models.GroupQuotaLocationSettings;
import com.azure.resourcemanager.quota.models.GroupQuotaSubscriptionAllocationRequests;
import com.azure.resourcemanager.quota.models.GroupQuotaSubscriptionAllocations;
import com.azure.resourcemanager.quota.models.GroupQuotaSubscriptionRequests;
import com.azure.resourcemanager.quota.models.GroupQuotaSubscriptions;
-import com.azure.resourcemanager.quota.models.GroupQuotaUsages;
import com.azure.resourcemanager.quota.models.GroupQuotas;
import com.azure.resourcemanager.quota.models.QuotaOperations;
import com.azure.resourcemanager.quota.models.QuotaRequestStatus;
@@ -69,17 +65,13 @@ public final class QuotaManager {
private GroupQuotaSubscriptionRequests groupQuotaSubscriptionRequests;
- private GroupQuotaLimits groupQuotaLimits;
-
private GroupQuotaLimitsRequests groupQuotaLimitsRequests;
- private GroupQuotaSubscriptionAllocations groupQuotaSubscriptionAllocations;
+ private GroupQuotaLimits groupQuotaLimits;
private GroupQuotaSubscriptionAllocationRequests groupQuotaSubscriptionAllocationRequests;
- private GroupQuotaUsages groupQuotaUsages;
-
- private GroupQuotaLocationSettings groupQuotaLocationSettings;
+ private GroupQuotaSubscriptionAllocations groupQuotaSubscriptionAllocations;
private Usages usages;
@@ -253,7 +245,7 @@ public QuotaManager authenticate(TokenCredential credential, AzureProfile profil
.append("-")
.append("com.azure.resourcemanager.quota")
.append("/")
- .append("1.1.0-beta.2");
+ .append("1.1.0-beta.3");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder.append(" (")
.append(Configuration.getGlobalConfiguration().get("java.version"))
@@ -337,18 +329,6 @@ public GroupQuotaSubscriptionRequests groupQuotaSubscriptionRequests() {
return groupQuotaSubscriptionRequests;
}
- /**
- * Gets the resource collection API of GroupQuotaLimits.
- *
- * @return Resource collection API of GroupQuotaLimits.
- */
- public GroupQuotaLimits groupQuotaLimits() {
- if (this.groupQuotaLimits == null) {
- this.groupQuotaLimits = new GroupQuotaLimitsImpl(clientObject.getGroupQuotaLimits(), this);
- }
- return groupQuotaLimits;
- }
-
/**
* Gets the resource collection API of GroupQuotaLimitsRequests.
*
@@ -363,16 +343,15 @@ public GroupQuotaLimitsRequests groupQuotaLimitsRequests() {
}
/**
- * Gets the resource collection API of GroupQuotaSubscriptionAllocations.
+ * Gets the resource collection API of GroupQuotaLimits.
*
- * @return Resource collection API of GroupQuotaSubscriptionAllocations.
+ * @return Resource collection API of GroupQuotaLimits.
*/
- public GroupQuotaSubscriptionAllocations groupQuotaSubscriptionAllocations() {
- if (this.groupQuotaSubscriptionAllocations == null) {
- this.groupQuotaSubscriptionAllocations
- = new GroupQuotaSubscriptionAllocationsImpl(clientObject.getGroupQuotaSubscriptionAllocations(), this);
+ public GroupQuotaLimits groupQuotaLimits() {
+ if (this.groupQuotaLimits == null) {
+ this.groupQuotaLimits = new GroupQuotaLimitsImpl(clientObject.getGroupQuotaLimits(), this);
}
- return groupQuotaSubscriptionAllocations;
+ return groupQuotaLimits;
}
/**
@@ -389,28 +368,16 @@ public GroupQuotaSubscriptionAllocationRequests groupQuotaSubscriptionAllocation
}
/**
- * Gets the resource collection API of GroupQuotaUsages.
- *
- * @return Resource collection API of GroupQuotaUsages.
- */
- public GroupQuotaUsages groupQuotaUsages() {
- if (this.groupQuotaUsages == null) {
- this.groupQuotaUsages = new GroupQuotaUsagesImpl(clientObject.getGroupQuotaUsages(), this);
- }
- return groupQuotaUsages;
- }
-
- /**
- * Gets the resource collection API of GroupQuotaLocationSettings.
+ * Gets the resource collection API of GroupQuotaSubscriptionAllocations.
*
- * @return Resource collection API of GroupQuotaLocationSettings.
+ * @return Resource collection API of GroupQuotaSubscriptionAllocations.
*/
- public GroupQuotaLocationSettings groupQuotaLocationSettings() {
- if (this.groupQuotaLocationSettings == null) {
- this.groupQuotaLocationSettings
- = new GroupQuotaLocationSettingsImpl(clientObject.getGroupQuotaLocationSettings(), this);
+ public GroupQuotaSubscriptionAllocations groupQuotaSubscriptionAllocations() {
+ if (this.groupQuotaSubscriptionAllocations == null) {
+ this.groupQuotaSubscriptionAllocations
+ = new GroupQuotaSubscriptionAllocationsImpl(clientObject.getGroupQuotaSubscriptionAllocations(), this);
}
- return groupQuotaLocationSettings;
+ return groupQuotaSubscriptionAllocations;
}
/**
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/AzureQuotaExtensionApi.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/AzureQuotaExtensionApi.java
index 44d3db678de35..708c3a71301f7 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/AzureQuotaExtensionApi.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/AzureQuotaExtensionApi.java
@@ -67,13 +67,6 @@ public interface AzureQuotaExtensionApi {
*/
GroupQuotaSubscriptionRequestsClient getGroupQuotaSubscriptionRequests();
- /**
- * Gets the GroupQuotaLimitsClient object to access its operations.
- *
- * @return the GroupQuotaLimitsClient object.
- */
- GroupQuotaLimitsClient getGroupQuotaLimits();
-
/**
* Gets the GroupQuotaLimitsRequestsClient object to access its operations.
*
@@ -82,11 +75,11 @@ public interface AzureQuotaExtensionApi {
GroupQuotaLimitsRequestsClient getGroupQuotaLimitsRequests();
/**
- * Gets the GroupQuotaSubscriptionAllocationsClient object to access its operations.
+ * Gets the GroupQuotaLimitsClient object to access its operations.
*
- * @return the GroupQuotaSubscriptionAllocationsClient object.
+ * @return the GroupQuotaLimitsClient object.
*/
- GroupQuotaSubscriptionAllocationsClient getGroupQuotaSubscriptionAllocations();
+ GroupQuotaLimitsClient getGroupQuotaLimits();
/**
* Gets the GroupQuotaSubscriptionAllocationRequestsClient object to access its operations.
@@ -96,18 +89,11 @@ public interface AzureQuotaExtensionApi {
GroupQuotaSubscriptionAllocationRequestsClient getGroupQuotaSubscriptionAllocationRequests();
/**
- * Gets the GroupQuotaUsagesClient object to access its operations.
- *
- * @return the GroupQuotaUsagesClient object.
- */
- GroupQuotaUsagesClient getGroupQuotaUsages();
-
- /**
- * Gets the GroupQuotaLocationSettingsClient object to access its operations.
+ * Gets the GroupQuotaSubscriptionAllocationsClient object to access its operations.
*
- * @return the GroupQuotaLocationSettingsClient object.
+ * @return the GroupQuotaSubscriptionAllocationsClient object.
*/
- GroupQuotaLocationSettingsClient getGroupQuotaLocationSettings();
+ GroupQuotaSubscriptionAllocationsClient getGroupQuotaSubscriptionAllocations();
/**
* Gets the UsagesClient object to access its operations.
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsClient.java
index 54f07d679d1cb..2d3e8592d3c7c 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsClient.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsClient.java
@@ -6,123 +6,50 @@
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitInner;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
/**
* An instance of this class provides access to all the operations defined in GroupQuotaLimitsClient.
*/
public interface GroupQuotaLimitsClient {
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link Response}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU} along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter, Context context);
+ Response listWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, Context context);
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- GroupQuotaLimitInner get(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, String filter);
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter);
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context);
+ GroupQuotaLimitListInner list(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location);
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsRequestsClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsRequestsClient.java
index 26640734c033b..ec4e563d5c061 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsRequestsClient.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLimitsRequestsClient.java
@@ -8,123 +8,22 @@
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
-import com.azure.core.management.ProxyResource;
import com.azure.core.management.polling.PollResult;
import com.azure.core.util.Context;
import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
import com.azure.resourcemanager.quota.fluent.models.SubmittedResourceRequestStatusInner;
/**
* An instance of this class provides access to all the operations defined in GroupQuotaLimitsRequestsClient.
*/
public interface GroupQuotaLimitsRequestsClient {
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName);
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context);
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName);
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest, Context context);
-
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -133,22 +32,22 @@ ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, St
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
+ * @return the {@link SyncPoller} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, SubmittedResourceRequestStatusInner>
- beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName);
+ SyncPoller, GroupQuotaLimitListInner> beginUpdate(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String location);
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -157,25 +56,25 @@ ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, St
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
+ * @return the {@link SyncPoller} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, SubmittedResourceRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context);
+ SyncPoller, GroupQuotaLimitListInner> beginUpdate(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String location, GroupQuotaLimitListInner groupQuotaRequest,
+ Context context);
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -184,22 +83,22 @@ SyncPoller, SubmittedResourceReq
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
+ * @return list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- SubmittedResourceRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName);
+ GroupQuotaLimitListInner update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location);
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -208,18 +107,17 @@ SubmittedResourceRequestStatusInner update(String managementGroupId, String grou
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
+ * @return list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- SubmittedResourceRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context);
+ GroupQuotaLimitListInner update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location, GroupQuotaLimitListInner groupQuotaRequest, Context context);
/**
* Get the status of a single GroupQuota request by requestId.
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLocationSettingsClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLocationSettingsClient.java
deleted file mode 100644
index 1616a67df060b..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaLocationSettingsClient.java
+++ /dev/null
@@ -1,339 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.polling.PollResult;
-import com.azure.core.util.Context;
-import com.azure.core.util.polling.SyncPoller;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEnforcementResponseInner;
-
-/**
- * An instance of this class provides access to all the operations defined in GroupQuotaLocationSettingsClient.
- */
-public interface GroupQuotaLocationSettingsClient {
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location, GroupQuotasEnforcementResponseInner locationSettings, Context context);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, GroupQuotasEnforcementResponseInner>
- beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String location);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, GroupQuotasEnforcementResponseInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- GroupQuotasEnforcementResponseInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location);
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- GroupQuotasEnforcementResponseInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context);
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, Context context);
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- GroupQuotasEnforcementResponseInner get(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location);
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName);
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, Context context);
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationRequestsClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationRequestsClient.java
index 533d86da7403a..94274ef71ff50 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationRequestsClient.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationRequestsClient.java
@@ -8,308 +8,209 @@
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
-import com.azure.core.management.ProxyResource;
import com.azure.core.management.polling.PollResult;
import com.azure.core.util.Context;
import com.azure.core.util.polling.SyncPoller;
import com.azure.resourcemanager.quota.fluent.models.QuotaAllocationRequestStatusInner;
+import com.azure.resourcemanager.quota.fluent.models.SubscriptionQuotaAllocationsListInner;
/**
* An instance of this class provides access to all the operations defined in
* GroupQuotaSubscriptionAllocationRequestsClient.
*/
public interface GroupQuotaSubscriptionAllocationRequestsClient {
- /**
- * Get the status of the quota allocation request for the subscriptionId.
- *
- * Get the quota allocation request status for the subscriptionId by allocationId.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String managementGroupId, String groupQuotaName,
- String allocationId, Context context);
-
- /**
- * Get the status of the quota allocation request for the subscriptionId.
- *
- * Get the quota allocation request status for the subscriptionId by allocationId.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- QuotaAllocationRequestStatusInner get(String managementGroupId, String groupQuotaName, String allocationId);
-
- /**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
- *
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter);
-
- /**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
- *
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context);
-
/**
* Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * with 202 response and status polling API.
*
* Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
* reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
* So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return the {@link SyncPoller} for polling of subscription quota list.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest);
+ SyncPoller, SubscriptionQuotaAllocationsListInner> beginUpdate(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest);
/**
* Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * with 202 response and status polling API.
*
* Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
* reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
* So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return the {@link SyncPoller} for polling of subscription quota list.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context);
+ SyncPoller, SubscriptionQuotaAllocationsListInner> beginUpdate(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest, Context context);
/**
* Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * with 202 response and status polling API.
*
* Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
* reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
* So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
+ * @return subscription quota list.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest);
+ SubscriptionQuotaAllocationsListInner update(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest);
/**
* Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * with 202 response and status polling API.
*
* Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
* reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
* So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
+ * @return subscription quota list.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context);
+ SubscriptionQuotaAllocationsListInner update(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest,
+ Context context);
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, QuotaAllocationRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String allocationId, Context context);
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
+ * @param allocationId Request Id.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return the quota allocation request status for the subscriptionId by allocationId.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, QuotaAllocationRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ QuotaAllocationRequestStatusInner get(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String allocationId);
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
+ *
+ * location eq {location}
+ * Example: $filter=location eq eastus.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
+ * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- QuotaAllocationRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String filter);
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
+ *
+ * location eq {location}
+ * Example: $filter=location eq eastus.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
+ * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- QuotaAllocationRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest,
- Context context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String filter, Context context);
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationsClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationsClient.java
index 6aa718444d0a4..38f5cf64598b4 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationsClient.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaSubscriptionAllocationsClient.java
@@ -6,113 +6,58 @@
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
-import com.azure.resourcemanager.quota.fluent.models.SubscriptionQuotaAllocationsInner;
+import com.azure.resourcemanager.quota.fluent.models.SubscriptionQuotaAllocationsListInner;
/**
* An instance of this class provides access to all the operations defined in GroupQuotaSubscriptionAllocationsClient.
*/
public interface GroupQuotaSubscriptionAllocationsClient {
/**
- * Gets all the quota allocated to a subscription for the specific Resource Provider, Location.
+ * Gets all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU}.
*
- * Gets all the quota allocated to a subscription for the specific Resource Provider, Location. This will include
- * the GroupQuota and total quota allocated to the subscription. Only the Group quota allocated to the subscription
- * can be allocated back to the MG Group Quota. Use the $filter parameter to filter out the specific resource based
- * on the ResourceProvider/Location. $filter is a required parameter.
+ * Gets all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU}. This will include the GroupQuota and total quota allocated to the
+ * subscription. Only the Group quota allocated to the subscription can be allocated back to the MG Group Quota.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quota allocated to a subscription for the specific Resource Provider, Location as paginated
- * response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String filter);
-
- /**
- * Gets all the quota allocated to a subscription for the specific Resource Provider, Location.
- *
- * Gets all the quota allocated to a subscription for the specific Resource Provider, Location. This will include
- * the GroupQuota and total quota allocated to the subscription. Only the Group quota allocated to the subscription
- * can be allocated back to the MG Group Quota. Use the $filter parameter to filter out the specific resource based
- * on the ResourceProvider/Location. $filter is a required parameter.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quota allocated to a subscription for the specific Resource Provider, Location as paginated
- * response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String filter, Context context);
-
- /**
- * Gets Quota allocated to a subscription for the specific Resource Provider, Location, ResourceName.
- *
- * Gets Quota allocated to a subscription for the specific Resource Provider, Location, ResourceName. This will
- * include the GroupQuota and total quota allocated to the subscription. Only the Group quota allocated to the
- * subscription can be allocated back to the MG Group Quota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return quota allocated to a subscription for the specific Resource Provider, Location, ResourceName along with
- * {@link Response}.
+ * @return all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU} along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceName, String filter, Context context);
+ Response listWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, Context context);
/**
- * Gets Quota allocated to a subscription for the specific Resource Provider, Location, ResourceName.
+ * Gets all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU}.
*
- * Gets Quota allocated to a subscription for the specific Resource Provider, Location, ResourceName. This will
- * include the GroupQuota and total quota allocated to the subscription. Only the Group quota allocated to the
- * subscription can be allocated back to the MG Group Quota.
+ * Gets all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU}. This will include the GroupQuota and total quota allocated to the
+ * subscription. Only the Group quota allocated to the subscription can be allocated back to the MG Group Quota.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return quota allocated to a subscription for the specific Resource Provider, Location, ResourceName.
+ * @return all the quota allocated to a subscription for the specified resource provider and location for resource
+ * names passed in $filter=resourceName eq {SKU}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- SubscriptionQuotaAllocationsInner get(String managementGroupId, String groupQuotaName, String resourceName,
- String filter);
+ SubscriptionQuotaAllocationsListInner list(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location);
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaUsagesClient.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaUsagesClient.java
deleted file mode 100644
index 45e838d69824c..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/GroupQuotaUsagesClient.java
+++ /dev/null
@@ -1,55 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.quota.fluent.models.ResourceUsagesInner;
-
-/**
- * An instance of this class provides access to all the operations defined in GroupQuotaUsagesClient.
- */
-public interface GroupQuotaUsagesClient {
- /**
- * Gets the GroupQuotas usages and limits(quota) for the resourceProvider/location.
- *
- * Gets the GroupQuotas usages and limits(quota). Location is required paramter.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas usages and limits(quota) as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location);
-
- /**
- * Gets the GroupQuotas usages and limits(quota) for the resourceProvider/location.
- *
- * Gets the GroupQuotas usages and limits(quota). Location is required paramter.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas usages and limits(quota) as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, Context context);
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitInner.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitInner.java
deleted file mode 100644
index bab9f6529dc27..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitInner.java
+++ /dev/null
@@ -1,166 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import com.azure.resourcemanager.quota.models.GroupQuotaDetails;
-import java.io.IOException;
-
-/**
- * Group Quota limit.
- */
-@Fluent
-public final class GroupQuotaLimitInner extends ProxyResource {
- /*
- * Group Quota properties for the specified resource.
- */
- private GroupQuotaDetails properties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- private SystemData systemData;
-
- /*
- * The type of the resource.
- */
- private String type;
-
- /*
- * The name of the resource.
- */
- private String name;
-
- /*
- * Fully qualified resource Id for the resource.
- */
- private String id;
-
- /**
- * Creates an instance of GroupQuotaLimitInner class.
- */
- public GroupQuotaLimitInner() {
- }
-
- /**
- * Get the properties property: Group Quota properties for the specified resource.
- *
- * @return the properties value.
- */
- public GroupQuotaDetails properties() {
- return this.properties;
- }
-
- /**
- * Set the properties property: Group Quota properties for the specified resource.
- *
- * @param properties the properties value to set.
- * @return the GroupQuotaLimitInner object itself.
- */
- public GroupQuotaLimitInner withProperties(GroupQuotaDetails properties) {
- this.properties = properties;
- return this;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the type property: The type of the resource.
- *
- * @return the type value.
- */
- @Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the name property: The name of the resource.
- *
- * @return the name value.
- */
- @Override
- public String name() {
- return this.name;
- }
-
- /**
- * Get the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- @Override
- public String id() {
- return this.id;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (properties() != null) {
- properties().validate();
- }
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeJsonField("properties", this.properties);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of GroupQuotaLimitInner from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of GroupQuotaLimitInner if the JsonReader was pointing to an instance of it, or null if it
- * was pointing to JSON null.
- * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the GroupQuotaLimitInner.
- */
- public static GroupQuotaLimitInner fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- GroupQuotaLimitInner deserializedGroupQuotaLimitInner = new GroupQuotaLimitInner();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("id".equals(fieldName)) {
- deserializedGroupQuotaLimitInner.id = reader.getString();
- } else if ("name".equals(fieldName)) {
- deserializedGroupQuotaLimitInner.name = reader.getString();
- } else if ("type".equals(fieldName)) {
- deserializedGroupQuotaLimitInner.type = reader.getString();
- } else if ("properties".equals(fieldName)) {
- deserializedGroupQuotaLimitInner.properties = GroupQuotaDetails.fromJson(reader);
- } else if ("systemData".equals(fieldName)) {
- deserializedGroupQuotaLimitInner.systemData = SystemData.fromJson(reader);
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedGroupQuotaLimitInner;
- });
- }
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/ResourceUsagesInner.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitListInner.java
similarity index 66%
rename from sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/ResourceUsagesInner.java
rename to sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitListInner.java
index ce8ba184776c0..144b286842ea7 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/ResourceUsagesInner.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaLimitListInner.java
@@ -10,18 +10,18 @@
import com.azure.json.JsonReader;
import com.azure.json.JsonToken;
import com.azure.json.JsonWriter;
-import com.azure.resourcemanager.quota.models.GroupQuotaUsagesBase;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitListProperties;
import java.io.IOException;
/**
- * Resource details with usages and GroupQuota.
+ * List of Group Quota Limit details.
*/
@Fluent
-public final class ResourceUsagesInner extends ProxyResource {
+public final class GroupQuotaLimitListInner extends ProxyResource {
/*
- * Resource details with usages and GroupQuota.
+ * The properties property.
*/
- private GroupQuotaUsagesBase properties;
+ private GroupQuotaLimitListProperties properties;
/*
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
@@ -44,27 +44,27 @@ public final class ResourceUsagesInner extends ProxyResource {
private String id;
/**
- * Creates an instance of ResourceUsagesInner class.
+ * Creates an instance of GroupQuotaLimitListInner class.
*/
- public ResourceUsagesInner() {
+ public GroupQuotaLimitListInner() {
}
/**
- * Get the properties property: Resource details with usages and GroupQuota.
+ * Get the properties property: The properties property.
*
* @return the properties value.
*/
- public GroupQuotaUsagesBase properties() {
+ public GroupQuotaLimitListProperties properties() {
return this.properties;
}
/**
- * Set the properties property: Resource details with usages and GroupQuota.
+ * Set the properties property: The properties property.
*
* @param properties the properties value to set.
- * @return the ResourceUsagesInner object itself.
+ * @return the GroupQuotaLimitListInner object itself.
*/
- public ResourceUsagesInner withProperties(GroupQuotaUsagesBase properties) {
+ public GroupQuotaLimitListInner withProperties(GroupQuotaLimitListProperties properties) {
this.properties = properties;
return this;
}
@@ -130,37 +130,37 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
}
/**
- * Reads an instance of ResourceUsagesInner from the JsonReader.
+ * Reads an instance of GroupQuotaLimitListInner from the JsonReader.
*
* @param jsonReader The JsonReader being read.
- * @return An instance of ResourceUsagesInner if the JsonReader was pointing to an instance of it, or null if it was
- * pointing to JSON null.
+ * @return An instance of GroupQuotaLimitListInner if the JsonReader was pointing to an instance of it, or null if
+ * it was pointing to JSON null.
* @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the ResourceUsagesInner.
+ * @throws IOException If an error occurs while reading the GroupQuotaLimitListInner.
*/
- public static ResourceUsagesInner fromJson(JsonReader jsonReader) throws IOException {
+ public static GroupQuotaLimitListInner fromJson(JsonReader jsonReader) throws IOException {
return jsonReader.readObject(reader -> {
- ResourceUsagesInner deserializedResourceUsagesInner = new ResourceUsagesInner();
+ GroupQuotaLimitListInner deserializedGroupQuotaLimitListInner = new GroupQuotaLimitListInner();
while (reader.nextToken() != JsonToken.END_OBJECT) {
String fieldName = reader.getFieldName();
reader.nextToken();
if ("id".equals(fieldName)) {
- deserializedResourceUsagesInner.id = reader.getString();
+ deserializedGroupQuotaLimitListInner.id = reader.getString();
} else if ("name".equals(fieldName)) {
- deserializedResourceUsagesInner.name = reader.getString();
+ deserializedGroupQuotaLimitListInner.name = reader.getString();
} else if ("type".equals(fieldName)) {
- deserializedResourceUsagesInner.type = reader.getString();
+ deserializedGroupQuotaLimitListInner.type = reader.getString();
} else if ("properties".equals(fieldName)) {
- deserializedResourceUsagesInner.properties = GroupQuotaUsagesBase.fromJson(reader);
+ deserializedGroupQuotaLimitListInner.properties = GroupQuotaLimitListProperties.fromJson(reader);
} else if ("systemData".equals(fieldName)) {
- deserializedResourceUsagesInner.systemData = SystemData.fromJson(reader);
+ deserializedGroupQuotaLimitListInner.systemData = SystemData.fromJson(reader);
} else {
reader.skipChildren();
}
}
- return deserializedResourceUsagesInner;
+ return deserializedGroupQuotaLimitListInner;
});
}
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaUsagesBaseName.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaUsagesBaseName.java
deleted file mode 100644
index df895d094d8d0..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotaUsagesBaseName.java
+++ /dev/null
@@ -1,110 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonSerializable;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import java.io.IOException;
-
-/**
- * Name of the resource provided by the resource provider. This property is already included in the request URI, so it
- * is a readonly property returned in the response.
- */
-@Fluent
-public final class GroupQuotaUsagesBaseName implements JsonSerializable {
- /*
- * Resource name.
- */
- private String value;
-
- /*
- * Resource display name.
- */
- private String localizedValue;
-
- /**
- * Creates an instance of GroupQuotaUsagesBaseName class.
- */
- public GroupQuotaUsagesBaseName() {
- }
-
- /**
- * Get the value property: Resource name.
- *
- * @return the value value.
- */
- public String value() {
- return this.value;
- }
-
- /**
- * Set the value property: Resource name.
- *
- * @param value the value value to set.
- * @return the GroupQuotaUsagesBaseName object itself.
- */
- public GroupQuotaUsagesBaseName withValue(String value) {
- this.value = value;
- return this;
- }
-
- /**
- * Get the localizedValue property: Resource display name.
- *
- * @return the localizedValue value.
- */
- public String localizedValue() {
- return this.localizedValue;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeStringField("value", this.value);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of GroupQuotaUsagesBaseName from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of GroupQuotaUsagesBaseName if the JsonReader was pointing to an instance of it, or null if
- * it was pointing to JSON null.
- * @throws IOException If an error occurs while reading the GroupQuotaUsagesBaseName.
- */
- public static GroupQuotaUsagesBaseName fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- GroupQuotaUsagesBaseName deserializedGroupQuotaUsagesBaseName = new GroupQuotaUsagesBaseName();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("value".equals(fieldName)) {
- deserializedGroupQuotaUsagesBaseName.value = reader.getString();
- } else if ("localizedValue".equals(fieldName)) {
- deserializedGroupQuotaUsagesBaseName.localizedValue = reader.getString();
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedGroupQuotaUsagesBaseName;
- });
- }
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEntityInner.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEntityInner.java
index 2723af0efbaa1..1a1a051189a72 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEntityInner.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEntityInner.java
@@ -10,7 +10,7 @@
import com.azure.json.JsonReader;
import com.azure.json.JsonToken;
import com.azure.json.JsonWriter;
-import com.azure.resourcemanager.quota.models.GroupQuotasEntityBase;
+import com.azure.resourcemanager.quota.models.GroupQuotasEntityProperties;
import java.io.IOException;
/**
@@ -19,9 +19,9 @@
@Fluent
public final class GroupQuotasEntityInner extends ProxyResource {
/*
- * Properties and filters for ShareQuota. The request parameter is optional, if there are no filters specified.
+ * Properties
*/
- private GroupQuotasEntityBase properties;
+ private GroupQuotasEntityProperties properties;
/*
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
@@ -50,23 +50,21 @@ public GroupQuotasEntityInner() {
}
/**
- * Get the properties property: Properties and filters for ShareQuota. The request parameter is optional, if there
- * are no filters specified.
+ * Get the properties property: Properties.
*
* @return the properties value.
*/
- public GroupQuotasEntityBase properties() {
+ public GroupQuotasEntityProperties properties() {
return this.properties;
}
/**
- * Set the properties property: Properties and filters for ShareQuota. The request parameter is optional, if there
- * are no filters specified.
+ * Set the properties property: Properties.
*
* @param properties the properties value to set.
* @return the GroupQuotasEntityInner object itself.
*/
- public GroupQuotasEntityInner withProperties(GroupQuotasEntityBase properties) {
+ public GroupQuotasEntityInner withProperties(GroupQuotasEntityProperties properties) {
this.properties = properties;
return this;
}
@@ -154,7 +152,7 @@ public static GroupQuotasEntityInner fromJson(JsonReader jsonReader) throws IOEx
} else if ("type".equals(fieldName)) {
deserializedGroupQuotasEntityInner.type = reader.getString();
} else if ("properties".equals(fieldName)) {
- deserializedGroupQuotasEntityInner.properties = GroupQuotasEntityBase.fromJson(reader);
+ deserializedGroupQuotasEntityInner.properties = GroupQuotasEntityProperties.fromJson(reader);
} else if ("systemData".equals(fieldName)) {
deserializedGroupQuotasEntityInner.systemData = SystemData.fromJson(reader);
} else {
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsInner.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsInner.java
deleted file mode 100644
index dcd7811492253..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsInner.java
+++ /dev/null
@@ -1,170 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import com.azure.resourcemanager.quota.models.SubscriptionQuotaDetails;
-import java.io.IOException;
-
-/**
- * Quota allocated to a subscription for the specific Resource Provider, Location, ResourceName. This will include the
- * GroupQuota and total quota allocated to the subscription. Only the Group quota allocated to the subscription can be
- * allocated back to the MG Group Quota.
- */
-@Fluent
-public final class SubscriptionQuotaAllocationsInner extends ProxyResource {
- /*
- * Quota properties for the specified resource.
- */
- private SubscriptionQuotaDetails properties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- private SystemData systemData;
-
- /*
- * The type of the resource.
- */
- private String type;
-
- /*
- * The name of the resource.
- */
- private String name;
-
- /*
- * Fully qualified resource Id for the resource.
- */
- private String id;
-
- /**
- * Creates an instance of SubscriptionQuotaAllocationsInner class.
- */
- public SubscriptionQuotaAllocationsInner() {
- }
-
- /**
- * Get the properties property: Quota properties for the specified resource.
- *
- * @return the properties value.
- */
- public SubscriptionQuotaDetails properties() {
- return this.properties;
- }
-
- /**
- * Set the properties property: Quota properties for the specified resource.
- *
- * @param properties the properties value to set.
- * @return the SubscriptionQuotaAllocationsInner object itself.
- */
- public SubscriptionQuotaAllocationsInner withProperties(SubscriptionQuotaDetails properties) {
- this.properties = properties;
- return this;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the type property: The type of the resource.
- *
- * @return the type value.
- */
- @Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the name property: The name of the resource.
- *
- * @return the name value.
- */
- @Override
- public String name() {
- return this.name;
- }
-
- /**
- * Get the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- @Override
- public String id() {
- return this.id;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (properties() != null) {
- properties().validate();
- }
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeJsonField("properties", this.properties);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SubscriptionQuotaAllocationsInner from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SubscriptionQuotaAllocationsInner if the JsonReader was pointing to an instance of it, or
- * null if it was pointing to JSON null.
- * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the SubscriptionQuotaAllocationsInner.
- */
- public static SubscriptionQuotaAllocationsInner fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SubscriptionQuotaAllocationsInner deserializedSubscriptionQuotaAllocationsInner
- = new SubscriptionQuotaAllocationsInner();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("id".equals(fieldName)) {
- deserializedSubscriptionQuotaAllocationsInner.id = reader.getString();
- } else if ("name".equals(fieldName)) {
- deserializedSubscriptionQuotaAllocationsInner.name = reader.getString();
- } else if ("type".equals(fieldName)) {
- deserializedSubscriptionQuotaAllocationsInner.type = reader.getString();
- } else if ("properties".equals(fieldName)) {
- deserializedSubscriptionQuotaAllocationsInner.properties
- = SubscriptionQuotaDetails.fromJson(reader);
- } else if ("systemData".equals(fieldName)) {
- deserializedSubscriptionQuotaAllocationsInner.systemData = SystemData.fromJson(reader);
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSubscriptionQuotaAllocationsInner;
- });
- }
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEnforcementResponseInner.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsListInner.java
similarity index 66%
rename from sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEnforcementResponseInner.java
rename to sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsListInner.java
index 944dafb7735c9..99bc7270d5dbf 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/GroupQuotasEnforcementResponseInner.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/fluent/models/SubscriptionQuotaAllocationsListInner.java
@@ -10,18 +10,18 @@
import com.azure.json.JsonReader;
import com.azure.json.JsonToken;
import com.azure.json.JsonWriter;
-import com.azure.resourcemanager.quota.models.GroupQuotasEnforcementResponseProperties;
+import com.azure.resourcemanager.quota.models.SubscriptionQuotaAllocationsListProperties;
import java.io.IOException;
/**
- * The GroupQuota Enforcement status for a Azure Location/Region.
+ * Subscription quota list.
*/
@Fluent
-public final class GroupQuotasEnforcementResponseInner extends ProxyResource {
+public final class SubscriptionQuotaAllocationsListInner extends ProxyResource {
/*
* The properties property.
*/
- private GroupQuotasEnforcementResponseProperties properties;
+ private SubscriptionQuotaAllocationsListProperties properties;
/*
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
@@ -44,9 +44,9 @@ public final class GroupQuotasEnforcementResponseInner extends ProxyResource {
private String id;
/**
- * Creates an instance of GroupQuotasEnforcementResponseInner class.
+ * Creates an instance of SubscriptionQuotaAllocationsListInner class.
*/
- public GroupQuotasEnforcementResponseInner() {
+ public SubscriptionQuotaAllocationsListInner() {
}
/**
@@ -54,7 +54,7 @@ public GroupQuotasEnforcementResponseInner() {
*
* @return the properties value.
*/
- public GroupQuotasEnforcementResponseProperties properties() {
+ public SubscriptionQuotaAllocationsListProperties properties() {
return this.properties;
}
@@ -62,9 +62,9 @@ public GroupQuotasEnforcementResponseProperties properties() {
* Set the properties property: The properties property.
*
* @param properties the properties value to set.
- * @return the GroupQuotasEnforcementResponseInner object itself.
+ * @return the SubscriptionQuotaAllocationsListInner object itself.
*/
- public GroupQuotasEnforcementResponseInner withProperties(GroupQuotasEnforcementResponseProperties properties) {
+ public SubscriptionQuotaAllocationsListInner withProperties(SubscriptionQuotaAllocationsListProperties properties) {
this.properties = properties;
return this;
}
@@ -130,39 +130,39 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
}
/**
- * Reads an instance of GroupQuotasEnforcementResponseInner from the JsonReader.
+ * Reads an instance of SubscriptionQuotaAllocationsListInner from the JsonReader.
*
* @param jsonReader The JsonReader being read.
- * @return An instance of GroupQuotasEnforcementResponseInner if the JsonReader was pointing to an instance of it,
+ * @return An instance of SubscriptionQuotaAllocationsListInner if the JsonReader was pointing to an instance of it,
* or null if it was pointing to JSON null.
* @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the GroupQuotasEnforcementResponseInner.
+ * @throws IOException If an error occurs while reading the SubscriptionQuotaAllocationsListInner.
*/
- public static GroupQuotasEnforcementResponseInner fromJson(JsonReader jsonReader) throws IOException {
+ public static SubscriptionQuotaAllocationsListInner fromJson(JsonReader jsonReader) throws IOException {
return jsonReader.readObject(reader -> {
- GroupQuotasEnforcementResponseInner deserializedGroupQuotasEnforcementResponseInner
- = new GroupQuotasEnforcementResponseInner();
+ SubscriptionQuotaAllocationsListInner deserializedSubscriptionQuotaAllocationsListInner
+ = new SubscriptionQuotaAllocationsListInner();
while (reader.nextToken() != JsonToken.END_OBJECT) {
String fieldName = reader.getFieldName();
reader.nextToken();
if ("id".equals(fieldName)) {
- deserializedGroupQuotasEnforcementResponseInner.id = reader.getString();
+ deserializedSubscriptionQuotaAllocationsListInner.id = reader.getString();
} else if ("name".equals(fieldName)) {
- deserializedGroupQuotasEnforcementResponseInner.name = reader.getString();
+ deserializedSubscriptionQuotaAllocationsListInner.name = reader.getString();
} else if ("type".equals(fieldName)) {
- deserializedGroupQuotasEnforcementResponseInner.type = reader.getString();
+ deserializedSubscriptionQuotaAllocationsListInner.type = reader.getString();
} else if ("properties".equals(fieldName)) {
- deserializedGroupQuotasEnforcementResponseInner.properties
- = GroupQuotasEnforcementResponseProperties.fromJson(reader);
+ deserializedSubscriptionQuotaAllocationsListInner.properties
+ = SubscriptionQuotaAllocationsListProperties.fromJson(reader);
} else if ("systemData".equals(fieldName)) {
- deserializedGroupQuotasEnforcementResponseInner.systemData = SystemData.fromJson(reader);
+ deserializedSubscriptionQuotaAllocationsListInner.systemData = SystemData.fromJson(reader);
} else {
reader.skipChildren();
}
}
- return deserializedGroupQuotasEnforcementResponseInner;
+ return deserializedSubscriptionQuotaAllocationsListInner;
});
}
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/AzureQuotaExtensionApiImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/AzureQuotaExtensionApiImpl.java
index 7109619c4e87e..7785fd5cdd1dc 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/AzureQuotaExtensionApiImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/AzureQuotaExtensionApiImpl.java
@@ -26,12 +26,10 @@
import com.azure.resourcemanager.quota.fluent.AzureQuotaExtensionApi;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsRequestsClient;
-import com.azure.resourcemanager.quota.fluent.GroupQuotaLocationSettingsClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotaSubscriptionAllocationRequestsClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotaSubscriptionAllocationsClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotaSubscriptionRequestsClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotaSubscriptionsClient;
-import com.azure.resourcemanager.quota.fluent.GroupQuotaUsagesClient;
import com.azure.resourcemanager.quota.fluent.GroupQuotasClient;
import com.azure.resourcemanager.quota.fluent.QuotaOperationsClient;
import com.azure.resourcemanager.quota.fluent.QuotaRequestStatusClient;
@@ -177,20 +175,6 @@ public GroupQuotaSubscriptionRequestsClient getGroupQuotaSubscriptionRequests()
return this.groupQuotaSubscriptionRequests;
}
- /**
- * The GroupQuotaLimitsClient object to access its operations.
- */
- private final GroupQuotaLimitsClient groupQuotaLimits;
-
- /**
- * Gets the GroupQuotaLimitsClient object to access its operations.
- *
- * @return the GroupQuotaLimitsClient object.
- */
- public GroupQuotaLimitsClient getGroupQuotaLimits() {
- return this.groupQuotaLimits;
- }
-
/**
* The GroupQuotaLimitsRequestsClient object to access its operations.
*/
@@ -206,17 +190,17 @@ public GroupQuotaLimitsRequestsClient getGroupQuotaLimitsRequests() {
}
/**
- * The GroupQuotaSubscriptionAllocationsClient object to access its operations.
+ * The GroupQuotaLimitsClient object to access its operations.
*/
- private final GroupQuotaSubscriptionAllocationsClient groupQuotaSubscriptionAllocations;
+ private final GroupQuotaLimitsClient groupQuotaLimits;
/**
- * Gets the GroupQuotaSubscriptionAllocationsClient object to access its operations.
+ * Gets the GroupQuotaLimitsClient object to access its operations.
*
- * @return the GroupQuotaSubscriptionAllocationsClient object.
+ * @return the GroupQuotaLimitsClient object.
*/
- public GroupQuotaSubscriptionAllocationsClient getGroupQuotaSubscriptionAllocations() {
- return this.groupQuotaSubscriptionAllocations;
+ public GroupQuotaLimitsClient getGroupQuotaLimits() {
+ return this.groupQuotaLimits;
}
/**
@@ -234,31 +218,17 @@ public GroupQuotaSubscriptionAllocationRequestsClient getGroupQuotaSubscriptionA
}
/**
- * The GroupQuotaUsagesClient object to access its operations.
- */
- private final GroupQuotaUsagesClient groupQuotaUsages;
-
- /**
- * Gets the GroupQuotaUsagesClient object to access its operations.
- *
- * @return the GroupQuotaUsagesClient object.
- */
- public GroupQuotaUsagesClient getGroupQuotaUsages() {
- return this.groupQuotaUsages;
- }
-
- /**
- * The GroupQuotaLocationSettingsClient object to access its operations.
+ * The GroupQuotaSubscriptionAllocationsClient object to access its operations.
*/
- private final GroupQuotaLocationSettingsClient groupQuotaLocationSettings;
+ private final GroupQuotaSubscriptionAllocationsClient groupQuotaSubscriptionAllocations;
/**
- * Gets the GroupQuotaLocationSettingsClient object to access its operations.
+ * Gets the GroupQuotaSubscriptionAllocationsClient object to access its operations.
*
- * @return the GroupQuotaLocationSettingsClient object.
+ * @return the GroupQuotaSubscriptionAllocationsClient object.
*/
- public GroupQuotaLocationSettingsClient getGroupQuotaLocationSettings() {
- return this.groupQuotaLocationSettings;
+ public GroupQuotaSubscriptionAllocationsClient getGroupQuotaSubscriptionAllocations() {
+ return this.groupQuotaSubscriptionAllocations;
}
/**
@@ -334,16 +304,14 @@ public QuotaOperationsClient getQuotaOperations() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2023-06-01-preview";
+ this.apiVersion = "2024-12-18-preview";
this.groupQuotas = new GroupQuotasClientImpl(this);
this.groupQuotaSubscriptions = new GroupQuotaSubscriptionsClientImpl(this);
this.groupQuotaSubscriptionRequests = new GroupQuotaSubscriptionRequestsClientImpl(this);
- this.groupQuotaLimits = new GroupQuotaLimitsClientImpl(this);
this.groupQuotaLimitsRequests = new GroupQuotaLimitsRequestsClientImpl(this);
- this.groupQuotaSubscriptionAllocations = new GroupQuotaSubscriptionAllocationsClientImpl(this);
+ this.groupQuotaLimits = new GroupQuotaLimitsClientImpl(this);
this.groupQuotaSubscriptionAllocationRequests = new GroupQuotaSubscriptionAllocationRequestsClientImpl(this);
- this.groupQuotaUsages = new GroupQuotaUsagesClientImpl(this);
- this.groupQuotaLocationSettings = new GroupQuotaLocationSettingsClientImpl(this);
+ this.groupQuotaSubscriptionAllocations = new GroupQuotaSubscriptionAllocationsClientImpl(this);
this.usages = new UsagesClientImpl(this);
this.quotas = new QuotasClientImpl(this);
this.quotaRequestStatus = new QuotaRequestStatusClientImpl(this);
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitListImpl.java
similarity index 65%
rename from sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitImpl.java
rename to sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitListImpl.java
index bd8ac2a0f09dc..01bcc6bcbcf7b 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitListImpl.java
@@ -5,16 +5,17 @@
package com.azure.resourcemanager.quota.implementation;
import com.azure.core.management.SystemData;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitInner;
-import com.azure.resourcemanager.quota.models.GroupQuotaDetails;
-import com.azure.resourcemanager.quota.models.GroupQuotaLimit;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitList;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitListProperties;
-public final class GroupQuotaLimitImpl implements GroupQuotaLimit {
- private GroupQuotaLimitInner innerObject;
+public final class GroupQuotaLimitListImpl implements GroupQuotaLimitList {
+ private GroupQuotaLimitListInner innerObject;
private final com.azure.resourcemanager.quota.QuotaManager serviceManager;
- GroupQuotaLimitImpl(GroupQuotaLimitInner innerObject, com.azure.resourcemanager.quota.QuotaManager serviceManager) {
+ GroupQuotaLimitListImpl(GroupQuotaLimitListInner innerObject,
+ com.azure.resourcemanager.quota.QuotaManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
}
@@ -31,7 +32,7 @@ public String type() {
return this.innerModel().type();
}
- public GroupQuotaDetails properties() {
+ public GroupQuotaLimitListProperties properties() {
return this.innerModel().properties();
}
@@ -39,7 +40,7 @@ public SystemData systemData() {
return this.innerModel().systemData();
}
- public GroupQuotaLimitInner innerModel() {
+ public GroupQuotaLimitListInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsClientImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsClientImpl.java
index 97c9435025fe8..32f9a9a0e7991 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsClientImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsClientImpl.java
@@ -16,18 +16,13 @@
import com.azure.core.annotation.ServiceInterface;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.RestProxy;
import com.azure.core.management.exception.ManagementException;
import com.azure.core.util.Context;
import com.azure.core.util.FluxUtil;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsClient;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitInner;
-import com.azure.resourcemanager.quota.models.GroupQuotaLimitList;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
import reactor.core.publisher.Mono;
/**
@@ -63,63 +58,34 @@ public final class GroupQuotaLimitsClientImpl implements GroupQuotaLimitsClient
@ServiceInterface(name = "AzureQuotaExtensionA")
public interface GroupQuotaLimitsService {
@Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaLimits/{resourceName}")
+ @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaLimits/{location}")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
+ Mono> list(@HostParam("$host") String endpoint,
@PathParam("managementGroupId") String managementGroupId,
@PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @PathParam("resourceName") String resourceName, @QueryParam("api-version") String apiVersion,
- @QueryParam("$filter") String filter, @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaLimits")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @QueryParam("api-version") String apiVersion, @QueryParam("$filter") String filter,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listNext(@PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint, @HeaderParam("Accept") String accept, Context context);
+ @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
+ @QueryParam("api-version") String apiVersion, @HeaderParam("Accept") String accept, Context context);
}
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link Response} on successful completion of {@link Mono}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU} along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter) {
+ private Mono> listWithResponseAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String location) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -135,48 +101,35 @@ private Mono> getWithResponseAsync(String managem
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
}
final String accept = "application/json";
return FluxUtil
- .withContext(context -> service.get(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, this.client.getApiVersion(), filter, accept, context))
+ .withContext(context -> service.list(this.client.getEndpoint(), managementGroupId, groupQuotaName,
+ resourceProviderName, location, this.client.getApiVersion(), accept, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link Response} on successful completion of {@link Mono}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU} along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter, Context context) {
+ private Mono> listWithResponseAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String location, Context context) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -192,387 +145,79 @@ private Mono> getWithResponseAsync(String managem
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
}
final String accept = "application/json";
context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
- resourceName, this.client.getApiVersion(), filter, accept, context);
+ return service.list(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
+ location, this.client.getApiVersion(), accept, context);
}
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota on successful completion
- * of {@link Mono}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, filter)
+ private Mono listAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location) {
+ return listWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, location)
.flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter, Context context) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, filter,
- context).block();
- }
-
- /**
- * Gets the GroupQuotaLimits for the specific resource.
- *
- * Gets the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the specific resource for a specific resource based on the resourceProviders,
- * resourceName and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public GroupQuotaLimitInner get(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, String filter) {
- return getWithResponse(managementGroupId, groupQuotaName, resourceProviderName, resourceName, filter,
- Context.NONE).getValue();
- }
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link PagedResponse} on successful completion of {@link Mono}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU} along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String filter) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.list(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, this.client.getApiVersion(), filter, accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ public Response listWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, Context context) {
+ return listWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, location, context)
+ .block();
}
/**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
+ * Gets the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota along with
- * {@link PagedResponse} on successful completion of {@link Mono}.
+ * @return the GroupQuotaLimits for the specified resource provider and location for resource names passed in
+ * $filter=resourceName eq {SKU}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String filter, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
- this.client.getApiVersion(), filter, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, filter),
- nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, filter, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName, filter));
- }
-
- /**
- * Gets the GroupQuotaLimits for all the resources for the specified location in $filter=location eq {location}.
- *
- * Gets the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotaLimits for the all resource for a specific resourceProvider and $filter passed.
- * The $filter=location eq {location} is required to location specific resources groupQuota as paginated response
- * with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName, filter, context));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Group Quota Limit details along with {@link PagedResponse} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil.withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Group Quota Limit details along with {@link PagedResponse} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink, Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
+ public GroupQuotaLimitListInner list(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location) {
+ return listWithResponse(managementGroupId, groupQuotaName, resourceProviderName, location, Context.NONE)
+ .getValue();
}
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsImpl.java
index 8fc70a38820e7..3b14b090e101e 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsImpl.java
@@ -4,14 +4,13 @@
package com.azure.resourcemanager.quota.implementation;
-import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.SimpleResponse;
import com.azure.core.util.Context;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsClient;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitInner;
-import com.azure.resourcemanager.quota.models.GroupQuotaLimit;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitList;
import com.azure.resourcemanager.quota.models.GroupQuotaLimits;
public final class GroupQuotaLimitsImpl implements GroupQuotaLimits {
@@ -27,43 +26,29 @@ public GroupQuotaLimitsImpl(GroupQuotaLimitsClient innerClient,
this.serviceManager = serviceManager;
}
- public Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, String filter, Context context) {
- Response inner = this.serviceClient()
- .getWithResponse(managementGroupId, groupQuotaName, resourceProviderName, resourceName, filter, context);
+ public Response listWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, Context context) {
+ Response inner = this.serviceClient()
+ .listWithResponse(managementGroupId, groupQuotaName, resourceProviderName, location, context);
if (inner != null) {
return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
- new GroupQuotaLimitImpl(inner.getValue(), this.manager()));
+ new GroupQuotaLimitListImpl(inner.getValue(), this.manager()));
} else {
return null;
}
}
- public GroupQuotaLimit get(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, String filter) {
- GroupQuotaLimitInner inner
- = this.serviceClient().get(managementGroupId, groupQuotaName, resourceProviderName, resourceName, filter);
+ public GroupQuotaLimitList list(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location) {
+ GroupQuotaLimitListInner inner
+ = this.serviceClient().list(managementGroupId, groupQuotaName, resourceProviderName, location);
if (inner != null) {
- return new GroupQuotaLimitImpl(inner, this.manager());
+ return new GroupQuotaLimitListImpl(inner, this.manager());
} else {
return null;
}
}
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter) {
- PagedIterable inner
- = this.serviceClient().list(managementGroupId, groupQuotaName, resourceProviderName, filter);
- return ResourceManagerUtils.mapPage(inner, inner1 -> new GroupQuotaLimitImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context) {
- PagedIterable inner
- = this.serviceClient().list(managementGroupId, groupQuotaName, resourceProviderName, filter, context);
- return ResourceManagerUtils.mapPage(inner, inner1 -> new GroupQuotaLimitImpl(inner1, this.manager()));
- }
-
private GroupQuotaLimitsClient serviceClient() {
return this.innerClient;
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsClientImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsClientImpl.java
index 783e76dc84a51..5129963836d49 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsClientImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsClientImpl.java
@@ -13,7 +13,6 @@
import com.azure.core.annotation.HostParam;
import com.azure.core.annotation.Patch;
import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
import com.azure.core.annotation.QueryParam;
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceInterface;
@@ -25,7 +24,6 @@
import com.azure.core.http.rest.PagedResponseBase;
import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.ProxyResource;
import com.azure.core.management.exception.ManagementException;
import com.azure.core.management.polling.PollResult;
import com.azure.core.util.Context;
@@ -33,6 +31,7 @@
import com.azure.core.util.polling.PollerFlux;
import com.azure.core.util.polling.SyncPoller;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsRequestsClient;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
import com.azure.resourcemanager.quota.fluent.models.SubmittedResourceRequestStatusInner;
import com.azure.resourcemanager.quota.models.SubmittedResourceRequestStatusList;
import java.nio.ByteBuffer;
@@ -72,27 +71,15 @@ public final class GroupQuotaLimitsRequestsClientImpl implements GroupQuotaLimit
@ServiceInterface(name = "AzureQuotaExtensionA")
public interface GroupQuotaLimitsRequestsService {
@Headers({ "Content-Type: application/json" })
- @Put("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaRequests/{resourceName}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> createOrUpdate(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @PathParam("resourceName") String resourceName, @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") SubmittedResourceRequestStatusInner groupQuotaRequest,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Patch("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaRequests/{resourceName}")
+ @Patch("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/groupQuotaLimits/{location}")
@ExpectedResponses({ 200, 202 })
@UnexpectedResponseExceptionType(ManagementException.class)
Mono>> update(@HostParam("$host") String endpoint,
@PathParam("managementGroupId") String managementGroupId,
@PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @PathParam("resourceName") String resourceName, @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") SubmittedResourceRequestStatusInner groupQuotaRequest,
+ @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") GroupQuotaLimitListInner groupQuotaRequest,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
@@ -124,419 +111,12 @@ Mono> listNext(
@HeaderParam("Accept") String accept, Context context);
}
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (groupQuotaRequest != null) {
- groupQuotaRequest.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, this.client.getApiVersion(), groupQuotaRequest, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (groupQuotaRequest != null) {
- groupQuotaRequest.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, this.client.getApiVersion(), groupQuotaRequest, accept, context);
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest) {
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, this.client.getContext());
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, this.client.getContext());
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest, context);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, context);
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest)
- .getSyncPoller();
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest, context)
- .getSyncPoller();
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest, context).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest).block();
- }
-
- /**
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource.
- *
- * Put the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * ("name": {"value" : "resourceName") properties are specified in the request body. Only 1 resource quota can be
- * requested.
- * Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
- * duration in seconds to check the intermediate status. This API provides the finals status with the request
- * details and status.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest, context).block();
- }
-
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -545,17 +125,16 @@ public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaN
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request along with {@link Response} on successful completion of
- * {@link Mono}.
+ * @return list of Group Quota Limit details along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest) {
+ String resourceProviderName, String location, GroupQuotaLimitListInner groupQuotaRequest) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -571,8 +150,8 @@ private Mono>> updateWithResponseAsync(String manageme
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
}
if (groupQuotaRequest != null) {
groupQuotaRequest.validate();
@@ -580,16 +159,16 @@ private Mono>> updateWithResponseAsync(String manageme
final String accept = "application/json";
return FluxUtil
.withContext(context -> service.update(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, this.client.getApiVersion(), groupQuotaRequest, accept, context))
+ resourceProviderName, location, this.client.getApiVersion(), groupQuotaRequest, accept, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -598,19 +177,17 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request along with {@link Response} on successful completion of
- * {@link Mono}.
+ * @return list of Group Quota Limit details along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context) {
+ String resourceProviderName, String location, GroupQuotaLimitListInner groupQuotaRequest, Context context) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -626,8 +203,8 @@ private Mono>> updateWithResponseAsync(String manageme
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
}
if (groupQuotaRequest != null) {
groupQuotaRequest.validate();
@@ -635,15 +212,15 @@ private Mono>> updateWithResponseAsync(String manageme
final String accept = "application/json";
context = this.client.mergeContext(context);
return service.update(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
- resourceName, this.client.getApiVersion(), groupQuotaRequest, accept, context);
+ location, this.client.getApiVersion(), groupQuotaRequest, accept, context);
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -652,30 +229,30 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
+ * @return the {@link PollerFlux} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, SubmittedResourceRequestStatusInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest) {
+ private PollerFlux, GroupQuotaLimitListInner> beginUpdateAsync(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ GroupQuotaLimitListInner groupQuotaRequest) {
Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), SubmittedResourceRequestStatusInner.class,
- SubmittedResourceRequestStatusInner.class, this.client.getContext());
+ resourceProviderName, location, groupQuotaRequest);
+ return this.client.getLroResult(mono,
+ this.client.getHttpPipeline(), GroupQuotaLimitListInner.class, GroupQuotaLimitListInner.class,
+ this.client.getContext());
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -684,30 +261,29 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
+ * @return the {@link PollerFlux} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, SubmittedResourceRequestStatusInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
+ private PollerFlux, GroupQuotaLimitListInner> beginUpdateAsync(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location) {
+ final GroupQuotaLimitListInner groupQuotaRequest = null;
Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), SubmittedResourceRequestStatusInner.class,
- SubmittedResourceRequestStatusInner.class, this.client.getContext());
+ resourceProviderName, location, groupQuotaRequest);
+ return this.client.getLroResult(mono,
+ this.client.getHttpPipeline(), GroupQuotaLimitListInner.class, GroupQuotaLimitListInner.class,
+ this.client.getContext());
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -716,32 +292,31 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of status of a single GroupQuota request.
+ * @return the {@link PollerFlux} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, SubmittedResourceRequestStatusInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
+ private PollerFlux, GroupQuotaLimitListInner> beginUpdateAsync(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ GroupQuotaLimitListInner groupQuotaRequest, Context context) {
context = this.client.mergeContext(context);
Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, groupQuotaRequest, context);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), SubmittedResourceRequestStatusInner.class,
- SubmittedResourceRequestStatusInner.class, context);
+ resourceProviderName, location, groupQuotaRequest, context);
+ return this.client.getLroResult(mono,
+ this.client.getHttpPipeline(), GroupQuotaLimitListInner.class, GroupQuotaLimitListInner.class, context);
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -750,27 +325,27 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
+ * @return the {@link SyncPoller} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, SubmittedResourceRequestStatusInner>
- beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
+ public SyncPoller, GroupQuotaLimitListInner>
+ beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String location) {
+ final GroupQuotaLimitListInner groupQuotaRequest = null;
return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest)
+ .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest)
.getSyncPoller();
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -779,20 +354,20 @@ private Mono>> updateWithResponseAsync(String manageme
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of status of a single GroupQuota request.
+ * @return the {@link SyncPoller} for polling of list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, SubmittedResourceRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
+ public SyncPoller, GroupQuotaLimitListInner> beginUpdate(
+ String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ GroupQuotaLimitListInner groupQuotaRequest, Context context) {
return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest,
+ .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest,
context)
.getSyncPoller();
}
@@ -800,9 +375,9 @@ public SyncPoller, SubmittedReso
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -811,26 +386,27 @@ public SyncPoller, SubmittedReso
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
+ * @return list of Group Quota Limit details on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest) {
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest).last().flatMap(this.client::getLroFinalResultOrError);
+ private Mono updateAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, GroupQuotaLimitListInner groupQuotaRequest) {
+ return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -839,26 +415,27 @@ private Mono updateAsync(String managementG
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
+ * @return list of Group Quota Limit details on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest).last().flatMap(this.client::getLroFinalResultOrError);
+ private Mono updateAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location) {
+ final GroupQuotaLimitListInner groupQuotaRequest = null;
+ return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -867,28 +444,27 @@ private Mono updateAsync(String managementG
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request on successful completion of {@link Mono}.
+ * @return list of Group Quota Limit details on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context) {
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- groupQuotaRequest, context).last().flatMap(this.client::getLroFinalResultOrError);
+ private Mono updateAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, GroupQuotaLimitListInner groupQuotaRequest, Context context) {
+ return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest,
+ context).last().flatMap(this.client::getLroFinalResultOrError);
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -897,26 +473,26 @@ private Mono updateAsync(String managementG
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
+ * @return list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public SubmittedResourceRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName) {
- final SubmittedResourceRequestStatusInner groupQuotaRequest = null;
- return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest)
+ public GroupQuotaLimitListInner update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location) {
+ final GroupQuotaLimitListInner groupQuotaRequest = null;
+ return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest)
.block();
}
/**
* Create the GroupQuota requests for a specific ResourceProvider/Location/Resource.
*
- * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. the location and resourceName
- * properties are specified in the request body. Only 1 resource quota can be requested. Please note that patch
- * request creates a new groupQuota request.
+ * Create the GroupQuota requests for a specific ResourceProvider/Location/Resource. The resourceName properties are
+ * specified in the request body. Only 1 resource quota can be requested. Please note that patch request creates a
+ * new groupQuota request.
* Use the polling API - OperationsStatus URI specified in Azure-AsyncOperation header field, with retry-after
* duration in seconds to check the intermediate status. This API provides the finals status with the request
* details and status.
@@ -925,19 +501,18 @@ public SubmittedResourceRequestStatusInner update(String managementGroupId, Stri
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
+ * @param location The name of the Azure region.
* @param groupQuotaRequest The GroupQuotaRequest body details for specific resourceProvider/location/resources.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return status of a single GroupQuota request.
+ * @return list of Group Quota Limit details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public SubmittedResourceRequestStatusInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context) {
- return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest,
+ public GroupQuotaLimitListInner update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location, GroupQuotaLimitListInner groupQuotaRequest, Context context) {
+ return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest,
context).block();
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsImpl.java
index e6af14e9daaaf..6edd2fb4b4ef2 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLimitsRequestsImpl.java
@@ -7,11 +7,12 @@
import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.SimpleResponse;
-import com.azure.core.management.ProxyResource;
import com.azure.core.util.Context;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.quota.fluent.GroupQuotaLimitsRequestsClient;
+import com.azure.resourcemanager.quota.fluent.models.GroupQuotaLimitListInner;
import com.azure.resourcemanager.quota.fluent.models.SubmittedResourceRequestStatusInner;
+import com.azure.resourcemanager.quota.models.GroupQuotaLimitList;
import com.azure.resourcemanager.quota.models.GroupQuotaLimitsRequests;
import com.azure.resourcemanager.quota.models.SubmittedResourceRequestStatus;
@@ -28,37 +29,23 @@ public GroupQuotaLimitsRequestsImpl(GroupQuotaLimitsRequestsClient innerClient,
this.serviceManager = serviceManager;
}
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName) {
- return this.serviceClient()
- .createOrUpdate(managementGroupId, groupQuotaName, resourceProviderName, resourceName);
- }
-
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest, Context context) {
- return this.serviceClient()
- .createOrUpdate(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest,
- context);
- }
-
- public SubmittedResourceRequestStatus update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName) {
- SubmittedResourceRequestStatusInner inner
- = this.serviceClient().update(managementGroupId, groupQuotaName, resourceProviderName, resourceName);
+ public GroupQuotaLimitList update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location) {
+ GroupQuotaLimitListInner inner
+ = this.serviceClient().update(managementGroupId, groupQuotaName, resourceProviderName, location);
if (inner != null) {
- return new SubmittedResourceRequestStatusImpl(inner, this.manager());
+ return new GroupQuotaLimitListImpl(inner, this.manager());
} else {
return null;
}
}
- public SubmittedResourceRequestStatus update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, SubmittedResourceRequestStatusInner groupQuotaRequest,
- Context context) {
- SubmittedResourceRequestStatusInner inner = this.serviceClient()
- .update(managementGroupId, groupQuotaName, resourceProviderName, resourceName, groupQuotaRequest, context);
+ public GroupQuotaLimitList update(String managementGroupId, String groupQuotaName, String resourceProviderName,
+ String location, GroupQuotaLimitListInner groupQuotaRequest, Context context) {
+ GroupQuotaLimitListInner inner = this.serviceClient()
+ .update(managementGroupId, groupQuotaName, resourceProviderName, location, groupQuotaRequest, context);
if (inner != null) {
- return new SubmittedResourceRequestStatusImpl(inner, this.manager());
+ return new GroupQuotaLimitListImpl(inner, this.manager());
} else {
return null;
}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsClientImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsClientImpl.java
deleted file mode 100644
index 7f58c00b99827..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsClientImpl.java
+++ /dev/null
@@ -1,1440 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.implementation;
-
-import com.azure.core.annotation.BodyParam;
-import com.azure.core.annotation.ExpectedResponses;
-import com.azure.core.annotation.Get;
-import com.azure.core.annotation.HeaderParam;
-import com.azure.core.annotation.Headers;
-import com.azure.core.annotation.Host;
-import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.Patch;
-import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
-import com.azure.core.annotation.QueryParam;
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceInterface;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.exception.ManagementException;
-import com.azure.core.management.polling.PollResult;
-import com.azure.core.util.Context;
-import com.azure.core.util.FluxUtil;
-import com.azure.core.util.polling.PollerFlux;
-import com.azure.core.util.polling.SyncPoller;
-import com.azure.resourcemanager.quota.fluent.GroupQuotaLocationSettingsClient;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEnforcementResponseInner;
-import com.azure.resourcemanager.quota.models.GroupQuotasEnforcementListResponse;
-import java.nio.ByteBuffer;
-import reactor.core.publisher.Flux;
-import reactor.core.publisher.Mono;
-
-/**
- * An instance of this class provides access to all the operations defined in GroupQuotaLocationSettingsClient.
- */
-public final class GroupQuotaLocationSettingsClientImpl implements GroupQuotaLocationSettingsClient {
- /**
- * The proxy service used to perform REST calls.
- */
- private final GroupQuotaLocationSettingsService service;
-
- /**
- * The service client containing this operation class.
- */
- private final AzureQuotaExtensionApiImpl client;
-
- /**
- * Initializes an instance of GroupQuotaLocationSettingsClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- GroupQuotaLocationSettingsClientImpl(AzureQuotaExtensionApiImpl client) {
- this.service = RestProxy.create(GroupQuotaLocationSettingsService.class, client.getHttpPipeline(),
- client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for AzureQuotaExtensionApiGroupQuotaLocationSettings to be used by the
- * proxy service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "AzureQuotaExtensionA")
- public interface GroupQuotaLocationSettingsService {
- @Headers({ "Content-Type: application/json" })
- @Put("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/locationSettings/{location}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> createOrUpdate(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
- @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") GroupQuotasEnforcementResponseInner locationSettings,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Patch("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/locationSettings/{location}")
- @ExpectedResponses({ 200, 202 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> update(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
- @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") GroupQuotasEnforcementResponseInner locationSettings,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/locationSettings/{location}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
- @QueryParam("api-version") String apiVersion, @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/locationSettings")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @QueryParam("api-version") String apiVersion, @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
- @HeaderParam("Accept") String accept, Context context);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region along with {@link Response} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- if (locationSettings != null) {
- locationSettings.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, location, this.client.getApiVersion(), locationSettings, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region along with {@link Response} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- if (locationSettings != null) {
- locationSettings.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, location, this.client.getApiVersion(), locationSettings, accept, context);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings) {
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, this.client.getContext());
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, this.client.getContext());
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings, context);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, context);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location,
- locationSettings)
- .getSyncPoller();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location,
- locationSettings, context)
- .getSyncPoller();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location,
- locationSettings).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location,
- locationSettings).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location,
- locationSettings, context).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings)
- .block();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location, GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings,
- context).block();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region along with {@link Response} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- if (locationSettings != null) {
- locationSettings.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.update(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, location, this.client.getApiVersion(), locationSettings, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region along with {@link Response} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- if (locationSettings != null) {
- locationSettings.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.update(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
- location, this.client.getApiVersion(), locationSettings, accept, context);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, GroupQuotasEnforcementResponseInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings) {
- Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), GroupQuotasEnforcementResponseInner.class,
- GroupQuotasEnforcementResponseInner.class, this.client.getContext());
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, GroupQuotasEnforcementResponseInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), GroupQuotasEnforcementResponseInner.class,
- GroupQuotasEnforcementResponseInner.class, this.client.getContext());
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, GroupQuotasEnforcementResponseInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, location, locationSettings, context);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), GroupQuotasEnforcementResponseInner.class,
- GroupQuotasEnforcementResponseInner.class, context);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, GroupQuotasEnforcementResponseInner>
- beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings)
- .getSyncPoller();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, GroupQuotasEnforcementResponseInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
- GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings,
- context)
- .getSyncPoller();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings) {
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings)
- .last()
- .flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context) {
- return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings,
- context).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public GroupQuotasEnforcementResponseInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- final GroupQuotasEnforcementResponseInner locationSettings = null;
- return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings).block();
- }
-
- /**
- * Enables the GroupQuotas enforcement settings for the resource provider and the location specified.
- *
- * Enables the GroupQuotas enforcement for the resource provider and the location specified. The resource provider
- * will start using the group quotas as the overall quota for the subscriptions included in the GroupQuota. The
- * subscriptions cannot request quota at subscription level.
- * The subscriptions share the GroupQuotaLimits assigned to the GroupQuota. If the GroupQuotaLimits is used, then
- * submit a groupQuotaLimit request for the specific resource - provider/location/resource.
- * Once the GroupQuota Enforcement is enabled then, it cannot be deleted or reverted back. To disable GroupQuota
- * Enforcement -
- * 1. Remove all the subscriptions from the groupQuota using the delete API for Subscriptions (Check the example -
- * GroupQuotaSubscriptions_Delete).
- * 2. Ten delete the GroupQuota (Check the example - GroupQuotas_Delete).
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param locationSettings The GroupQuota body details for creation or update of a GroupQuota entity.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuota Enforcement status for a Azure Location/Region.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public GroupQuotasEnforcementResponseInner update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context) {
- return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings, context)
- .block();
- }
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location along with {@link Response} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.get(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, location, this.client.getApiVersion(), accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location along with {@link Response} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (location == null) {
- return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName, location,
- this.client.getApiVersion(), accept, context);
- }
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, location)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String location, Context context) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, location, context).block();
- }
-
- /**
- * Gets the GroupQuotas enforcement settings for the resource provider/location.
- *
- * Gets the GroupQuotas enforcement settings for the ResourceProvider/location. The locations, where GroupQuota
- * enforcement is not enabled will return Not Found.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param location The name of the Azure region.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the GroupQuotas enforcement settings for the ResourceProvider/location.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public GroupQuotasEnforcementResponseInner get(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- return getWithResponse(managementGroupId, groupQuotaName, resourceProviderName, location, Context.NONE)
- .getValue();
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement along with {@link PagedResponse}
- * on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.list(this.client.getEndpoint(), managementGroupId, groupQuotaName,
- resourceProviderName, this.client.getApiVersion(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement along with {@link PagedResponse}
- * on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), managementGroupId, groupQuotaName, resourceProviderName,
- this.client.getApiVersion(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName) {
- return new PagedFlux<>(() -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName),
- nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName));
- }
-
- /**
- * Returns a list of the Azure regions settings, where the GroupQuotas enforcement is enabled.
- *
- * Returns only the list of the Azure regions settings, where the GroupQuotas enforcement is enabled. The locations
- * not included in GroupQuota Enforcement will not be listed, the regions in failed status with listed as status
- * Failed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement as paginated response with
- * {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, Context context) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName, context));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement along with {@link PagedResponse}
- * on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil.withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return list of Azure regions, where the group quotas is enabled for enforcement along with {@link PagedResponse}
- * on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink,
- Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsImpl.java
deleted file mode 100644
index 7a9a6908d8839..0000000000000
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaLocationSettingsImpl.java
+++ /dev/null
@@ -1,112 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.quota.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.SimpleResponse;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.quota.fluent.GroupQuotaLocationSettingsClient;
-import com.azure.resourcemanager.quota.fluent.models.GroupQuotasEnforcementResponseInner;
-import com.azure.resourcemanager.quota.models.GroupQuotaLocationSettings;
-import com.azure.resourcemanager.quota.models.GroupQuotasEnforcementResponse;
-
-public final class GroupQuotaLocationSettingsImpl implements GroupQuotaLocationSettings {
- private static final ClientLogger LOGGER = new ClientLogger(GroupQuotaLocationSettingsImpl.class);
-
- private final GroupQuotaLocationSettingsClient innerClient;
-
- private final com.azure.resourcemanager.quota.QuotaManager serviceManager;
-
- public GroupQuotaLocationSettingsImpl(GroupQuotaLocationSettingsClient innerClient,
- com.azure.resourcemanager.quota.QuotaManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location) {
- return this.serviceClient().createOrUpdate(managementGroupId, groupQuotaName, resourceProviderName, location);
- }
-
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String location, GroupQuotasEnforcementResponseInner locationSettings, Context context) {
- return this.serviceClient()
- .createOrUpdate(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings,
- context);
- }
-
- public GroupQuotasEnforcementResponse update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- GroupQuotasEnforcementResponseInner inner
- = this.serviceClient().update(managementGroupId, groupQuotaName, resourceProviderName, location);
- if (inner != null) {
- return new GroupQuotasEnforcementResponseImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public GroupQuotasEnforcementResponse update(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, GroupQuotasEnforcementResponseInner locationSettings,
- Context context) {
- GroupQuotasEnforcementResponseInner inner = this.serviceClient()
- .update(managementGroupId, groupQuotaName, resourceProviderName, location, locationSettings, context);
- if (inner != null) {
- return new GroupQuotasEnforcementResponseImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public Response getWithResponse(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location, Context context) {
- Response inner = this.serviceClient()
- .getWithResponse(managementGroupId, groupQuotaName, resourceProviderName, location, context);
- if (inner != null) {
- return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
- new GroupQuotasEnforcementResponseImpl(inner.getValue(), this.manager()));
- } else {
- return null;
- }
- }
-
- public GroupQuotasEnforcementResponse get(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String location) {
- GroupQuotasEnforcementResponseInner inner
- = this.serviceClient().get(managementGroupId, groupQuotaName, resourceProviderName, location);
- if (inner != null) {
- return new GroupQuotasEnforcementResponseImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName) {
- PagedIterable inner
- = this.serviceClient().list(managementGroupId, groupQuotaName, resourceProviderName);
- return ResourceManagerUtils.mapPage(inner,
- inner1 -> new GroupQuotasEnforcementResponseImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, Context context) {
- PagedIterable inner
- = this.serviceClient().list(managementGroupId, groupQuotaName, resourceProviderName, context);
- return ResourceManagerUtils.mapPage(inner,
- inner1 -> new GroupQuotasEnforcementResponseImpl(inner1, this.manager()));
- }
-
- private GroupQuotaLocationSettingsClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.quota.QuotaManager manager() {
- return this.serviceManager;
- }
-}
diff --git a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaSubscriptionAllocationRequestsClientImpl.java b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaSubscriptionAllocationRequestsClientImpl.java
index 36587b3a786de..0ec77f277a5d4 100644
--- a/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaSubscriptionAllocationRequestsClientImpl.java
+++ b/sdk/quota/azure-resourcemanager-quota/src/main/java/com/azure/resourcemanager/quota/implementation/GroupQuotaSubscriptionAllocationRequestsClientImpl.java
@@ -13,7 +13,6 @@
import com.azure.core.annotation.HostParam;
import com.azure.core.annotation.Patch;
import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
import com.azure.core.annotation.QueryParam;
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceInterface;
@@ -25,7 +24,6 @@
import com.azure.core.http.rest.PagedResponseBase;
import com.azure.core.http.rest.Response;
import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.ProxyResource;
import com.azure.core.management.exception.ManagementException;
import com.azure.core.management.polling.PollResult;
import com.azure.core.util.Context;
@@ -34,6 +32,7 @@
import com.azure.core.util.polling.SyncPoller;
import com.azure.resourcemanager.quota.fluent.GroupQuotaSubscriptionAllocationRequestsClient;
import com.azure.resourcemanager.quota.fluent.models.QuotaAllocationRequestStatusInner;
+import com.azure.resourcemanager.quota.fluent.models.SubscriptionQuotaAllocationsListInner;
import com.azure.resourcemanager.quota.models.QuotaAllocationRequestStatusList;
import java.nio.ByteBuffer;
import reactor.core.publisher.Flux;
@@ -74,48 +73,37 @@ public final class GroupQuotaSubscriptionAllocationRequestsClientImpl
@ServiceInterface(name = "AzureQuotaExtensionA")
public interface GroupQuotaSubscriptionAllocationRequestsService {
@Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/quotaAllocationRequests/{allocationId}")
- @ExpectedResponses({ 200 })
+ @Patch("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocations/{location}")
+ @ExpectedResponses({ 200, 202 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
+ Mono>> update(@HostParam("$host") String endpoint,
@PathParam("managementGroupId") String managementGroupId,
@PathParam("subscriptionId") String subscriptionId, @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("allocationId") String allocationId, @QueryParam("api-version") String apiVersion,
+ @PathParam("resourceProviderName") String resourceProviderName, @PathParam("location") String location,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") SubscriptionQuotaAllocationsListInner allocateQuotaRequest,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
- @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocationRequests")
+ @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocationRequests/{allocationId}")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
- @PathParam("managementGroupId") String managementGroupId,
- @PathParam("subscriptionId") String subscriptionId, @PathParam("groupQuotaName") String groupQuotaName,
- @PathParam("resourceProviderName") String resourceProviderName,
- @QueryParam("api-version") String apiVersion, @QueryParam("$filter") String filter,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Put("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocationRequests/{resourceName}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> createOrUpdate(@HostParam("$host") String endpoint,
+ Mono> get(@HostParam("$host") String endpoint,
@PathParam("managementGroupId") String managementGroupId,
@PathParam("subscriptionId") String subscriptionId, @PathParam("groupQuotaName") String groupQuotaName,
@PathParam("resourceProviderName") String resourceProviderName,
- @PathParam("resourceName") String resourceName, @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") QuotaAllocationRequestStatusInner allocateQuotaRequest,
+ @PathParam("allocationId") String allocationId, @QueryParam("api-version") String apiVersion,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
- @Patch("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocationRequests/{resourceName}")
- @ExpectedResponses({ 200, 202 })
+ @Get("/providers/Microsoft.Management/managementGroups/{managementGroupId}/subscriptions/{subscriptionId}/providers/Microsoft.Quota/groupQuotas/{groupQuotaName}/resourceProviders/{resourceProviderName}/quotaAllocationRequests")
+ @ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> update(@HostParam("$host") String endpoint,
+ Mono> list(@HostParam("$host") String endpoint,
@PathParam("managementGroupId") String managementGroupId,
@PathParam("subscriptionId") String subscriptionId, @PathParam("groupQuotaName") String groupQuotaName,
@PathParam("resourceProviderName") String resourceProviderName,
- @PathParam("resourceName") String resourceName, @QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") QuotaAllocationRequestStatusInner allocateQuotaRequest,
+ @QueryParam("api-version") String apiVersion, @QueryParam("$filter") String filter,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
@@ -128,22 +116,29 @@ Mono> listNext(
}
/**
- * Get the status of the quota allocation request for the subscriptionId.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get the quota allocation request status for the subscriptionId by allocationId.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response} on
- * successful completion of {@link Mono}.
+ * @return subscription quota list along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId,
- String groupQuotaName, String allocationId) {
+ private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -159,35 +154,53 @@ private Mono> getWithResponseAsync(S
if (groupQuotaName == null) {
return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
}
- if (allocationId == null) {
- return Mono.error(new IllegalArgumentException("Parameter allocationId is required and cannot be null."));
+ if (resourceProviderName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
+ }
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (allocateQuotaRequest == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
+ } else {
+ allocateQuotaRequest.validate();
}
final String accept = "application/json";
return FluxUtil
- .withContext(
- context -> service.get(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
- groupQuotaName, allocationId, this.client.getApiVersion(), accept, context))
+ .withContext(context -> service.update(this.client.getEndpoint(), managementGroupId,
+ this.client.getSubscriptionId(), groupQuotaName, resourceProviderName, location,
+ this.client.getApiVersion(), allocateQuotaRequest, accept, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Get the status of the quota allocation request for the subscriptionId.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get the quota allocation request status for the subscriptionId by allocationId.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response} on
- * successful completion of {@link Mono}.
+ * @return subscription quota list along with {@link Response} on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String managementGroupId,
- String groupQuotaName, String allocationId, Context context) {
+ private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest,
+ Context context) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -203,326 +216,290 @@ private Mono> getWithResponseAsync(S
if (groupQuotaName == null) {
return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
}
- if (allocationId == null) {
- return Mono.error(new IllegalArgumentException("Parameter allocationId is required and cannot be null."));
+ if (resourceProviderName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
+ }
+ if (location == null) {
+ return Mono.error(new IllegalArgumentException("Parameter location is required and cannot be null."));
+ }
+ if (allocateQuotaRequest == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
+ } else {
+ allocateQuotaRequest.validate();
}
final String accept = "application/json";
context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
- groupQuotaName, allocationId, this.client.getApiVersion(), accept, context);
+ return service.update(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
+ groupQuotaName, resourceProviderName, location, this.client.getApiVersion(), allocateQuotaRequest, accept,
+ context);
}
/**
- * Get the status of the quota allocation request for the subscriptionId.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get the quota allocation request status for the subscriptionId by allocationId.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId on successful completion of
- * {@link Mono}.
+ * @return the {@link PollerFlux} for polling of subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String managementGroupId, String groupQuotaName,
- String allocationId) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, allocationId)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, SubscriptionQuotaAllocationsListInner>
+ beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest) {
+ Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
+ resourceProviderName, location, allocateQuotaRequest);
+ return this.client.getLroResult(
+ mono, this.client.getHttpPipeline(), SubscriptionQuotaAllocationsListInner.class,
+ SubscriptionQuotaAllocationsListInner.class, this.client.getContext());
}
/**
- * Get the status of the quota allocation request for the subscriptionId.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get the quota allocation request status for the subscriptionId by allocationId.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response}.
+ * @return the {@link PollerFlux} for polling of subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String managementGroupId, String groupQuotaName,
- String allocationId, Context context) {
- return getWithResponseAsync(managementGroupId, groupQuotaName, allocationId, context).block();
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, SubscriptionQuotaAllocationsListInner>
+ beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
+ resourceProviderName, location, allocateQuotaRequest, context);
+ return this.client.getLroResult(
+ mono, this.client.getHttpPipeline(), SubscriptionQuotaAllocationsListInner.class,
+ SubscriptionQuotaAllocationsListInner.class, context);
}
/**
- * Get the status of the quota allocation request for the subscriptionId.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get the quota allocation request status for the subscriptionId by allocationId.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param allocationId Request Id.
+ * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
+ * Microsoft.Compute resource provider supports this API.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the quota allocation request status for the subscriptionId by allocationId.
+ * @return the {@link SyncPoller} for polling of subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- public QuotaAllocationRequestStatusInner get(String managementGroupId, String groupQuotaName, String allocationId) {
- return getWithResponse(managementGroupId, groupQuotaName, allocationId, Context.NONE).getValue();
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, SubscriptionQuotaAllocationsListInner>
+ beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest) {
+ return this
+ .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest)
+ .getSyncPoller();
}
/**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
+ * @return the {@link SyncPoller} for polling of subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String filter) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(
- context -> service.list(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
- groupQuotaName, resourceProviderName, this.client.getApiVersion(), filter, accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, SubscriptionQuotaAllocationsListInner>
+ beginUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName, String location,
+ SubscriptionQuotaAllocationsListInner allocateQuotaRequest, Context context) {
+ return this
+ .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest,
+ context)
+ .getSyncPoller();
}
/**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @param context The context to associate with this operation.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
+ * @return subscription quota list on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String filter, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (filter == null) {
- return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(), groupQuotaName,
- resourceProviderName, this.client.getApiVersion(), filter, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
+ private Mono updateAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest) {
+ return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
}
/**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
- *
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, filter),
- nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
- *
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedFlux}.
+ * @return subscription quota list on successful completion of {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context) {
- return new PagedFlux<>(
- () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, filter, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono updateAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest,
+ Context context) {
+ return beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest,
+ context).last().flatMap(this.client::getLroFinalResultOrError);
}
/**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedIterable}.
+ * @return subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName, filter));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public SubscriptionQuotaAllocationsListInner update(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest) {
+ return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest)
+ .block();
}
/**
- * Get all the quotaAllocationRequests for a resourceProvider/location.
+ * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
+ * with 202 response and status polling API.
*
- * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
- * required.
+ * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
+ * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
+ * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
+ * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
+ * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param filter | Field | Supported operators
- * |---------------------|------------------------
- *
- * location eq {location}
- * Example: $filter=location eq eastus.
+ * @param location The name of the Azure region.
+ * @param allocateQuotaRequest Quota requests payload.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
- * {@link PagedIterable}.
+ * @return subscription quota list.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String filter, Context context) {
- return new PagedIterable<>(listAsync(managementGroupId, groupQuotaName, resourceProviderName, filter, context));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public SubscriptionQuotaAllocationsListInner update(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String location, SubscriptionQuotaAllocationsListInner allocateQuotaRequest,
+ Context context) {
+ return updateAsync(managementGroupId, groupQuotaName, resourceProviderName, location, allocateQuotaRequest,
+ context).block();
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status along with {@link Response} on successful completion of
- * {@link Mono}.
+ * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response} on
+ * successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest) {
+ private Mono> getWithResponseAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String allocationId) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -542,50 +519,37 @@ private Mono>> createOrUpdateWithResponseAsync(String
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (allocateQuotaRequest == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
- } else {
- allocateQuotaRequest.validate();
+ if (allocationId == null) {
+ return Mono.error(new IllegalArgumentException("Parameter allocationId is required and cannot be null."));
}
final String accept = "application/json";
return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), managementGroupId,
- this.client.getSubscriptionId(), groupQuotaName, resourceProviderName, resourceName,
- this.client.getApiVersion(), allocateQuotaRequest, accept, context))
+ .withContext(
+ context -> service.get(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
+ groupQuotaName, resourceProviderName, allocationId, this.client.getApiVersion(), accept, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status along with {@link Response} on successful completion of
- * {@link Mono}.
+ * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response} on
+ * successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
+ private Mono> getWithResponseAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String allocationId, Context context) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -605,352 +569,164 @@ private Mono>> createOrUpdateWithResponseAsync(String
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (allocateQuotaRequest == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
- } else {
- allocateQuotaRequest.validate();
+ if (allocationId == null) {
+ return Mono.error(new IllegalArgumentException("Parameter allocationId is required and cannot be null."));
}
final String accept = "application/json";
context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
- groupQuotaName, resourceProviderName, resourceName, this.client.getApiVersion(), allocateQuotaRequest,
- accept, context);
+ return service.get(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
+ groupQuotaName, resourceProviderName, allocationId, this.client.getApiVersion(), accept, context);
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the subscription quota allocation status.
+ * @return the quota allocation request status for the subscriptionId by allocationId on successful completion of
+ * {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, allocateQuotaRequest);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, this.client.getContext());
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String allocationId) {
+ return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, allocationId)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the subscription quota allocation status.
+ * @return the quota allocation request status for the subscriptionId by allocationId along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, ProxyResource> beginCreateOrUpdateAsync(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = createOrUpdateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, allocateQuotaRequest, context);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(),
- ProxyResource.class, ProxyResource.class, context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String allocationId, Context context) {
+ return getWithResponseAsync(managementGroupId, groupQuotaName, resourceProviderName, allocationId, context)
+ .block();
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get the status of the quota allocation request for the subscriptionId.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get the quota allocation request status for the subscriptionId by allocationId.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param allocationId Request Id.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return the quota allocation request status for the subscriptionId by allocationId.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest)
- .getSyncPoller();
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public QuotaAllocationRequestStatusInner get(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String allocationId) {
+ return getWithResponse(managementGroupId, groupQuotaName, resourceProviderName, allocationId, Context.NONE)
+ .getValue();
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
+ *
+ * location eq {location}
+ * Example: $filter=location eq eastus.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return all the quotaAllocationRequests for a resourceProvider/location along with {@link PagedResponse} on
+ * successful completion of {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, ProxyResource> beginCreateOrUpdate(String managementGroupId,
- String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
- return this
- .beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest, context)
- .getSyncPoller();
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSinglePageAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String filter) {
+ if (this.client.getEndpoint() == null) {
+ return Mono.error(
+ new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (managementGroupId == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
+ }
+ if (this.client.getSubscriptionId() == null) {
+ return Mono.error(new IllegalArgumentException(
+ "Parameter this.client.getSubscriptionId() is required and cannot be null."));
+ }
+ if (groupQuotaName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
+ }
+ if (resourceProviderName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
+ }
+ if (filter == null) {
+ return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context -> service.list(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
+ groupQuotaName, resourceProviderName, this.client.getApiVersion(), filter, accept, context))
+ .>map(res -> new PagedResponseBase<>(res.getRequest(),
+ res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
+ *
+ * location eq {location}
+ * Example: $filter=location eq eastus.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status on successful completion of {@link Mono}.
+ * @return all the quotaAllocationRequests for a resourceProvider/location along with {@link PagedResponse} on
+ * successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest,
- Context context) {
- return beginCreateOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest, context).last().flatMap(this.client::getLroFinalResultOrError);
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest).block();
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * to check the status using Async polling as standards defined at -
- * https://github.com/Azure/azure-resource-manager-rpc/blob/master/v1.0/async-api-reference.md#asynchronous-operations.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public ProxyResource createOrUpdate(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
- return createOrUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest, context).block();
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (managementGroupId == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter managementGroupId is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (groupQuotaName == null) {
- return Mono.error(new IllegalArgumentException("Parameter groupQuotaName is required and cannot be null."));
- }
- if (resourceProviderName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (allocateQuotaRequest == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
- } else {
- allocateQuotaRequest.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.update(this.client.getEndpoint(), managementGroupId,
- this.client.getSubscriptionId(), groupQuotaName, resourceProviderName, resourceName,
- this.client.getApiVersion(), allocateQuotaRequest, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
- *
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the subscription quota allocation status along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String managementGroupId, String groupQuotaName,
- String resourceProviderName, String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest,
- Context context) {
+ private Mono> listSinglePageAsync(String managementGroupId,
+ String groupQuotaName, String resourceProviderName, String filter, Context context) {
if (this.client.getEndpoint() == null) {
return Mono.error(
new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
@@ -970,265 +746,130 @@ private Mono>> updateWithResponseAsync(String manageme
return Mono
.error(new IllegalArgumentException("Parameter resourceProviderName is required and cannot be null."));
}
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (allocateQuotaRequest == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter allocateQuotaRequest is required and cannot be null."));
- } else {
- allocateQuotaRequest.validate();
+ if (filter == null) {
+ return Mono.error(new IllegalArgumentException("Parameter filter is required and cannot be null."));
}
final String accept = "application/json";
context = this.client.mergeContext(context);
- return service.update(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(),
- groupQuotaName, resourceProviderName, resourceName, this.client.getApiVersion(), allocateQuotaRequest,
- accept, context);
+ return service
+ .list(this.client.getEndpoint(), managementGroupId, this.client.getSubscriptionId(), groupQuotaName,
+ resourceProviderName, this.client.getApiVersion(), filter, accept, context)
+ .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
+ res.getValue().value(), res.getValue().nextLink(), null));
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the subscription quota allocation status.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, QuotaAllocationRequestStatusInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, allocateQuotaRequest);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), QuotaAllocationRequestStatusInner.class,
- QuotaAllocationRequestStatusInner.class, this.client.getContext());
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
*
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @param context The context to associate with this operation.
+ * location eq {location}
+ * Example: $filter=location eq eastus.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of the subscription quota allocation status.
+ * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
+ * {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, QuotaAllocationRequestStatusInner>
- beginUpdateAsync(String managementGroupId, String groupQuotaName, String resourceProviderName,
- String resourceName, QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = updateWithResponseAsync(managementGroupId, groupQuotaName,
- resourceProviderName, resourceName, allocateQuotaRequest, context);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), QuotaAllocationRequestStatusInner.class,
- QuotaAllocationRequestStatusInner.class, context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listAsync(String managementGroupId, String groupQuotaName,
+ String resourceProviderName, String filter) {
+ return new PagedFlux<>(
+ () -> listSinglePageAsync(managementGroupId, groupQuotaName, resourceProviderName, filter),
+ nextLink -> listNextSinglePageAsync(nextLink));
}
/**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
+ * Get all the quotaAllocationRequests for a resourceProvider/location.
*
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * Get all the quotaAllocationRequests for a resourceProvider/location. The filter paramter for location is
+ * required.
*
* @param managementGroupId Management Group Id.
* @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
* @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
* Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
- */
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, QuotaAllocationRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest) {
- return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest)
- .getSyncPoller();
- }
-
- /**
- * Request to assign quota from group quota to a specific Subscription. This request will use Asynchronous pattern
- * with 202 response and status polling API.
- *
- * Request to assign quota from group quota to a specific Subscription. The assign GroupQuota to subscriptions or
- * reduce the quota allocated to subscription to give back the unused quota ( quota >= usages) to the groupQuota.
- * So, this API can be used to assign Quota to subscriptions and assign back unused quota to group quota, which can
- * be assigned to another subscriptions in the GroupQuota. User can collect unused quotas from multiple
- * subscriptions within the groupQuota and assign the groupQuota to the subscription, where it's needed.
+ * @param filter | Field | Supported operators
+ * |---------------------|------------------------
*
- * @param managementGroupId Management Group Id.
- * @param groupQuotaName The GroupQuota name. The name should be unique for the provided context tenantId/MgId.
- * @param resourceProviderName The resource provider name, such as - Microsoft.Compute. Currently only
- * Microsoft.Compute resource provider supports this API.
- * @param resourceName Resource name.
- * @param allocateQuotaRequest Quota requests payload.
+ * location eq {location}
+ * Example: $filter=location eq eastus.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of the subscription quota allocation status.
+ * @return all the quotaAllocationRequests for a resourceProvider/location as paginated response with
+ * {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, QuotaAllocationRequestStatusInner> beginUpdate(
- String managementGroupId, String groupQuotaName, String resourceProviderName, String resourceName,
- QuotaAllocationRequestStatusInner allocateQuotaRequest, Context context) {
- return this
- .beginUpdateAsync(managementGroupId, groupQuotaName, resourceProviderName, resourceName,
- allocateQuotaRequest, context)
- .getSyncPoller();
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux