Skip to content

Commit

Permalink
CodeGen from PR 32288 in Azure/azure-rest-api-specs
Browse files Browse the repository at this point in the history
Merge 6d0c502e981b4a53fa55700360e5e9bafd5ead5e into b0fc2a2389b4563d46b6a54b959b8e93d658d7de
  • Loading branch information
SDKAuto committed Jan 29, 2025
1 parent ed2691b commit 2b6db3b
Show file tree
Hide file tree
Showing 76 changed files with 579 additions and 594 deletions.
4 changes: 2 additions & 2 deletions sdk/clientcore/annotation-processor-test/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<parent>
<groupId>io.clientcore</groupId>
<artifactId>clientcore-parent</artifactId>
<version>1.0.0-beta.1</version> <!-- {x-version-update;io.clientcore:clientcore-parent;current} -->
<version>1.0.0-beta.2</version> <!-- {x-version-update;io.clientcore:clientcore-parent;current} -->
<relativePath>../../parents/clientcore-parent</relativePath>
</parent>

Expand Down Expand Up @@ -48,7 +48,7 @@
<dependency>
<groupId>io.clientcore</groupId>
<artifactId>core</artifactId>
<version>1.0.0-beta.3</version> <!-- {x-version-update;io.clientcore:core;current} -->
<version>1.0.0-beta.4</version> <!-- {x-version-update;io.clientcore:core;current} -->
</dependency>

<!-- Test dependencies -->
Expand Down
2 changes: 1 addition & 1 deletion sdk/clientcore/annotation-processor/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -110,7 +110,7 @@
<dependency>
<groupId>io.clientcore</groupId>
<artifactId>core</artifactId>
<version>1.0.0-beta.3</version> <!-- {x-version-update;io.clientcore:core;current} -->
<version>1.0.0-beta.4</version> <!-- {x-version-update;io.clientcore:core;current} -->
</dependency>

<!-- Unit Test -->
Expand Down
28 changes: 27 additions & 1 deletion sdk/standbypool/azure-resourcemanager-standbypool/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,32 @@
# Release History

## 1.1.0-beta.1 (Unreleased)
## 1.1.0-beta.1 (2025-01-29)

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

### Breaking Changes

#### `StandbyPoolManager` was modified

* `fluent.StandbyPoolClient serviceClient()` -> `fluent.StandbyPoolManagementClient serviceClient()`

### Features Added

* `models.HealthStateCode` was added

* `models.PoolStatus` was added

#### `models.StandbyVirtualMachinePoolRuntimeViewResourceProperties` was modified

* `status()` was added

#### `models.StandbyContainerGroupPoolRuntimeViewResourceProperties` was modified

* `status()` was added

## 1.0.0-beta.1 (2025-01-29)

- Azure Resource Manager Standby Pool client library for Java. This package contains Microsoft Azure SDK for Standby Pool Management SDK. 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
43 changes: 42 additions & 1 deletion sdk/standbypool/azure-resourcemanager-standbypool/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Various documentation is available to help you get started
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-standbypool</artifactId>
<version>1.0.0</version>
<version>1.1.0-beta.1</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down Expand Up @@ -70,6 +70,47 @@ See [API design][design] for general introduction on design and key concepts on

## Examples

```java
// reference https://learn.microsoft.com/azure/virtual-machine-scale-sets/standby-pools-create

// Create virtual network and virtual machine scale set
virtualNetwork = this.computeManager.networkManager()
.networks()
.define("vmssvnet")
.withRegion(REGION)
.withExistingResourceGroup(resourceGroupName)
.withAddressSpace("10.0.0.0/27")
.withSubnet("default", "10.0.0.0/27")
.create();

virtualMachineScaleSet = computeManager.virtualMachineScaleSets()
.define("vmss")
.withRegion(REGION)
.withExistingResourceGroup(resourceGroupName)
.withFlexibleOrchestrationMode()
.withSku(VirtualMachineScaleSetSkuTypes.STANDARD_A0)
.withExistingPrimaryNetworkSubnet(virtualNetwork, "default")
.withoutPrimaryInternetFacingLoadBalancer()
.withoutPrimaryInternalLoadBalancer()
.withPopularLinuxImage(KnownLinuxVirtualMachineImage.UBUNTU_SERVER_18_04_LTS)
.withRootUsername("Foo12")
.withSsh(sshPublicKey())
.withVirtualMachinePublicIp()
.withCapacity(3L)
.create();

// create standby virtual machine pool
standbyVirtualMachinePool = standbyPoolManager.standbyVirtualMachinePools()
.define(poolName)
.withRegion(REGION)
.withExistingResourceGroup(resourceGroupName)
.withProperties(new StandbyVirtualMachinePoolResourceProperties()
.withAttachedVirtualMachineScaleSetId(virtualMachineScaleSet.id())
.withVirtualMachineState(VirtualMachineState.DEALLOCATED)
.withElasticityProfile(new StandbyVirtualMachinePoolElasticityProfile().withMaxReadyCapacity(3L)
.withMinReadyCapacity(1L)))
.create();
```
[Code snippets and samples](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/standbypool/azure-resourcemanager-standbypool/SAMPLE.md)


Expand Down
38 changes: 19 additions & 19 deletions sdk/standbypool/azure-resourcemanager-standbypool/SAMPLE.md
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
*/
public final class OperationsListSamples {
/*
* x-ms-original-file: 2024-03-01/Operations_List.json
* x-ms-original-file: 2025-03-01/Operations_List.json
*/
/**
* Sample code: Operations_List.
Expand All @@ -66,7 +66,7 @@ public final class OperationsListSamples {
*/
public final class StandbyContainerGroupPoolRuntimeViewsGetSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPoolRuntimeViews_Get.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPoolRuntimeViews_Get.json
*/
/**
* Sample code: StandbyContainerGroupPoolRuntimeViews_Get.
Expand All @@ -89,7 +89,7 @@ public final class StandbyContainerGroupPoolRuntimeViewsGetSamples {
*/
public final class StandbyContainerGroupPoolRuntimeViewsListByStandbyPoolSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPoolRuntimeViews_ListByStandbyPool.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPoolRuntimeViews_ListByStandbyPool.json
*/
/**
* Sample code: StandbyContainerGroupPoolRuntimeViews_ListByStandbyPool.
Expand Down Expand Up @@ -122,7 +122,7 @@ import java.util.Map;
*/
public final class StandbyContainerGroupPoolsCreateOrUpdateSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_CreateOrUpdate.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_CreateOrUpdate.json
*/
/**
* Sample code: StandbyContainerGroupPools_CreateOrUpdate.
Expand Down Expand Up @@ -170,7 +170,7 @@ public final class StandbyContainerGroupPoolsCreateOrUpdateSamples {
*/
public final class StandbyContainerGroupPoolsDeleteSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_Delete.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_Delete.json
*/
/**
* Sample code: StandbyContainerGroupPools_Delete.
Expand All @@ -192,7 +192,7 @@ public final class StandbyContainerGroupPoolsDeleteSamples {
*/
public final class StandbyContainerGroupPoolsGetByResourceGroupSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_Get.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_Get.json
*/
/**
* Sample code: StandbyContainerGroupPools_Get.
Expand All @@ -214,7 +214,7 @@ public final class StandbyContainerGroupPoolsGetByResourceGroupSamples {
*/
public final class StandbyContainerGroupPoolsListSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_ListBySubscription.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_ListBySubscription.json
*/
/**
* Sample code: StandbyContainerGroupPools_ListBySubscription.
Expand All @@ -236,7 +236,7 @@ public final class StandbyContainerGroupPoolsListSamples {
*/
public final class StandbyContainerGroupPoolsListByResourceGroupSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_ListByResourceGroup.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_ListByResourceGroup.json
*/
/**
* Sample code: StandbyContainerGroupPools_ListByResourceGroup.
Expand Down Expand Up @@ -269,7 +269,7 @@ import java.util.Map;
*/
public final class StandbyContainerGroupPoolsUpdateSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyContainerGroupPools_Update.json
* x-ms-original-file: 2025-03-01/StandbyContainerGroupPools_Update.json
*/
/**
* Sample code: StandbyContainerGroupPools_Update.
Expand Down Expand Up @@ -317,7 +317,7 @@ public final class StandbyContainerGroupPoolsUpdateSamples {
*/
public final class StandbyVirtualMachinePoolRuntimeViewsGetSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePoolRuntimeViews_Get.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePoolRuntimeViews_Get.json
*/
/**
* Sample code: StandbyVirtualMachinePoolRuntimeViews_Get.
Expand All @@ -340,7 +340,7 @@ public final class StandbyVirtualMachinePoolRuntimeViewsGetSamples {
*/
public final class StandbyVirtualMachinePoolRuntimeViewsListByStandbyPoolSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePoolRuntimeViews_ListByStandbyPool.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePoolRuntimeViews_ListByStandbyPool.json
*/
/**
* Sample code: StandbyVirtualMachinePoolRuntimeViews_ListByStandbyPool.
Expand Down Expand Up @@ -369,7 +369,7 @@ import java.util.Map;
*/
public final class StandbyVirtualMachinePoolsCreateOrUpdateSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_CreateOrUpdate.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_CreateOrUpdate.json
*/
/**
* Sample code: StandbyVirtualMachinePools_CreateOrUpdate.
Expand Down Expand Up @@ -414,7 +414,7 @@ public final class StandbyVirtualMachinePoolsCreateOrUpdateSamples {
*/
public final class StandbyVirtualMachinePoolsDeleteSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_Delete.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_Delete.json
*/
/**
* Sample code: StandbyVirtualMachinePools_Delete.
Expand All @@ -436,7 +436,7 @@ public final class StandbyVirtualMachinePoolsDeleteSamples {
*/
public final class StandbyVirtualMachinePoolsGetByResourceGroupSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_Get.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_Get.json
*/
/**
* Sample code: StandbyVirtualMachinePools_Get.
Expand All @@ -458,7 +458,7 @@ public final class StandbyVirtualMachinePoolsGetByResourceGroupSamples {
*/
public final class StandbyVirtualMachinePoolsListSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_ListBySubscription.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_ListBySubscription.json
*/
/**
* Sample code: StandbyVirtualMachinePools_ListBySubscription.
Expand All @@ -480,7 +480,7 @@ public final class StandbyVirtualMachinePoolsListSamples {
*/
public final class StandbyVirtualMachinePoolsListByResourceGroupSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_ListByResourceGroup.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_ListByResourceGroup.json
*/
/**
* Sample code: StandbyVirtualMachinePools_ListByResourceGroup.
Expand Down Expand Up @@ -509,7 +509,7 @@ import java.util.Map;
*/
public final class StandbyVirtualMachinePoolsUpdateSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachinePools_Update.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachinePools_Update.json
*/
/**
* Sample code: StandbyVirtualMachinePools_Update.
Expand Down Expand Up @@ -554,7 +554,7 @@ public final class StandbyVirtualMachinePoolsUpdateSamples {
*/
public final class StandbyVirtualMachinesGetSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachines_Get.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachines_Get.json
*/
/**
* Sample code: StandbyVirtualMachines_Get.
Expand All @@ -576,7 +576,7 @@ public final class StandbyVirtualMachinesGetSamples {
*/
public final class StandbyVirtualMachinesListByStandbyVirtualMachinePoolResourceSamples {
/*
* x-ms-original-file: 2024-03-01/StandbyVirtualMachines_ListByStandbyVirtualMachinePoolResource.json
* x-ms-original-file: 2025-03-01/StandbyVirtualMachines_ListByStandbyVirtualMachinePoolResource.json
*/
/**
* Sample code: StandbyVirtualMachines_ListByStandbyVirtualMachinePoolResource.
Expand Down
21 changes: 11 additions & 10 deletions sdk/standbypool/azure-resourcemanager-standbypool/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,9 @@
<jacoco.min.linecoverage>0</jacoco.min.linecoverage>
<jacoco.min.branchcoverage>0</jacoco.min.branchcoverage>
<revapi.skip>true</revapi.skip>
<spotless.skip>false</spotless.skip>
</properties>
<dependencies>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-json</artifactId>
<version>1.4.0</version> <!-- {x-version-update;com.azure:azure-json;dependency} -->
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-core</artifactId>
Expand All @@ -70,15 +66,20 @@
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-compute</artifactId>
<version>2.47.0</version> <!-- {x-version-update;com.azure.resourcemanager:azure-resourcemanager-compute;dependency} -->
<groupId>com.azure</groupId>
<artifactId>azure-identity</artifactId>
<version>1.15.0</version> <!-- {x-version-update;com.azure:azure-identity;dependency} -->
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.azure</groupId>
<artifactId>azure-identity</artifactId>
<version>1.15.0</version> <!-- {x-version-update;com.azure:azure-identity;dependency} -->
<artifactId>azure-json</artifactId>
<version>1.4.0</version> <!-- {x-version-update;com.azure:azure-json;dependency} -->
</dependency>
<dependency>
<groupId>com.azure.resourcemanager</groupId>
<artifactId>azure-resourcemanager-compute</artifactId>
<version>2.47.0</version> <!-- {x-version-update;com.azure.resourcemanager:azure-resourcemanager-compute;dependency} -->
<scope>test</scope>
</dependency>
</dependencies>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@
import com.azure.core.management.profile.AzureProfile;
import com.azure.core.util.Configuration;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.standbypool.fluent.StandbyPoolClient;
import com.azure.resourcemanager.standbypool.fluent.StandbyPoolManagementClient;
import com.azure.resourcemanager.standbypool.implementation.OperationsImpl;
import com.azure.resourcemanager.standbypool.implementation.StandbyContainerGroupPoolRuntimeViewsImpl;
import com.azure.resourcemanager.standbypool.implementation.StandbyContainerGroupPoolsImpl;
import com.azure.resourcemanager.standbypool.implementation.StandbyPoolClientBuilder;
import com.azure.resourcemanager.standbypool.implementation.StandbyPoolManagementClientBuilder;
import com.azure.resourcemanager.standbypool.implementation.StandbyVirtualMachinePoolRuntimeViewsImpl;
import com.azure.resourcemanager.standbypool.implementation.StandbyVirtualMachinePoolsImpl;
import com.azure.resourcemanager.standbypool.implementation.StandbyVirtualMachinesImpl;
Expand Down Expand Up @@ -60,12 +60,12 @@ public final class StandbyPoolManager {

private StandbyContainerGroupPoolRuntimeViews standbyContainerGroupPoolRuntimeViews;

private final StandbyPoolClient clientObject;
private final StandbyPoolManagementClient clientObject;

private StandbyPoolManager(HttpPipeline httpPipeline, AzureProfile profile, Duration defaultPollInterval) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
Objects.requireNonNull(profile, "'profile' cannot be null.");
this.clientObject = new StandbyPoolClientBuilder().pipeline(httpPipeline)
this.clientObject = new StandbyPoolManagementClientBuilder().pipeline(httpPipeline)
.endpoint(profile.getEnvironment().getResourceManagerEndpoint())
.subscriptionId(profile.getSubscriptionId())
.defaultPollInterval(defaultPollInterval)
Expand Down Expand Up @@ -224,7 +224,7 @@ public StandbyPoolManager authenticate(TokenCredential credential, AzureProfile
.append("-")
.append("com.azure.resourcemanager.standbypool")
.append("/")
.append("1.0.0-beta.1");
.append("1.1.0-beta.1");
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder.append(" (")
.append(Configuration.getGlobalConfiguration().get("java.version"))
Expand Down Expand Up @@ -348,12 +348,12 @@ public StandbyContainerGroupPoolRuntimeViews standbyContainerGroupPoolRuntimeVie
}

/**
* Gets wrapped service client StandbyPoolClient providing direct access to the underlying auto-generated API
* implementation, based on Azure REST API.
* Gets wrapped service client StandbyPoolManagementClient providing direct access to the underlying auto-generated
* API implementation, based on Azure REST API.
*
* @return Wrapped service client StandbyPoolClient.
* @return Wrapped service client StandbyPoolManagementClient.
*/
public StandbyPoolClient serviceClient() {
public StandbyPoolManagementClient serviceClient() {
return this.clientObject;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,9 @@
import java.time.Duration;

/**
* The interface for StandbyPoolClient class.
* The interface for StandbyPoolManagementClient class.
*/
public interface StandbyPoolClient {
public interface StandbyPoolManagementClient {
/**
* Gets Service host.
*
Expand Down
Loading

0 comments on commit 2b6db3b

Please sign in to comment.