Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,14 +1,52 @@
# Release History

## 1.0.0-beta.2 (Unreleased)
## 1.0.0-beta.2 (2026-08-03)

- Azure Resource Manager Compute Recommender client library for Java. This package contains Microsoft Azure SDK for Compute Recommender Management SDK. The Compute Recommender Resource Provider Client. Package api-version 2026-05-05-preview. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).

### Features Added

### Breaking Changes
* `models.SkuMixPlacementBase` was added

* `models.SkuMixPlacementItem` was added

* `models.SkuMixPlacementResponse` was added

* `models.SkuMixPlacementProperties` was added

* `models.SkuMixPlacementPartialFulfillmentReason` was added

* `models.SkuMixPlacementCapacityProfile` was added

* `models.SkuMixPlacementPriority` was added

* `models.SkuMixPlacementRequest` was added

* `models.SkuMixPlacementInstanceDescription` was added

* `models.SkuMixPlacementSpotPriorityProfile` was added

* `models.SkuMixPlacementCapacityType` was added

* `models.SkuMixPlacementZoneAllocationPolicy` was added

* `models.SkuMixPlacementAllocationStrategy` was added

* `models.SkuMixPlacementScores` was added

* `models.SkuMixPlacementDeploymentChoice` was added

* `models.SkuMixPlacementVMSize` was added

* `models.SkuMixPlacementZonePreference` was added

* `models.SkuMixPlacementOSType` was added

* `models.SkuMixPlacementZonalDistributionStrategy` was added

### Bugs Fixed
#### `ComputeRecommenderManager` was modified

### Other Changes
* `skuMixPlacementScores()` was added

## 1.0.0-beta.1 (2025-09-24)

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Azure Resource Manager Compute Recommender client library for Java.

This package contains Microsoft Azure SDK for Compute Recommender Management SDK. The Compute Recommender Resource Provider Client. Package api-version 2025-06-05. 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 Compute Recommender Management SDK. The Compute Recommender Resource Provider Client. Package api-version 2026-05-05-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

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-compute-recommender</artifactId>
<version>1.0.0-beta.1</version>
<version>1.0.0-beta.2</version>
</dependency>
```
[//]: # ({x-version-update-end})
Expand Down
83 changes: 79 additions & 4 deletions sdk/compute/azure-resourcemanager-compute-recommender/SAMPLE.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,11 @@

- [List](#operations_list)

## SkuMixPlacementScores

- [Get](#skumixplacementscores_get)
- [Post](#skumixplacementscores_post)

## SpotPlacementScores

- [Get](#spotplacementscores_get)
Expand All @@ -17,7 +22,7 @@
*/
public final class OperationsListSamples {
/*
* x-ms-original-file: 2025-06-05/Operations_List_MinimumSet_Gen.json
* x-ms-original-file: 2026-05-05-preview/Operations_List_MinimumSet_Gen.json
*/
/**
* Sample code: Operations_List_MinimumSet_Gen.
Expand All @@ -30,7 +35,7 @@ public final class OperationsListSamples {
}

/*
* x-ms-original-file: 2025-06-05/Operations_List_MaximumSet_Gen.json
* x-ms-original-file: 2026-05-05-preview/Operations_List_MaximumSet_Gen.json
*/
/**
* Sample code: Operations_List_MaximumSet_Gen.
Expand All @@ -44,6 +49,76 @@ public final class OperationsListSamples {
}
```

### SkuMixPlacementScores_Get

```java
/**
* Samples for SkuMixPlacementScores Get.
*/
public final class SkuMixPlacementScoresGetSamples {
/*
* x-ms-original-file: 2026-05-05-preview/GetSkuMixPlacementScores.json
*/
/**
* Sample code: Gets the metadata of SkuMixPlacement Scores.
*
* @param manager Entry point to ComputeRecommenderManager.
*/
public static void getsTheMetadataOfSkuMixPlacementScores(
com.azure.resourcemanager.compute.recommender.ComputeRecommenderManager manager) {
manager.skuMixPlacementScores().getWithResponse("eastus", com.azure.core.util.Context.NONE);
}
}
```

### SkuMixPlacementScores_Post

```java
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementAllocationStrategy;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementCapacityProfile;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementCapacityType;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementInstanceDescription;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementOSType;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementPriority;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementRequest;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementVMSize;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementZonalDistributionStrategy;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementZoneAllocationPolicy;
import java.util.Arrays;

/**
* Samples for SkuMixPlacementScores Post.
*/
public final class SkuMixPlacementScoresPostSamples {
/*
* x-ms-original-file: 2026-05-05-preview/GenerateSkuMixPlacementScores.json
*/
/**
* Sample code: Generates SkuMixPlacement scores for VM SKU mix placement with explicit VM sizes.
*
* @param manager Entry point to ComputeRecommenderManager.
*/
public static void generatesSkuMixPlacementScoresForVMSKUMixPlacementWithExplicitVMSizes(
com.azure.resourcemanager.compute.recommender.ComputeRecommenderManager manager) {
manager.skuMixPlacementScores()
.postWithResponse("eastus",
new SkuMixPlacementRequest().withZones(Arrays.asList("1", "2", "3"))
.withCapacityProfile(new SkuMixPlacementCapacityProfile().withCapacity(10)
.withCapacityType(SkuMixPlacementCapacityType.VM)
.withPriority(SkuMixPlacementPriority.REGULAR)
.withAllocationStrategy(SkuMixPlacementAllocationStrategy.LOWEST_PRICE)
.withOsType(SkuMixPlacementOSType.LINUX)
.withZoneAllocationPolicy(new SkuMixPlacementZoneAllocationPolicy()
.withDistributionStrategy(SkuMixPlacementZonalDistributionStrategy.BEST_EFFORT_BALANCED)))
.withInstanceDescription(new SkuMixPlacementInstanceDescription()
.withVmSizes(Arrays.asList(new SkuMixPlacementVMSize().withName("Standard_D2s_v3"),
new SkuMixPlacementVMSize().withName("Standard_D4s_v3"),
new SkuMixPlacementVMSize().withName("Standard_D8s_v3")))),
com.azure.core.util.Context.NONE);
}
}
```

### SpotPlacementScores_Get

```java
Expand All @@ -52,7 +127,7 @@ public final class OperationsListSamples {
*/
public final class SpotPlacementScoresGetSamples {
/*
* x-ms-original-file: 2025-06-05/GetSpotPlacementScores.json
* x-ms-original-file: 2026-05-05-preview/GetSpotPlacementScores.json
*/
/**
* Sample code: Gets the metadata of Spot Placement Scores.
Expand All @@ -78,7 +153,7 @@ import java.util.Arrays;
*/
public final class SpotPlacementScoresPostSamples {
/*
* x-ms-original-file: 2025-06-05/GenerateSpotPlacementScores.json
* x-ms-original-file: 2026-05-05-preview/GenerateSpotPlacementScores.json
*/
/**
* Sample code: Returns spot VM placement scores for given configurations.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
~ Licensed under the MIT License.
~ Code generated by Microsoft (R) TypeSpec Code Generator.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.azure</groupId>
Expand All @@ -18,7 +18,7 @@
<packaging>jar</packaging>

<name>Microsoft Azure SDK for Compute Recommender Management</name>
<description>This package contains Microsoft Azure SDK for Compute Recommender Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. The Compute Recommender Resource Provider Client. Package api-version 2025-06-05.</description>
<description>This package contains Microsoft Azure SDK for Compute Recommender Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. The Compute Recommender Resource Provider Client. Package api-version 2026-05-05-preview.</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 @@ -27,8 +27,10 @@
import com.azure.resourcemanager.compute.recommender.fluent.ComputeRecommenderManagementClient;
import com.azure.resourcemanager.compute.recommender.implementation.ComputeRecommenderManagementClientBuilder;
import com.azure.resourcemanager.compute.recommender.implementation.OperationsImpl;
import com.azure.resourcemanager.compute.recommender.implementation.SkuMixPlacementScoresImpl;
import com.azure.resourcemanager.compute.recommender.implementation.SpotPlacementScoresImpl;
import com.azure.resourcemanager.compute.recommender.models.Operations;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementScores;
import com.azure.resourcemanager.compute.recommender.models.SpotPlacementScores;
import java.time.Duration;
import java.time.temporal.ChronoUnit;
Expand All @@ -45,6 +47,8 @@
public final class ComputeRecommenderManager {
private Operations operations;

private SkuMixPlacementScores skuMixPlacementScores;

private SpotPlacementScores spotPlacementScores;

private final ComputeRecommenderManagementClient clientObject;
Expand Down Expand Up @@ -274,6 +278,18 @@ public Operations operations() {
return operations;
}

/**
* Gets the resource collection API of SkuMixPlacementScores.
*
* @return Resource collection API of SkuMixPlacementScores.
*/
public SkuMixPlacementScores skuMixPlacementScores() {
if (this.skuMixPlacementScores == null) {
this.skuMixPlacementScores = new SkuMixPlacementScoresImpl(clientObject.getSkuMixPlacementScores(), this);
}
return skuMixPlacementScores;
}

/**
* Gets the resource collection API of SpotPlacementScores.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,13 @@ public interface ComputeRecommenderManagementClient {
*/
OperationsClient getOperations();

/**
* Gets the SkuMixPlacementScoresClient object to access its operations.
*
* @return the SkuMixPlacementScoresClient object.
*/
SkuMixPlacementScoresClient getSkuMixPlacementScores();

/**
* Gets the SpotPlacementScoresClient object to access its operations.
*
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,71 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
// Code generated by Microsoft (R) TypeSpec Code Generator.

package com.azure.resourcemanager.compute.recommender.fluent;

import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
import com.azure.resourcemanager.compute.recommender.fluent.models.SkuMixPlacementBaseInner;
import com.azure.resourcemanager.compute.recommender.fluent.models.SkuMixPlacementResponseInner;
import com.azure.resourcemanager.compute.recommender.models.SkuMixPlacementRequest;

/**
* An instance of this class provides access to all the operations defined in SkuMixPlacementScoresClient.
*/
public interface SkuMixPlacementScoresClient {
/**
* Gets SkuMixPlacement scoring metadata.
*
* @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 skuMixPlacement scoring metadata along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
Response<SkuMixPlacementBaseInner> getWithResponse(String location, Context context);

/**
* Gets SkuMixPlacement scoring metadata.
*
* @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 skuMixPlacement scoring metadata.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
SkuMixPlacementBaseInner get(String location);

/**
* Generates placement scores for VM SKU mix placement.
*
* @param location The name of the Azure region.
* @param skuMixPlacementRequest SkuMixPlacement request object supplied in the body of the generate operation.
* @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 sku Mix Placement API response along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
Response<SkuMixPlacementResponseInner> postWithResponse(String location,
SkuMixPlacementRequest skuMixPlacementRequest, Context context);

/**
* Generates placement scores for VM SKU mix placement.
*
* @param location The name of the Azure region.
* @param skuMixPlacementRequest SkuMixPlacement request object supplied in the body of the generate 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 sku Mix Placement API response.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
SkuMixPlacementResponseInner post(String location, SkuMixPlacementRequest skuMixPlacementRequest);
}
Loading
Loading