Skip to content

Commit

Permalink
CodeGen from PR 17436 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 9276feca44b4f624c96d7264adedbbfcfda919d2 into 84c09261f588a7ad29cfb4b46ad7f038f7254275
  • Loading branch information
SDKAuto committed Jan 20, 2022
1 parent 4386100 commit a4dac6a
Show file tree
Hide file tree
Showing 29 changed files with 364 additions and 694 deletions.
4 changes: 3 additions & 1 deletion sdk/quota/azure-resourcemanager-quota/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
# Release History

## 1.0.0-beta.3 (Unreleased)
## 1.0.0-beta.1 (2022-01-20)

- Azure Resource Manager quota client library for Java. This package contains Microsoft Azure SDK for quota Management SDK. Microsoft Azure Quota Resource Provider. Package tag package-2022-02. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

### Features Added

Expand Down
4 changes: 2 additions & 2 deletions sdk/quota/azure-resourcemanager-quota/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -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. Package tag package-2021-03-15-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. Package tag package-2022-02. 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

Expand Down Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-quota</artifactId>
<version>1.0.0-beta.2</version>
<version>1.0.0-beta.3</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
205 changes: 18 additions & 187 deletions sdk/quota/azure-resourcemanager-quota/SAMPLE.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,30 +31,7 @@ import com.azure.resourcemanager.quota.models.ResourceName;
/** Samples for Quota CreateOrUpdate. */
public final class QuotaCreateOrUpdateSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/putMachineLearningServicesQuotaRequestLowPriority.json
*/
/**
* Sample code: Quotas_Request_ForMachineLearningServices_LowPriorityResource.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasRequestForMachineLearningServicesLowPriorityResource(
com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.quotas()
.define("TotalLowPriorityCores")
.withExistingScope(
"subscriptions/D7EC67B3-7657-4966-BFFC-41EFD36BAAB3/providers/Microsoft.MachineLearningServices/locations/eastus")
.withProperties(
new QuotaProperties()
.withLimit(new LimitObject().withValue(10))
.withName(new ResourceName().withValue("TotalLowPriorityCores"))
.withResourceType("lowPriority"))
.create();
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/putNetworkOneSkuQuotaRequestStandardSkuPublicIpAddresses.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/putNetworkOneSkuQuotaRequestStandardSkuPublicIpAddresses.json
*/
/**
* Sample code: Quotas_PutRequest_ForNetwork_StandardSkuPublicIpAddressesResource.
Expand All @@ -77,28 +54,7 @@ public final class QuotaCreateOrUpdateSamples {
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/putComputeOneSkuQuotaRequest.json
*/
/**
* Sample code: Quotas_Put_Request_ForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasPutRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.quotas()
.define("standardFSv2Family")
.withExistingScope(
"subscriptions/D7EC67B3-7657-4966-BFFC-41EFD36BAAB3/providers/Microsoft.Compute/locations/eastus")
.withProperties(
new QuotaProperties()
.withLimit(new LimitObject().withValue(10))
.withName(new ResourceName().withValue("standardFSv2Family")))
.create();
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/putNetworkOneSkuQuotaRequest.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/putNetworkOneSkuQuotaRequest.json
*/
/**
* Sample code: Quotas_PutRequest_ForNetwork.
Expand Down Expand Up @@ -129,7 +85,7 @@ import com.azure.core.util.Context;
/** Samples for Quota Get. */
public final class QuotaGetSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getNetworkOneSkuQuotaLimit.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getNetworkOneSkuQuotaLimit.json
*/
/**
* Sample code: Quotas_UsagesRequest_ForNetwork.
Expand All @@ -140,25 +96,8 @@ public final class QuotaGetSamples {
manager
.quotas()
.getWithResponse(
"MinPublicIpInterNetworkPrefixLength",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Network/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getComputeOneSkuQuotaLimit.json
*/
/**
* Sample code: Quotas_Get_Request_ForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasGetRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.quotas()
.getWithResponse(
"standardNDSFamily",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
"MinPublicIpInterNetworkPrefixLength",
Context.NONE);
}
}
Expand All @@ -172,40 +111,7 @@ import com.azure.core.util.Context;
/** Samples for Quota List. */
public final class QuotaListSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getMachineLearningServicesQuotaLimits.json
*/
/**
* Sample code: Quotas_listQuotaLimitsMachineLearningServices.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasListQuotaLimitsMachineLearningServices(
com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.quotas()
.list(
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.MachineLearningServices/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getComputeQuotaLimits.json
*/
/**
* Sample code: Quotas_listQuotaLimitsForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasListQuotaLimitsForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.quotas()
.list(
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getNetworkQuotaLimits.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getNetworkQuotaLimits.json
*/
/**
* Sample code: Quotas_listQuotaLimitsForNetwork.
Expand Down Expand Up @@ -234,33 +140,7 @@ import com.azure.resourcemanager.quota.models.ResourceName;
/** Samples for Quota Update. */
public final class QuotaUpdateSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/patchComputeQuotaRequest.json
*/
/**
* Sample code: Quotas_Request_PatchForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasRequestPatchForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
CurrentQuotaLimitBase resource =
manager
.quotas()
.getWithResponse(
"standardFSv2Family",
"subscriptions/D7EC67B3-7657-4966-BFFC-41EFD36BAAB3/providers/Microsoft.Compute/locations/eastus",
Context.NONE)
.getValue();
resource
.update()
.withProperties(
new QuotaProperties()
.withLimit(new LimitObject().withValue(10))
.withName(new ResourceName().withValue("standardFSv2Family")))
.apply();
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/patchNetworkOneSkuQuotaRequest.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/patchNetworkOneSkuQuotaRequest.json
*/
/**
* Sample code: Quotas_Request_PatchForNetwork.
Expand All @@ -272,8 +152,8 @@ public final class QuotaUpdateSamples {
manager
.quotas()
.getWithResponse(
"MinPublicIpInterNetworkPrefixLength",
"subscriptions/D7EC67B3-7657-4966-BFFC-41EFD36BAAB3/providers/Microsoft.Network/locations/eastus",
"MinPublicIpInterNetworkPrefixLength",
Context.NONE)
.getValue();
resource
Expand All @@ -296,7 +176,7 @@ import com.azure.core.util.Context;
/** Samples for QuotaOperation List. */
public final class QuotaOperationListSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/GetOperations.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/GetOperations.json
*/
/**
* Sample code: GetOperations.
Expand All @@ -317,7 +197,7 @@ import com.azure.core.util.Context;
/** Samples for QuotaRequestStatus Get. */
public final class QuotaRequestStatusGetSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getQuotaRequestStatusFailed.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getQuotaRequestStatusFailed.json
*/
/**
* Sample code: QuotaRequestFailed.
Expand All @@ -328,13 +208,13 @@ public final class QuotaRequestStatusGetSamples {
manager
.quotaRequestStatus()
.getWithResponse(
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getQuotaRequestStatusById.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getQuotaRequestStatusById.json
*/
/**
* Sample code: QuotaRequestStatus.
Expand All @@ -345,13 +225,13 @@ public final class QuotaRequestStatusGetSamples {
manager
.quotaRequestStatus()
.getWithResponse(
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
"subscriptions/D7EC67B3-7657-4966-BFFC-41EFD36BAAB3/providers/Microsoft.Compute/locations/eastus",
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getQuotaRequestStatusInProgress.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getQuotaRequestStatusInProgress.json
*/
/**
* Sample code: QuotaRequestInProgress.
Expand All @@ -362,8 +242,8 @@ public final class QuotaRequestStatusGetSamples {
manager
.quotaRequestStatus()
.getWithResponse(
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
"2B5C8515-37D8-4B6A-879B-CD641A2CF605",
Context.NONE);
}
}
Expand All @@ -377,7 +257,7 @@ import com.azure.core.util.Context;
/** Samples for QuotaRequestStatus List. */
public final class QuotaRequestStatusListSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getQuotaRequestsHistory.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getQuotaRequestsHistory.json
*/
/**
* Sample code: QuotaRequestHistory.
Expand Down Expand Up @@ -405,7 +285,7 @@ import com.azure.core.util.Context;
/** Samples for Usages Get. */
public final class UsagesGetSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getNetworkOneSkuUsages.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getNetworkOneSkuUsages.json
*/
/**
* Sample code: Quotas_UsagesRequest_ForNetwork.
Expand All @@ -416,25 +296,8 @@ public final class UsagesGetSamples {
manager
.usages()
.getWithResponse(
"MinPublicIpInterNetworkPrefixLength",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Network/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getComputeOneSkuUsages.json
*/
/**
* Sample code: Quotas_UsagesRequest_ForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasUsagesRequestForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.usages()
.getWithResponse(
"standardNDSFamily",
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
"MinPublicIpInterNetworkPrefixLength",
Context.NONE);
}
}
Expand All @@ -448,23 +311,7 @@ import com.azure.core.util.Context;
/** Samples for Usages List. */
public final class UsagesListSamples {
/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getComputeUsages.json
*/
/**
* Sample code: Quotas_listUsagesForCompute.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasListUsagesForCompute(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.usages()
.list(
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Compute/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getNetworkUsages.json
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/stable/2022-02-25/examples/getNetworkUsages.json
*/
/**
* Sample code: Quotas_listUsagesForNetwork.
Expand All @@ -478,22 +325,6 @@ public final class UsagesListSamples {
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.Network/locations/eastus",
Context.NONE);
}

/*
* x-ms-original-file: specification/quota/resource-manager/Microsoft.Quota/preview/2021-03-15-preview/examples/getMachineLearningServicesUsages.json
*/
/**
* Sample code: Quotas_listUsagesMachineLearningServices.
*
* @param manager Entry point to QuotaManager.
*/
public static void quotasListUsagesMachineLearningServices(com.azure.resourcemanager.quota.QuotaManager manager) {
manager
.usages()
.list(
"subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.MachineLearningServices/locations/eastus",
Context.NONE);
}
}
```

2 changes: 1 addition & 1 deletion sdk/quota/azure-resourcemanager-quota/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
<packaging>jar</packaging>

<name>Microsoft Azure SDK for quota Management</name>
<description>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. Package tag package-2021-03-15-preview.</description>
<description>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. Package tag package-2022-02.</description>
<url>https://github.com/Azure/azure-sdk-for-java</url>

<licenses>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@ public QuotaManager authenticate(TokenCredential credential, AzureProfile profil
.append("-")
.append("com.azure.resourcemanager.quota")
.append("/")
.append("1.0.0-beta.2");
.append("1.0.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder
.append(" (")
Expand Down
Loading

0 comments on commit a4dac6a

Please sign in to comment.