diff --git a/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md b/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md
index 949e9ab274d8..9cc930945c36 100644
--- a/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md
+++ b/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md
@@ -1,7 +1,8 @@
# Release History
-## 1.0.0-beta.2 (Unreleased)
+## 1.0.0-beta.1 (2021-07-26)
+- Azure Resource Manager Batch client library for Java. This package contains Microsoft Azure SDK for Batch Management SDK. Package tag package-2021-06. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## 1.0.0-beta.1 (2021-04-21)
diff --git a/sdk/batch/azure-resourcemanager-batch/README.md b/sdk/batch/azure-resourcemanager-batch/README.md
index 8cfcdee633bb..c4877fae35ac 100644
--- a/sdk/batch/azure-resourcemanager-batch/README.md
+++ b/sdk/batch/azure-resourcemanager-batch/README.md
@@ -2,7 +2,7 @@
Azure Resource Manager Batch client library for Java.
-This package contains Microsoft Azure SDK for Batch Management SDK. Package tag package-2021-01. 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 Batch Management SDK. Package tag package-2021-06. 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-batch
- 1.0.0-beta.1
+ 1.0.0-beta.2
```
[//]: # ({x-version-update-end})
@@ -74,6 +74,8 @@ See [API design][design] for general introduction on design and key concepts on
## Examples
+
+
## Troubleshooting
## Next steps
diff --git a/sdk/batch/azure-resourcemanager-batch/pom.xml b/sdk/batch/azure-resourcemanager-batch/pom.xml
index 2af2d0662841..3525393cbc24 100644
--- a/sdk/batch/azure-resourcemanager-batch/pom.xml
+++ b/sdk/batch/azure-resourcemanager-batch/pom.xml
@@ -1,67 +1,86 @@
- 4.0.0
-
- com.azure
- azure-client-sdk-parent
- 1.7.0
- ../../parents/azure-client-sdk-parent
-
+ 4.0.0
+
+ com.azure
+ azure-client-sdk-parent
+ 1.7.0
+ ../../parents/azure-client-sdk-parent
+
- com.azure.resourcemanager
- azure-resourcemanager-batch
- 1.0.0-beta.2
- jar
+ com.azure.resourcemanager
+ azure-resourcemanager-batch
+ 1.0.0-beta.2
+ jar
- Microsoft Azure SDK for Batch Management
- This package contains Microsoft Azure SDK for Batch Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Package tag package-2021-01.
- https://github.com/Azure/azure-sdk-for-java
+ Microsoft Azure SDK for Batch Management
+ This package contains Microsoft Azure SDK for Batch Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Package tag package-2021-06.
+ https://github.com/Azure/azure-sdk-for-java
-
-
- The MIT License (MIT)
- http://opensource.org/licenses/MIT
- repo
-
-
+
+
+ The MIT License (MIT)
+ http://opensource.org/licenses/MIT
+ repo
+
+
-
- https://github.com/Azure/azure-sdk-for-java
- scm:git:git@github.com:Azure/azure-sdk-for-java.git
- scm:git:git@github.com:Azure/azure-sdk-for-java.git
- HEAD
-
-
-
- microsoft
- Microsoft
-
-
-
- UTF-8
-
-
-
-
- com.azure
- azure-core
- 1.18.0
-
-
- com.azure
- azure-core-management
- 1.3.1
-
-
-
-
-
- org.jacoco
- jacoco-maven-plugin
- 0.8.5
-
- true
-
-
-
-
+
+ https://github.com/Azure/azure-sdk-for-java
+ scm:git:git@github.com:Azure/azure-sdk-for-java.git
+ scm:git:git@github.com:Azure/azure-sdk-for-java.git
+ HEAD
+
+
+
+ microsoft
+ Microsoft
+
+
+
+ UTF-8
+
+
+
+
+ com.azure
+ azure-core
+ 1.18.0
+
+
+ com.azure
+ azure-core-management
+ 1.3.1
+
+
+
+
+
+ org.jacoco
+ jacoco-maven-plugin
+ 0.8.5
+
+ true
+
+
+
+ org.revapi
+ revapi-maven-plugin
+ 0.11.2
+
+
+
+ -
+
java.method.addedToInterface
+
+ -
+ true
+
.*
+ com\.azure\.resourcemanager(\.[^.]+)+\.fluent(\.[^.]+)*
+
+
+
+
+
+
+
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/BatchManager.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/BatchManager.java
index 191c5a2d6d51..628dca053cdf 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/BatchManager.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/BatchManager.java
@@ -9,7 +9,6 @@
import com.azure.core.http.HttpPipeline;
import com.azure.core.http.HttpPipelineBuilder;
import com.azure.core.http.policy.AddDatePolicy;
-import com.azure.core.http.policy.BearerTokenAuthenticationPolicy;
import com.azure.core.http.policy.HttpLogOptions;
import com.azure.core.http.policy.HttpLoggingPolicy;
import com.azure.core.http.policy.HttpPipelinePolicy;
@@ -17,6 +16,7 @@
import com.azure.core.http.policy.RequestIdPolicy;
import com.azure.core.http.policy.RetryPolicy;
import com.azure.core.http.policy.UserAgentPolicy;
+import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
import com.azure.core.management.profile.AzureProfile;
import com.azure.core.util.Configuration;
import com.azure.core.util.logging.ClientLogger;
@@ -109,6 +109,7 @@ public static final class Configurable {
private HttpClient httpClient;
private HttpLogOptions httpLogOptions;
private final List policies = new ArrayList<>();
+ private final List scopes = new ArrayList<>();
private RetryPolicy retryPolicy;
private Duration defaultPollInterval;
@@ -148,6 +149,17 @@ public Configurable withPolicy(HttpPipelinePolicy policy) {
return this;
}
+ /**
+ * Adds the scope to permission sets.
+ *
+ * @param scope the scope.
+ * @return the configurable object itself.
+ */
+ public Configurable withScope(String scope) {
+ this.scopes.add(Objects.requireNonNull(scope, "'scope' cannot be null."));
+ return this;
+ }
+
/**
* Sets the retry policy to the HTTP pipeline.
*
@@ -204,6 +216,9 @@ public BatchManager authenticate(TokenCredential credential, AzureProfile profil
userAgentBuilder.append(" (auto-generated)");
}
+ if (scopes.isEmpty()) {
+ scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default");
+ }
if (retryPolicy == null) {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
}
@@ -213,10 +228,7 @@ public BatchManager authenticate(TokenCredential credential, AzureProfile profil
HttpPolicyProviders.addBeforeRetryPolicies(policies);
policies.add(retryPolicy);
policies.add(new AddDatePolicy());
- policies
- .add(
- new BearerTokenAuthenticationPolicy(
- credential, profile.getEnvironment().getManagementEndpoint() + "/.default"));
+ policies.add(new ArmChallengeAuthenticationPolicy(credential, scopes.toArray(new String[0])));
policies.addAll(this.policies);
HttpPolicyProviders.addAfterRetryPolicies(policies);
policies.add(new HttpLoggingPolicy(httpLogOptions));
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationPackagesClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationPackagesClient.java
index 31deee5e5360..6dad4951d492 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationPackagesClient.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationPackagesClient.java
@@ -61,9 +61,9 @@ Response activateWithResponse(
Context context);
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -79,9 +79,9 @@ ApplicationPackageInner create(
String resourceGroupName, String accountName, String applicationName, String versionName);
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/BatchAccountsClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/BatchAccountsClient.java
index 2154974617db..d0530a007036 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/BatchAccountsClient.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/BatchAccountsClient.java
@@ -13,6 +13,7 @@
import com.azure.core.util.polling.SyncPoller;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountInner;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountKeysInner;
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
import com.azure.resourcemanager.batch.models.BatchAccountCreateParameters;
import com.azure.resourcemanager.batch.models.BatchAccountRegenerateKeyParameters;
import com.azure.resourcemanager.batch.models.BatchAccountUpdateParameters;
@@ -254,7 +255,8 @@ Response getByResourceGroupWithResponse(
PagedIterable listByResourceGroup(String resourceGroupName, Context context);
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -266,7 +268,8 @@ Response getByResourceGroupWithResponse(
void synchronizeAutoStorageKeys(String resourceGroupName, String accountName);
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -281,7 +284,10 @@ Response synchronizeAutoStorageKeysWithResponse(
String resourceGroupName, String accountName, Context context);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -296,7 +302,10 @@ BatchAccountKeysInner regenerateKey(
String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -312,9 +321,9 @@ Response regenerateKeyWithResponse(
String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context);
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -327,9 +336,9 @@ Response regenerateKeyWithResponse(
BatchAccountKeysInner getKeys(String resourceGroupName, String accountName);
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -341,4 +350,41 @@ Response regenerateKeyWithResponse(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
Response getKeysWithResponse(String resourceGroupName, String accountName, Context context);
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName);
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName, Context context);
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/LocationsClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/LocationsClient.java
index a20c9b0640b9..557c8d6eb3bb 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/LocationsClient.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/LocationsClient.java
@@ -6,10 +6,12 @@
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.batch.fluent.models.BatchLocationQuotaInner;
import com.azure.resourcemanager.batch.fluent.models.CheckNameAvailabilityResultInner;
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
import com.azure.resourcemanager.batch.models.CheckNameAvailabilityParameters;
/** An instance of this class provides access to all the operations defined in LocationsClient. */
@@ -39,6 +41,62 @@ public interface LocationsClient {
@ServiceMethod(returns = ReturnType.SINGLE)
Response getQuotasWithResponse(String locationName, Context context);
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listSupportedVirtualMachineSkus(String locationName);
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listSupportedVirtualMachineSkus(
+ String locationName, Integer maxresults, String filter, Context context);
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listSupportedCloudServiceSkus(String locationName);
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listSupportedCloudServiceSkus(
+ String locationName, Integer maxresults, String filter, Context context);
+
/**
* Checks whether the Batch account name is available in the specified region.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountInner.java
index 01fcecfae790..a8efe621cab4 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountInner.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountInner.java
@@ -8,6 +8,7 @@
import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.Resource;
import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.batch.models.AuthenticationMode;
import com.azure.resourcemanager.batch.models.AutoStorageProperties;
import com.azure.resourcemanager.batch.models.BatchAccountIdentity;
import com.azure.resourcemanager.batch.models.EncryptionProperties;
@@ -132,6 +133,14 @@ public class BatchAccountInner extends Resource {
@JsonProperty(value = "properties.activeJobAndJobScheduleQuota", access = JsonProperty.Access.WRITE_ONLY)
private Integer activeJobAndJobScheduleQuota;
+ /*
+ * List of allowed authentication modes for the Batch account that can be
+ * used to authenticate with the data plane. This does not affect
+ * authentication with the control plane.
+ */
+ @JsonProperty(value = "properties.allowedAuthenticationModes", access = JsonProperty.Access.WRITE_ONLY)
+ private List allowedAuthenticationModes;
+
/**
* Get the identity property: The identity of the Batch account.
*
@@ -291,6 +300,16 @@ public Integer activeJobAndJobScheduleQuota() {
return this.activeJobAndJobScheduleQuota;
}
+ /**
+ * Get the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @return the allowedAuthenticationModes value.
+ */
+ public List allowedAuthenticationModes() {
+ return this.allowedAuthenticationModes;
+ }
+
/** {@inheritDoc} */
@Override
public BatchAccountInner withLocation(String location) {
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OperationInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OperationInner.java
index ea7878410637..66cadb8f26b4 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OperationInner.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OperationInner.java
@@ -21,6 +21,12 @@ public final class OperationInner {
@JsonProperty(value = "name")
private String name;
+ /*
+ * Indicates whether the operation is a data action
+ */
+ @JsonProperty(value = "isDataAction")
+ private Boolean isDataAction;
+
/*
* The object that describes the operation.
*/
@@ -59,6 +65,26 @@ public OperationInner withName(String name) {
return this;
}
+ /**
+ * Get the isDataAction property: Indicates whether the operation is a data action.
+ *
+ * @return the isDataAction value.
+ */
+ public Boolean isDataAction() {
+ return this.isDataAction;
+ }
+
+ /**
+ * Set the isDataAction property: Indicates whether the operation is a data action.
+ *
+ * @param isDataAction the isDataAction value to set.
+ * @return the OperationInner object itself.
+ */
+ public OperationInner withIsDataAction(Boolean isDataAction) {
+ this.isDataAction = isDataAction;
+ return this;
+ }
+
/**
* Get the display property: The object that describes the operation.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OutboundEnvironmentEndpointInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OutboundEnvironmentEndpointInner.java
new file mode 100644
index 000000000000..52286504ae8d
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/OutboundEnvironmentEndpointInner.java
@@ -0,0 +1,60 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.batch.models.EndpointDependency;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** A collection of related endpoints from the same service for which the Batch service requires outbound access. */
+@Immutable
+public final class OutboundEnvironmentEndpointInner {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(OutboundEnvironmentEndpointInner.class);
+
+ /*
+ * The type of service that the Batch service connects to.
+ */
+ @JsonProperty(value = "category", access = JsonProperty.Access.WRITE_ONLY)
+ private String category;
+
+ /*
+ * The endpoints for this service to which the Batch service makes outbound
+ * calls.
+ */
+ @JsonProperty(value = "endpoints", access = JsonProperty.Access.WRITE_ONLY)
+ private List endpoints;
+
+ /**
+ * Get the category property: The type of service that the Batch service connects to.
+ *
+ * @return the category value.
+ */
+ public String category() {
+ return this.category;
+ }
+
+ /**
+ * Get the endpoints property: The endpoints for this service to which the Batch service makes outbound calls.
+ *
+ * @return the endpoints value.
+ */
+ public List endpoints() {
+ return this.endpoints;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (endpoints() != null) {
+ endpoints().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolInner.java
index 7b83be87fb95..2a04f5da8b70 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolInner.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolInner.java
@@ -119,7 +119,7 @@ public class PoolInner extends ProxyResource {
private Integer currentDedicatedNodes;
/*
- * The number of low priority compute nodes currently in the pool.
+ * The number of low-priority compute nodes currently in the pool.
*/
@JsonProperty(value = "properties.currentLowPriorityNodes", access = JsonProperty.Access.WRITE_ONLY)
private Integer currentLowPriorityNodes;
@@ -405,7 +405,7 @@ public Integer currentDedicatedNodes() {
}
/**
- * Get the currentLowPriorityNodes property: The number of low priority compute nodes currently in the pool.
+ * Get the currentLowPriorityNodes property: The number of low-priority compute nodes currently in the pool.
*
* @return the currentLowPriorityNodes value.
*/
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/SupportedSkuInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/SupportedSkuInner.java
new file mode 100644
index 000000000000..7355f949b50b
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/SupportedSkuInner.java
@@ -0,0 +1,74 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.batch.models.SkuCapability;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Describes a Batch supported SKU. */
+@Immutable
+public final class SupportedSkuInner {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(SupportedSkuInner.class);
+
+ /*
+ * The name of the SKU.
+ */
+ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
+ private String name;
+
+ /*
+ * The family name of the SKU.
+ */
+ @JsonProperty(value = "familyName", access = JsonProperty.Access.WRITE_ONLY)
+ private String familyName;
+
+ /*
+ * A collection of capabilities which this SKU supports.
+ */
+ @JsonProperty(value = "capabilities", access = JsonProperty.Access.WRITE_ONLY)
+ private List capabilities;
+
+ /**
+ * Get the name property: The name of the SKU.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the familyName property: The family name of the SKU.
+ *
+ * @return the familyName value.
+ */
+ public String familyName() {
+ return this.familyName;
+ }
+
+ /**
+ * Get the capabilities property: A collection of capabilities which this SKU supports.
+ *
+ * @return the capabilities value.
+ */
+ public List capabilities() {
+ return this.capabilities;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (capabilities() != null) {
+ capabilities().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesClientImpl.java
index 79f0ff308773..c734776fe44f 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesClientImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesClientImpl.java
@@ -388,9 +388,9 @@ public Response activateWithResponse(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -458,9 +458,9 @@ private Mono> createWithResponseAsync(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -527,9 +527,9 @@ private Mono> createWithResponseAsync(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -560,9 +560,9 @@ private Mono createAsync(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -589,9 +589,9 @@ private Mono createAsync(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -610,9 +610,9 @@ public ApplicationPackageInner create(
}
/**
- * Creates an application package record. The record contains the SAS where the package should be uploaded to. Once
- * it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can be
- * used.
+ * Creates an application package record. The record contains a storageUrl where the package should be uploaded to.
+ * Once it is uploaded the `ApplicationPackage` needs to be activated using `ApplicationPackageActive` before it can
+ * be used. If the auto storage account was configured to use storage keys, the URL returned will contain a SAS.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountImpl.java
index 435c99cd2fea..31a3e1ed8831 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountImpl.java
@@ -9,6 +9,7 @@
import com.azure.core.util.Context;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountInner;
import com.azure.resourcemanager.batch.fluent.models.PrivateEndpointConnectionInner;
+import com.azure.resourcemanager.batch.models.AuthenticationMode;
import com.azure.resourcemanager.batch.models.AutoStorageBaseProperties;
import com.azure.resourcemanager.batch.models.AutoStorageProperties;
import com.azure.resourcemanager.batch.models.BatchAccount;
@@ -134,6 +135,15 @@ public Integer activeJobAndJobScheduleQuota() {
return this.innerModel().activeJobAndJobScheduleQuota();
}
+ public List allowedAuthenticationModes() {
+ List inner = this.innerModel().allowedAuthenticationModes();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
public Region region() {
return Region.fromName(this.regionName());
}
@@ -334,6 +344,16 @@ public BatchAccountImpl withEncryption(EncryptionProperties encryption) {
}
}
+ public BatchAccountImpl withAllowedAuthenticationModes(List allowedAuthenticationModes) {
+ if (isInCreateMode()) {
+ this.createParameters.withAllowedAuthenticationModes(allowedAuthenticationModes);
+ return this;
+ } else {
+ this.updateParameters.withAllowedAuthenticationModes(allowedAuthenticationModes);
+ return this;
+ }
+ }
+
private boolean isInCreateMode() {
return this.innerModel().id() == null;
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsClientImpl.java
index 6f8138891d35..e5fd98147bb6 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsClientImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsClientImpl.java
@@ -37,10 +37,12 @@
import com.azure.resourcemanager.batch.fluent.BatchAccountsClient;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountInner;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountKeysInner;
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
import com.azure.resourcemanager.batch.models.BatchAccountCreateParameters;
import com.azure.resourcemanager.batch.models.BatchAccountListResult;
import com.azure.resourcemanager.batch.models.BatchAccountRegenerateKeyParameters;
import com.azure.resourcemanager.batch.models.BatchAccountUpdateParameters;
+import com.azure.resourcemanager.batch.models.OutboundEnvironmentEndpointCollection;
import java.nio.ByteBuffer;
import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
@@ -206,6 +208,21 @@ Mono> getKeys(
@HeaderParam("Accept") String accept,
Context context);
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Batch/batchAccounts"
+ + "/{accountName}/outboundNetworkDependenciesEndpoints")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listOutboundNetworkDependenciesEndpoints(
+ @HostParam("$host") String endpoint,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("accountName") String accountName,
+ @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
@Headers({"Content-Type: application/json"})
@Get("{nextLink}")
@ExpectedResponses({200})
@@ -225,6 +242,16 @@ Mono> listByResourceGroupNext(
@HostParam("$host") String endpoint,
@HeaderParam("Accept") String accept,
Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("{nextLink}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listOutboundNetworkDependenciesEndpointsNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept,
+ Context context);
}
/**
@@ -1376,7 +1403,8 @@ public PagedIterable listByResourceGroup(String resourceGroup
}
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1424,7 +1452,8 @@ private Mono> synchronizeAutoStorageKeysWithResponseAsync(
}
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1470,7 +1499,8 @@ private Mono> synchronizeAutoStorageKeysWithResponseAsync(
}
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1486,7 +1516,8 @@ private Mono synchronizeAutoStorageKeysAsync(String resourceGroupName, Str
}
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1500,7 +1531,8 @@ public void synchronizeAutoStorageKeys(String resourceGroupName, String accountN
}
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1517,7 +1549,10 @@ public Response synchronizeAutoStorageKeysWithResponse(
}
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1572,7 +1607,10 @@ private Mono> regenerateKeyWithResponseAsync(
}
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1625,7 +1663,10 @@ private Mono> regenerateKeyWithResponseAsync(
}
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1650,7 +1691,10 @@ private Mono regenerateKeyAsync(
}
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1667,7 +1711,10 @@ public BatchAccountKeysInner regenerateKey(
}
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1685,9 +1732,9 @@ public Response regenerateKeyWithResponse(
}
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1735,9 +1782,9 @@ private Mono> getKeysWithResponseAsync(
}
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1783,9 +1830,9 @@ private Mono> getKeysWithResponseAsync(
}
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1808,9 +1855,9 @@ private Mono getKeysAsync(String resourceGroupName, Strin
}
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1825,9 +1872,9 @@ public BatchAccountKeysInner getKeys(String resourceGroupName, String accountNam
}
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -1843,6 +1890,214 @@ public Response getKeysWithResponse(
return getKeysWithResponseAsync(resourceGroupName, accountName, context).block();
}
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listOutboundNetworkDependenciesEndpointsSinglePageAsync(String resourceGroupName, String accountName) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (accountName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter accountName 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .listOutboundNetworkDependenciesEndpoints(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ accountName,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ 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()));
+ }
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listOutboundNetworkDependenciesEndpointsSinglePageAsync(
+ String resourceGroupName, String accountName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (resourceGroupName == null) {
+ return Mono
+ .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
+ }
+ if (accountName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter accountName 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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listOutboundNetworkDependenciesEndpoints(
+ this.client.getEndpoint(),
+ resourceGroupName,
+ accountName,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ accept,
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listOutboundNetworkDependenciesEndpointsAsync(
+ String resourceGroupName, String accountName) {
+ return new PagedFlux<>(
+ () -> listOutboundNetworkDependenciesEndpointsSinglePageAsync(resourceGroupName, accountName),
+ nextLink -> listOutboundNetworkDependenciesEndpointsNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listOutboundNetworkDependenciesEndpointsAsync(
+ String resourceGroupName, String accountName, Context context) {
+ return new PagedFlux<>(
+ () -> listOutboundNetworkDependenciesEndpointsSinglePageAsync(resourceGroupName, accountName, context),
+ nextLink -> listOutboundNetworkDependenciesEndpointsNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName) {
+ return new PagedIterable<>(listOutboundNetworkDependenciesEndpointsAsync(resourceGroupName, accountName));
+ }
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName, Context context) {
+ return new PagedIterable<>(
+ listOutboundNetworkDependenciesEndpointsAsync(resourceGroupName, accountName, context));
+ }
+
/**
* Get the next page of items.
*
@@ -1986,4 +2241,81 @@ private Mono> listByResourceGroupNextSinglePage
res.getValue().nextLink(),
null));
}
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listOutboundNetworkDependenciesEndpointsNextSinglePageAsync(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
+ .listOutboundNetworkDependenciesEndpointsNext(
+ 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 nextLink parameter.
+ * @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 values returned by the List operation.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>
+ listOutboundNetworkDependenciesEndpointsNextSinglePageAsync(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
+ .listOutboundNetworkDependenciesEndpointsNext(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/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsImpl.java
index 8aaeb91e97ae..7728b1875750 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchAccountsImpl.java
@@ -12,10 +12,12 @@
import com.azure.resourcemanager.batch.fluent.BatchAccountsClient;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountInner;
import com.azure.resourcemanager.batch.fluent.models.BatchAccountKeysInner;
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
import com.azure.resourcemanager.batch.models.BatchAccount;
import com.azure.resourcemanager.batch.models.BatchAccountKeys;
import com.azure.resourcemanager.batch.models.BatchAccountRegenerateKeyParameters;
import com.azure.resourcemanager.batch.models.BatchAccounts;
+import com.azure.resourcemanager.batch.models.OutboundEnvironmentEndpoint;
import com.fasterxml.jackson.annotation.JsonIgnore;
public final class BatchAccountsImpl implements BatchAccounts {
@@ -141,6 +143,20 @@ public Response getKeysWithResponse(
}
}
+ public PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName) {
+ PagedIterable inner =
+ this.serviceClient().listOutboundNetworkDependenciesEndpoints(resourceGroupName, accountName);
+ return Utils.mapPage(inner, inner1 -> new OutboundEnvironmentEndpointImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName, Context context) {
+ PagedIterable inner =
+ this.serviceClient().listOutboundNetworkDependenciesEndpoints(resourceGroupName, accountName, context);
+ return Utils.mapPage(inner, inner1 -> new OutboundEnvironmentEndpointImpl(inner1, this.manager()));
+ }
+
public BatchAccount getById(String id) {
String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups");
if (resourceGroupName == null) {
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementImpl.java
index 6bcd40f3342e..d393afe132cc 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementImpl.java
@@ -249,7 +249,7 @@ public PoolsClient getPools() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2021-01-01";
+ this.apiVersion = "2021-06-01";
this.batchAccounts = new BatchAccountsClientImpl(this);
this.applicationPackages = new ApplicationPackagesClientImpl(this);
this.applications = new ApplicationsClientImpl(this);
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificateImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificateImpl.java
index 2fccc93d3f04..5734f7b52872 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificateImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificateImpl.java
@@ -261,8 +261,13 @@ public CertificateImpl withPassword(String password) {
}
public CertificateImpl withIfMatch(String ifMatch) {
- this.createIfMatch = ifMatch;
- return this;
+ if (isInCreateMode()) {
+ this.createIfMatch = ifMatch;
+ return this;
+ } else {
+ this.updateIfMatch = ifMatch;
+ return this;
+ }
}
public CertificateImpl withIfNoneMatch(String ifNoneMatch) {
@@ -270,11 +275,6 @@ public CertificateImpl withIfNoneMatch(String ifNoneMatch) {
return this;
}
- public CertificateImpl ifMatch(String ifMatch) {
- this.updateIfMatch = ifMatch;
- return this;
- }
-
private boolean isInCreateMode() {
return this.innerModel().id() == null;
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsClientImpl.java
index 86b528738040..f9e768ebd91e 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsClientImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsClientImpl.java
@@ -18,6 +18,10 @@
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;
@@ -27,7 +31,9 @@
import com.azure.resourcemanager.batch.fluent.LocationsClient;
import com.azure.resourcemanager.batch.fluent.models.BatchLocationQuotaInner;
import com.azure.resourcemanager.batch.fluent.models.CheckNameAvailabilityResultInner;
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
import com.azure.resourcemanager.batch.models.CheckNameAvailabilityParameters;
+import com.azure.resourcemanager.batch.models.SupportedSkusResult;
import reactor.core.publisher.Mono;
/** An instance of this class provides access to all the operations defined in LocationsClient. */
@@ -70,6 +76,34 @@ Mono> getQuotas(
@HeaderParam("Accept") String accept,
Context context);
+ @Headers({"Content-Type: application/json"})
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.Batch/locations/{locationName}/virtualMachineSkus")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listSupportedVirtualMachineSkus(
+ @HostParam("$host") String endpoint,
+ @PathParam("locationName") String locationName,
+ @QueryParam("maxresults") Integer maxresults,
+ @QueryParam("$filter") String filter,
+ @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.Batch/locations/{locationName}/cloudServiceSkus")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listSupportedCloudServiceSkus(
+ @HostParam("$host") String endpoint,
+ @PathParam("locationName") String locationName,
+ @QueryParam("maxresults") Integer maxresults,
+ @QueryParam("$filter") String filter,
+ @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
@Headers({"Content-Type: application/json"})
@Post(
"/subscriptions/{subscriptionId}/providers/Microsoft.Batch/locations/{locationName}/checkNameAvailability")
@@ -83,6 +117,26 @@ Mono> checkNameAvailability(
@BodyParam("application/json") CheckNameAvailabilityParameters parameters,
@HeaderParam("Accept") String accept,
Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("{nextLink}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listSupportedVirtualMachineSkusNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("{nextLink}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listSupportedCloudServiceSkusNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept,
+ Context context);
}
/**
@@ -216,6 +270,404 @@ public Response getQuotasWithResponse(String locationNa
return getQuotasWithResponseAsync(locationName, context).block();
}
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedVirtualMachineSkusSinglePageAsync(
+ String locationName, Integer maxresults, String filter) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (locationName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter locationName 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .listSupportedVirtualMachineSkus(
+ this.client.getEndpoint(),
+ locationName,
+ maxresults,
+ filter,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ 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()));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedVirtualMachineSkusSinglePageAsync(
+ String locationName, Integer maxresults, 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 (locationName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter locationName 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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listSupportedVirtualMachineSkus(
+ this.client.getEndpoint(),
+ locationName,
+ maxresults,
+ filter,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ accept,
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedVirtualMachineSkusAsync(
+ String locationName, Integer maxresults, String filter) {
+ return new PagedFlux<>(
+ () -> listSupportedVirtualMachineSkusSinglePageAsync(locationName, maxresults, filter),
+ nextLink -> listSupportedVirtualMachineSkusNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedVirtualMachineSkusAsync(String locationName) {
+ final Integer maxresults = null;
+ final String filter = null;
+ return new PagedFlux<>(
+ () -> listSupportedVirtualMachineSkusSinglePageAsync(locationName, maxresults, filter),
+ nextLink -> listSupportedVirtualMachineSkusNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedVirtualMachineSkusAsync(
+ String locationName, Integer maxresults, String filter, Context context) {
+ return new PagedFlux<>(
+ () -> listSupportedVirtualMachineSkusSinglePageAsync(locationName, maxresults, filter, context),
+ nextLink -> listSupportedVirtualMachineSkusNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listSupportedVirtualMachineSkus(String locationName) {
+ final Integer maxresults = null;
+ final String filter = null;
+ return new PagedIterable<>(listSupportedVirtualMachineSkusAsync(locationName, maxresults, filter));
+ }
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listSupportedVirtualMachineSkus(
+ String locationName, Integer maxresults, String filter, Context context) {
+ return new PagedIterable<>(listSupportedVirtualMachineSkusAsync(locationName, maxresults, filter, context));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedCloudServiceSkusSinglePageAsync(
+ String locationName, Integer maxresults, String filter) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (locationName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter locationName 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."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .listSupportedCloudServiceSkus(
+ this.client.getEndpoint(),
+ locationName,
+ maxresults,
+ filter,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ 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()));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedCloudServiceSkusSinglePageAsync(
+ String locationName, Integer maxresults, 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 (locationName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter locationName 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."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listSupportedCloudServiceSkus(
+ this.client.getEndpoint(),
+ locationName,
+ maxresults,
+ filter,
+ this.client.getApiVersion(),
+ this.client.getSubscriptionId(),
+ accept,
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedCloudServiceSkusAsync(
+ String locationName, Integer maxresults, String filter) {
+ return new PagedFlux<>(
+ () -> listSupportedCloudServiceSkusSinglePageAsync(locationName, maxresults, filter),
+ nextLink -> listSupportedCloudServiceSkusNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedCloudServiceSkusAsync(String locationName) {
+ final Integer maxresults = null;
+ final String filter = null;
+ return new PagedFlux<>(
+ () -> listSupportedCloudServiceSkusSinglePageAsync(locationName, maxresults, filter),
+ nextLink -> listSupportedCloudServiceSkusNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listSupportedCloudServiceSkusAsync(
+ String locationName, Integer maxresults, String filter, Context context) {
+ return new PagedFlux<>(
+ () -> listSupportedCloudServiceSkusSinglePageAsync(locationName, maxresults, filter, context),
+ nextLink -> listSupportedCloudServiceSkusNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listSupportedCloudServiceSkus(String locationName) {
+ final Integer maxresults = null;
+ final String filter = null;
+ return new PagedIterable<>(listSupportedCloudServiceSkusAsync(locationName, maxresults, filter));
+ }
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listSupportedCloudServiceSkus(
+ String locationName, Integer maxresults, String filter, Context context) {
+ return new PagedIterable<>(listSupportedCloudServiceSkusAsync(locationName, maxresults, filter, context));
+ }
+
/**
* Checks whether the Batch account name is available in the specified region.
*
@@ -368,4 +820,152 @@ public Response checkNameAvailabilityWithRespo
String locationName, CheckNameAvailabilityParameters parameters, Context context) {
return checkNameAvailabilityWithResponseAsync(locationName, parameters, context).block();
}
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @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 Batch List supported SKUs operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedVirtualMachineSkusNextSinglePageAsync(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.listSupportedVirtualMachineSkusNext(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 nextLink parameter.
+ * @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 Batch List supported SKUs operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedVirtualMachineSkusNextSinglePageAsync(
+ 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
+ .listSupportedVirtualMachineSkusNext(nextLink, this.client.getEndpoint(), accept, context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @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 Batch List supported SKUs operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedCloudServiceSkusNextSinglePageAsync(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.listSupportedCloudServiceSkusNext(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 nextLink parameter.
+ * @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 Batch List supported SKUs operation response.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSupportedCloudServiceSkusNextSinglePageAsync(
+ 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
+ .listSupportedCloudServiceSkusNext(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/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsImpl.java
index 49f52aa554d7..15f449723fa6 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsImpl.java
@@ -4,6 +4,7 @@
package com.azure.resourcemanager.batch.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;
@@ -11,10 +12,12 @@
import com.azure.resourcemanager.batch.fluent.LocationsClient;
import com.azure.resourcemanager.batch.fluent.models.BatchLocationQuotaInner;
import com.azure.resourcemanager.batch.fluent.models.CheckNameAvailabilityResultInner;
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
import com.azure.resourcemanager.batch.models.BatchLocationQuota;
import com.azure.resourcemanager.batch.models.CheckNameAvailabilityParameters;
import com.azure.resourcemanager.batch.models.CheckNameAvailabilityResult;
import com.azure.resourcemanager.batch.models.Locations;
+import com.azure.resourcemanager.batch.models.SupportedSku;
import com.fasterxml.jackson.annotation.JsonIgnore;
public final class LocationsImpl implements Locations {
@@ -51,6 +54,30 @@ public Response getQuotasWithResponse(String locationName, C
}
}
+ public PagedIterable listSupportedVirtualMachineSkus(String locationName) {
+ PagedIterable inner = this.serviceClient().listSupportedVirtualMachineSkus(locationName);
+ return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listSupportedVirtualMachineSkus(
+ String locationName, Integer maxresults, String filter, Context context) {
+ PagedIterable inner =
+ this.serviceClient().listSupportedVirtualMachineSkus(locationName, maxresults, filter, context);
+ return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listSupportedCloudServiceSkus(String locationName) {
+ PagedIterable inner = this.serviceClient().listSupportedCloudServiceSkus(locationName);
+ return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listSupportedCloudServiceSkus(
+ String locationName, Integer maxresults, String filter, Context context) {
+ PagedIterable inner =
+ this.serviceClient().listSupportedCloudServiceSkus(locationName, maxresults, filter, context);
+ return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager()));
+ }
+
public CheckNameAvailabilityResult checkNameAvailability(
String locationName, CheckNameAvailabilityParameters parameters) {
CheckNameAvailabilityResultInner inner = this.serviceClient().checkNameAvailability(locationName, parameters);
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationImpl.java
index 1269354e9f0d..0981ea7e1388 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationImpl.java
@@ -22,6 +22,10 @@ public String name() {
return this.innerModel().name();
}
+ public Boolean isDataAction() {
+ return this.innerModel().isDataAction();
+ }
+
public OperationDisplay display() {
return this.innerModel().display();
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OutboundEnvironmentEndpointImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OutboundEnvironmentEndpointImpl.java
new file mode 100644
index 000000000000..b3d60df82122
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OutboundEnvironmentEndpointImpl.java
@@ -0,0 +1,44 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.implementation;
+
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
+import com.azure.resourcemanager.batch.models.EndpointDependency;
+import com.azure.resourcemanager.batch.models.OutboundEnvironmentEndpoint;
+import java.util.Collections;
+import java.util.List;
+
+public final class OutboundEnvironmentEndpointImpl implements OutboundEnvironmentEndpoint {
+ private OutboundEnvironmentEndpointInner innerObject;
+
+ private final com.azure.resourcemanager.batch.BatchManager serviceManager;
+
+ OutboundEnvironmentEndpointImpl(
+ OutboundEnvironmentEndpointInner innerObject, com.azure.resourcemanager.batch.BatchManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public String category() {
+ return this.innerModel().category();
+ }
+
+ public List endpoints() {
+ List inner = this.innerModel().endpoints();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public OutboundEnvironmentEndpointInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.batch.BatchManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolImpl.java
index ddf8b61f5f23..72d4999408d4 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolImpl.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolImpl.java
@@ -402,8 +402,13 @@ public PoolImpl withMountConfiguration(List mountConfigurati
}
public PoolImpl withIfMatch(String ifMatch) {
- this.createIfMatch = ifMatch;
- return this;
+ if (isInCreateMode()) {
+ this.createIfMatch = ifMatch;
+ return this;
+ } else {
+ this.updateIfMatch = ifMatch;
+ return this;
+ }
}
public PoolImpl withIfNoneMatch(String ifNoneMatch) {
@@ -411,8 +416,7 @@ public PoolImpl withIfNoneMatch(String ifNoneMatch) {
return this;
}
- public PoolImpl ifMatch(String ifMatch) {
- this.updateIfMatch = ifMatch;
- return this;
+ private boolean isInCreateMode() {
+ return this.innerModel().id() == null;
}
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/SupportedSkuImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/SupportedSkuImpl.java
new file mode 100644
index 000000000000..adc5878d40ec
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/SupportedSkuImpl.java
@@ -0,0 +1,47 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.implementation;
+
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
+import com.azure.resourcemanager.batch.models.SkuCapability;
+import com.azure.resourcemanager.batch.models.SupportedSku;
+import java.util.Collections;
+import java.util.List;
+
+public final class SupportedSkuImpl implements SupportedSku {
+ private SupportedSkuInner innerObject;
+
+ private final com.azure.resourcemanager.batch.BatchManager serviceManager;
+
+ SupportedSkuImpl(SupportedSkuInner innerObject, com.azure.resourcemanager.batch.BatchManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public String name() {
+ return this.innerModel().name();
+ }
+
+ public String familyName() {
+ return this.innerModel().familyName();
+ }
+
+ public List capabilities() {
+ List inner = this.innerModel().capabilities();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public SupportedSkuInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.batch.BatchManager manager() {
+ return this.serviceManager;
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AuthenticationMode.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AuthenticationMode.java
new file mode 100644
index 000000000000..7c366c5b3486
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AuthenticationMode.java
@@ -0,0 +1,50 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonValue;
+
+/** Defines values for AuthenticationMode. */
+public enum AuthenticationMode {
+ /** Enum value SharedKey. */
+ SHARED_KEY("SharedKey"),
+
+ /** Enum value AAD. */
+ AAD("AAD"),
+
+ /** Enum value TaskAuthenticationToken. */
+ TASK_AUTHENTICATION_TOKEN("TaskAuthenticationToken");
+
+ /** The actual serialized value for a AuthenticationMode instance. */
+ private final String value;
+
+ AuthenticationMode(String value) {
+ this.value = value;
+ }
+
+ /**
+ * Parses a serialized value to a AuthenticationMode instance.
+ *
+ * @param value the serialized value to parse.
+ * @return the parsed AuthenticationMode object, or null if unable to parse.
+ */
+ @JsonCreator
+ public static AuthenticationMode fromString(String value) {
+ AuthenticationMode[] items = AuthenticationMode.values();
+ for (AuthenticationMode item : items) {
+ if (item.toString().equalsIgnoreCase(value)) {
+ return item;
+ }
+ }
+ return null;
+ }
+
+ @JsonValue
+ @Override
+ public String toString() {
+ return this.value;
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageAuthenticationMode.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageAuthenticationMode.java
new file mode 100644
index 000000000000..773a3f15595d
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageAuthenticationMode.java
@@ -0,0 +1,47 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonValue;
+
+/** Defines values for AutoStorageAuthenticationMode. */
+public enum AutoStorageAuthenticationMode {
+ /** Enum value StorageKeys. */
+ STORAGE_KEYS("StorageKeys"),
+
+ /** Enum value BatchAccountManagedIdentity. */
+ BATCH_ACCOUNT_MANAGED_IDENTITY("BatchAccountManagedIdentity");
+
+ /** The actual serialized value for a AutoStorageAuthenticationMode instance. */
+ private final String value;
+
+ AutoStorageAuthenticationMode(String value) {
+ this.value = value;
+ }
+
+ /**
+ * Parses a serialized value to a AutoStorageAuthenticationMode instance.
+ *
+ * @param value the serialized value to parse.
+ * @return the parsed AutoStorageAuthenticationMode object, or null if unable to parse.
+ */
+ @JsonCreator
+ public static AutoStorageAuthenticationMode fromString(String value) {
+ AutoStorageAuthenticationMode[] items = AutoStorageAuthenticationMode.values();
+ for (AutoStorageAuthenticationMode item : items) {
+ if (item.toString().equalsIgnoreCase(value)) {
+ return item;
+ }
+ }
+ return null;
+ }
+
+ @JsonValue
+ @Override
+ public String toString() {
+ return this.value;
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageBaseProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageBaseProperties.java
index 490036fdfa7c..c16e8d72e8a3 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageBaseProperties.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageBaseProperties.java
@@ -21,6 +21,20 @@ public class AutoStorageBaseProperties {
@JsonProperty(value = "storageAccountId", required = true)
private String storageAccountId;
+ /*
+ * The authentication mode which the Batch service will use to manage the
+ * auto-storage account.
+ */
+ @JsonProperty(value = "authenticationMode")
+ private AutoStorageAuthenticationMode authenticationMode;
+
+ /*
+ * The identity referenced here must be assigned to pools which have
+ * compute nodes that need access to auto-storage.
+ */
+ @JsonProperty(value = "nodeIdentityReference")
+ private ComputeNodeIdentityReference nodeIdentityReference;
+
/**
* Get the storageAccountId property: The resource ID of the storage account to be used for auto-storage account.
*
@@ -41,6 +55,50 @@ public AutoStorageBaseProperties withStorageAccountId(String storageAccountId) {
return this;
}
+ /**
+ * Get the authenticationMode property: The authentication mode which the Batch service will use to manage the
+ * auto-storage account.
+ *
+ * @return the authenticationMode value.
+ */
+ public AutoStorageAuthenticationMode authenticationMode() {
+ return this.authenticationMode;
+ }
+
+ /**
+ * Set the authenticationMode property: The authentication mode which the Batch service will use to manage the
+ * auto-storage account.
+ *
+ * @param authenticationMode the authenticationMode value to set.
+ * @return the AutoStorageBaseProperties object itself.
+ */
+ public AutoStorageBaseProperties withAuthenticationMode(AutoStorageAuthenticationMode authenticationMode) {
+ this.authenticationMode = authenticationMode;
+ return this;
+ }
+
+ /**
+ * Get the nodeIdentityReference property: The identity referenced here must be assigned to pools which have compute
+ * nodes that need access to auto-storage.
+ *
+ * @return the nodeIdentityReference value.
+ */
+ public ComputeNodeIdentityReference nodeIdentityReference() {
+ return this.nodeIdentityReference;
+ }
+
+ /**
+ * Set the nodeIdentityReference property: The identity referenced here must be assigned to pools which have compute
+ * nodes that need access to auto-storage.
+ *
+ * @param nodeIdentityReference the nodeIdentityReference value to set.
+ * @return the AutoStorageBaseProperties object itself.
+ */
+ public AutoStorageBaseProperties withNodeIdentityReference(ComputeNodeIdentityReference nodeIdentityReference) {
+ this.nodeIdentityReference = nodeIdentityReference;
+ return this;
+ }
+
/**
* Validates the instance.
*
@@ -53,5 +111,8 @@ public void validate() {
new IllegalArgumentException(
"Missing required property storageAccountId in model AutoStorageBaseProperties"));
}
+ if (nodeIdentityReference() != null) {
+ nodeIdentityReference().validate();
+ }
}
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageProperties.java
index b4a834295adb..e4896e09bb5e 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageProperties.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoStorageProperties.java
@@ -49,6 +49,20 @@ public AutoStorageProperties withStorageAccountId(String storageAccountId) {
return this;
}
+ /** {@inheritDoc} */
+ @Override
+ public AutoStorageProperties withAuthenticationMode(AutoStorageAuthenticationMode authenticationMode) {
+ super.withAuthenticationMode(authenticationMode);
+ return this;
+ }
+
+ /** {@inheritDoc} */
+ @Override
+ public AutoStorageProperties withNodeIdentityReference(ComputeNodeIdentityReference nodeIdentityReference) {
+ super.withNodeIdentityReference(nodeIdentityReference);
+ return this;
+ }
+
/**
* Validates the instance.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureBlobFileSystemConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureBlobFileSystemConfiguration.java
index d31dec173520..c08b3cdef5eb 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureBlobFileSystemConfiguration.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureBlobFileSystemConfiguration.java
@@ -27,15 +27,15 @@ public final class AzureBlobFileSystemConfiguration {
private String containerName;
/*
- * This property is mutually exclusive with sasKey and one must be
- * specified.
+ * This property is mutually exclusive with both sasKey and identity;
+ * exactly one must be specified.
*/
@JsonProperty(value = "accountKey")
private String accountKey;
/*
- * This property is mutually exclusive with accountKey and one must be
- * specified.
+ * This property is mutually exclusive with both accountKey and identity;
+ * exactly one must be specified.
*/
@JsonProperty(value = "sasKey")
private String sasKey;
@@ -53,6 +53,13 @@ public final class AzureBlobFileSystemConfiguration {
@JsonProperty(value = "relativeMountPath", required = true)
private String relativeMountPath;
+ /*
+ * This property is mutually exclusive with both accountKey and sasKey;
+ * exactly one must be specified.
+ */
+ @JsonProperty(value = "identityReference")
+ private ComputeNodeIdentityReference identityReference;
+
/**
* Get the accountName property: The Azure Storage Account name.
*
@@ -94,7 +101,8 @@ public AzureBlobFileSystemConfiguration withContainerName(String containerName)
}
/**
- * Get the accountKey property: This property is mutually exclusive with sasKey and one must be specified.
+ * Get the accountKey property: This property is mutually exclusive with both sasKey and identity; exactly one must
+ * be specified.
*
* @return the accountKey value.
*/
@@ -103,7 +111,8 @@ public String accountKey() {
}
/**
- * Set the accountKey property: This property is mutually exclusive with sasKey and one must be specified.
+ * Set the accountKey property: This property is mutually exclusive with both sasKey and identity; exactly one must
+ * be specified.
*
* @param accountKey the accountKey value to set.
* @return the AzureBlobFileSystemConfiguration object itself.
@@ -114,7 +123,8 @@ public AzureBlobFileSystemConfiguration withAccountKey(String accountKey) {
}
/**
- * Get the sasKey property: This property is mutually exclusive with accountKey and one must be specified.
+ * Get the sasKey property: This property is mutually exclusive with both accountKey and identity; exactly one must
+ * be specified.
*
* @return the sasKey value.
*/
@@ -123,7 +133,8 @@ public String sasKey() {
}
/**
- * Set the sasKey property: This property is mutually exclusive with accountKey and one must be specified.
+ * Set the sasKey property: This property is mutually exclusive with both accountKey and identity; exactly one must
+ * be specified.
*
* @param sasKey the sasKey value to set.
* @return the AzureBlobFileSystemConfiguration object itself.
@@ -175,6 +186,28 @@ public AzureBlobFileSystemConfiguration withRelativeMountPath(String relativeMou
return this;
}
+ /**
+ * Get the identityReference property: This property is mutually exclusive with both accountKey and sasKey; exactly
+ * one must be specified.
+ *
+ * @return the identityReference value.
+ */
+ public ComputeNodeIdentityReference identityReference() {
+ return this.identityReference;
+ }
+
+ /**
+ * Set the identityReference property: This property is mutually exclusive with both accountKey and sasKey; exactly
+ * one must be specified.
+ *
+ * @param identityReference the identityReference value to set.
+ * @return the AzureBlobFileSystemConfiguration object itself.
+ */
+ public AzureBlobFileSystemConfiguration withIdentityReference(ComputeNodeIdentityReference identityReference) {
+ this.identityReference = identityReference;
+ return this;
+ }
+
/**
* Validates the instance.
*
@@ -199,5 +232,8 @@ public void validate() {
new IllegalArgumentException(
"Missing required property relativeMountPath in model AzureBlobFileSystemConfiguration"));
}
+ if (identityReference() != null) {
+ identityReference().validate();
+ }
}
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccount.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccount.java
index 95d6ce1817ed..93844751aa00 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccount.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccount.java
@@ -166,6 +166,14 @@ public interface BatchAccount {
*/
Integer activeJobAndJobScheduleQuota();
+ /**
+ * Gets the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @return the allowedAuthenticationModes value.
+ */
+ List allowedAuthenticationModes();
+
/**
* Gets the region of the resource.
*
@@ -238,7 +246,8 @@ interface WithCreate
DefinitionStages.WithPoolAllocationMode,
DefinitionStages.WithKeyVaultReference,
DefinitionStages.WithPublicNetworkAccess,
- DefinitionStages.WithEncryption {
+ DefinitionStages.WithEncryption,
+ DefinitionStages.WithAllowedAuthenticationModes {
/**
* Executes the create request.
*
@@ -335,6 +344,19 @@ interface WithEncryption {
*/
WithCreate withEncryption(EncryptionProperties encryption);
}
+ /** The stage of the BatchAccount definition allowing to specify allowedAuthenticationModes. */
+ interface WithAllowedAuthenticationModes {
+ /**
+ * Specifies the allowedAuthenticationModes property: List of allowed authentication modes for the Batch
+ * account that can be used to authenticate with the data plane. This does not affect authentication with
+ * the control plane..
+ *
+ * @param allowedAuthenticationModes List of allowed authentication modes for the Batch account that can be
+ * used to authenticate with the data plane. This does not affect authentication with the control plane.
+ * @return the next definition stage.
+ */
+ WithCreate withAllowedAuthenticationModes(List allowedAuthenticationModes);
+ }
}
/**
* Begins update for the BatchAccount resource.
@@ -348,7 +370,8 @@ interface Update
extends UpdateStages.WithTags,
UpdateStages.WithIdentity,
UpdateStages.WithAutoStorage,
- UpdateStages.WithEncryption {
+ UpdateStages.WithEncryption,
+ UpdateStages.WithAllowedAuthenticationModes {
/**
* Executes the update request.
*
@@ -410,6 +433,19 @@ interface WithEncryption {
*/
Update withEncryption(EncryptionProperties encryption);
}
+ /** The stage of the BatchAccount update allowing to specify allowedAuthenticationModes. */
+ interface WithAllowedAuthenticationModes {
+ /**
+ * Specifies the allowedAuthenticationModes property: List of allowed authentication modes for the Batch
+ * account that can be used to authenticate with the data plane. This does not affect authentication with
+ * the control plane..
+ *
+ * @param allowedAuthenticationModes List of allowed authentication modes for the Batch account that can be
+ * used to authenticate with the data plane. This does not affect authentication with the control plane.
+ * @return the next definition stage.
+ */
+ Update withAllowedAuthenticationModes(List allowedAuthenticationModes);
+ }
}
/**
* Refreshes the resource to sync with Azure.
@@ -427,7 +463,8 @@ interface WithEncryption {
BatchAccount refresh(Context context);
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @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.
@@ -435,7 +472,8 @@ interface WithEncryption {
void synchronizeAutoStorageKeys();
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
@@ -446,7 +484,10 @@ interface WithEncryption {
Response synchronizeAutoStorageKeysWithResponse(Context context);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param parameters The type of key to regenerate.
* @throws IllegalArgumentException thrown if parameters fail the validation.
@@ -457,7 +498,10 @@ interface WithEncryption {
BatchAccountKeys regenerateKey(BatchAccountRegenerateKeyParameters parameters);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param parameters The type of key to regenerate.
* @param context The context to associate with this operation.
@@ -470,9 +514,9 @@ Response regenerateKeyWithResponse(
BatchAccountRegenerateKeyParameters parameters, Context context);
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @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.
@@ -481,9 +525,9 @@ Response regenerateKeyWithResponse(
BatchAccountKeys getKeys();
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountCreateParameters.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountCreateParameters.java
index 1ccb7975edb4..bd8fbefafaa7 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountCreateParameters.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountCreateParameters.java
@@ -9,6 +9,7 @@
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
import java.util.Map;
/** Parameters supplied to the Create operation. */
@@ -71,6 +72,14 @@ public class BatchAccountCreateParameters {
@JsonProperty(value = "properties.encryption")
private EncryptionProperties encryption;
+ /*
+ * List of allowed authentication modes for the Batch account that can be
+ * used to authenticate with the data plane. This does not affect
+ * authentication with the control plane.
+ */
+ @JsonProperty(value = "properties.allowedAuthenticationModes")
+ private List allowedAuthenticationModes;
+
/**
* Get the location property: The region in which to create the account.
*
@@ -239,6 +248,29 @@ public BatchAccountCreateParameters withEncryption(EncryptionProperties encrypti
return this;
}
+ /**
+ * Get the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @return the allowedAuthenticationModes value.
+ */
+ public List allowedAuthenticationModes() {
+ return this.allowedAuthenticationModes;
+ }
+
+ /**
+ * Set the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @param allowedAuthenticationModes the allowedAuthenticationModes value to set.
+ * @return the BatchAccountCreateParameters object itself.
+ */
+ public BatchAccountCreateParameters withAllowedAuthenticationModes(
+ List allowedAuthenticationModes) {
+ this.allowedAuthenticationModes = allowedAuthenticationModes;
+ return this;
+ }
+
/**
* Validates the instance.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentity.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentity.java
index bd923b5b27ac..cc32a8aac25d 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentity.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentity.java
@@ -11,8 +11,8 @@
import java.util.Map;
/**
- * The identity of the Batch account, if configured. This is only used when the user specifies 'Microsoft.KeyVault' as
- * their Batch account encryption configuration.
+ * The identity of the Batch account, if configured. This is used when the user specifies 'Microsoft.KeyVault' as their
+ * Batch account encryption configuration or when `ManagedIdentity` is selected as the auto-storage authentication mode.
*/
@Fluent
public class BatchAccountIdentity {
@@ -39,12 +39,10 @@ public class BatchAccountIdentity {
private ResourceIdentityType type;
/*
- * The list of user identities associated with the Batch account. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * The list of user identities associated with the Batch account.
*/
@JsonProperty(value = "userAssignedIdentities")
- private Map userAssignedIdentities;
+ private Map userAssignedIdentities;
/**
* Get the principalId property: The principal id of the Batch account. This property will only be provided for a
@@ -87,26 +85,21 @@ public BatchAccountIdentity withType(ResourceIdentityType type) {
}
/**
- * Get the userAssignedIdentities property: The list of user identities associated with the Batch account. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * Get the userAssignedIdentities property: The list of user identities associated with the Batch account.
*
* @return the userAssignedIdentities value.
*/
- public Map userAssignedIdentities() {
+ public Map userAssignedIdentities() {
return this.userAssignedIdentities;
}
/**
- * Set the userAssignedIdentities property: The list of user identities associated with the Batch account. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * Set the userAssignedIdentities property: The list of user identities associated with the Batch account.
*
* @param userAssignedIdentities the userAssignedIdentities value to set.
* @return the BatchAccountIdentity object itself.
*/
- public BatchAccountIdentity withUserAssignedIdentities(
- Map userAssignedIdentities) {
+ public BatchAccountIdentity withUserAssignedIdentities(Map userAssignedIdentities) {
this.userAssignedIdentities = userAssignedIdentities;
return this;
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentityUserAssignedIdentities.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentityUserAssignedIdentities.java
deleted file mode 100644
index 0af19ff176e4..000000000000
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountIdentityUserAssignedIdentities.java
+++ /dev/null
@@ -1,54 +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.batch.models;
-
-import com.azure.core.annotation.Immutable;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** The BatchAccountIdentityUserAssignedIdentities model. */
-@Immutable
-public final class BatchAccountIdentityUserAssignedIdentities {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(BatchAccountIdentityUserAssignedIdentities.class);
-
- /*
- * The principal id of user assigned identity.
- */
- @JsonProperty(value = "principalId", access = JsonProperty.Access.WRITE_ONLY)
- private String principalId;
-
- /*
- * The client id of user assigned identity.
- */
- @JsonProperty(value = "clientId", access = JsonProperty.Access.WRITE_ONLY)
- private String clientId;
-
- /**
- * Get the principalId property: The principal id of user assigned identity.
- *
- * @return the principalId value.
- */
- public String principalId() {
- return this.principalId;
- }
-
- /**
- * Get the clientId property: The client id of user assigned identity.
- *
- * @return the clientId value.
- */
- public String clientId() {
- return this.clientId;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountUpdateParameters.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountUpdateParameters.java
index 619a7a1759ea..c650aab40b5b 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountUpdateParameters.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountUpdateParameters.java
@@ -9,6 +9,7 @@
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
import java.util.Map;
/** Parameters for updating an Azure Batch account. */
@@ -43,6 +44,14 @@ public class BatchAccountUpdateParameters {
@JsonProperty(value = "properties.encryption")
private EncryptionProperties encryption;
+ /*
+ * List of allowed authentication modes for the Batch account that can be
+ * used to authenticate with the data plane. This does not affect
+ * authentication with the control plane.
+ */
+ @JsonProperty(value = "properties.allowedAuthenticationModes")
+ private List allowedAuthenticationModes;
+
/**
* Get the tags property: The user-specified tags associated with the account.
*
@@ -127,6 +136,29 @@ public BatchAccountUpdateParameters withEncryption(EncryptionProperties encrypti
return this;
}
+ /**
+ * Get the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @return the allowedAuthenticationModes value.
+ */
+ public List allowedAuthenticationModes() {
+ return this.allowedAuthenticationModes;
+ }
+
+ /**
+ * Set the allowedAuthenticationModes property: List of allowed authentication modes for the Batch account that can
+ * be used to authenticate with the data plane. This does not affect authentication with the control plane.
+ *
+ * @param allowedAuthenticationModes the allowedAuthenticationModes value to set.
+ * @return the BatchAccountUpdateParameters object itself.
+ */
+ public BatchAccountUpdateParameters withAllowedAuthenticationModes(
+ List allowedAuthenticationModes) {
+ this.allowedAuthenticationModes = allowedAuthenticationModes;
+ return this;
+ }
+
/**
* Validates the instance.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccounts.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccounts.java
index e1801d8c05b0..81e22ae35802 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccounts.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccounts.java
@@ -103,7 +103,8 @@ Response getByResourceGroupWithResponse(
PagedIterable listByResourceGroup(String resourceGroupName, Context context);
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -114,7 +115,8 @@ Response getByResourceGroupWithResponse(
void synchronizeAutoStorageKeys(String resourceGroupName, String accountName);
/**
- * Synchronizes access keys for the auto-storage account configured for the specified Batch account.
+ * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage
+ * key authentication is being used.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -128,7 +130,10 @@ Response synchronizeAutoStorageKeysWithResponse(
String resourceGroupName, String accountName, Context context);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -142,7 +147,10 @@ BatchAccountKeys regenerateKey(
String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters);
/**
- * Regenerates the specified account key for the Batch account.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, regenerating the keys will
+ * fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -157,9 +165,9 @@ Response regenerateKeyWithResponse(
String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context);
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -171,9 +179,9 @@ Response regenerateKeyWithResponse(
BatchAccountKeys getKeys(String resourceGroupName, String accountName);
/**
- * This operation applies only to Batch accounts created with a poolAllocationMode of 'BatchService'. If the Batch
- * account was created with a poolAllocationMode of 'UserSubscription', clients cannot use access to keys to
- * authenticate, and must use Azure Active Directory instead. In this case, getting the keys will fail.
+ * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the
+ * Batch account doesn't contain 'SharedKey' in its allowedAuthenticationMode, clients cannot use shared keys to
+ * authenticate, and must use another allowedAuthenticationModes instead. In this case, getting the keys will fail.
*
* @param resourceGroupName The name of the resource group that contains the Batch account.
* @param accountName The name of the Batch account.
@@ -185,6 +193,41 @@ Response regenerateKeyWithResponse(
*/
Response getKeysWithResponse(String resourceGroupName, String accountName, Context context);
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName);
+
+ /**
+ * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service
+ * administration. If you are deploying a Pool inside of a virtual network that you specify, you must make sure your
+ * network allows outbound access to these endpoints. Failure to allow access to these endpoints may cause Batch to
+ * mark the affected nodes as unusable. For more information about creating a pool inside of a virtual network, see
+ * https://docs.microsoft.com/en-us/azure/batch/batch-virtual-network.
+ *
+ * @param resourceGroupName The name of the resource group that contains the Batch account.
+ * @param accountName The name of the Batch account.
+ * @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 values returned by the List operation.
+ */
+ PagedIterable listOutboundNetworkDependenciesEndpoints(
+ String resourceGroupName, String accountName, Context context);
+
/**
* Gets information about the specified Batch account.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentity.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentity.java
index 1cdf96f53ab8..f270a490f3fa 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentity.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentity.java
@@ -25,12 +25,10 @@ public class BatchPoolIdentity {
private PoolIdentityType type;
/*
- * The list of user identities associated with the Batch pool. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * The list of user identities associated with the Batch pool.
*/
@JsonProperty(value = "userAssignedIdentities")
- private Map userAssignedIdentities;
+ private Map userAssignedIdentities;
/**
* Get the type property: The type of identity used for the Batch Pool.
@@ -53,26 +51,21 @@ public BatchPoolIdentity withType(PoolIdentityType type) {
}
/**
- * Get the userAssignedIdentities property: The list of user identities associated with the Batch pool. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * Get the userAssignedIdentities property: The list of user identities associated with the Batch pool.
*
* @return the userAssignedIdentities value.
*/
- public Map userAssignedIdentities() {
+ public Map userAssignedIdentities() {
return this.userAssignedIdentities;
}
/**
- * Set the userAssignedIdentities property: The list of user identities associated with the Batch pool. The user
- * identity dictionary key references will be ARM resource ids in the form:
- * '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.ManagedIdentity/userAssignedIdentities/{identityName}'.
+ * Set the userAssignedIdentities property: The list of user identities associated with the Batch pool.
*
* @param userAssignedIdentities the userAssignedIdentities value to set.
* @return the BatchPoolIdentity object itself.
*/
- public BatchPoolIdentity withUserAssignedIdentities(
- Map userAssignedIdentities) {
+ public BatchPoolIdentity withUserAssignedIdentities(Map userAssignedIdentities) {
this.userAssignedIdentities = userAssignedIdentities;
return this;
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificate.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificate.java
index 2a684f21ef51..7b23ebca9616 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificate.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificate.java
@@ -253,7 +253,7 @@ interface Update
UpdateStages.WithFormat,
UpdateStages.WithData,
UpdateStages.WithPassword,
- UpdateStages.WithifMatch {
+ UpdateStages.WithIfMatch {
/**
* Executes the update request.
*
@@ -325,7 +325,7 @@ interface WithPassword {
Update withPassword(String password);
}
/** The stage of the Certificate update allowing to specify ifMatch. */
- interface WithifMatch {
+ interface WithIfMatch {
/**
* Specifies the ifMatch property: The entity state (ETag) version of the certificate to update. This value
* can be omitted or set to "*" to apply the operation unconditionally..
@@ -334,7 +334,7 @@ interface WithifMatch {
* set to "*" to apply the operation unconditionally.
* @return the next definition stage.
*/
- Update ifMatch(String ifMatch);
+ Update withIfMatch(String ifMatch);
}
}
/**
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateBaseProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateBaseProperties.java
index 1d683a016353..eecb731393e5 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateBaseProperties.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateBaseProperties.java
@@ -9,7 +9,7 @@
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-/** The CertificateBaseProperties model. */
+/** Base certificate properties. */
@Fluent
public class CertificateBaseProperties {
@JsonIgnore private final ClientLogger logger = new ClientLogger(CertificateBaseProperties.class);
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProperties.java
index 419e1b7b996c..f9c58d45491a 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProperties.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProperties.java
@@ -4,14 +4,14 @@
package com.azure.resourcemanager.batch.models;
-import com.azure.core.annotation.Immutable;
+import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.time.OffsetDateTime;
/** Certificate properties. */
-@Immutable
+@Fluent
public final class CertificateProperties extends CertificateBaseProperties {
@JsonIgnore private final ClientLogger logger = new ClientLogger(CertificateProperties.class);
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeIdentityReference.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeIdentityReference.java
new file mode 100644
index 000000000000..ee29c5f854df
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeIdentityReference.java
@@ -0,0 +1,50 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** The reference to a user assigned identity associated with the Batch pool which a compute node will use. */
+@Fluent
+public final class ComputeNodeIdentityReference {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeNodeIdentityReference.class);
+
+ /*
+ * The ARM resource id of the user assigned identity.
+ */
+ @JsonProperty(value = "resourceId")
+ private String resourceId;
+
+ /**
+ * Get the resourceId property: The ARM resource id of the user assigned identity.
+ *
+ * @return the resourceId value.
+ */
+ public String resourceId() {
+ return this.resourceId;
+ }
+
+ /**
+ * Set the resourceId property: The ARM resource id of the user assigned identity.
+ *
+ * @param resourceId the resourceId value to set.
+ * @return the ComputeNodeIdentityReference object itself.
+ */
+ public ComputeNodeIdentityReference withResourceId(String resourceId) {
+ this.resourceId = resourceId;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerRegistry.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerRegistry.java
index 9f82c2c013cf..a420340a2057 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerRegistry.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerRegistry.java
@@ -14,43 +14,30 @@
public final class ContainerRegistry {
@JsonIgnore private final ClientLogger logger = new ClientLogger(ContainerRegistry.class);
- /*
- * If omitted, the default is "docker.io".
- */
- @JsonProperty(value = "registryServer")
- private String registryServer;
-
/*
* The user name to log into the registry server.
*/
- @JsonProperty(value = "username", required = true)
+ @JsonProperty(value = "username")
private String username;
/*
* The password to log into the registry server.
*/
- @JsonProperty(value = "password", required = true)
+ @JsonProperty(value = "password")
private String password;
- /**
- * Get the registryServer property: If omitted, the default is "docker.io".
- *
- * @return the registryServer value.
+ /*
+ * If omitted, the default is "docker.io".
*/
- public String registryServer() {
- return this.registryServer;
- }
+ @JsonProperty(value = "registryServer")
+ private String registryServer;
- /**
- * Set the registryServer property: If omitted, the default is "docker.io".
- *
- * @param registryServer the registryServer value to set.
- * @return the ContainerRegistry object itself.
+ /*
+ * The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
*/
- public ContainerRegistry withRegistryServer(String registryServer) {
- this.registryServer = registryServer;
- return this;
- }
+ @JsonProperty(value = "identityReference")
+ private ComputeNodeIdentityReference identityReference;
/**
* Get the username property: The user name to log into the registry server.
@@ -92,21 +79,56 @@ public ContainerRegistry withPassword(String password) {
return this;
}
+ /**
+ * Get the registryServer property: If omitted, the default is "docker.io".
+ *
+ * @return the registryServer value.
+ */
+ public String registryServer() {
+ return this.registryServer;
+ }
+
+ /**
+ * Set the registryServer property: If omitted, the default is "docker.io".
+ *
+ * @param registryServer the registryServer value to set.
+ * @return the ContainerRegistry object itself.
+ */
+ public ContainerRegistry withRegistryServer(String registryServer) {
+ this.registryServer = registryServer;
+ return this;
+ }
+
+ /**
+ * Get the identityReference property: The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
+ *
+ * @return the identityReference value.
+ */
+ public ComputeNodeIdentityReference identityReference() {
+ return this.identityReference;
+ }
+
+ /**
+ * Set the identityReference property: The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
+ *
+ * @param identityReference the identityReference value to set.
+ * @return the ContainerRegistry object itself.
+ */
+ public ContainerRegistry withIdentityReference(ComputeNodeIdentityReference identityReference) {
+ this.identityReference = identityReference;
+ return this;
+ }
+
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (username() == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException("Missing required property username in model ContainerRegistry"));
- }
- if (password() == null) {
- throw logger
- .logExceptionAsError(
- new IllegalArgumentException("Missing required property password in model ContainerRegistry"));
+ if (identityReference() != null) {
+ identityReference().validate();
}
}
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskPlacement.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskPlacement.java
new file mode 100644
index 000000000000..9c9ba3e41e9a
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskPlacement.java
@@ -0,0 +1,44 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonValue;
+
+/** Defines values for DiffDiskPlacement. */
+public enum DiffDiskPlacement {
+ /** Enum value CacheDisk. */
+ CACHE_DISK("CacheDisk");
+
+ /** The actual serialized value for a DiffDiskPlacement instance. */
+ private final String value;
+
+ DiffDiskPlacement(String value) {
+ this.value = value;
+ }
+
+ /**
+ * Parses a serialized value to a DiffDiskPlacement instance.
+ *
+ * @param value the serialized value to parse.
+ * @return the parsed DiffDiskPlacement object, or null if unable to parse.
+ */
+ @JsonCreator
+ public static DiffDiskPlacement fromString(String value) {
+ DiffDiskPlacement[] items = DiffDiskPlacement.values();
+ for (DiffDiskPlacement item : items) {
+ if (item.toString().equalsIgnoreCase(value)) {
+ return item;
+ }
+ }
+ return null;
+ }
+
+ @JsonValue
+ @Override
+ public String toString() {
+ return this.value;
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskSettings.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskSettings.java
new file mode 100644
index 000000000000..39ab94eb9402
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiffDiskSettings.java
@@ -0,0 +1,65 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Specifies the ephemeral Disk Settings for the operating system disk used by the virtual machine. */
+@Fluent
+public final class DiffDiskSettings {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(DiffDiskSettings.class);
+
+ /*
+ * This property can be used by user in the request to choose which
+ * location the operating system should be in. e.g., cache disk space for
+ * Ephemeral OS disk provisioning. For more information on Ephemeral OS
+ * disk size requirements, please refer to Ephemeral OS disk size
+ * requirements for Windows VMs at
+ * https://docs.microsoft.com/en-us/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements
+ * and Linux VMs at
+ * https://docs.microsoft.com/en-us/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.
+ */
+ @JsonProperty(value = "placement")
+ private DiffDiskPlacement placement;
+
+ /**
+ * Get the placement property: This property can be used by user in the request to choose which location the
+ * operating system should be in. e.g., cache disk space for Ephemeral OS disk provisioning. For more information on
+ * Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at
+ * https://docs.microsoft.com/en-us/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux
+ * VMs at https://docs.microsoft.com/en-us/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.
+ *
+ * @return the placement value.
+ */
+ public DiffDiskPlacement placement() {
+ return this.placement;
+ }
+
+ /**
+ * Set the placement property: This property can be used by user in the request to choose which location the
+ * operating system should be in. e.g., cache disk space for Ephemeral OS disk provisioning. For more information on
+ * Ephemeral OS disk size requirements, please refer to Ephemeral OS disk size requirements for Windows VMs at
+ * https://docs.microsoft.com/en-us/azure/virtual-machines/windows/ephemeral-os-disks#size-requirements and Linux
+ * VMs at https://docs.microsoft.com/en-us/azure/virtual-machines/linux/ephemeral-os-disks#size-requirements.
+ *
+ * @param placement the placement value to set.
+ * @return the DiffDiskSettings object itself.
+ */
+ public DiffDiskSettings withPlacement(DiffDiskPlacement placement) {
+ this.placement = placement;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDependency.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDependency.java
new file mode 100644
index 000000000000..bb82dc3b8171
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDependency.java
@@ -0,0 +1,77 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** A domain name and connection details used to access a dependency. */
+@Immutable
+public final class EndpointDependency {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(EndpointDependency.class);
+
+ /*
+ * The domain name of the dependency. Domain names may be fully qualified
+ * or may contain a * wildcard.
+ */
+ @JsonProperty(value = "domainName", access = JsonProperty.Access.WRITE_ONLY)
+ private String domainName;
+
+ /*
+ * Human-readable supplemental information about the dependency and when it
+ * is applicable.
+ */
+ @JsonProperty(value = "description", access = JsonProperty.Access.WRITE_ONLY)
+ private String description;
+
+ /*
+ * The list of connection details for this endpoint.
+ */
+ @JsonProperty(value = "endpointDetails", access = JsonProperty.Access.WRITE_ONLY)
+ private List endpointDetails;
+
+ /**
+ * Get the domainName property: The domain name of the dependency. Domain names may be fully qualified or may
+ * contain a * wildcard.
+ *
+ * @return the domainName value.
+ */
+ public String domainName() {
+ return this.domainName;
+ }
+
+ /**
+ * Get the description property: Human-readable supplemental information about the dependency and when it is
+ * applicable.
+ *
+ * @return the description value.
+ */
+ public String description() {
+ return this.description;
+ }
+
+ /**
+ * Get the endpointDetails property: The list of connection details for this endpoint.
+ *
+ * @return the endpointDetails value.
+ */
+ public List endpointDetails() {
+ return this.endpointDetails;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (endpointDetails() != null) {
+ endpointDetails().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDetail.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDetail.java
new file mode 100644
index 000000000000..c40f1f8f8251
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointDetail.java
@@ -0,0 +1,39 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Details about the connection between the Batch service and the endpoint. */
+@Immutable
+public final class EndpointDetail {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(EndpointDetail.class);
+
+ /*
+ * The port an endpoint is connected to.
+ */
+ @JsonProperty(value = "port", access = JsonProperty.Access.WRITE_ONLY)
+ private Integer port;
+
+ /**
+ * Get the port property: The port an endpoint is connected to.
+ *
+ * @return the port value.
+ */
+ public Integer port() {
+ return this.port;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Locations.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Locations.java
index c0d1e1ef2488..9b701d4e3cb5 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Locations.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Locations.java
@@ -4,6 +4,7 @@
package com.azure.resourcemanager.batch.models;
+import com.azure.core.http.rest.PagedIterable;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
@@ -32,6 +33,58 @@ public interface Locations {
*/
Response getQuotasWithResponse(String locationName, Context context);
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ PagedIterable listSupportedVirtualMachineSkus(String locationName);
+
+ /**
+ * Gets the list of Batch supported Virtual Machine VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Virtual Machine VM sizes available at the given location.
+ */
+ PagedIterable listSupportedVirtualMachineSkus(
+ String locationName, Integer maxresults, String filter, Context context);
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ PagedIterable listSupportedCloudServiceSkus(String locationName);
+
+ /**
+ * Gets the list of Batch supported Cloud Service VM sizes available at the given location.
+ *
+ * @param locationName The region for which to retrieve Batch service supported SKUs.
+ * @param maxresults The maximum number of items to return in the response.
+ * @param filter OData filter expression. Valid properties for filtering are "familyName".
+ * @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 list of Batch supported Cloud Service VM sizes available at the given location.
+ */
+ PagedIterable listSupportedCloudServiceSkus(
+ String locationName, Integer maxresults, String filter, Context context);
+
/**
* Checks whether the Batch account name is available in the specified region.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OSDisk.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OSDisk.java
new file mode 100644
index 000000000000..61bb0a048859
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OSDisk.java
@@ -0,0 +1,56 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Settings for the operating system disk of the virtual machine. */
+@Fluent
+public final class OSDisk {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(OSDisk.class);
+
+ /*
+ * Specifies the ephemeral Disk Settings for the operating system disk used
+ * by the virtual machine.
+ */
+ @JsonProperty(value = "ephemeralOSDiskSettings")
+ private DiffDiskSettings ephemeralOSDiskSettings;
+
+ /**
+ * Get the ephemeralOSDiskSettings property: Specifies the ephemeral Disk Settings for the operating system disk
+ * used by the virtual machine.
+ *
+ * @return the ephemeralOSDiskSettings value.
+ */
+ public DiffDiskSettings ephemeralOSDiskSettings() {
+ return this.ephemeralOSDiskSettings;
+ }
+
+ /**
+ * Set the ephemeralOSDiskSettings property: Specifies the ephemeral Disk Settings for the operating system disk
+ * used by the virtual machine.
+ *
+ * @param ephemeralOSDiskSettings the ephemeralOSDiskSettings value to set.
+ * @return the OSDisk object itself.
+ */
+ public OSDisk withEphemeralOSDiskSettings(DiffDiskSettings ephemeralOSDiskSettings) {
+ this.ephemeralOSDiskSettings = ephemeralOSDiskSettings;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (ephemeralOSDiskSettings() != null) {
+ ephemeralOSDiskSettings().validate();
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Operation.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Operation.java
index b5dfd0d04d36..faa38c52f0a4 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Operation.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Operation.java
@@ -15,6 +15,13 @@ public interface Operation {
*/
String name();
+ /**
+ * Gets the isDataAction property: Indicates whether the operation is a data action.
+ *
+ * @return the isDataAction value.
+ */
+ Boolean isDataAction();
+
/**
* Gets the display property: The object that describes the operation.
*
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpoint.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpoint.java
new file mode 100644
index 000000000000..666abc9ce870
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpoint.java
@@ -0,0 +1,32 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
+import java.util.List;
+
+/** An immutable client-side representation of OutboundEnvironmentEndpoint. */
+public interface OutboundEnvironmentEndpoint {
+ /**
+ * Gets the category property: The type of service that the Batch service connects to.
+ *
+ * @return the category value.
+ */
+ String category();
+
+ /**
+ * Gets the endpoints property: The endpoints for this service to which the Batch service makes outbound calls.
+ *
+ * @return the endpoints value.
+ */
+ List endpoints();
+
+ /**
+ * Gets the inner com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner object.
+ *
+ * @return the inner object.
+ */
+ OutboundEnvironmentEndpointInner innerModel();
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpointCollection.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpointCollection.java
new file mode 100644
index 000000000000..f9b97d719f68
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OutboundEnvironmentEndpointCollection.java
@@ -0,0 +1,72 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.batch.fluent.models.OutboundEnvironmentEndpointInner;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Values returned by the List operation. */
+@Fluent
+public final class OutboundEnvironmentEndpointCollection {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(OutboundEnvironmentEndpointCollection.class);
+
+ /*
+ * The collection of outbound network dependency endpoints returned by the
+ * listing operation.
+ */
+ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY)
+ private List value;
+
+ /*
+ * The continuation token.
+ */
+ @JsonProperty(value = "nextLink")
+ private String nextLink;
+
+ /**
+ * Get the value property: The collection of outbound network dependency endpoints returned by the listing
+ * operation.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Get the nextLink property: The continuation token.
+ *
+ * @return the nextLink value.
+ */
+ public String nextLink() {
+ return this.nextLink;
+ }
+
+ /**
+ * Set the nextLink property: The continuation token.
+ *
+ * @param nextLink the nextLink value to set.
+ * @return the OutboundEnvironmentEndpointCollection object itself.
+ */
+ public OutboundEnvironmentEndpointCollection withNextLink(String nextLink) {
+ this.nextLink = nextLink;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() != null) {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pool.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pool.java
index 1f2de55f92cf..9f2c86484f31 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pool.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pool.java
@@ -123,7 +123,7 @@ public interface Pool {
Integer currentDedicatedNodes();
/**
- * Gets the currentLowPriorityNodes property: The number of low priority compute nodes currently in the pool.
+ * Gets the currentLowPriorityNodes property: The number of low-priority compute nodes currently in the pool.
*
* @return the currentLowPriorityNodes value.
*/
@@ -584,7 +584,7 @@ interface Update
UpdateStages.WithApplicationPackages,
UpdateStages.WithApplicationLicenses,
UpdateStages.WithMountConfiguration,
- UpdateStages.WithifMatch {
+ UpdateStages.WithIfMatch {
/**
* Executes the update request.
*
@@ -821,7 +821,7 @@ interface WithMountConfiguration {
Update withMountConfiguration(List mountConfiguration);
}
/** The stage of the Pool update allowing to specify ifMatch. */
- interface WithifMatch {
+ interface WithIfMatch {
/**
* Specifies the ifMatch property: The entity state (ETag) version of the pool to update. This value can be
* omitted or set to "*" to apply the operation unconditionally..
@@ -830,7 +830,7 @@ interface WithifMatch {
* "*" to apply the operation unconditionally.
* @return the next definition stage.
*/
- Update ifMatch(String ifMatch);
+ Update withIfMatch(String ifMatch);
}
}
/**
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeOperationStatus.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeOperationStatus.java
index 264ee1d550ef..6add764cd63c 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeOperationStatus.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeOperationStatus.java
@@ -27,7 +27,7 @@ public final class ResizeOperationStatus {
private Integer targetDedicatedNodes;
/*
- * The desired number of low priority compute nodes in the pool.
+ * The desired number of low-priority compute nodes in the pool.
*/
@JsonProperty(value = "targetLowPriorityNodes")
private Integer targetLowPriorityNodes;
@@ -81,7 +81,7 @@ public ResizeOperationStatus withTargetDedicatedNodes(Integer targetDedicatedNod
}
/**
- * Get the targetLowPriorityNodes property: The desired number of low priority compute nodes in the pool.
+ * Get the targetLowPriorityNodes property: The desired number of low-priority compute nodes in the pool.
*
* @return the targetLowPriorityNodes value.
*/
@@ -90,7 +90,7 @@ public Integer targetLowPriorityNodes() {
}
/**
- * Set the targetLowPriorityNodes property: The desired number of low priority compute nodes in the pool.
+ * Set the targetLowPriorityNodes property: The desired number of low-priority compute nodes in the pool.
*
* @param targetLowPriorityNodes the targetLowPriorityNodes value to set.
* @return the ResizeOperationStatus object itself.
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceFile.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceFile.java
index cb57ec71859d..03c915b15b46 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceFile.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceFile.java
@@ -24,25 +24,23 @@ public final class ResourceFile {
/*
* The autoStorageContainerName, storageContainerUrl and httpUrl properties
* are mutually exclusive and one of them must be specified. This URL must
- * be readable and listable using anonymous access; that is, the Batch
- * service does not present any credentials when downloading the blob.
- * There are two ways to get such a URL for a blob in Azure storage:
- * include a Shared Access Signature (SAS) granting read and list
- * permissions on the blob, or set the ACL for the blob or its container to
- * allow public access.
+ * be readable and listable from compute nodes. There are three ways to get
+ * such a URL for a container in Azure storage: include a Shared Access
+ * Signature (SAS) granting read and list permissions on the container, use
+ * a managed identity with read and list permissions, or set the ACL for
+ * the container to allow public access.
*/
@JsonProperty(value = "storageContainerUrl")
private String storageContainerUrl;
/*
* The autoStorageContainerName, storageContainerUrl and httpUrl properties
- * are mutually exclusive and one of them must be specified. If the URL is
- * Azure Blob Storage, it must be readable using anonymous access; that is,
- * the Batch service does not present any credentials when downloading the
- * blob. There are two ways to get such a URL for a blob in Azure storage:
+ * are mutually exclusive and one of them must be specified. If the URL
+ * points to Azure Blob Storage, it must be readable from compute nodes.
+ * There are three ways to get such a URL for a blob in Azure storage:
* include a Shared Access Signature (SAS) granting read permissions on the
- * blob, or set the ACL for the blob or its container to allow public
- * access.
+ * blob, use a managed identity with read permission, or set the ACL for
+ * the blob or its container to allow public access.
*/
@JsonProperty(value = "httpUrl")
private String httpUrl;
@@ -79,6 +77,13 @@ public final class ResourceFile {
@JsonProperty(value = "fileMode")
private String fileMode;
+ /*
+ * The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
+ */
+ @JsonProperty(value = "identityReference")
+ private ComputeNodeIdentityReference identityReference;
+
/**
* Get the autoStorageContainerName property: The autoStorageContainerName, storageContainerUrl and httpUrl
* properties are mutually exclusive and one of them must be specified.
@@ -103,10 +108,10 @@ public ResourceFile withAutoStorageContainerName(String autoStorageContainerName
/**
* Get the storageContainerUrl property: The autoStorageContainerName, storageContainerUrl and httpUrl properties
- * are mutually exclusive and one of them must be specified. This URL must be readable and listable using anonymous
- * access; that is, the Batch service does not present any credentials when downloading the blob. There are two ways
- * to get such a URL for a blob in Azure storage: include a Shared Access Signature (SAS) granting read and list
- * permissions on the blob, or set the ACL for the blob or its container to allow public access.
+ * are mutually exclusive and one of them must be specified. This URL must be readable and listable from compute
+ * nodes. There are three ways to get such a URL for a container in Azure storage: include a Shared Access Signature
+ * (SAS) granting read and list permissions on the container, use a managed identity with read and list permissions,
+ * or set the ACL for the container to allow public access.
*
* @return the storageContainerUrl value.
*/
@@ -116,10 +121,10 @@ public String storageContainerUrl() {
/**
* Set the storageContainerUrl property: The autoStorageContainerName, storageContainerUrl and httpUrl properties
- * are mutually exclusive and one of them must be specified. This URL must be readable and listable using anonymous
- * access; that is, the Batch service does not present any credentials when downloading the blob. There are two ways
- * to get such a URL for a blob in Azure storage: include a Shared Access Signature (SAS) granting read and list
- * permissions on the blob, or set the ACL for the blob or its container to allow public access.
+ * are mutually exclusive and one of them must be specified. This URL must be readable and listable from compute
+ * nodes. There are three ways to get such a URL for a container in Azure storage: include a Shared Access Signature
+ * (SAS) granting read and list permissions on the container, use a managed identity with read and list permissions,
+ * or set the ACL for the container to allow public access.
*
* @param storageContainerUrl the storageContainerUrl value to set.
* @return the ResourceFile object itself.
@@ -131,10 +136,10 @@ public ResourceFile withStorageContainerUrl(String storageContainerUrl) {
/**
* Get the httpUrl property: The autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually
- * exclusive and one of them must be specified. If the URL is Azure Blob Storage, it must be readable using
- * anonymous access; that is, the Batch service does not present any credentials when downloading the blob. There
- * are two ways to get such a URL for a blob in Azure storage: include a Shared Access Signature (SAS) granting read
- * permissions on the blob, or set the ACL for the blob or its container to allow public access.
+ * exclusive and one of them must be specified. If the URL points to Azure Blob Storage, it must be readable from
+ * compute nodes. There are three ways to get such a URL for a blob in Azure storage: include a Shared Access
+ * Signature (SAS) granting read permissions on the blob, use a managed identity with read permission, or set the
+ * ACL for the blob or its container to allow public access.
*
* @return the httpUrl value.
*/
@@ -144,10 +149,10 @@ public String httpUrl() {
/**
* Set the httpUrl property: The autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually
- * exclusive and one of them must be specified. If the URL is Azure Blob Storage, it must be readable using
- * anonymous access; that is, the Batch service does not present any credentials when downloading the blob. There
- * are two ways to get such a URL for a blob in Azure storage: include a Shared Access Signature (SAS) granting read
- * permissions on the blob, or set the ACL for the blob or its container to allow public access.
+ * exclusive and one of them must be specified. If the URL points to Azure Blob Storage, it must be readable from
+ * compute nodes. There are three ways to get such a URL for a blob in Azure storage: include a Shared Access
+ * Signature (SAS) granting read permissions on the blob, use a managed identity with read permission, or set the
+ * ACL for the blob or its container to allow public access.
*
* @param httpUrl the httpUrl value to set.
* @return the ResourceFile object itself.
@@ -235,11 +240,36 @@ public ResourceFile withFileMode(String fileMode) {
return this;
}
+ /**
+ * Get the identityReference property: The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
+ *
+ * @return the identityReference value.
+ */
+ public ComputeNodeIdentityReference identityReference() {
+ return this.identityReference;
+ }
+
+ /**
+ * Set the identityReference property: The reference to a user assigned identity associated with the Batch pool
+ * which a compute node will use.
+ *
+ * @param identityReference the identityReference value to set.
+ * @return the ResourceFile object itself.
+ */
+ public ResourceFile withIdentityReference(ComputeNodeIdentityReference identityReference) {
+ this.identityReference = identityReference;
+ return this;
+ }
+
/**
* Validates the instance.
*
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
+ if (identityReference() != null) {
+ identityReference().validate();
+ }
}
}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SkuCapability.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SkuCapability.java
new file mode 100644
index 000000000000..91cdd7a09a7c
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SkuCapability.java
@@ -0,0 +1,54 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** A SKU capability, such as the number of cores. */
+@Immutable
+public final class SkuCapability {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuCapability.class);
+
+ /*
+ * The name of the feature.
+ */
+ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
+ private String name;
+
+ /*
+ * The value of the feature.
+ */
+ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY)
+ private String value;
+
+ /**
+ * Get the name property: The name of the feature.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the value property: The value of the feature.
+ *
+ * @return the value value.
+ */
+ public String value() {
+ return this.value;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSku.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSku.java
new file mode 100644
index 000000000000..9991faca5b94
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSku.java
@@ -0,0 +1,39 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
+import java.util.List;
+
+/** An immutable client-side representation of SupportedSku. */
+public interface SupportedSku {
+ /**
+ * Gets the name property: The name of the SKU.
+ *
+ * @return the name value.
+ */
+ String name();
+
+ /**
+ * Gets the familyName property: The family name of the SKU.
+ *
+ * @return the familyName value.
+ */
+ String familyName();
+
+ /**
+ * Gets the capabilities property: A collection of capabilities which this SKU supports.
+ *
+ * @return the capabilities value.
+ */
+ List capabilities();
+
+ /**
+ * Gets the inner com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner object.
+ *
+ * @return the inner object.
+ */
+ SupportedSkuInner innerModel();
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSkusResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSkusResult.java
new file mode 100644
index 000000000000..404f1c7d1eda
--- /dev/null
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/SupportedSkusResult.java
@@ -0,0 +1,74 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.batch.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.batch.fluent.models.SupportedSkuInner;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** The Batch List supported SKUs operation response. */
+@Fluent
+public final class SupportedSkusResult {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(SupportedSkusResult.class);
+
+ /*
+ * The list of SKUs available for the Batch service in the location.
+ */
+ @JsonProperty(value = "value", required = true)
+ private List value;
+
+ /*
+ * The URL to use for getting the next set of results.
+ */
+ @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY)
+ private String nextLink;
+
+ /**
+ * Get the value property: The list of SKUs available for the Batch service in the location.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Set the value property: The list of SKUs available for the Batch service in the location.
+ *
+ * @param value the value value to set.
+ * @return the SupportedSkusResult object itself.
+ */
+ public SupportedSkusResult withValue(List value) {
+ this.value = value;
+ return this;
+ }
+
+ /**
+ * Get the nextLink property: The URL to use for getting the next set of results.
+ *
+ * @return the nextLink value.
+ */
+ public String nextLink() {
+ return this.nextLink;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property value in model SupportedSkusResult"));
+ } else {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentityUserAssignedIdentities.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java
similarity index 89%
rename from sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentityUserAssignedIdentities.java
rename to sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java
index cf6676e611aa..35747739612c 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchPoolIdentityUserAssignedIdentities.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java
@@ -9,10 +9,10 @@
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-/** The BatchPoolIdentityUserAssignedIdentities model. */
+/** The list of associated user identities. */
@Immutable
-public final class BatchPoolIdentityUserAssignedIdentities {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(BatchPoolIdentityUserAssignedIdentities.class);
+public final class UserAssignedIdentities {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(UserAssignedIdentities.class);
/*
* The principal id of user assigned identity.
diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineConfiguration.java
index 2f2894b471e8..936d02a5638b 100644
--- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineConfiguration.java
+++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineConfiguration.java
@@ -93,6 +93,12 @@ public final class VirtualMachineConfiguration {
@JsonProperty(value = "extensions")
private List extensions;
+ /*
+ * Contains configuration for ephemeral OSDisk settings.
+ */
+ @JsonProperty(value = "osDisk")
+ private OSDisk osDisk;
+
/**
* Get the imageReference property: A reference to an Azure Virtual Machines Marketplace image or the Azure Image
* resource of a custom Virtual Machine. To get the list of all imageReferences verified by Azure Batch, see the
@@ -311,6 +317,26 @@ public VirtualMachineConfiguration withExtensions(List extensions)
return this;
}
+ /**
+ * Get the osDisk property: Contains configuration for ephemeral OSDisk settings.
+ *
+ * @return the osDisk value.
+ */
+ public OSDisk osDisk() {
+ return this.osDisk;
+ }
+
+ /**
+ * Set the osDisk property: Contains configuration for ephemeral OSDisk settings.
+ *
+ * @param osDisk the osDisk value to set.
+ * @return the VirtualMachineConfiguration object itself.
+ */
+ public VirtualMachineConfiguration withOsDisk(OSDisk osDisk) {
+ this.osDisk = osDisk;
+ return this;
+ }
+
/**
* Validates the instance.
*
@@ -349,5 +375,8 @@ public void validate() {
if (extensions() != null) {
extensions().forEach(e -> e.validate());
}
+ if (osDisk() != null) {
+ osDisk().validate();
+ }
}
}