diff --git a/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md b/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md index 3481ce371a42..b82d93ec5d47 100644 --- a/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md +++ b/sdk/batch/azure-resourcemanager-batch/CHANGELOG.md @@ -1,6 +1,8 @@ # Release History -## 1.1.0-beta.1 (Unreleased) +## 1.0.0-beta.1 (2022-10-25) + +- Azure Resource Manager Batch client library for Java. This package contains Microsoft Azure SDK for Batch Management SDK. Batch Client. Package tag package-2022-10. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ### Features Added diff --git a/sdk/batch/azure-resourcemanager-batch/README.md b/sdk/batch/azure-resourcemanager-batch/README.md index e99e92b99215..adef79a7232e 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. Batch Client. Package tag package-2022-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. Batch Client. Package tag package-2022-10. 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 + 1.1.0-beta.1 ``` [//]: # ({x-version-update-end}) diff --git a/sdk/batch/azure-resourcemanager-batch/SAMPLE.md b/sdk/batch/azure-resourcemanager-batch/SAMPLE.md index 6f4b3dc2ba0d..943d1885f568 100644 --- a/sdk/batch/azure-resourcemanager-batch/SAMPLE.md +++ b/sdk/batch/azure-resourcemanager-batch/SAMPLE.md @@ -64,6 +64,7 @@ ## PrivateEndpointConnection +- [Delete](#privateendpointconnection_delete) - [Get](#privateendpointconnection_get) - [ListByBatchAccount](#privateendpointconnection_listbybatchaccount) - [Update](#privateendpointconnection_update) @@ -78,7 +79,7 @@ /** Samples for Application Create. */ public final class ApplicationCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationCreate.json */ /** * Sample code: ApplicationCreate. @@ -105,7 +106,7 @@ import com.azure.core.util.Context; /** Samples for Application Delete. */ public final class ApplicationDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationDelete.json */ /** * Sample code: ApplicationDelete. @@ -126,7 +127,7 @@ import com.azure.core.util.Context; /** Samples for Application Get. */ public final class ApplicationGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationGet.json */ /** * Sample code: ApplicationGet. @@ -147,7 +148,7 @@ import com.azure.core.util.Context; /** Samples for Application List. */ public final class ApplicationListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationList.json */ /** * Sample code: ApplicationList. @@ -169,7 +170,7 @@ import com.azure.resourcemanager.batch.models.Application; /** Samples for Application Update. */ public final class ApplicationUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationUpdate.json */ /** * Sample code: ApplicationUpdate. @@ -196,7 +197,7 @@ import com.azure.resourcemanager.batch.models.ActivateApplicationPackageParamete /** Samples for ApplicationPackage Activate. */ public final class ApplicationPackageActivateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageActivate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageActivate.json */ /** * Sample code: ApplicationPackageActivate. @@ -223,7 +224,7 @@ public final class ApplicationPackageActivateSamples { /** Samples for ApplicationPackage Create. */ public final class ApplicationPackageCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageCreate.json */ /** * Sample code: ApplicationPackageCreate. @@ -248,7 +249,7 @@ import com.azure.core.util.Context; /** Samples for ApplicationPackage Delete. */ public final class ApplicationPackageDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageDelete.json */ /** * Sample code: ApplicationPackageDelete. @@ -271,7 +272,7 @@ import com.azure.core.util.Context; /** Samples for ApplicationPackage Get. */ public final class ApplicationPackageGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageGet.json */ /** * Sample code: ApplicationPackageGet. @@ -294,7 +295,7 @@ import com.azure.core.util.Context; /** Samples for ApplicationPackage List. */ public final class ApplicationPackageListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageList.json */ /** * Sample code: ApplicationPackageList. @@ -323,7 +324,7 @@ import java.util.Map; /** Samples for BatchAccount Create. */ public final class BatchAccountCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_BYOS.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_BYOS.json */ /** * Sample code: BatchAccountCreate_BYOS. @@ -350,7 +351,7 @@ public final class BatchAccountCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_UserAssignedIdentity.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_UserAssignedIdentity.json */ /** * Sample code: BatchAccountCreate_UserAssignedIdentity. @@ -378,7 +379,7 @@ public final class BatchAccountCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateBatchAccountCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateBatchAccountCreate.json */ /** * Sample code: PrivateBatchAccountCreate. @@ -405,7 +406,7 @@ public final class BatchAccountCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_SystemAssignedIdentity.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_SystemAssignedIdentity.json */ /** * Sample code: BatchAccountCreate_SystemAssignedIdentity. @@ -427,7 +428,7 @@ public final class BatchAccountCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_Default.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_Default.json */ /** * Sample code: BatchAccountCreate_Default. @@ -468,7 +469,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount Delete. */ public final class BatchAccountDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountDelete.json */ /** * Sample code: BatchAccountDelete. @@ -489,7 +490,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount GetByResourceGroup. */ public final class BatchAccountGetByResourceGroupSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateBatchAccountGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateBatchAccountGet.json */ /** * Sample code: PrivateBatchAccountGet. @@ -503,7 +504,7 @@ public final class BatchAccountGetByResourceGroupSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountGet.json */ /** * Sample code: BatchAccountGet. @@ -526,7 +527,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount GetDetector. */ public final class BatchAccountGetDetectorSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/DetectorGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/DetectorGet.json */ /** * Sample code: GetDetector. @@ -549,7 +550,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount GetKeys. */ public final class BatchAccountGetKeysSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountGetKeys.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountGetKeys.json */ /** * Sample code: BatchAccountGetKeys. @@ -570,7 +571,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount List. */ public final class BatchAccountListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountList.json */ /** * Sample code: BatchAccountList. @@ -591,7 +592,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount ListByResourceGroup. */ public final class BatchAccountListByResourceGroupSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountListByResourceGroup.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountListByResourceGroup.json */ /** * Sample code: BatchAccountListByResourceGroup. @@ -612,7 +613,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount ListDetectors. */ public final class BatchAccountListDetectorsSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/DetectorList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/DetectorList.json */ /** * Sample code: ListDetectors. @@ -633,7 +634,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount ListOutboundNetworkDependenciesEndpoints. */ public final class BatchAccountListOutboundNetworkDependenciesEndpointsSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountListOutboundNetworkDependenciesEndpoints.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountListOutboundNetworkDependenciesEndpoints.json */ /** * Sample code: ListOutboundNetworkDependencies. @@ -658,7 +659,7 @@ import com.azure.resourcemanager.batch.models.BatchAccountRegenerateKeyParameter /** Samples for BatchAccount RegenerateKey. */ public final class BatchAccountRegenerateKeySamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountRegenerateKey.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountRegenerateKey.json */ /** * Sample code: BatchAccountRegenerateKey. @@ -685,7 +686,7 @@ import com.azure.core.util.Context; /** Samples for BatchAccount SynchronizeAutoStorageKeys. */ public final class BatchAccountSynchronizeAutoStorageKeysSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountSynchronizeAutoStorageKeys.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountSynchronizeAutoStorageKeys.json */ /** * Sample code: BatchAccountSynchronizeAutoStorageKeys. @@ -710,7 +711,7 @@ import com.azure.resourcemanager.batch.models.BatchAccount; /** Samples for BatchAccount Update. */ public final class BatchAccountUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountUpdate.json */ /** * Sample code: BatchAccountUpdate. @@ -742,7 +743,7 @@ import com.azure.core.util.Context; /** Samples for Certificate CancelDeletion. */ public final class CertificateCancelDeletionSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCancelDeletion.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCancelDeletion.json */ /** * Sample code: CertificateCancelDeletion. @@ -769,7 +770,7 @@ import com.azure.resourcemanager.batch.models.CertificateFormat; /** Samples for Certificate Create. */ public final class CertificateCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_Full.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_Full.json */ /** * Sample code: CreateCertificate - Full. @@ -781,7 +782,6 @@ public final class CertificateCreateSamples { .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIIJsgIBAzCCCW4GCSqGSIb3DQE...") .withPassword("") .withThumbprintAlgorithm("sha1") .withThumbprint("0a0e4f50d51beadeac1d35afc5116098e7902e6e") @@ -790,7 +790,7 @@ public final class CertificateCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_Minimal.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_Minimal.json */ /** * Sample code: CreateCertificate - Minimal Pfx. @@ -802,13 +802,12 @@ public final class CertificateCreateSamples { .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIIJsgIBAzCCCW4GCSqGSIb3DQE...") .withPassword("") .create(); } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_MinimalCer.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_MinimalCer.json */ /** * Sample code: CreateCertificate - Minimal Cer. @@ -820,7 +819,6 @@ public final class CertificateCreateSamples { .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIICrjCCAZagAwI...") .withFormat(CertificateFormat.CER) .create(); } @@ -835,7 +833,7 @@ import com.azure.core.util.Context; /** Samples for Certificate Delete. */ public final class CertificateDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateDelete.json */ /** * Sample code: CertificateDelete. @@ -862,7 +860,7 @@ import com.azure.core.util.Context; /** Samples for Certificate Get. */ public final class CertificateGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateGetWithDeletionError.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateGetWithDeletionError.json */ /** * Sample code: Get Certificate with Deletion Error. @@ -880,7 +878,7 @@ public final class CertificateGetSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateGet.json */ /** * Sample code: Get Certificate. @@ -907,7 +905,7 @@ import com.azure.core.util.Context; /** Samples for Certificate ListByBatchAccount. */ public final class CertificateListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateListWithFilter.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateListWithFilter.json */ /** * Sample code: ListCertificates - Filter and Select. @@ -928,7 +926,7 @@ public final class CertificateListByBatchAccountSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateList.json */ /** * Sample code: ListCertificates. @@ -952,7 +950,7 @@ import com.azure.resourcemanager.batch.models.Certificate; /** Samples for Certificate Update. */ public final class CertificateUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateUpdate.json */ /** * Sample code: UpdateCertificate. @@ -983,7 +981,7 @@ import com.azure.resourcemanager.batch.models.CheckNameAvailabilityParameters; /** Samples for Location CheckNameAvailability. */ public final class LocationCheckNameAvailabilitySamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationCheckNameAvailability_AlreadyExists.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationCheckNameAvailability_AlreadyExists.json */ /** * Sample code: LocationCheckNameAvailability_AlreadyExists. @@ -999,7 +997,7 @@ public final class LocationCheckNameAvailabilitySamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationCheckNameAvailability_Available.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationCheckNameAvailability_Available.json */ /** * Sample code: LocationCheckNameAvailability_Available. @@ -1023,7 +1021,7 @@ import com.azure.core.util.Context; /** Samples for Location GetQuotas. */ public final class LocationGetQuotasSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationGetQuotas.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationGetQuotas.json */ /** * Sample code: LocationGetQuotas. @@ -1044,7 +1042,7 @@ import com.azure.core.util.Context; /** Samples for Location ListSupportedCloudServiceSkus. */ public final class LocationListSupportedCloudServiceSkusSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationListCloudServiceSkus.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationListCloudServiceSkus.json */ /** * Sample code: LocationListCloudServiceSkus. @@ -1065,7 +1063,7 @@ import com.azure.core.util.Context; /** Samples for Location ListSupportedVirtualMachineSkus. */ public final class LocationListSupportedVirtualMachineSkusSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationListVirtualMachineSkus.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationListVirtualMachineSkus.json */ /** * Sample code: LocationListVirtualMachineSkus. @@ -1086,7 +1084,7 @@ import com.azure.core.util.Context; /** Samples for Operations List. */ public final class OperationsListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/OperationsList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/OperationsList.json */ /** * Sample code: OperationsList. @@ -1135,6 +1133,7 @@ import com.azure.resourcemanager.batch.models.MetadataItem; import com.azure.resourcemanager.batch.models.NetworkConfiguration; import com.azure.resourcemanager.batch.models.NetworkSecurityGroupRule; import com.azure.resourcemanager.batch.models.NetworkSecurityGroupRuleAccess; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.NodePlacementConfiguration; import com.azure.resourcemanager.batch.models.NodePlacementPolicyType; import com.azure.resourcemanager.batch.models.OSDisk; @@ -1161,7 +1160,7 @@ import java.util.Map; /** Samples for Pool Create. */ public final class PoolCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_SharedImageGallery.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_SharedImageGallery.json */ /** * Sample code: CreatePool - Custom Image. @@ -1187,7 +1186,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_CloudServiceConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_CloudServiceConfiguration.json */ /** * Sample code: CreatePool - Full CloudServiceConfiguration. @@ -1286,7 +1285,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_MinimalCloudServiceConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_MinimalCloudServiceConfiguration.json */ /** * Sample code: CreatePool - Minimal CloudServiceConfiguration. @@ -1308,7 +1307,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_MinimalVirtualMachineConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_MinimalVirtualMachineConfiguration.json */ /** * Sample code: CreatePool - Minimal VirtualMachineConfiguration. @@ -1343,7 +1342,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_NoPublicIPAddresses.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_NoPublicIPAddresses.json */ /** * Sample code: CreatePool - No public IP. @@ -1376,7 +1375,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_VirtualMachineConfiguration_Extensions.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_VirtualMachineConfiguration_Extensions.json */ /** * Sample code: CreatePool - VirtualMachineConfiguration Extensions. @@ -1429,11 +1428,12 @@ public final class PoolCreateSamples { new AutoScaleSettings() .withFormula("$TargetDedicatedNodes=1") .withEvaluationInterval(Duration.parse("PT5M")))) + .withTargetNodeCommunicationMode(NodeCommunicationMode.DEFAULT) .create(); } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_UserAssignedIdentities.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_UserAssignedIdentities.json */ /** * Sample code: CreatePool - UserAssignedIdentities. @@ -1476,7 +1476,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_PublicIPs.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_PublicIPs.json */ /** * Sample code: CreatePool - Public IPs. @@ -1513,7 +1513,7 @@ public final class PoolCreateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_VirtualMachineConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_VirtualMachineConfiguration.json */ /** * Sample code: CreatePool - Full VirtualMachineConfiguration. @@ -1619,7 +1619,7 @@ import com.azure.core.util.Context; /** Samples for Pool Delete. */ public final class PoolDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolDelete.json */ /** * Sample code: DeletePool. @@ -1640,7 +1640,7 @@ import com.azure.core.util.Context; /** Samples for Pool DisableAutoScale. */ public final class PoolDisableAutoScaleSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolDisableAutoScale.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolDisableAutoScale.json */ /** * Sample code: Disable AutoScale. @@ -1663,7 +1663,7 @@ import com.azure.core.util.Context; /** Samples for Pool Get. */ public final class PoolGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolGet_VirtualMachineConfiguration_Extensions.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolGet_VirtualMachineConfiguration_Extensions.json */ /** * Sample code: GetPool - VirtualMachineConfiguration Extensions. @@ -1676,7 +1676,7 @@ public final class PoolGetSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolGet.json */ /** * Sample code: GetPool. @@ -1697,7 +1697,7 @@ import com.azure.core.util.Context; /** Samples for Pool ListByBatchAccount. */ public final class PoolListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolList.json */ /** * Sample code: ListPool. @@ -1711,7 +1711,7 @@ public final class PoolListByBatchAccountSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolListWithFilter.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolListWithFilter.json */ /** * Sample code: ListPoolWithFilter. @@ -1741,7 +1741,7 @@ import com.azure.core.util.Context; /** Samples for Pool StopResize. */ public final class PoolStopResizeSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolStopResize.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolStopResize.json */ /** * Sample code: StopPoolResize. @@ -1765,6 +1765,7 @@ import com.azure.resourcemanager.batch.models.CertificateStoreLocation; import com.azure.resourcemanager.batch.models.ComputeNodeDeallocationOption; import com.azure.resourcemanager.batch.models.FixedScaleSettings; import com.azure.resourcemanager.batch.models.MetadataItem; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.Pool; import com.azure.resourcemanager.batch.models.ScaleSettings; import com.azure.resourcemanager.batch.models.StartTask; @@ -1774,7 +1775,7 @@ import java.util.Arrays; /** Samples for Pool Update. */ public final class PoolUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_EnableAutoScale.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_EnableAutoScale.json */ /** * Sample code: UpdatePool - Enable Autoscale. @@ -1795,7 +1796,7 @@ public final class PoolUpdateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_RemoveStartTask.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_RemoveStartTask.json */ /** * Sample code: UpdatePool - Remove Start Task. @@ -1812,7 +1813,7 @@ public final class PoolUpdateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_ResizePool.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_ResizePool.json */ /** * Sample code: UpdatePool - Resize Pool. @@ -1839,7 +1840,7 @@ public final class PoolUpdateSamples { } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_OtherProperties.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_OtherProperties.json */ /** * Sample code: UpdatePool - Other Properties. @@ -1873,11 +1874,39 @@ public final class PoolUpdateSamples { .withId( "/subscriptions/subid/resourceGroups/default-azurebatch-japaneast/providers/Microsoft.Batch/batchAccounts/sampleacct/pools/testpool/applications/app_5678") .withVersion("1.0"))) + .withTargetNodeCommunicationMode(NodeCommunicationMode.SIMPLIFIED) .apply(); } } ``` +### PrivateEndpointConnection_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnection Delete. */ +public final class PrivateEndpointConnectionDeleteSamples { + /* + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionDelete.json + */ + /** + * Sample code: PrivateEndpointConnectionDelete. + * + * @param manager Entry point to BatchManager. + */ + public static void privateEndpointConnectionDelete(com.azure.resourcemanager.batch.BatchManager manager) { + manager + .privateEndpointConnections() + .delete( + "default-azurebatch-japaneast", + "sampleacct", + "testprivateEndpointConnection5testprivateEndpointConnection5.24d6b4b5-e65c-4330-bbe9-3a290d62f8e0", + Context.NONE); + } +} +``` + ### PrivateEndpointConnection_Get ```java @@ -1886,7 +1915,7 @@ import com.azure.core.util.Context; /** Samples for PrivateEndpointConnection Get. */ public final class PrivateEndpointConnectionGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionGet.json */ /** * Sample code: GetPrivateEndpointConnection. @@ -1913,7 +1942,7 @@ import com.azure.core.util.Context; /** Samples for PrivateEndpointConnection ListByBatchAccount. */ public final class PrivateEndpointConnectionListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionsList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionsList.json */ /** * Sample code: ListPrivateEndpointConnections. @@ -1939,7 +1968,7 @@ import com.azure.resourcemanager.batch.models.PrivateLinkServiceConnectionStatus /** Samples for PrivateEndpointConnection Update. */ public final class PrivateEndpointConnectionUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionUpdate.json */ /** * Sample code: UpdatePrivateEndpointConnection. @@ -1972,7 +2001,7 @@ import com.azure.core.util.Context; /** Samples for PrivateLinkResource Get. */ public final class PrivateLinkResourceGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateLinkResourceGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateLinkResourceGet.json */ /** * Sample code: GetPrivateLinkResource. @@ -1982,7 +2011,7 @@ public final class PrivateLinkResourceGetSamples { public static void getPrivateLinkResource(com.azure.resourcemanager.batch.BatchManager manager) { manager .privateLinkResources() - .getWithResponse("default-azurebatch-japaneast", "sampleacct", "sampleacct", Context.NONE); + .getWithResponse("default-azurebatch-japaneast", "sampleacct", "batchAccount", Context.NONE); } } ``` @@ -1995,7 +2024,7 @@ import com.azure.core.util.Context; /** Samples for PrivateLinkResource ListByBatchAccount. */ public final class PrivateLinkResourceListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateLinkResourcesList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateLinkResourcesList.json */ /** * Sample code: ListPrivateLinkResource. diff --git a/sdk/batch/azure-resourcemanager-batch/pom.xml b/sdk/batch/azure-resourcemanager-batch/pom.xml index 3d6544049953..ac57b32b7bc8 100644 --- a/sdk/batch/azure-resourcemanager-batch/pom.xml +++ b/sdk/batch/azure-resourcemanager-batch/pom.xml @@ -13,7 +13,7 @@ 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. Batch Client. Package tag package-2022-01. + 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. Batch Client. Package tag package-2022-10. https://github.com/Azure/azure-sdk-for-java 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 80a36a13b5b5..fbce220efc6e 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 @@ -10,11 +10,13 @@ import com.azure.core.http.HttpPipelineBuilder; import com.azure.core.http.HttpPipelinePosition; import com.azure.core.http.policy.AddDatePolicy; +import com.azure.core.http.policy.AddHeadersFromContextPolicy; import com.azure.core.http.policy.HttpLogOptions; import com.azure.core.http.policy.HttpLoggingPolicy; import com.azure.core.http.policy.HttpPipelinePolicy; import com.azure.core.http.policy.HttpPolicyProviders; import com.azure.core.http.policy.RequestIdPolicy; +import com.azure.core.http.policy.RetryOptions; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy; @@ -95,6 +97,19 @@ public static BatchManager authenticate(TokenCredential credential, AzureProfile return configure().authenticate(credential, profile); } + /** + * Creates an instance of Batch service API entry point. + * + * @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential. + * @param profile the Azure profile for client. + * @return the Batch service API instance. + */ + public static BatchManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) { + Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null."); + Objects.requireNonNull(profile, "'profile' cannot be null."); + return new BatchManager(httpPipeline, profile, null); + } + /** * Gets a Configurable instance that can be used to create BatchManager with optional configuration. * @@ -113,6 +128,7 @@ public static final class Configurable { private final List policies = new ArrayList<>(); private final List scopes = new ArrayList<>(); private RetryPolicy retryPolicy; + private RetryOptions retryOptions; private Duration defaultPollInterval; private Configurable() { @@ -173,6 +189,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) { return this; } + /** + * Sets the retry options for the HTTP pipeline retry policy. + * + *

This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}. + * + * @param retryOptions the retry options for the HTTP pipeline retry policy. + * @return the configurable object itself. + */ + public Configurable withRetryOptions(RetryOptions retryOptions) { + this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null."); + return this; + } + /** * Sets the default poll interval, used when service does not provide "Retry-After" header. * @@ -206,7 +235,7 @@ public BatchManager authenticate(TokenCredential credential, AzureProfile profil .append("-") .append("com.azure.resourcemanager.batch") .append("/") - .append("1.0.0-beta.3"); + .append("1.0.0-beta.1"); if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) { userAgentBuilder .append(" (") @@ -224,10 +253,15 @@ public BatchManager authenticate(TokenCredential credential, AzureProfile profil scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default"); } if (retryPolicy == null) { - retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + if (retryOptions != null) { + retryPolicy = new RetryPolicy(retryOptions); + } else { + retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + } } List policies = new ArrayList<>(); policies.add(new UserAgentPolicy(userAgentBuilder.toString())); + policies.add(new AddHeadersFromContextPolicy()); policies.add(new RequestIdPolicy()); policies .addAll( @@ -258,7 +292,11 @@ public BatchManager authenticate(TokenCredential credential, AzureProfile profil } } - /** @return Resource collection API of BatchAccounts. */ + /** + * Gets the resource collection API of BatchAccounts. It manages BatchAccount. + * + * @return Resource collection API of BatchAccounts. + */ public BatchAccounts batchAccounts() { if (this.batchAccounts == null) { this.batchAccounts = new BatchAccountsImpl(clientObject.getBatchAccounts(), this); @@ -266,7 +304,11 @@ public BatchAccounts batchAccounts() { return batchAccounts; } - /** @return Resource collection API of ApplicationPackages. */ + /** + * Gets the resource collection API of ApplicationPackages. It manages ApplicationPackage. + * + * @return Resource collection API of ApplicationPackages. + */ public ApplicationPackages applicationPackages() { if (this.applicationPackages == null) { this.applicationPackages = new ApplicationPackagesImpl(clientObject.getApplicationPackages(), this); @@ -274,7 +316,11 @@ public ApplicationPackages applicationPackages() { return applicationPackages; } - /** @return Resource collection API of Applications. */ + /** + * Gets the resource collection API of Applications. It manages Application. + * + * @return Resource collection API of Applications. + */ public Applications applications() { if (this.applications == null) { this.applications = new ApplicationsImpl(clientObject.getApplications(), this); @@ -282,7 +328,11 @@ public Applications applications() { return applications; } - /** @return Resource collection API of Locations. */ + /** + * Gets the resource collection API of Locations. + * + * @return Resource collection API of Locations. + */ public Locations locations() { if (this.locations == null) { this.locations = new LocationsImpl(clientObject.getLocations(), this); @@ -290,7 +340,11 @@ public Locations locations() { return locations; } - /** @return Resource collection API of Operations. */ + /** + * Gets the resource collection API of Operations. + * + * @return Resource collection API of Operations. + */ public Operations operations() { if (this.operations == null) { this.operations = new OperationsImpl(clientObject.getOperations(), this); @@ -298,7 +352,11 @@ public Operations operations() { return operations; } - /** @return Resource collection API of Certificates. */ + /** + * Gets the resource collection API of Certificates. It manages Certificate. + * + * @return Resource collection API of Certificates. + */ public Certificates certificates() { if (this.certificates == null) { this.certificates = new CertificatesImpl(clientObject.getCertificates(), this); @@ -306,7 +364,11 @@ public Certificates certificates() { return certificates; } - /** @return Resource collection API of PrivateLinkResources. */ + /** + * Gets the resource collection API of PrivateLinkResources. + * + * @return Resource collection API of PrivateLinkResources. + */ public PrivateLinkResources privateLinkResources() { if (this.privateLinkResources == null) { this.privateLinkResources = new PrivateLinkResourcesImpl(clientObject.getPrivateLinkResources(), this); @@ -314,7 +376,11 @@ public PrivateLinkResources privateLinkResources() { return privateLinkResources; } - /** @return Resource collection API of PrivateEndpointConnections. */ + /** + * Gets the resource collection API of PrivateEndpointConnections. + * + * @return Resource collection API of PrivateEndpointConnections. + */ public PrivateEndpointConnections privateEndpointConnections() { if (this.privateEndpointConnections == null) { this.privateEndpointConnections = @@ -323,7 +389,11 @@ public PrivateEndpointConnections privateEndpointConnections() { return privateEndpointConnections; } - /** @return Resource collection API of Pools. */ + /** + * Gets the resource collection API of Pools. It manages Pool. + * + * @return Resource collection API of Pools. + */ public Pools pools() { if (this.pools == null) { this.pools = new PoolsImpl(clientObject.getPools(), this); 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 e84150a8e15a..360ee5838799 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 @@ -14,28 +14,6 @@ /** An instance of this class provides access to all the operations defined in ApplicationPackagesClient. */ public interface ApplicationPackagesClient { - /** - * Activates the specified application package. This should be done after the `ApplicationPackage` was created and - * uploaded. This needs to be done before an `ApplicationPackage` can be used on Pools or Tasks. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param applicationName The name of the application. This must be unique within the account. - * @param versionName The version of the application. - * @param parameters The parameters for the request. - * @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 an application package which represents a particular version of an application. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationPackageInner activate( - String resourceGroupName, - String accountName, - String applicationName, - String versionName, - ActivateApplicationPackageParameters parameters); - /** * Activates the specified application package. This should be done after the `ApplicationPackage` was created and * uploaded. This needs to be done before an `ApplicationPackage` can be used on Pools or Tasks. @@ -62,22 +40,26 @@ Response activateWithResponse( Context context); /** - * 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. + * Activates the specified application package. This should be done after the `ApplicationPackage` was created and + * uploaded. This needs to be done before an `ApplicationPackage` can be used on Pools or Tasks. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @param parameters The parameters for the request. * @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 an application package which represents a particular version of an application. */ @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationPackageInner create( - String resourceGroupName, String accountName, String applicationName, String versionName); + ApplicationPackageInner activate( + String resourceGroupName, + String accountName, + String applicationName, + String versionName, + ActivateApplicationPackageParameters parameters); /** * Creates an application package record. The record contains a storageUrl where the package should be uploaded to. @@ -106,7 +88,9 @@ Response createWithResponse( Context context); /** - * Deletes an application package record and its associated binary file. + * 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. @@ -115,9 +99,11 @@ Response createWithResponse( * @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 an application package which represents a particular version of an application. */ @ServiceMethod(returns = ReturnType.SINGLE) - void delete(String resourceGroupName, String accountName, String applicationName, String versionName); + ApplicationPackageInner create( + String resourceGroupName, String accountName, String applicationName, String versionName); /** * Deletes an application package record and its associated binary file. @@ -137,7 +123,7 @@ Response deleteWithResponse( String resourceGroupName, String accountName, String applicationName, String versionName, Context context); /** - * Gets information about the specified application package. + * Deletes an application package record and its associated binary file. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. @@ -146,11 +132,9 @@ Response deleteWithResponse( * @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 information about the specified application package. */ @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationPackageInner get( - String resourceGroupName, String accountName, String applicationName, String versionName); + void delete(String resourceGroupName, String accountName, String applicationName, String versionName); /** * Gets information about the specified application package. @@ -169,6 +153,22 @@ ApplicationPackageInner get( Response getWithResponse( String resourceGroupName, String accountName, String applicationName, String versionName, Context context); + /** + * Gets information about the specified application package. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param applicationName The name of the application. This must be unique within the account. + * @param versionName The version of the application. + * @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 information about the specified application package. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + ApplicationPackageInner get( + String resourceGroupName, String accountName, String applicationName, String versionName); + /** * Lists all of the application packages in the specified application. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationsClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationsClient.java index 3c46b10f2caf..a60c84f5eafc 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationsClient.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/ApplicationsClient.java @@ -13,20 +13,6 @@ /** An instance of this class provides access to all the operations defined in ApplicationsClient. */ public interface ApplicationsClient { - /** - * Adds an application to the specified Batch account. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param applicationName The name of the application. This must be unique within the 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 contains information about an application in a Batch account. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationInner create(String resourceGroupName, String accountName, String applicationName); - /** * Adds an application to the specified Batch account. * @@ -49,7 +35,7 @@ Response createWithResponse( Context context); /** - * Deletes an application. + * Adds an application to the specified Batch account. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. @@ -57,9 +43,10 @@ Response createWithResponse( * @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 contains information about an application in a Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - void delete(String resourceGroupName, String accountName, String applicationName); + ApplicationInner create(String resourceGroupName, String accountName, String applicationName); /** * Deletes an application. @@ -78,7 +65,7 @@ Response deleteWithResponse( String resourceGroupName, String accountName, String applicationName, Context context); /** - * Gets information about the specified application. + * Deletes an application. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. @@ -86,10 +73,9 @@ Response deleteWithResponse( * @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 information about the specified application. */ @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationInner get(String resourceGroupName, String accountName, String applicationName); + void delete(String resourceGroupName, String accountName, String applicationName); /** * Gets information about the specified application. @@ -108,20 +94,18 @@ Response getWithResponse( String resourceGroupName, String accountName, String applicationName, Context context); /** - * Updates settings for the specified application. + * Gets information about the specified application. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. - * @param parameters The parameters for the request. * @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 contains information about an application in a Batch account. + * @return information about the specified application. */ @ServiceMethod(returns = ReturnType.SINGLE) - ApplicationInner update( - String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters); + ApplicationInner get(String resourceGroupName, String accountName, String applicationName); /** * Updates settings for the specified application. @@ -144,6 +128,22 @@ Response updateWithResponse( ApplicationInner parameters, Context context); + /** + * Updates settings for the specified application. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param applicationName The name of the application. This must be unique within the account. + * @param parameters The parameters for the request. + * @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 contains information about an application in a Batch account. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + ApplicationInner update( + String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters); + /** * Lists all of the applications in the specified 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 1b93fc0fbd75..c4dcc953b7bb 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 @@ -104,13 +104,15 @@ BatchAccountInner create( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters Additional parameters for account update. + * @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 contains information about an Azure Batch account. + * @return contains information about an Azure Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - BatchAccountInner update(String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters); + Response updateWithResponse( + String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters, Context context); /** * Updates the properties of an existing Batch account. @@ -118,15 +120,13 @@ BatchAccountInner create( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters Additional parameters for account update. - * @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 contains information about an Azure Batch account along with {@link Response}. + * @return contains information about an Azure Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response updateWithResponse( - String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters, Context context); + BatchAccountInner update(String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters); /** * Deletes the specified Batch account. @@ -185,28 +185,28 @@ Response updateWithResponse( * * @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 information about the specified Batch account. + * @return information about the specified Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - BatchAccountInner getByResourceGroup(String resourceGroupName, String accountName); + Response getByResourceGroupWithResponse( + String resourceGroupName, String accountName, Context context); /** * Gets information about the specified Batch account. * * @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 information about the specified Batch account along with {@link Response}. + * @return information about the specified Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getByResourceGroupWithResponse( - String resourceGroupName, String accountName, Context context); + BatchAccountInner getByResourceGroup(String resourceGroupName, String accountName); /** * Gets information about the Batch accounts associated with the subscription. @@ -265,12 +265,15 @@ Response getByResourceGroupWithResponse( * * @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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - void synchronizeAutoStorageKeys(String resourceGroupName, String accountName); + Response synchronizeAutoStorageKeysWithResponse( + String resourceGroupName, String accountName, Context context); /** * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage @@ -278,18 +281,17 @@ Response getByResourceGroupWithResponse( * * @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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response synchronizeAutoStorageKeysWithResponse( - String resourceGroupName, String accountName, Context context); + void synchronizeAutoStorageKeys(String resourceGroupName, String accountName); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -297,17 +299,20 @@ Response synchronizeAutoStorageKeysWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - BatchAccountKeysInner regenerateKey( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters); + Response regenerateKeyWithResponse( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -315,46 +320,49 @@ BatchAccountKeysInner regenerateKey( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response regenerateKeyWithResponse( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context); + BatchAccountKeysInner regenerateKey( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - BatchAccountKeysInner getKeys(String resourceGroupName, String accountName); + Response getKeysWithResponse(String resourceGroupName, String accountName, Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getKeysWithResponse(String resourceGroupName, String accountName, Context context); + BatchAccountKeysInner getKeys(String resourceGroupName, String accountName); /** * Gets information about the detectors available for a given Batch account. @@ -391,13 +399,15 @@ Response regenerateKeyWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. + * @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 information about the given detector for a given Batch account. + * @return information about the given detector for a given Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - DetectorResponseInner getDetector(String resourceGroupName, String accountName, String detectorId); + Response getDetectorWithResponse( + String resourceGroupName, String accountName, String detectorId, Context context); /** * Gets information about the given detector for a given Batch account. @@ -405,15 +415,13 @@ Response regenerateKeyWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. - * @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 information about the given detector for a given Batch account along with {@link Response}. + * @return information about the given detector for a given Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getDetectorWithResponse( - String resourceGroupName, String accountName, String detectorId, Context context); + DetectorResponseInner getDetector(String resourceGroupName, String accountName, String detectorId); /** * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/CertificatesClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/CertificatesClient.java index 744baa622a1f..d121e71133c1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/CertificatesClient.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/CertificatesClient.java @@ -22,6 +22,9 @@ public interface CertificatesClient { /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @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. @@ -35,6 +38,9 @@ public interface CertificatesClient { /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -60,99 +66,114 @@ PagedIterable listByBatchAccount( /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Additional parameters for certificate creation. + * @param ifMatch The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply + * the operation only if the certificate already exists. If omitted, this operation will always be applied. + * @param ifNoneMatch Set to '*' to allow a new certificate to be created, but to prevent updating an existing + * certificate. Other values will be ignored. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificateInner create( + CertificatesCreateResponse createWithResponse( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters); + CertificateCreateOrUpdateParameters parameters, + String ifMatch, + String ifNoneMatch, + Context context); /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Additional parameters for certificate creation. - * @param ifMatch The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply - * the operation only if the certificate already exists. If omitted, this operation will always be applied. - * @param ifNoneMatch Set to '*' to allow a new certificate to be created, but to prevent updating an existing - * certificate. Other values will be ignored. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificatesCreateResponse createWithResponse( + CertificateInner create( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch, - String ifNoneMatch, - Context context); + CertificateCreateOrUpdateParameters parameters); /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Certificate entity to update. + * @param ifMatch The entity state (ETag) version of the certificate to update. This value can be omitted or set to + * "*" to apply the operation unconditionally. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificateInner update( + CertificatesUpdateResponse updateWithResponse( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters); + CertificateCreateOrUpdateParameters parameters, + String ifMatch, + Context context); /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Certificate entity to update. - * @param ifMatch The entity state (ETag) version of the certificate to update. This value can be omitted or set to - * "*" to apply the operation unconditionally. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificatesUpdateResponse updateWithResponse( + CertificateInner update( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch, - Context context); + CertificateCreateOrUpdateParameters parameters); /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -169,6 +190,9 @@ SyncPoller, Void> beginDelete( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -186,6 +210,9 @@ SyncPoller, Void> beginDelete( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -200,6 +227,9 @@ SyncPoller, Void> beginDelete( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -215,72 +245,88 @@ SyncPoller, Void> beginDelete( /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 information about the specified certificate. + * @return contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificateInner get(String resourceGroupName, String accountName, String certificateName); + CertificatesGetResponse getWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context); /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 information about the specified certificate. + * @return contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificatesGetResponse getWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context); + CertificateInner get(String resourceGroupName, String accountName, String certificateName); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificateInner cancelDeletion(String resourceGroupName, String accountName, String certificateName); + CertificatesCancelDeletionResponse cancelDeletionWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - CertificatesCancelDeletionResponse cancelDeletionWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context); + CertificateInner cancelDeletion(String resourceGroupName, String accountName, String certificateName); } 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 763ccd23e0a1..9fe7d1c18880 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 @@ -20,27 +20,27 @@ public interface LocationsClient { * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. + * @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 Batch service quotas for the specified subscription at the given location. + * @return the Batch service quotas for the specified subscription at the given location along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - BatchLocationQuotaInner getQuotas(String locationName); + Response getQuotasWithResponse(String locationName, Context context); /** * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. - * @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 Batch service quotas for the specified subscription at the given location along with {@link - * Response}. + * @return the Batch service quotas for the specified subscription at the given location. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getQuotasWithResponse(String locationName, Context context); + BatchLocationQuotaInner getQuotas(String locationName); /** * Gets the list of Batch supported Virtual Machine VM sizes available at the given location. @@ -107,27 +107,27 @@ PagedIterable listSupportedCloudServiceSkus( * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. + * @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 CheckNameAvailability operation response. + * @return the CheckNameAvailability operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - CheckNameAvailabilityResultInner checkNameAvailability( - String locationName, CheckNameAvailabilityParameters parameters); + Response checkNameAvailabilityWithResponse( + String locationName, CheckNameAvailabilityParameters parameters, Context context); /** * Checks whether the Batch account name is available in the specified region. * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. - * @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 CheckNameAvailability operation response along with {@link Response}. + * @return the CheckNameAvailability operation response. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response checkNameAvailabilityWithResponse( - String locationName, CheckNameAvailabilityParameters parameters, Context context); + CheckNameAvailabilityResultInner checkNameAvailability( + String locationName, CheckNameAvailabilityParameters parameters); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PoolsClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PoolsClient.java index 6f6d9774380b..7f5cf73475b7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PoolsClient.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PoolsClient.java @@ -60,21 +60,6 @@ PagedIterable listByBatchAccount( String filter, Context context); - /** - * Creates a new pool inside the specified account. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param poolName The pool name. This must be unique within the account. - * @param parameters Additional parameters for pool creation. - * @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 contains information about a pool. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - PoolInner create(String resourceGroupName, String accountName, String poolName, PoolInner parameters); - /** * Creates a new pool inside the specified account. * @@ -103,20 +88,19 @@ PoolsCreateResponse createWithResponse( Context context); /** - * Updates the properties of an existing pool. + * Creates a new pool inside the specified account. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the account. - * @param parameters Pool properties that should be updated. Properties that are supplied will be updated, any - * property not supplied will be unchanged. + * @param parameters Additional parameters for pool creation. * @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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolInner update(String resourceGroupName, String accountName, String poolName, PoolInner parameters); + PoolInner create(String resourceGroupName, String accountName, String poolName, PoolInner parameters); /** * Updates the properties of an existing pool. @@ -143,6 +127,22 @@ PoolsUpdateResponse updateWithResponse( String ifMatch, Context context); + /** + * Updates the properties of an existing pool. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param poolName The pool name. This must be unique within the account. + * @param parameters Pool properties that should be updated. Properties that are supplied will be updated, any + * property not supplied will be unchanged. + * @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 contains information about a pool. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + PoolInner update(String resourceGroupName, String accountName, String poolName, PoolInner parameters); + /** * Deletes the specified pool. * @@ -206,13 +206,14 @@ SyncPoller, Void> beginDelete( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolInner get(String resourceGroupName, String accountName, String poolName); + PoolsGetResponse getWithResponse(String resourceGroupName, String accountName, String poolName, Context context); /** * Gets information about the specified pool. @@ -220,14 +221,13 @@ SyncPoller, Void> beginDelete( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolsGetResponse getWithResponse(String resourceGroupName, String accountName, String poolName, Context context); + PoolInner get(String resourceGroupName, String accountName, String poolName); /** * Disables automatic scaling for a pool. @@ -235,13 +235,15 @@ SyncPoller, Void> beginDelete( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolInner disableAutoScale(String resourceGroupName, String accountName, String poolName); + PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( + String resourceGroupName, String accountName, String poolName, Context context); /** * Disables automatic scaling for a pool. @@ -249,18 +251,18 @@ SyncPoller, Void> beginDelete( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( - String resourceGroupName, String accountName, String poolName, Context context); + PoolInner disableAutoScale(String resourceGroupName, String accountName, String poolName); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -269,16 +271,20 @@ PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolInner stopResize(String resourceGroupName, String accountName, String poolName); + PoolsStopResizeResponse stopResizeWithResponse( + String resourceGroupName, String accountName, String poolName, Context context); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -287,13 +293,11 @@ PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - PoolsStopResizeResponse stopResizeWithResponse( - String resourceGroupName, String accountName, String poolName, Context context); + PoolInner stopResize(String resourceGroupName, String accountName, String poolName); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateEndpointConnectionsClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateEndpointConnectionsClient.java index b8c8ab1302e8..f51b95e2a993 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateEndpointConnectionsClient.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateEndpointConnectionsClient.java @@ -51,14 +51,15 @@ PagedIterable listByBatchAccount( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection. + * @return information about the specified private endpoint connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - PrivateEndpointConnectionInner get( - String resourceGroupName, String accountName, String privateEndpointConnectionName); + Response getWithResponse( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); /** * Gets information about the specified private endpoint connection. @@ -67,15 +68,14 @@ PrivateEndpointConnectionInner get( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection along with {@link Response}. + * @return information about the specified private endpoint connection. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getWithResponse( - String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); + PrivateEndpointConnectionInner get( + String resourceGroupName, String accountName, String privateEndpointConnectionName); /** * Updates the properties of an existing private endpoint connection. @@ -86,8 +86,6 @@ Response getWithResponse( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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. @@ -98,8 +96,7 @@ SyncPoller, PrivateEndpointConnection String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch); + PrivateEndpointConnectionInner parameters); /** * Updates the properties of an existing private endpoint connection. @@ -136,8 +133,6 @@ SyncPoller, PrivateEndpointConnection * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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. @@ -148,8 +143,7 @@ PrivateEndpointConnectionInner update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch); + PrivateEndpointConnectionInner parameters); /** * Updates the properties of an existing private endpoint connection. @@ -160,6 +154,9 @@ PrivateEndpointConnectionInner update( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. + * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted + * or set to "*" to apply the operation unconditionally. + * @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. @@ -170,31 +167,69 @@ PrivateEndpointConnectionInner update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters); + PrivateEndpointConnectionInner parameters, + String ifMatch, + Context context); /** - * Updates the properties of an existing private endpoint connection. + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, Void> beginDelete( + String resourceGroupName, String accountName, String privateEndpointConnectionName); + + /** + * Deletes the specified private endpoint connection. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * account. - * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will - * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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 contains information about a private link resource. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, Void> beginDelete( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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. */ @ServiceMethod(returns = ReturnType.SINGLE) - PrivateEndpointConnectionInner update( - String resourceGroupName, - String accountName, - String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch, - Context context); + void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName); + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateLinkResourcesClient.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateLinkResourcesClient.java index 0098137a7005..05e4d92798ee 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateLinkResourcesClient.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/PrivateLinkResourcesClient.java @@ -48,13 +48,15 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource. + * @return information about the specified private link resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - PrivateLinkResourceInner get(String resourceGroupName, String accountName, String privateLinkResourceName); + Response getWithResponse( + String resourceGroupName, String accountName, String privateLinkResourceName, Context context); /** * Gets information about the specified private link resource. @@ -62,13 +64,11 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource along with {@link Response}. + * @return information about the specified private link resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response getWithResponse( - String resourceGroupName, String accountName, String privateLinkResourceName, Context context); + PrivateLinkResourceInner get(String resourceGroupName, String accountName, String privateLinkResourceName); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationInner.java index 1a845c33df2a..b3b7158458ea 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationInner.java @@ -23,6 +23,10 @@ public final class ApplicationInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of ApplicationInner class. */ + public ApplicationInner() { + } + /** * Get the innerProperties property: The properties associated with the Application. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageInner.java index a6565f7c1ea4..2c41c911671c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageInner.java @@ -4,14 +4,14 @@ package com.azure.resourcemanager.batch.fluent.models; -import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Immutable; import com.azure.core.management.ProxyResource; import com.azure.resourcemanager.batch.models.PackageState; import com.fasterxml.jackson.annotation.JsonProperty; import java.time.OffsetDateTime; /** An application package which represents a particular version of an application. */ -@Fluent +@Immutable public final class ApplicationPackageInner extends ProxyResource { /* * The properties associated with the Application Package. @@ -25,6 +25,10 @@ public final class ApplicationPackageInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of ApplicationPackageInner class. */ + public ApplicationPackageInner() { + } + /** * Get the innerProperties property: The properties associated with the Application Package. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageProperties.java index 41a41ead2fe0..92fb6eaae0de 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationPackageProperties.java @@ -37,12 +37,15 @@ public final class ApplicationPackageProperties { private OffsetDateTime storageUrlExpiry; /* - * The time at which the package was last activated, if the package is - * active. + * The time at which the package was last activated, if the package is active. */ @JsonProperty(value = "lastActivationTime", access = JsonProperty.Access.WRITE_ONLY) private OffsetDateTime lastActivationTime; + /** Creates an instance of ApplicationPackageProperties class. */ + public ApplicationPackageProperties() { + } + /** * Get the state property: The current state of the application package. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationProperties.java index bf2b3f294c80..4fc7f8d1eb7a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/ApplicationProperties.java @@ -17,20 +17,22 @@ public final class ApplicationProperties { private String displayName; /* - * A value indicating whether packages within the application may be - * overwritten using the same version string. + * A value indicating whether packages within the application may be overwritten using the same version string. */ @JsonProperty(value = "allowUpdates") private Boolean allowUpdates; /* - * The package to use if a client requests the application but does not - * specify a version. This property can only be set to the name of an - * existing package. + * The package to use if a client requests the application but does not specify a version. This property can only + * be set to the name of an existing package. */ @JsonProperty(value = "defaultVersion") private String defaultVersion; + /** Creates an instance of ApplicationProperties class. */ + public ApplicationProperties() { + } + /** * Get the displayName property: The display name for the application. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountCreateProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountCreateProperties.java index 684f527d4e8b..339d140aad39 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountCreateProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountCreateProperties.java @@ -9,6 +9,7 @@ import com.azure.resourcemanager.batch.models.AutoStorageBaseProperties; import com.azure.resourcemanager.batch.models.EncryptionProperties; import com.azure.resourcemanager.batch.models.KeyVaultReference; +import com.azure.resourcemanager.batch.models.NetworkProfile; import com.azure.resourcemanager.batch.models.PoolAllocationMode; import com.azure.resourcemanager.batch.models.PublicNetworkAccessType; import com.fasterxml.jackson.annotation.JsonProperty; @@ -24,11 +25,9 @@ public final class BatchAccountCreateProperties { private AutoStorageBaseProperties autoStorage; /* - * The pool allocation mode also affects how clients may authenticate to - * the Batch Service API. If the mode is BatchService, clients may - * authenticate using access keys or Azure Active Directory. If the mode is - * UserSubscription, clients must use Azure Active Directory. The default - * is BatchService. + * The pool allocation mode also affects how clients may authenticate to the Batch Service API. If the mode is + * BatchService, clients may authenticate using access keys or Azure Active Directory. If the mode is + * UserSubscription, clients must use Azure Active Directory. The default is BatchService. */ @JsonProperty(value = "poolAllocationMode") private PoolAllocationMode poolAllocationMode; @@ -46,21 +45,29 @@ public final class BatchAccountCreateProperties { private PublicNetworkAccessType publicNetworkAccess; /* - * Configures how customer data is encrypted inside the Batch account. By - * default, accounts are encrypted using a Microsoft managed key. For - * additional control, a customer-managed key can be used instead. + * The network profile only takes effect when publicNetworkAccess is enabled. + */ + @JsonProperty(value = "networkProfile") + private NetworkProfile networkProfile; + + /* + * Configures how customer data is encrypted inside the Batch account. By default, accounts are encrypted using a + * Microsoft managed key. For additional control, a customer-managed key can be used instead. */ @JsonProperty(value = "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. + * 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 = "allowedAuthenticationModes") private List allowedAuthenticationModes; + /** Creates an instance of BatchAccountCreateProperties class. */ + public BatchAccountCreateProperties() { + } + /** * Get the autoStorage property: The properties related to the auto-storage account. * @@ -145,6 +152,26 @@ public BatchAccountCreateProperties withPublicNetworkAccess(PublicNetworkAccessT return this; } + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.networkProfile; + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountCreateProperties object itself. + */ + public BatchAccountCreateProperties withNetworkProfile(NetworkProfile networkProfile) { + this.networkProfile = networkProfile; + return this; + } + /** * Get the encryption property: Configures how customer data is encrypted inside the Batch account. By default, * accounts are encrypted using a Microsoft managed key. For additional control, a customer-managed key can be used @@ -204,6 +231,9 @@ public void validate() { if (keyVaultReference() != null) { keyVaultReference().validate(); } + if (networkProfile() != null) { + networkProfile().validate(); + } if (encryption() != null) { encryption().validate(); } 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 cbe706f1a279..3670348caf78 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 @@ -11,6 +11,7 @@ import com.azure.resourcemanager.batch.models.BatchAccountIdentity; import com.azure.resourcemanager.batch.models.EncryptionProperties; import com.azure.resourcemanager.batch.models.KeyVaultReference; +import com.azure.resourcemanager.batch.models.NetworkProfile; import com.azure.resourcemanager.batch.models.PoolAllocationMode; import com.azure.resourcemanager.batch.models.ProvisioningState; import com.azure.resourcemanager.batch.models.PublicNetworkAccessType; @@ -34,6 +35,10 @@ public final class BatchAccountInner extends Resource { @JsonProperty(value = "identity") private BatchAccountIdentity identity; + /** Creates an instance of BatchAccountInner class. */ + public BatchAccountInner() { + } + /** * Get the innerProperties property: The properties associated with the account. * @@ -86,6 +91,16 @@ public String accountEndpoint() { return this.innerProperties() == null ? null : this.innerProperties().accountEndpoint(); } + /** + * Get the nodeManagementEndpoint property: The endpoint used by compute node to connect to the Batch node + * management service. + * + * @return the nodeManagementEndpoint value. + */ + public String nodeManagementEndpoint() { + return this.innerProperties() == null ? null : this.innerProperties().nodeManagementEndpoint(); + } + /** * Get the provisioningState property: The provisioned state of the resource. * @@ -122,6 +137,43 @@ public PublicNetworkAccessType publicNetworkAccess() { return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess(); } + /** + * Set the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the BatchAccountInner object itself. + */ + public BatchAccountInner withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess) { + if (this.innerProperties() == null) { + this.innerProperties = new BatchAccountProperties(); + } + this.innerProperties().withPublicNetworkAccess(publicNetworkAccess); + return this; + } + + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.innerProperties() == null ? null : this.innerProperties().networkProfile(); + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountInner object itself. + */ + public BatchAccountInner withNetworkProfile(NetworkProfile networkProfile) { + if (this.innerProperties() == null) { + this.innerProperties = new BatchAccountProperties(); + } + this.innerProperties().withNetworkProfile(networkProfile); + return this; + } + /** * Get the privateEndpointConnections property: List of private endpoint connections associated with the Batch * account. @@ -154,8 +206,10 @@ public EncryptionProperties encryption() { } /** - * Get the dedicatedCoreQuota property: The dedicated core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Get the dedicatedCoreQuota property: The dedicated core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the dedicatedCoreQuota value. */ @@ -164,8 +218,10 @@ public Integer dedicatedCoreQuota() { } /** - * Get the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Get the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the lowPriorityCoreQuota value. */ @@ -186,12 +242,11 @@ public List dedicatedCoreQuotaPerVMFamily() { /** * Get the dedicatedCoreQuotaPerVMFamilyEnforced property: A value indicating whether core quotas per Virtual - * Machine family are enforced for this account Batch is transitioning its core quota system for dedicated cores to - * be enforced per Virtual Machine family. During this transitional phase, the dedicated core quota per Virtual - * Machine family may not yet be enforced. If this flag is false, dedicated core quota is enforced via the old - * dedicatedCoreQuota property on the account and does not consider Virtual Machine family. If this flag is true, - * dedicated core quota is enforced via the dedicatedCoreQuotaPerVMFamily property on the account, and the old - * dedicatedCoreQuota does not apply. + * Machine family are enforced for this account + * + *

If this flag is true, dedicated core quota is enforced via both the dedicatedCoreQuotaPerVMFamily and + * dedicatedCoreQuota properties on the account. If this flag is false, dedicated core quota is enforced only via + * the dedicatedCoreQuota property on the account and does not consider Virtual Machine family. * * @return the dedicatedCoreQuotaPerVMFamilyEnforced value. */ diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountKeysInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountKeysInner.java index 325e21fd41e5..6e90760314fb 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountKeysInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountKeysInner.java @@ -28,6 +28,10 @@ public final class BatchAccountKeysInner { @JsonProperty(value = "secondary", access = JsonProperty.Access.WRITE_ONLY) private String secondary; + /** Creates an instance of BatchAccountKeysInner class. */ + public BatchAccountKeysInner() { + } + /** * Get the accountName property: The Batch account name. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountProperties.java index 55f1568e1e0e..a42b0b936b8e 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountProperties.java @@ -4,11 +4,12 @@ package com.azure.resourcemanager.batch.fluent.models; -import com.azure.core.annotation.Immutable; +import com.azure.core.annotation.Fluent; import com.azure.resourcemanager.batch.models.AuthenticationMode; import com.azure.resourcemanager.batch.models.AutoStorageProperties; import com.azure.resourcemanager.batch.models.EncryptionProperties; import com.azure.resourcemanager.batch.models.KeyVaultReference; +import com.azure.resourcemanager.batch.models.NetworkProfile; import com.azure.resourcemanager.batch.models.PoolAllocationMode; import com.azure.resourcemanager.batch.models.ProvisioningState; import com.azure.resourcemanager.batch.models.PublicNetworkAccessType; @@ -17,7 +18,7 @@ import java.util.List; /** Account specific properties. */ -@Immutable +@Fluent public final class BatchAccountProperties { /* * The account endpoint used to interact with the Batch service. @@ -25,6 +26,12 @@ public final class BatchAccountProperties { @JsonProperty(value = "accountEndpoint", access = JsonProperty.Access.WRITE_ONLY) private String accountEndpoint; + /* + * The endpoint used by compute node to connect to the Batch node management service. + */ + @JsonProperty(value = "nodeManagementEndpoint", access = JsonProperty.Access.WRITE_ONLY) + private String nodeManagementEndpoint; + /* * The provisioned state of the resource */ @@ -46,9 +53,15 @@ public final class BatchAccountProperties { /* * If not specified, the default value is 'enabled'. */ - @JsonProperty(value = "publicNetworkAccess", access = JsonProperty.Access.WRITE_ONLY) + @JsonProperty(value = "publicNetworkAccess") private PublicNetworkAccessType publicNetworkAccess; + /* + * The network profile only takes effect when publicNetworkAccess is enabled. + */ + @JsonProperty(value = "networkProfile") + private NetworkProfile networkProfile; + /* * List of private endpoint connections associated with the Batch account */ @@ -56,55 +69,49 @@ public final class BatchAccountProperties { private List privateEndpointConnections; /* - * Contains information about the auto-storage account associated with a - * Batch account. + * Contains information about the auto-storage account associated with a Batch account. */ @JsonProperty(value = "autoStorage", access = JsonProperty.Access.WRITE_ONLY) private AutoStorageProperties autoStorage; /* - * Configures how customer data is encrypted inside the Batch account. By - * default, accounts are encrypted using a Microsoft managed key. For - * additional control, a customer-managed key can be used instead. + * Configures how customer data is encrypted inside the Batch account. By default, accounts are encrypted using a + * Microsoft managed key. For additional control, a customer-managed key can be used instead. */ @JsonProperty(value = "encryption", access = JsonProperty.Access.WRITE_ONLY) private EncryptionProperties encryption; /* - * The dedicated core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the - * subscription so this value is not returned. + * The dedicated core quota for the Batch account. + * + * For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value + * is not returned. */ @JsonProperty(value = "dedicatedCoreQuota", access = JsonProperty.Access.WRITE_ONLY) private Integer dedicatedCoreQuota; /* - * The Spot/low-priority core quota for the Batch account. For accounts - * with PoolAllocationMode set to UserSubscription, quota is managed on the - * subscription so this value is not returned. + * The Spot/low-priority core quota for the Batch account. + * + * For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value + * is not returned. */ @JsonProperty(value = "lowPriorityCoreQuota", access = JsonProperty.Access.WRITE_ONLY) private Integer lowPriorityCoreQuota; /* - * A list of the dedicated core quota per Virtual Machine family for the - * Batch account. For accounts with PoolAllocationMode set to - * UserSubscription, quota is managed on the subscription so this value is - * not returned. + * A list of the dedicated core quota per Virtual Machine family for the Batch account. For accounts with + * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. */ @JsonProperty(value = "dedicatedCoreQuotaPerVMFamily", access = JsonProperty.Access.WRITE_ONLY) private List dedicatedCoreQuotaPerVMFamily; /* - * A value indicating whether core quotas per Virtual Machine family are - * enforced for this account Batch is transitioning its core quota system - * for dedicated cores to be enforced per Virtual Machine family. During - * this transitional phase, the dedicated core quota per Virtual Machine - * family may not yet be enforced. If this flag is false, dedicated core - * quota is enforced via the old dedicatedCoreQuota property on the account - * and does not consider Virtual Machine family. If this flag is true, - * dedicated core quota is enforced via the dedicatedCoreQuotaPerVMFamily - * property on the account, and the old dedicatedCoreQuota does not apply. + * A value indicating whether core quotas per Virtual Machine family are enforced for this account + * + * If this flag is true, dedicated core quota is enforced via both the dedicatedCoreQuotaPerVMFamily and + * dedicatedCoreQuota properties on the account. If this flag is false, dedicated core quota is enforced only via + * the dedicatedCoreQuota property on the account and does not consider Virtual Machine family. */ @JsonProperty(value = "dedicatedCoreQuotaPerVMFamilyEnforced", access = JsonProperty.Access.WRITE_ONLY) private Boolean dedicatedCoreQuotaPerVMFamilyEnforced; @@ -122,13 +129,16 @@ public final class BatchAccountProperties { 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. + * 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 = "allowedAuthenticationModes", access = JsonProperty.Access.WRITE_ONLY) private List allowedAuthenticationModes; + /** Creates an instance of BatchAccountProperties class. */ + public BatchAccountProperties() { + } + /** * Get the accountEndpoint property: The account endpoint used to interact with the Batch service. * @@ -138,6 +148,16 @@ public String accountEndpoint() { return this.accountEndpoint; } + /** + * Get the nodeManagementEndpoint property: The endpoint used by compute node to connect to the Batch node + * management service. + * + * @return the nodeManagementEndpoint value. + */ + public String nodeManagementEndpoint() { + return this.nodeManagementEndpoint; + } + /** * Get the provisioningState property: The provisioned state of the resource. * @@ -174,6 +194,37 @@ public PublicNetworkAccessType publicNetworkAccess() { return this.publicNetworkAccess; } + /** + * Set the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the BatchAccountProperties object itself. + */ + public BatchAccountProperties withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess) { + this.publicNetworkAccess = publicNetworkAccess; + return this; + } + + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.networkProfile; + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountProperties object itself. + */ + public BatchAccountProperties withNetworkProfile(NetworkProfile networkProfile) { + this.networkProfile = networkProfile; + return this; + } + /** * Get the privateEndpointConnections property: List of private endpoint connections associated with the Batch * account. @@ -206,8 +257,10 @@ public EncryptionProperties encryption() { } /** - * Get the dedicatedCoreQuota property: The dedicated core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Get the dedicatedCoreQuota property: The dedicated core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the dedicatedCoreQuota value. */ @@ -216,8 +269,10 @@ public Integer dedicatedCoreQuota() { } /** - * Get the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Get the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the lowPriorityCoreQuota value. */ @@ -238,12 +293,11 @@ public List dedicatedCoreQuotaPerVMFamily() { /** * Get the dedicatedCoreQuotaPerVMFamilyEnforced property: A value indicating whether core quotas per Virtual - * Machine family are enforced for this account Batch is transitioning its core quota system for dedicated cores to - * be enforced per Virtual Machine family. During this transitional phase, the dedicated core quota per Virtual - * Machine family may not yet be enforced. If this flag is false, dedicated core quota is enforced via the old - * dedicatedCoreQuota property on the account and does not consider Virtual Machine family. If this flag is true, - * dedicated core quota is enforced via the dedicatedCoreQuotaPerVMFamily property on the account, and the old - * dedicatedCoreQuota does not apply. + * Machine family are enforced for this account + * + *

If this flag is true, dedicated core quota is enforced via both the dedicatedCoreQuotaPerVMFamily and + * dedicatedCoreQuota properties on the account. If this flag is false, dedicated core quota is enforced only via + * the dedicatedCoreQuota property on the account and does not consider Virtual Machine family. * * @return the dedicatedCoreQuotaPerVMFamilyEnforced value. */ @@ -288,6 +342,9 @@ public void validate() { if (keyVaultReference() != null) { keyVaultReference().validate(); } + if (networkProfile() != null) { + networkProfile().validate(); + } if (privateEndpointConnections() != null) { privateEndpointConnections().forEach(e -> e.validate()); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountUpdateProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountUpdateProperties.java index 236461db87df..32627301433c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountUpdateProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchAccountUpdateProperties.java @@ -8,6 +8,8 @@ import com.azure.resourcemanager.batch.models.AuthenticationMode; import com.azure.resourcemanager.batch.models.AutoStorageBaseProperties; import com.azure.resourcemanager.batch.models.EncryptionProperties; +import com.azure.resourcemanager.batch.models.NetworkProfile; +import com.azure.resourcemanager.batch.models.PublicNetworkAccessType; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; @@ -21,21 +23,35 @@ public final class BatchAccountUpdateProperties { private AutoStorageBaseProperties autoStorage; /* - * Configures how customer data is encrypted inside the Batch account. By - * default, accounts are encrypted using a Microsoft managed key. For - * additional control, a customer-managed key can be used instead. + * Configures how customer data is encrypted inside the Batch account. By default, accounts are encrypted using a + * Microsoft managed key. For additional control, a customer-managed key can be used instead. */ @JsonProperty(value = "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. + * 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 = "allowedAuthenticationModes") private List allowedAuthenticationModes; + /* + * If not specified, the default value is 'enabled'. + */ + @JsonProperty(value = "publicNetworkAccess") + private PublicNetworkAccessType publicNetworkAccess; + + /* + * The network profile only takes effect when publicNetworkAccess is enabled. + */ + @JsonProperty(value = "networkProfile") + private NetworkProfile networkProfile; + + /** Creates an instance of BatchAccountUpdateProperties class. */ + public BatchAccountUpdateProperties() { + } + /** * Get the autoStorage property: The properties related to the auto-storage account. * @@ -103,6 +119,46 @@ public BatchAccountUpdateProperties withAllowedAuthenticationModes( return this; } + /** + * Get the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccessType publicNetworkAccess() { + return this.publicNetworkAccess; + } + + /** + * Set the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the BatchAccountUpdateProperties object itself. + */ + public BatchAccountUpdateProperties withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess) { + this.publicNetworkAccess = publicNetworkAccess; + return this; + } + + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.networkProfile; + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountUpdateProperties object itself. + */ + public BatchAccountUpdateProperties withNetworkProfile(NetworkProfile networkProfile) { + this.networkProfile = networkProfile; + return this; + } + /** * Validates the instance. * @@ -115,5 +171,8 @@ public void validate() { if (encryption() != null) { encryption().validate(); } + if (networkProfile() != null) { + networkProfile().validate(); + } } } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchLocationQuotaInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchLocationQuotaInner.java index f891e5839531..286d690dc607 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchLocationQuotaInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/BatchLocationQuotaInner.java @@ -11,12 +11,15 @@ @Immutable public final class BatchLocationQuotaInner { /* - * The number of Batch accounts that may be created under the subscription - * in the specified region. + * The number of Batch accounts that may be created under the subscription in the specified region. */ @JsonProperty(value = "accountQuota", access = JsonProperty.Access.WRITE_ONLY) private Integer accountQuota; + /** Creates an instance of BatchLocationQuotaInner class. */ + public BatchLocationQuotaInner() { + } + /** * Get the accountQuota property: The number of Batch accounts that may be created under the subscription in the * specified region. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateCreateOrUpdateProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateCreateOrUpdateProperties.java index 11640e5dba46..b45ca84657d5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateCreateOrUpdateProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateCreateOrUpdateProperties.java @@ -14,21 +14,29 @@ @Fluent public final class CertificateCreateOrUpdateProperties extends CertificateBaseProperties { /* - * The base64-encoded contents of the certificate. The maximum size is - * 10KB. + * The base64-encoded contents of the certificate. + * + * The maximum size is 10KB. */ @JsonProperty(value = "data", required = true) private String data; /* - * The password to access the certificate's private key. This must not be - * specified if the certificate format is Cer. + * The password to access the certificate's private key. + * + * This must not be specified if the certificate format is Cer. */ @JsonProperty(value = "password") private String password; + /** Creates an instance of CertificateCreateOrUpdateProperties class. */ + public CertificateCreateOrUpdateProperties() { + } + /** - * Get the data property: The base64-encoded contents of the certificate. The maximum size is 10KB. + * Get the data property: The base64-encoded contents of the certificate. + * + *

The maximum size is 10KB. * * @return the data value. */ @@ -37,7 +45,9 @@ public String data() { } /** - * Set the data property: The base64-encoded contents of the certificate. The maximum size is 10KB. + * Set the data property: The base64-encoded contents of the certificate. + * + *

The maximum size is 10KB. * * @param data the data value to set. * @return the CertificateCreateOrUpdateProperties object itself. @@ -48,8 +58,9 @@ public CertificateCreateOrUpdateProperties withData(String data) { } /** - * Get the password property: The password to access the certificate's private key. This must not be specified if - * the certificate format is Cer. + * Get the password property: The password to access the certificate's private key. + * + *

This must not be specified if the certificate format is Cer. * * @return the password value. */ @@ -58,8 +69,9 @@ public String password() { } /** - * Set the password property: The password to access the certificate's private key. This must not be specified if - * the certificate format is Cer. + * Set the password property: The password to access the certificate's private key. + * + *

This must not be specified if the certificate format is Cer. * * @param password the password value to set. * @return the CertificateCreateOrUpdateProperties object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateInner.java index 96d734b1c92b..67c5e3fd29e8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateInner.java @@ -27,6 +27,10 @@ public final class CertificateInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of CertificateInner class. */ + public CertificateInner() { + } + /** * Get the innerProperties property: The properties associated with the certificate. * @@ -102,8 +106,9 @@ public DeleteCertificateError deleteCertificateError() { } /** - * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @return the thumbprintAlgorithm value. */ @@ -112,8 +117,9 @@ public String thumbprintAlgorithm() { } /** - * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @param thumbprintAlgorithm the thumbprintAlgorithm value to set. * @return the CertificateInner object itself. @@ -127,7 +133,9 @@ public CertificateInner withThumbprintAlgorithm(String thumbprintAlgorithm) { } /** - * Get the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Get the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @return the thumbprint value. */ @@ -136,7 +144,9 @@ public String thumbprint() { } /** - * Set the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Set the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @param thumbprint the thumbprint value to set. * @return the CertificateInner object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateProperties.java index d9759b651634..18e667d1c6a9 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CertificateProperties.java @@ -46,12 +46,15 @@ public final class CertificateProperties extends CertificateBaseProperties { private String publicData; /* - * This is only returned when the certificate provisioningState is - * 'Failed'. + * This is only returned when the certificate provisioningState is 'Failed'. */ @JsonProperty(value = "deleteCertificateError", access = JsonProperty.Access.WRITE_ONLY) private DeleteCertificateError deleteCertificateError; + /** Creates an instance of CertificateProperties class. */ + public CertificateProperties() { + } + /** * Get the provisioningState property: The provisioningState property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CheckNameAvailabilityResultInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CheckNameAvailabilityResultInner.java index 3489a20e5646..f2cd488afebe 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CheckNameAvailabilityResultInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/CheckNameAvailabilityResultInner.java @@ -12,16 +12,15 @@ @Immutable public final class CheckNameAvailabilityResultInner { /* - * Gets a boolean value that indicates whether the name is available for - * you to use. If true, the name is available. If false, the name has - * already been taken or invalid and cannot be used. + * Gets a boolean value that indicates whether the name is available for you to use. If true, the name is + * available. If false, the name has already been taken or invalid and cannot be used. */ @JsonProperty(value = "nameAvailable", access = JsonProperty.Access.WRITE_ONLY) private Boolean nameAvailable; /* - * Gets the reason that a Batch account name could not be used. The Reason - * element is only returned if NameAvailable is false. + * Gets the reason that a Batch account name could not be used. The Reason element is only returned if + * NameAvailable is false. */ @JsonProperty(value = "reason", access = JsonProperty.Access.WRITE_ONLY) private NameAvailabilityReason reason; @@ -32,6 +31,10 @@ public final class CheckNameAvailabilityResultInner { @JsonProperty(value = "message", access = JsonProperty.Access.WRITE_ONLY) private String message; + /** Creates an instance of CheckNameAvailabilityResultInner class. */ + public CheckNameAvailabilityResultInner() { + } + /** * Get the nameAvailable property: Gets a boolean value that indicates whether the name is available for you to use. * If true, the name is available. If false, the name has already been taken or invalid and cannot be used. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseInner.java index 55095dff8cd7..91968c30fc45 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseInner.java @@ -23,6 +23,10 @@ public final class DetectorResponseInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of DetectorResponseInner class. */ + public DetectorResponseInner() { + } + /** * Get the innerProperties property: The properties associated with the detector. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseProperties.java index ece5ad5dce80..ba7ee8d73243 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/DetectorResponseProperties.java @@ -16,6 +16,10 @@ public final class DetectorResponseProperties { @JsonProperty(value = "value") private String value; + /** Creates an instance of DetectorResponseProperties class. */ + public DetectorResponseProperties() { + } + /** * Get the value property: A base64 encoded string that represents the content of a detector. * 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 3b1a9430134a..c08ff37033d5 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 @@ -12,8 +12,9 @@ @Fluent public final class OperationInner { /* - * The operation name. This is of the format - * {provider}/{resource}/{operation} + * The operation name. + * + * This is of the format {provider}/{resource}/{operation} */ @JsonProperty(value = "name") private String name; @@ -37,13 +38,19 @@ public final class OperationInner { private String origin; /* - * Any object + * Properties of the operation. */ @JsonProperty(value = "properties") private Object properties; + /** Creates an instance of OperationInner class. */ + public OperationInner() { + } + /** - * Get the name property: The operation name. This is of the format {provider}/{resource}/{operation}. + * Get the name property: The operation name. + * + *

This is of the format {provider}/{resource}/{operation}. * * @return the name value. */ @@ -52,7 +59,9 @@ public String name() { } /** - * Set the name property: The operation name. This is of the format {provider}/{resource}/{operation}. + * Set the name property: The operation name. + * + *

This is of the format {provider}/{resource}/{operation}. * * @param name the name value to set. * @return the OperationInner object itself. @@ -123,7 +132,7 @@ public OperationInner withOrigin(String origin) { } /** - * Get the properties property: Any object. + * Get the properties property: Properties of the operation. * * @return the properties value. */ @@ -132,7 +141,7 @@ public Object properties() { } /** - * Set the properties property: Any object. + * Set the properties property: Properties of the operation. * * @param properties the properties value to set. * @return the OperationInner object itself. 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 index 2b1c55896cee..23fe1db1efbb 100644 --- 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 @@ -19,12 +19,15 @@ public final class OutboundEnvironmentEndpointInner { private String category; /* - * The endpoints for this service to which the Batch service makes outbound - * calls. + * The endpoints for this service to which the Batch service makes outbound calls. */ @JsonProperty(value = "endpoints", access = JsonProperty.Access.WRITE_ONLY) private List endpoints; + /** Creates an instance of OutboundEnvironmentEndpointInner class. */ + public OutboundEnvironmentEndpointInner() { + } + /** * Get the category property: The type of service that the Batch service connects to. * 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 3a1a39d37b8e..1028601c0211 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 @@ -16,6 +16,7 @@ import com.azure.resourcemanager.batch.models.MetadataItem; import com.azure.resourcemanager.batch.models.MountConfiguration; import com.azure.resourcemanager.batch.models.NetworkConfiguration; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.PoolProvisioningState; import com.azure.resourcemanager.batch.models.ResizeOperationStatus; import com.azure.resourcemanager.batch.models.ScaleSettings; @@ -47,6 +48,10 @@ public final class PoolInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of PoolInner class. */ + public PoolInner() { + } + /** * Get the innerProperties property: The properties associated with the pool. * @@ -86,8 +91,9 @@ public String etag() { } /** - * Get the displayName property: The display name for the pool. The display name need not be unique and can contain - * any Unicode characters up to a maximum length of 1024. + * Get the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. * * @return the displayName value. */ @@ -96,8 +102,9 @@ public String displayName() { } /** - * Set the displayName property: The display name for the pool. The display name need not be unique and can contain - * any Unicode characters up to a maximum length of 1024. + * Set the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. * * @param displayName the displayName value to set. * @return the PoolInner object itself. @@ -111,9 +118,10 @@ public PoolInner withDisplayName(String displayName) { } /** - * Get the lastModified property: The last modified time of the pool. This is the last time at which the pool level - * data, such as the targetDedicatedNodes or autoScaleSettings, changed. It does not factor in node-level changes - * such as a compute node changing state. + * Get the lastModified property: The last modified time of the pool. + * + *

This is the last time at which the pool level data, such as the targetDedicatedNodes or autoScaleSettings, + * changed. It does not factor in node-level changes such as a compute node changing state. * * @return the lastModified value. */ @@ -167,8 +175,9 @@ public OffsetDateTime allocationStateTransitionTime() { } /** - * Get the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with + * Get the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the @@ -185,8 +194,9 @@ public String vmSize() { } /** - * Set the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with + * Set the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the @@ -208,9 +218,10 @@ public PoolInner withVmSize(String vmSize) { } /** - * Get the deploymentConfiguration property: Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration - * uses Azure Virtual Machines (IaaS). + * Get the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * * @return the deploymentConfiguration value. */ @@ -219,9 +230,10 @@ public DeploymentConfiguration deploymentConfiguration() { } /** - * Set the deploymentConfiguration property: Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration - * uses Azure Virtual Machines (IaaS). + * Set the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * * @param deploymentConfiguration the deploymentConfiguration value to set. * @return the PoolInner object itself. @@ -235,7 +247,7 @@ public PoolInner withDeploymentConfiguration(DeploymentConfiguration deploymentC } /** - * Get the currentDedicatedNodes property: The number of compute nodes currently in the pool. + * Get the currentDedicatedNodes property: The number of dedicated compute nodes currently in the pool. * * @return the currentDedicatedNodes value. */ @@ -253,10 +265,11 @@ public Integer currentLowPriorityNodes() { } /** - * Get the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. This can either - * be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a formula - * which is periodically reevaluated. If this property is not specified, the pool will have a fixed scale with 0 - * targetDedicatedNodes. + * Get the scaleSettings property: Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. * * @return the scaleSettings value. */ @@ -265,10 +278,11 @@ public ScaleSettings scaleSettings() { } /** - * Set the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. This can either - * be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a formula - * which is periodically reevaluated. If this property is not specified, the pool will have a fixed scale with 0 - * targetDedicatedNodes. + * Set the scaleSettings property: Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. * * @param scaleSettings the scaleSettings value to set. * @return the PoolInner object itself. @@ -282,8 +296,9 @@ public PoolInner withScaleSettings(ScaleSettings scaleSettings) { } /** - * Get the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. This - * property is set only if the pool automatically scales, i.e. autoScaleSettings are used. + * Get the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. + * + *

This property is set only if the pool automatically scales, i.e. autoScaleSettings are used. * * @return the autoScaleRun value. */ @@ -292,9 +307,11 @@ public AutoScaleRun autoScaleRun() { } /** - * Get the interNodeCommunication property: Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of the - * requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + * Get the interNodeCommunication property: Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the + * chance of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. * * @return the interNodeCommunication value. */ @@ -303,9 +320,11 @@ public InterNodeCommunicationState interNodeCommunication() { } /** - * Set the interNodeCommunication property: Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of the - * requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + * Set the interNodeCommunication property: Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the + * chance of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. * * @param interNodeCommunication the interNodeCommunication value to set. * @return the PoolInner object itself. @@ -343,8 +362,10 @@ public PoolInner withNetworkConfiguration(NetworkConfiguration networkConfigurat /** * Get the taskSlotsPerNode property: The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the number of cores - * of the vmSize of the pool or 256. + * compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the + * pool or 256. * * @return the taskSlotsPerNode value. */ @@ -354,8 +375,10 @@ public Integer taskSlotsPerNode() { /** * Set the taskSlotsPerNode property: The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the number of cores - * of the vmSize of the pool or 256. + * compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the + * pool or 256. * * @param taskSlotsPerNode the taskSlotsPerNode value to set. * @return the PoolInner object itself. @@ -369,8 +392,9 @@ public PoolInner withTaskSlotsPerNode(Integer taskSlotsPerNode) { } /** - * Get the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Get the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. + * + *

If not specified, the default is spread. * * @return the taskSchedulingPolicy value. */ @@ -379,8 +403,9 @@ public TaskSchedulingPolicy taskSchedulingPolicy() { } /** - * Set the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Set the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. + * + *

If not specified, the default is spread. * * @param taskSchedulingPolicy the taskSchedulingPolicy value to set. * @return the PoolInner object itself. @@ -417,8 +442,9 @@ public PoolInner withUserAccounts(List userAccounts) { } /** - * Get the metadata property: A list of name-value pairs associated with the pool as metadata. The Batch service - * does not assign any meaning to metadata; it is solely for the use of user code. + * Get the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * * @return the metadata value. */ @@ -427,8 +453,9 @@ public List metadata() { } /** - * Set the metadata property: A list of name-value pairs associated with the pool as metadata. The Batch service - * does not assign any meaning to metadata; it is solely for the use of user code. + * Set the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * * @param metadata the metadata value to set. * @return the PoolInner object itself. @@ -443,8 +470,10 @@ public PoolInner withMetadata(List metadata) { /** * Get the startTask property: A task which is run when a compute node joins a pool in the Azure Batch service, or - * when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to an - * empty object to remove the start task from the pool. + * when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. * * @return the startTask value. */ @@ -454,8 +483,10 @@ public StartTask startTask() { /** * Set the startTask property: A task which is run when a compute node joins a pool in the Azure Batch service, or - * when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to an - * empty object to remove the start task from the pool. + * when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. * * @param startTask the startTask value to set. * @return the PoolInner object itself. @@ -469,13 +500,17 @@ public PoolInner withStartTask(StartTask startTask) { } /** - * Get the certificates property: The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * Get the certificates property: The list of certificates to be installed on each compute node in the pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @return the certificates value. */ public List certificates() { @@ -483,13 +518,17 @@ public List certificates() { } /** - * Set the certificates property: The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * Set the certificates property: The list of certificates to be installed on each compute node in the pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param certificates the certificates value to set. * @return the PoolInner object itself. */ @@ -503,8 +542,10 @@ public PoolInner withCertificates(List certificates) { /** * Get the applicationPackages property: The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new compute nodes joining the pool, but do not - * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 * application package references on any given pool. * * @return the applicationPackages value. @@ -515,8 +556,10 @@ public List applicationPackages() { /** * Set the applicationPackages property: The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new compute nodes joining the pool, but do not - * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 * application package references on any given pool. * * @param applicationPackages the applicationPackages value to set. @@ -532,8 +575,10 @@ public PoolInner withApplicationPackages(List appli /** * Get the applicationLicenses property: The list of application licenses the Batch service will make available on - * each compute node in the pool. The list of application licenses must be a subset of available Batch service - * application licenses. If a license is requested which is not supported, pool creation will fail. + * each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If a + * license is requested which is not supported, pool creation will fail. * * @return the applicationLicenses value. */ @@ -543,8 +588,10 @@ public List applicationLicenses() { /** * Set the applicationLicenses property: The list of application licenses the Batch service will make available on - * each compute node in the pool. The list of application licenses must be a subset of available Batch service - * application licenses. If a license is requested which is not supported, pool creation will fail. + * each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If a + * license is requested which is not supported, pool creation will fail. * * @param applicationLicenses the applicationLicenses value to set. * @return the PoolInner object itself. @@ -558,9 +605,10 @@ public PoolInner withApplicationLicenses(List applicationLicenses) { } /** - * Get the resizeOperationStatus property: Details about the current or last completed resize operation. Describes - * either the current operation (if the pool AllocationState is Resizing) or the previously completed operation (if - * the AllocationState is Steady). + * Get the resizeOperationStatus property: Details about the current or last completed resize operation. + * + *

Describes either the current operation (if the pool AllocationState is Resizing) or the previously completed + * operation (if the AllocationState is Steady). * * @return the resizeOperationStatus value. */ @@ -569,8 +617,9 @@ public ResizeOperationStatus resizeOperationStatus() { } /** - * Get the mountConfiguration property: A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * Get the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * * @return the mountConfiguration value. */ @@ -579,8 +628,9 @@ public List mountConfiguration() { } /** - * Set the mountConfiguration property: A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * Set the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * * @param mountConfiguration the mountConfiguration value to set. * @return the PoolInner object itself. @@ -593,6 +643,42 @@ public PoolInner withMountConfiguration(List mountConfigurat return this; } + /** + * Get the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + *

If omitted, the default value is Default. + * + * @return the targetNodeCommunicationMode value. + */ + public NodeCommunicationMode targetNodeCommunicationMode() { + return this.innerProperties() == null ? null : this.innerProperties().targetNodeCommunicationMode(); + } + + /** + * Set the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + *

If omitted, the default value is Default. + * + * @param targetNodeCommunicationMode the targetNodeCommunicationMode value to set. + * @return the PoolInner object itself. + */ + public PoolInner withTargetNodeCommunicationMode(NodeCommunicationMode targetNodeCommunicationMode) { + if (this.innerProperties() == null) { + this.innerProperties = new PoolProperties(); + } + this.innerProperties().withTargetNodeCommunicationMode(targetNodeCommunicationMode); + return this; + } + + /** + * Get the currentNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + * @return the currentNodeCommunicationMode value. + */ + public NodeCommunicationMode currentNodeCommunicationMode() { + return this.innerProperties() == null ? null : this.innerProperties().currentNodeCommunicationMode(); + } + /** * Validates the instance. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolProperties.java index c09fdc6ec744..8161fc08a8d3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PoolProperties.java @@ -14,6 +14,7 @@ import com.azure.resourcemanager.batch.models.MetadataItem; import com.azure.resourcemanager.batch.models.MountConfiguration; import com.azure.resourcemanager.batch.models.NetworkConfiguration; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.PoolProvisioningState; import com.azure.resourcemanager.batch.models.ResizeOperationStatus; import com.azure.resourcemanager.batch.models.ScaleSettings; @@ -28,17 +29,18 @@ @Fluent public final class PoolProperties { /* - * The display name for the pool. The display name need not be unique and - * can contain any Unicode characters up to a maximum length of 1024. + * The display name for the pool. + * + * The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. */ @JsonProperty(value = "displayName") private String displayName; /* - * The last modified time of the pool. This is the last time at which the - * pool level data, such as the targetDedicatedNodes or autoScaleSettings, - * changed. It does not factor in node-level changes such as a compute node - * changing state. + * The last modified time of the pool. + * + * This is the last time at which the pool level data, such as the targetDedicatedNodes or autoScaleSettings, + * changed. It does not factor in node-level changes such as a compute node changing state. */ @JsonProperty(value = "lastModified", access = JsonProperty.Access.WRITE_ONLY) private OffsetDateTime lastModified; @@ -74,35 +76,32 @@ public final class PoolProperties { private OffsetDateTime allocationStateTransitionTime; /* - * The size of virtual machines in the pool. All VMs in a pool are the same - * size. For information about available sizes of virtual machines for - * Cloud Services pools (pools created with cloudServiceConfiguration), see - * Sizes for Cloud Services - * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). - * Batch supports all Cloud Services VM sizes except ExtraSmall. For - * information about available VM sizes for pools using images from the - * Virtual Machines Marketplace (pools created with - * virtualMachineConfiguration) see Sizes for Virtual Machines (Linux) - * (https://azure.microsoft.com/documentation/articles/virtual-machines-linux-sizes/) - * or Sizes for Virtual Machines (Windows) - * (https://azure.microsoft.com/documentation/articles/virtual-machines-windows-sizes/). - * Batch supports all Azure VM sizes except STANDARD_A0 and those with - * premium storage (STANDARD_GS, STANDARD_DS, and STANDARD_DSV2 series). + * The size of virtual machines in the pool. All VMs in a pool are the same size. + * + * For information about available sizes of virtual machines for Cloud Services pools (pools created with + * cloudServiceConfiguration), see Sizes for Cloud Services + * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud + * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the + * Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see Sizes for Virtual Machines + * (Linux) (https://azure.microsoft.com/documentation/articles/virtual-machines-linux-sizes/) or Sizes for Virtual + * Machines (Windows) (https://azure.microsoft.com/documentation/articles/virtual-machines-windows-sizes/). Batch + * supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, STANDARD_DS, and + * STANDARD_DSV2 series). */ @JsonProperty(value = "vmSize") private String vmSize; /* - * Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services - * (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines - * (IaaS). + * Deployment configuration properties. + * + * Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). */ @JsonProperty(value = "deploymentConfiguration") private DeploymentConfiguration deploymentConfiguration; /* - * The number of compute nodes currently in the pool. + * The number of dedicated compute nodes currently in the pool. */ @JsonProperty(value = "currentDedicatedNodes", access = JsonProperty.Access.WRITE_ONLY) private Integer currentDedicatedNodes; @@ -114,29 +113,29 @@ public final class PoolProperties { private Integer currentLowPriorityNodes; /* - * Scale settings for the pool Defines the desired size of the pool. This - * can either be 'fixedScale' where the requested targetDedicatedNodes is - * specified, or 'autoScale' which defines a formula which is periodically - * reevaluated. If this property is not specified, the pool will have a - * fixed scale with 0 targetDedicatedNodes. + * Scale settings for the pool + * + * Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. */ @JsonProperty(value = "scaleSettings") private ScaleSettings scaleSettings; /* * The results and errors from an execution of a pool autoscale formula. - * This property is set only if the pool automatically scales, i.e. - * autoScaleSettings are used. + * + * This property is set only if the pool automatically scales, i.e. autoScaleSettings are used. */ @JsonProperty(value = "autoScaleRun", access = JsonProperty.Access.WRITE_ONLY) private AutoScaleRun autoScaleRun; /* - * Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. - * Enabling this value can reduce the chance of the requested number of - * nodes to be allocated in the pool. If not specified, this value defaults - * to 'Disabled'. + * Whether the pool permits direct communication between nodes. + * + * This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance + * of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. */ @JsonProperty(value = "interNodeCommunication") private InterNodeCommunicationState interNodeCommunication; @@ -148,17 +147,18 @@ public final class PoolProperties { private NetworkConfiguration networkConfiguration; /* - * The number of task slots that can be used to run concurrent tasks on a - * single compute node in the pool. The default value is 1. The maximum - * value is the smaller of 4 times the number of cores of the vmSize of the + * The number of task slots that can be used to run concurrent tasks on a single compute node in the pool. + * + * The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the * pool or 256. */ @JsonProperty(value = "taskSlotsPerNode") private Integer taskSlotsPerNode; /* - * Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Specifies how tasks should be distributed across compute nodes. + * + * If not specified, the default is spread. */ @JsonProperty(value = "taskSchedulingPolicy") private TaskSchedulingPolicy taskSchedulingPolicy; @@ -170,74 +170,96 @@ public final class PoolProperties { private List userAccounts; /* - * A list of name-value pairs associated with the pool as metadata. The - * Batch service does not assign any meaning to metadata; it is solely for - * the use of user code. + * A list of name-value pairs associated with the pool as metadata. + * + * The Batch service does not assign any meaning to metadata; it is solely for the use of user code. */ @JsonProperty(value = "metadata") private List metadata; /* - * A task which is run when a compute node joins a pool in the Azure Batch - * service, or when the compute node is rebooted or reimaged. In an PATCH - * (update) operation, this property can be set to an empty object to - * remove the start task from the pool. + * A task which is run when a compute node joins a pool in the Azure Batch service, or when the compute node is + * rebooted or reimaged. + * + * In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. */ @JsonProperty(value = "startTask") private StartTask startTask; /* - * The list of certificates to be installed on each compute node in the - * pool. For Windows compute nodes, the Batch service installs the - * certificates to the specified certificate store and location. For Linux - * compute nodes, the certificates are stored in a directory inside the - * task working directory and an environment variable - * AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this - * location. For certificates with visibility of 'remoteUser', a 'certs' - * directory is created in the user's home directory (e.g., + * The list of certificates to be installed on each compute node in the pool. + * + * For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory + * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For + * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. + * + * Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. */ @JsonProperty(value = "certificates") private List certificates; /* - * The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new - * compute nodes joining the pool, but do not affect compute nodes that are - * already in the pool until they are rebooted or reimaged. There is a - * maximum of 10 application package references on any given pool. + * The list of application packages to be installed on each compute node in the pool. + * + * Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * application package references on any given pool. */ @JsonProperty(value = "applicationPackages") private List applicationPackages; /* - * The list of application licenses the Batch service will make available - * on each compute node in the pool. The list of application licenses must - * be a subset of available Batch service application licenses. If a - * license is requested which is not supported, pool creation will fail. + * The list of application licenses the Batch service will make available on each compute node in the pool. + * + * The list of application licenses must be a subset of available Batch service application licenses. If a license + * is requested which is not supported, pool creation will fail. */ @JsonProperty(value = "applicationLicenses") private List applicationLicenses; /* - * Details about the current or last completed resize operation. Describes - * either the current operation (if the pool AllocationState is Resizing) - * or the previously completed operation (if the AllocationState is - * Steady). + * Details about the current or last completed resize operation. + * + * Describes either the current operation (if the pool AllocationState is Resizing) or the previously completed + * operation (if the AllocationState is Steady). */ @JsonProperty(value = "resizeOperationStatus", access = JsonProperty.Access.WRITE_ONLY) private ResizeOperationStatus resizeOperationStatus; /* - * A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * A list of file systems to mount on each node in the pool. + * + * This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. */ @JsonProperty(value = "mountConfiguration") private List mountConfiguration; + /* + * Determines how a pool communicates with the Batch service. + * + * If omitted, the default value is Default. + */ + @JsonProperty(value = "targetNodeCommunicationMode") + private NodeCommunicationMode targetNodeCommunicationMode; + + /* + * Determines how a pool communicates with the Batch service. + */ + @JsonProperty(value = "currentNodeCommunicationMode", access = JsonProperty.Access.WRITE_ONLY) + private NodeCommunicationMode currentNodeCommunicationMode; + + /** Creates an instance of PoolProperties class. */ + public PoolProperties() { + } + /** - * Get the displayName property: The display name for the pool. The display name need not be unique and can contain - * any Unicode characters up to a maximum length of 1024. + * Get the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. * * @return the displayName value. */ @@ -246,8 +268,9 @@ public String displayName() { } /** - * Set the displayName property: The display name for the pool. The display name need not be unique and can contain - * any Unicode characters up to a maximum length of 1024. + * Set the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. * * @param displayName the displayName value to set. * @return the PoolProperties object itself. @@ -258,9 +281,10 @@ public PoolProperties withDisplayName(String displayName) { } /** - * Get the lastModified property: The last modified time of the pool. This is the last time at which the pool level - * data, such as the targetDedicatedNodes or autoScaleSettings, changed. It does not factor in node-level changes - * such as a compute node changing state. + * Get the lastModified property: The last modified time of the pool. + * + *

This is the last time at which the pool level data, such as the targetDedicatedNodes or autoScaleSettings, + * changed. It does not factor in node-level changes such as a compute node changing state. * * @return the lastModified value. */ @@ -314,8 +338,9 @@ public OffsetDateTime allocationStateTransitionTime() { } /** - * Get the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with + * Get the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the @@ -332,8 +357,9 @@ public String vmSize() { } /** - * Set the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with + * Set the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the @@ -352,9 +378,10 @@ public PoolProperties withVmSize(String vmSize) { } /** - * Get the deploymentConfiguration property: Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration - * uses Azure Virtual Machines (IaaS). + * Get the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * * @return the deploymentConfiguration value. */ @@ -363,9 +390,10 @@ public DeploymentConfiguration deploymentConfiguration() { } /** - * Set the deploymentConfiguration property: Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration - * uses Azure Virtual Machines (IaaS). + * Set the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * * @param deploymentConfiguration the deploymentConfiguration value to set. * @return the PoolProperties object itself. @@ -376,7 +404,7 @@ public PoolProperties withDeploymentConfiguration(DeploymentConfiguration deploy } /** - * Get the currentDedicatedNodes property: The number of compute nodes currently in the pool. + * Get the currentDedicatedNodes property: The number of dedicated compute nodes currently in the pool. * * @return the currentDedicatedNodes value. */ @@ -394,10 +422,11 @@ public Integer currentLowPriorityNodes() { } /** - * Get the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. This can either - * be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a formula - * which is periodically reevaluated. If this property is not specified, the pool will have a fixed scale with 0 - * targetDedicatedNodes. + * Get the scaleSettings property: Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. * * @return the scaleSettings value. */ @@ -406,10 +435,11 @@ public ScaleSettings scaleSettings() { } /** - * Set the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. This can either - * be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a formula - * which is periodically reevaluated. If this property is not specified, the pool will have a fixed scale with 0 - * targetDedicatedNodes. + * Set the scaleSettings property: Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. * * @param scaleSettings the scaleSettings value to set. * @return the PoolProperties object itself. @@ -420,8 +450,9 @@ public PoolProperties withScaleSettings(ScaleSettings scaleSettings) { } /** - * Get the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. This - * property is set only if the pool automatically scales, i.e. autoScaleSettings are used. + * Get the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. + * + *

This property is set only if the pool automatically scales, i.e. autoScaleSettings are used. * * @return the autoScaleRun value. */ @@ -430,9 +461,11 @@ public AutoScaleRun autoScaleRun() { } /** - * Get the interNodeCommunication property: Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of the - * requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + * Get the interNodeCommunication property: Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the + * chance of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. * * @return the interNodeCommunication value. */ @@ -441,9 +474,11 @@ public InterNodeCommunicationState interNodeCommunication() { } /** - * Set the interNodeCommunication property: Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of the - * requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + * Set the interNodeCommunication property: Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the + * chance of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. * * @param interNodeCommunication the interNodeCommunication value to set. * @return the PoolProperties object itself. @@ -475,8 +510,10 @@ public PoolProperties withNetworkConfiguration(NetworkConfiguration networkConfi /** * Get the taskSlotsPerNode property: The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the number of cores - * of the vmSize of the pool or 256. + * compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the + * pool or 256. * * @return the taskSlotsPerNode value. */ @@ -486,8 +523,10 @@ public Integer taskSlotsPerNode() { /** * Set the taskSlotsPerNode property: The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the number of cores - * of the vmSize of the pool or 256. + * compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the + * pool or 256. * * @param taskSlotsPerNode the taskSlotsPerNode value to set. * @return the PoolProperties object itself. @@ -498,8 +537,9 @@ public PoolProperties withTaskSlotsPerNode(Integer taskSlotsPerNode) { } /** - * Get the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Get the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. + * + *

If not specified, the default is spread. * * @return the taskSchedulingPolicy value. */ @@ -508,8 +548,9 @@ public TaskSchedulingPolicy taskSchedulingPolicy() { } /** - * Set the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Set the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. + * + *

If not specified, the default is spread. * * @param taskSchedulingPolicy the taskSchedulingPolicy value to set. * @return the PoolProperties object itself. @@ -540,8 +581,9 @@ public PoolProperties withUserAccounts(List userAccounts) { } /** - * Get the metadata property: A list of name-value pairs associated with the pool as metadata. The Batch service - * does not assign any meaning to metadata; it is solely for the use of user code. + * Get the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * * @return the metadata value. */ @@ -550,8 +592,9 @@ public List metadata() { } /** - * Set the metadata property: A list of name-value pairs associated with the pool as metadata. The Batch service - * does not assign any meaning to metadata; it is solely for the use of user code. + * Set the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * * @param metadata the metadata value to set. * @return the PoolProperties object itself. @@ -563,8 +606,10 @@ public PoolProperties withMetadata(List metadata) { /** * Get the startTask property: A task which is run when a compute node joins a pool in the Azure Batch service, or - * when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to an - * empty object to remove the start task from the pool. + * when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. * * @return the startTask value. */ @@ -574,8 +619,10 @@ public StartTask startTask() { /** * Set the startTask property: A task which is run when a compute node joins a pool in the Azure Batch service, or - * when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to an - * empty object to remove the start task from the pool. + * when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. * * @param startTask the startTask value to set. * @return the PoolProperties object itself. @@ -586,13 +633,17 @@ public PoolProperties withStartTask(StartTask startTask) { } /** - * Get the certificates property: The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * Get the certificates property: The list of certificates to be installed on each compute node in the pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @return the certificates value. */ public List certificates() { @@ -600,13 +651,17 @@ public List certificates() { } /** - * Set the certificates property: The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * Set the certificates property: The list of certificates to be installed on each compute node in the pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param certificates the certificates value to set. * @return the PoolProperties object itself. */ @@ -617,8 +672,10 @@ public PoolProperties withCertificates(List certificates) /** * Get the applicationPackages property: The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new compute nodes joining the pool, but do not - * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 * application package references on any given pool. * * @return the applicationPackages value. @@ -629,8 +686,10 @@ public List applicationPackages() { /** * Set the applicationPackages property: The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new compute nodes joining the pool, but do not - * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 * application package references on any given pool. * * @param applicationPackages the applicationPackages value to set. @@ -643,8 +702,10 @@ public PoolProperties withApplicationPackages(List /** * Get the applicationLicenses property: The list of application licenses the Batch service will make available on - * each compute node in the pool. The list of application licenses must be a subset of available Batch service - * application licenses. If a license is requested which is not supported, pool creation will fail. + * each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If a + * license is requested which is not supported, pool creation will fail. * * @return the applicationLicenses value. */ @@ -654,8 +715,10 @@ public List applicationLicenses() { /** * Set the applicationLicenses property: The list of application licenses the Batch service will make available on - * each compute node in the pool. The list of application licenses must be a subset of available Batch service - * application licenses. If a license is requested which is not supported, pool creation will fail. + * each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If a + * license is requested which is not supported, pool creation will fail. * * @param applicationLicenses the applicationLicenses value to set. * @return the PoolProperties object itself. @@ -666,9 +729,10 @@ public PoolProperties withApplicationLicenses(List applicationLicenses) } /** - * Get the resizeOperationStatus property: Details about the current or last completed resize operation. Describes - * either the current operation (if the pool AllocationState is Resizing) or the previously completed operation (if - * the AllocationState is Steady). + * Get the resizeOperationStatus property: Details about the current or last completed resize operation. + * + *

Describes either the current operation (if the pool AllocationState is Resizing) or the previously completed + * operation (if the AllocationState is Steady). * * @return the resizeOperationStatus value. */ @@ -677,8 +741,9 @@ public ResizeOperationStatus resizeOperationStatus() { } /** - * Get the mountConfiguration property: A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * Get the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * * @return the mountConfiguration value. */ @@ -687,8 +752,9 @@ public List mountConfiguration() { } /** - * Set the mountConfiguration property: A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * Set the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * * @param mountConfiguration the mountConfiguration value to set. * @return the PoolProperties object itself. @@ -698,6 +764,39 @@ public PoolProperties withMountConfiguration(List mountConfi return this; } + /** + * Get the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + *

If omitted, the default value is Default. + * + * @return the targetNodeCommunicationMode value. + */ + public NodeCommunicationMode targetNodeCommunicationMode() { + return this.targetNodeCommunicationMode; + } + + /** + * Set the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + *

If omitted, the default value is Default. + * + * @param targetNodeCommunicationMode the targetNodeCommunicationMode value to set. + * @return the PoolProperties object itself. + */ + public PoolProperties withTargetNodeCommunicationMode(NodeCommunicationMode targetNodeCommunicationMode) { + this.targetNodeCommunicationMode = targetNodeCommunicationMode; + return this; + } + + /** + * Get the currentNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + * @return the currentNodeCommunicationMode value. + */ + public NodeCommunicationMode currentNodeCommunicationMode() { + return this.currentNodeCommunicationMode; + } + /** * Validates the instance. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionInner.java index 973622967360..aaec6a9277dc 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionInner.java @@ -10,6 +10,7 @@ import com.azure.resourcemanager.batch.models.PrivateEndpointConnectionProvisioningState; import com.azure.resourcemanager.batch.models.PrivateLinkServiceConnectionState; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; /** Contains information about a private link resource. */ @Fluent @@ -26,6 +27,10 @@ public final class PrivateEndpointConnectionInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of PrivateEndpointConnectionInner class. */ + public PrivateEndpointConnectionInner() { + } + /** * Get the innerProperties property: The properties associated with the private endpoint connection. * @@ -63,17 +68,14 @@ public PrivateEndpoint privateEndpoint() { } /** - * Set the privateEndpoint property: The private endpoint of the private endpoint connection. + * Get the groupIds property: The group id of the private endpoint connection. * - * @param privateEndpoint the privateEndpoint value to set. - * @return the PrivateEndpointConnectionInner object itself. + *

The value has one and only one group id. + * + * @return the groupIds value. */ - public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privateEndpoint) { - if (this.innerProperties() == null) { - this.innerProperties = new PrivateEndpointConnectionProperties(); - } - this.innerProperties().withPrivateEndpoint(privateEndpoint); - return this; + public List groupIds() { + return this.innerProperties() == null ? null : this.innerProperties().groupIds(); } /** diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionProperties.java index 076a6c9ffb69..088aed42c069 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateEndpointConnectionProperties.java @@ -9,6 +9,7 @@ import com.azure.resourcemanager.batch.models.PrivateEndpointConnectionProvisioningState; import com.azure.resourcemanager.batch.models.PrivateLinkServiceConnectionState; import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; /** Private endpoint connection properties. */ @Fluent @@ -22,16 +23,27 @@ public final class PrivateEndpointConnectionProperties { /* * The private endpoint of the private endpoint connection. */ - @JsonProperty(value = "privateEndpoint") + @JsonProperty(value = "privateEndpoint", access = JsonProperty.Access.WRITE_ONLY) private PrivateEndpoint privateEndpoint; /* - * The private link service connection state of the private endpoint - * connection + * The group id of the private endpoint connection. + * + * The value has one and only one group id. + */ + @JsonProperty(value = "groupIds", access = JsonProperty.Access.WRITE_ONLY) + private List groupIds; + + /* + * The private link service connection state of the private endpoint connection */ @JsonProperty(value = "privateLinkServiceConnectionState") private PrivateLinkServiceConnectionState privateLinkServiceConnectionState; + /** Creates an instance of PrivateEndpointConnectionProperties class. */ + public PrivateEndpointConnectionProperties() { + } + /** * Get the provisioningState property: The provisioning state of the private endpoint connection. * @@ -51,14 +63,14 @@ public PrivateEndpoint privateEndpoint() { } /** - * Set the privateEndpoint property: The private endpoint of the private endpoint connection. + * Get the groupIds property: The group id of the private endpoint connection. * - * @param privateEndpoint the privateEndpoint value to set. - * @return the PrivateEndpointConnectionProperties object itself. + *

The value has one and only one group id. + * + * @return the groupIds value. */ - public PrivateEndpointConnectionProperties withPrivateEndpoint(PrivateEndpoint privateEndpoint) { - this.privateEndpoint = privateEndpoint; - return this; + public List groupIds() { + return this.groupIds; } /** diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceInner.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceInner.java index abe922b3e699..c85e83fad5bc 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceInner.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceInner.java @@ -4,13 +4,13 @@ package com.azure.resourcemanager.batch.fluent.models; -import com.azure.core.annotation.Fluent; +import com.azure.core.annotation.Immutable; import com.azure.core.management.ProxyResource; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Contains information about a private link resource. */ -@Fluent +@Immutable public final class PrivateLinkResourceInner extends ProxyResource { /* * The properties associated with the private link resource. @@ -24,6 +24,10 @@ public final class PrivateLinkResourceInner extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of PrivateLinkResourceInner class. */ + public PrivateLinkResourceInner() { + } + /** * Get the innerProperties property: The properties associated with the private link resource. * @@ -43,8 +47,9 @@ public String etag() { } /** - * Get the groupId property: The group id of the private link resource. The group id is used to establish the - * private link connection. + * Get the groupId property: The group id of the private link resource. + * + *

The group id is used to establish the private link connection. * * @return the groupId value. */ diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceProperties.java index c883154d128c..8e8d81829506 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/fluent/models/PrivateLinkResourceProperties.java @@ -12,15 +12,15 @@ @Immutable public final class PrivateLinkResourceProperties { /* - * The group id of the private link resource. The group id is used to - * establish the private link connection. + * The group id of the private link resource. + * + * The group id is used to establish the private link connection. */ @JsonProperty(value = "groupId", access = JsonProperty.Access.WRITE_ONLY) private String groupId; /* - * The list of required members that are used to establish the private link - * connection. + * The list of required members that are used to establish the private link connection. */ @JsonProperty(value = "requiredMembers", access = JsonProperty.Access.WRITE_ONLY) private List requiredMembers; @@ -31,9 +31,14 @@ public final class PrivateLinkResourceProperties { @JsonProperty(value = "requiredZoneNames", access = JsonProperty.Access.WRITE_ONLY) private List requiredZoneNames; + /** Creates an instance of PrivateLinkResourceProperties class. */ + public PrivateLinkResourceProperties() { + } + /** - * Get the groupId property: The group id of the private link resource. The group id is used to establish the - * private link connection. + * Get the groupId property: The group id of the private link resource. + * + *

The group id is used to establish the private link connection. * * @return the groupId 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 index cbd5bfded755..9cdabc6337f8 100644 --- 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 @@ -30,6 +30,10 @@ public final class SupportedSkuInner { @JsonProperty(value = "capabilities", access = JsonProperty.Access.WRITE_ONLY) private List capabilities; + /** Creates an instance of SupportedSkuInner class. */ + public SupportedSkuInner() { + } + /** * Get the name property: The name of the SKU. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationImpl.java index e0d83b6bdbb7..c2b473a36edd 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationImpl.java @@ -41,6 +41,10 @@ public String defaultVersion() { return this.innerModel().defaultVersion(); } + public String resourceGroupName() { + return resourceGroupName; + } + public ApplicationInner innerModel() { return this.innerObject; } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackageImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackageImpl.java index 632f8bd304f6..289f09ead0db 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackageImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackageImpl.java @@ -131,16 +131,16 @@ public ApplicationPackage refresh(Context context) { return this; } - public ApplicationPackage activate(ActivateApplicationPackageParameters parameters) { + public Response activateWithResponse( + ActivateApplicationPackageParameters parameters, Context context) { return serviceManager .applicationPackages() - .activate(resourceGroupName, accountName, applicationName, versionName, parameters); + .activateWithResponse(resourceGroupName, accountName, applicationName, versionName, parameters, context); } - public Response activateWithResponse( - ActivateApplicationPackageParameters parameters, Context context) { + public ApplicationPackage activate(ActivateApplicationPackageParameters parameters) { return serviceManager .applicationPackages() - .activateWithResponse(resourceGroupName, accountName, applicationName, versionName, parameters, context); + .activate(resourceGroupName, accountName, applicationName, versionName, parameters); } } 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 2403ac1de5e4..727f52930fd9 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 @@ -325,14 +325,7 @@ private Mono activateAsync( String versionName, ActivateApplicationPackageParameters parameters) { return activateWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -344,19 +337,24 @@ private Mono activateAsync( * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. * @param parameters The parameters for the request. + * @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 an application package which represents a particular version of an application. + * @return an application package which represents a particular version of an application along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ApplicationPackageInner activate( + public Response activateWithResponse( String resourceGroupName, String accountName, String applicationName, String versionName, - ActivateApplicationPackageParameters parameters) { - return activateAsync(resourceGroupName, accountName, applicationName, versionName, parameters).block(); + ActivateApplicationPackageParameters parameters, + Context context) { + return activateWithResponseAsync( + resourceGroupName, accountName, applicationName, versionName, parameters, context) + .block(); } /** @@ -368,24 +366,21 @@ public ApplicationPackageInner activate( * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. * @param parameters The parameters for the request. - * @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 an application package which represents a particular version of an application along with {@link - * Response}. + * @return an application package which represents a particular version of an application. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response activateWithResponse( + public ApplicationPackageInner activate( String resourceGroupName, String accountName, String applicationName, String versionName, - ActivateApplicationPackageParameters parameters, - Context context) { - return activateWithResponseAsync( - resourceGroupName, accountName, applicationName, versionName, parameters, context) - .block(); + ActivateApplicationPackageParameters parameters) { + return activateWithResponse( + resourceGroupName, accountName, applicationName, versionName, parameters, Context.NONE) + .getValue(); } /** @@ -538,7 +533,6 @@ private Mono> createWithResponseAsync( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. - * @param parameters The parameters for the request. * @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. @@ -547,20 +541,10 @@ private Mono> createWithResponseAsync( */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createAsync( - String resourceGroupName, - String accountName, - String applicationName, - String versionName, - ApplicationPackageInner parameters) { + String resourceGroupName, String accountName, String applicationName, String versionName) { + final ApplicationPackageInner parameters = null; return createWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -572,25 +556,25 @@ private Mono createAsync( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @param parameters The parameters for the request. + * @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 an application package which represents a particular version of an application on successful completion - * of {@link Mono}. + * @return an application package which represents a particular version of an application along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( - String resourceGroupName, String accountName, String applicationName, String versionName) { - final ApplicationPackageInner parameters = null; - return createWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + public Response createWithResponse( + String resourceGroupName, + String accountName, + String applicationName, + String versionName, + ApplicationPackageInner parameters, + Context context) { + return createWithResponseAsync( + resourceGroupName, accountName, applicationName, versionName, parameters, context) + .block(); } /** @@ -611,37 +595,9 @@ private Mono createAsync( public ApplicationPackageInner create( String resourceGroupName, String accountName, String applicationName, String versionName) { final ApplicationPackageInner parameters = null; - return createAsync(resourceGroupName, accountName, applicationName, versionName, parameters).block(); - } - - /** - * 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. - * @param applicationName The name of the application. This must be unique within the account. - * @param versionName The version of the application. - * @param parameters The parameters for the request. - * @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 an application package which represents a particular version of an application along with {@link - * Response}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response createWithResponse( - String resourceGroupName, - String accountName, - String applicationName, - String versionName, - ApplicationPackageInner parameters, - Context context) { - return createWithResponseAsync( - resourceGroupName, accountName, applicationName, versionName, parameters, context) - .block(); + return createWithResponse( + resourceGroupName, accountName, applicationName, versionName, parameters, Context.NONE) + .getValue(); } /** @@ -776,7 +732,7 @@ private Mono> deleteWithResponseAsync( private Mono deleteAsync( String resourceGroupName, String accountName, String applicationName, String versionName) { return deleteWithResponseAsync(resourceGroupName, accountName, applicationName, versionName) - .flatMap((Response res) -> Mono.empty()); + .flatMap(ignored -> Mono.empty()); } /** @@ -786,13 +742,16 @@ private Mono deleteAsync( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public void delete(String resourceGroupName, String accountName, String applicationName, String versionName) { - deleteAsync(resourceGroupName, accountName, applicationName, versionName).block(); + public Response deleteWithResponse( + String resourceGroupName, String accountName, String applicationName, String versionName, Context context) { + return deleteWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, context).block(); } /** @@ -802,16 +761,13 @@ public void delete(String resourceGroupName, String accountName, String applicat * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. - * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response deleteWithResponse( - String resourceGroupName, String accountName, String applicationName, String versionName, Context context) { - return deleteWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, context).block(); + public void delete(String resourceGroupName, String accountName, String applicationName, String versionName) { + deleteWithResponse(resourceGroupName, accountName, applicationName, versionName, Context.NONE); } /** @@ -948,14 +904,7 @@ private Mono> getWithResponseAsync( private Mono getAsync( String resourceGroupName, String accountName, String applicationName, String versionName) { return getWithResponseAsync(resourceGroupName, accountName, applicationName, versionName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -965,15 +914,16 @@ private Mono getAsync( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @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 information about the specified application package. + * @return information about the specified application package along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ApplicationPackageInner get( - String resourceGroupName, String accountName, String applicationName, String versionName) { - return getAsync(resourceGroupName, accountName, applicationName, versionName).block(); + public Response getWithResponse( + String resourceGroupName, String accountName, String applicationName, String versionName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, context).block(); } /** @@ -983,16 +933,15 @@ public ApplicationPackageInner get( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. - * @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 information about the specified application package along with {@link Response}. + * @return information about the specified application package. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getWithResponse( - String resourceGroupName, String accountName, String applicationName, String versionName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, applicationName, versionName, context).block(); + public ApplicationPackageInner get( + String resourceGroupName, String accountName, String applicationName, String versionName) { + return getWithResponse(resourceGroupName, accountName, applicationName, versionName, Context.NONE).getValue(); } /** @@ -1226,7 +1175,8 @@ public PagedIterable list( /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -1262,7 +1212,8 @@ private Mono> listNextSinglePageAsync(Str /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesImpl.java index bc05610c9e0a..01ec4382df0c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationPackagesImpl.java @@ -28,21 +28,6 @@ public ApplicationPackagesImpl( this.serviceManager = serviceManager; } - public ApplicationPackage activate( - String resourceGroupName, - String accountName, - String applicationName, - String versionName, - ActivateApplicationPackageParameters parameters) { - ApplicationPackageInner inner = - this.serviceClient().activate(resourceGroupName, accountName, applicationName, versionName, parameters); - if (inner != null) { - return new ApplicationPackageImpl(inner, this.manager()); - } else { - return null; - } - } - public Response activateWithResponse( String resourceGroupName, String accountName, @@ -66,8 +51,19 @@ public Response activateWithResponse( } } - public void delete(String resourceGroupName, String accountName, String applicationName, String versionName) { - this.serviceClient().delete(resourceGroupName, accountName, applicationName, versionName); + public ApplicationPackage activate( + String resourceGroupName, + String accountName, + String applicationName, + String versionName, + ActivateApplicationPackageParameters parameters) { + ApplicationPackageInner inner = + this.serviceClient().activate(resourceGroupName, accountName, applicationName, versionName, parameters); + if (inner != null) { + return new ApplicationPackageImpl(inner, this.manager()); + } else { + return null; + } } public Response deleteWithResponse( @@ -77,15 +73,8 @@ public Response deleteWithResponse( .deleteWithResponse(resourceGroupName, accountName, applicationName, versionName, context); } - public ApplicationPackage get( - String resourceGroupName, String accountName, String applicationName, String versionName) { - ApplicationPackageInner inner = - this.serviceClient().get(resourceGroupName, accountName, applicationName, versionName); - if (inner != null) { - return new ApplicationPackageImpl(inner, this.manager()); - } else { - return null; - } + public void delete(String resourceGroupName, String accountName, String applicationName, String versionName) { + this.serviceClient().delete(resourceGroupName, accountName, applicationName, versionName); } public Response getWithResponse( @@ -103,6 +92,17 @@ public Response getWithResponse( } } + public ApplicationPackage get( + String resourceGroupName, String accountName, String applicationName, String versionName) { + ApplicationPackageInner inner = + this.serviceClient().get(resourceGroupName, accountName, applicationName, versionName); + if (inner != null) { + return new ApplicationPackageImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable list( String resourceGroupName, String accountName, String applicationName) { PagedIterable inner = diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsClientImpl.java index 8a674ddbb454..fefa1324dcc2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsClientImpl.java @@ -281,24 +281,16 @@ private Mono> createWithResponseAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. - * @param parameters The parameters for the request. * @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 contains information about an application in a Batch account on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( - String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters) { + private Mono createAsync(String resourceGroupName, String accountName, String applicationName) { + final ApplicationInner parameters = null; return createWithResponseAsync(resourceGroupName, accountName, applicationName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -307,23 +299,21 @@ private Mono createAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. + * @param parameters The parameters for the request. + * @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 contains information about an application in a Batch account on successful completion of {@link Mono}. + * @return contains information about an application in a Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync(String resourceGroupName, String accountName, String applicationName) { - final ApplicationInner parameters = null; - return createWithResponseAsync(resourceGroupName, accountName, applicationName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + public Response createWithResponse( + String resourceGroupName, + String accountName, + String applicationName, + ApplicationInner parameters, + Context context) { + return createWithResponseAsync(resourceGroupName, accountName, applicationName, parameters, context).block(); } /** @@ -340,30 +330,7 @@ private Mono createAsync(String resourceGroupName, String acco @ServiceMethod(returns = ReturnType.SINGLE) public ApplicationInner create(String resourceGroupName, String accountName, String applicationName) { final ApplicationInner parameters = null; - return createAsync(resourceGroupName, accountName, applicationName, parameters).block(); - } - - /** - * Adds an application to the specified Batch account. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param applicationName The name of the application. This must be unique within the account. - * @param parameters The parameters for the request. - * @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 contains information about an application in a Batch account along with {@link Response}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response createWithResponse( - String resourceGroupName, - String accountName, - String applicationName, - ApplicationInner parameters, - Context context) { - return createWithResponseAsync(resourceGroupName, accountName, applicationName, parameters, context).block(); + return createWithResponse(resourceGroupName, accountName, applicationName, parameters, Context.NONE).getValue(); } /** @@ -486,7 +453,7 @@ private Mono> deleteWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String accountName, String applicationName) { return deleteWithResponseAsync(resourceGroupName, accountName, applicationName) - .flatMap((Response res) -> Mono.empty()); + .flatMap(ignored -> Mono.empty()); } /** @@ -495,13 +462,16 @@ private Mono deleteAsync(String resourceGroupName, String accountName, Str * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public void delete(String resourceGroupName, String accountName, String applicationName) { - deleteAsync(resourceGroupName, accountName, applicationName).block(); + public Response deleteWithResponse( + String resourceGroupName, String accountName, String applicationName, Context context) { + return deleteWithResponseAsync(resourceGroupName, accountName, applicationName, context).block(); } /** @@ -510,16 +480,13 @@ public void delete(String resourceGroupName, String accountName, String applicat * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response deleteWithResponse( - String resourceGroupName, String accountName, String applicationName, Context context) { - return deleteWithResponseAsync(resourceGroupName, accountName, applicationName, context).block(); + public void delete(String resourceGroupName, String accountName, String applicationName) { + deleteWithResponse(resourceGroupName, accountName, applicationName, Context.NONE); } /** @@ -644,14 +611,7 @@ private Mono> getWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync(String resourceGroupName, String accountName, String applicationName) { return getWithResponseAsync(resourceGroupName, accountName, applicationName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -660,14 +620,16 @@ private Mono getAsync(String resourceGroupName, String account * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 information about the specified application. + * @return information about the specified application along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ApplicationInner get(String resourceGroupName, String accountName, String applicationName) { - return getAsync(resourceGroupName, accountName, applicationName).block(); + public Response getWithResponse( + String resourceGroupName, String accountName, String applicationName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, applicationName, context).block(); } /** @@ -676,16 +638,14 @@ public ApplicationInner get(String resourceGroupName, String accountName, String * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 information about the specified application along with {@link Response}. + * @return information about the specified application. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getWithResponse( - String resourceGroupName, String accountName, String applicationName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, applicationName, context).block(); + public ApplicationInner get(String resourceGroupName, String accountName, String applicationName) { + return getWithResponse(resourceGroupName, accountName, applicationName, Context.NONE).getValue(); } /** @@ -830,14 +790,7 @@ private Mono> updateWithResponseAsync( private Mono updateAsync( String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters) { return updateWithResponseAsync(resourceGroupName, accountName, applicationName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -847,15 +800,20 @@ private Mono updateAsync( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param parameters The parameters for the request. + * @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 contains information about an application in a Batch account. + * @return contains information about an application in a Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ApplicationInner update( - String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters) { - return updateAsync(resourceGroupName, accountName, applicationName, parameters).block(); + public Response updateWithResponse( + String resourceGroupName, + String accountName, + String applicationName, + ApplicationInner parameters, + Context context) { + return updateWithResponseAsync(resourceGroupName, accountName, applicationName, parameters, context).block(); } /** @@ -865,20 +823,15 @@ public ApplicationInner update( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param parameters The parameters for the request. - * @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 contains information about an application in a Batch account along with {@link Response}. + * @return contains information about an application in a Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response updateWithResponse( - String resourceGroupName, - String accountName, - String applicationName, - ApplicationInner parameters, - Context context) { - return updateWithResponseAsync(resourceGroupName, accountName, applicationName, parameters, context).block(); + public ApplicationInner update( + String resourceGroupName, String accountName, String applicationName, ApplicationInner parameters) { + return updateWithResponse(resourceGroupName, accountName, applicationName, parameters, Context.NONE).getValue(); } /** @@ -1092,7 +1045,8 @@ public PagedIterable list( /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -1128,7 +1082,8 @@ private Mono> listNextSinglePageAsync(String nex /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsImpl.java index 6ccb71d0f7f8..580fc1408adb 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/ApplicationsImpl.java @@ -27,22 +27,13 @@ public ApplicationsImpl( this.serviceManager = serviceManager; } - public void delete(String resourceGroupName, String accountName, String applicationName) { - this.serviceClient().delete(resourceGroupName, accountName, applicationName); - } - public Response deleteWithResponse( String resourceGroupName, String accountName, String applicationName, Context context) { return this.serviceClient().deleteWithResponse(resourceGroupName, accountName, applicationName, context); } - public Application get(String resourceGroupName, String accountName, String applicationName) { - ApplicationInner inner = this.serviceClient().get(resourceGroupName, accountName, applicationName); - if (inner != null) { - return new ApplicationImpl(inner, this.manager()); - } else { - return null; - } + public void delete(String resourceGroupName, String accountName, String applicationName) { + this.serviceClient().delete(resourceGroupName, accountName, applicationName); } public Response getWithResponse( @@ -60,6 +51,15 @@ public Response getWithResponse( } } + public Application get(String resourceGroupName, String accountName, String applicationName) { + ApplicationInner inner = this.serviceClient().get(resourceGroupName, accountName, applicationName); + if (inner != null) { + return new ApplicationImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable list(String resourceGroupName, String accountName) { PagedIterable inner = this.serviceClient().list(resourceGroupName, accountName); return Utils.mapPage(inner, inner1 -> new ApplicationImpl(inner1, this.manager())); 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 31a3e1ed8831..128293eccf65 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 @@ -20,6 +20,7 @@ import com.azure.resourcemanager.batch.models.BatchAccountUpdateParameters; import com.azure.resourcemanager.batch.models.EncryptionProperties; import com.azure.resourcemanager.batch.models.KeyVaultReference; +import com.azure.resourcemanager.batch.models.NetworkProfile; import com.azure.resourcemanager.batch.models.PoolAllocationMode; import com.azure.resourcemanager.batch.models.PrivateEndpointConnection; import com.azure.resourcemanager.batch.models.ProvisioningState; @@ -68,6 +69,10 @@ public String accountEndpoint() { return this.innerModel().accountEndpoint(); } + public String nodeManagementEndpoint() { + return this.innerModel().nodeManagementEndpoint(); + } + public ProvisioningState provisioningState() { return this.innerModel().provisioningState(); } @@ -84,6 +89,10 @@ public PublicNetworkAccessType publicNetworkAccess() { return this.innerModel().publicNetworkAccess(); } + public NetworkProfile networkProfile() { + return this.innerModel().networkProfile(); + } + public List privateEndpointConnections() { List inner = this.innerModel().privateEndpointConnections(); if (inner != null) { @@ -152,6 +161,10 @@ public String regionName() { return this.location(); } + public String resourceGroupName() { + return resourceGroupName; + } + public BatchAccountInner innerModel() { return this.innerObject; } @@ -250,18 +263,14 @@ public BatchAccount refresh(Context context) { return this; } - public void synchronizeAutoStorageKeys() { - serviceManager.batchAccounts().synchronizeAutoStorageKeys(resourceGroupName, accountName); - } - public Response synchronizeAutoStorageKeysWithResponse(Context context) { return serviceManager .batchAccounts() .synchronizeAutoStorageKeysWithResponse(resourceGroupName, accountName, context); } - public BatchAccountKeys regenerateKey(BatchAccountRegenerateKeyParameters parameters) { - return serviceManager.batchAccounts().regenerateKey(resourceGroupName, accountName, parameters); + public void synchronizeAutoStorageKeys() { + serviceManager.batchAccounts().synchronizeAutoStorageKeys(resourceGroupName, accountName); } public Response regenerateKeyWithResponse( @@ -271,14 +280,18 @@ public Response regenerateKeyWithResponse( .regenerateKeyWithResponse(resourceGroupName, accountName, parameters, context); } - public BatchAccountKeys getKeys() { - return serviceManager.batchAccounts().getKeys(resourceGroupName, accountName); + public BatchAccountKeys regenerateKey(BatchAccountRegenerateKeyParameters parameters) { + return serviceManager.batchAccounts().regenerateKey(resourceGroupName, accountName, parameters); } public Response getKeysWithResponse(Context context) { return serviceManager.batchAccounts().getKeysWithResponse(resourceGroupName, accountName, context); } + public BatchAccountKeys getKeys() { + return serviceManager.batchAccounts().getKeys(resourceGroupName, accountName); + } + public BatchAccountImpl withRegion(Region location) { this.createParameters.withLocation(location.toString()); return this; @@ -330,8 +343,23 @@ public BatchAccountImpl withKeyVaultReference(KeyVaultReference keyVaultReferenc } public BatchAccountImpl withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess) { - this.createParameters.withPublicNetworkAccess(publicNetworkAccess); - return this; + if (isInCreateMode()) { + this.createParameters.withPublicNetworkAccess(publicNetworkAccess); + return this; + } else { + this.updateParameters.withPublicNetworkAccess(publicNetworkAccess); + return this; + } + } + + public BatchAccountImpl withNetworkProfile(NetworkProfile networkProfile) { + if (isInCreateMode()) { + this.createParameters.withNetworkProfile(networkProfile); + return this; + } else { + this.updateParameters.withNetworkProfile(networkProfile); + return this; + } } public BatchAccountImpl withEncryption(EncryptionProperties encryption) { 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 336ca4c6e914..51c34f8428ba 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 @@ -727,14 +727,7 @@ private Mono> updateWithResponseAsync( private Mono updateAsync( String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters) { return updateWithResponseAsync(resourceGroupName, accountName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -743,15 +736,16 @@ private Mono updateAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters Additional parameters for account update. + * @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 contains information about an Azure Batch account. + * @return contains information about an Azure Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public BatchAccountInner update( - String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters) { - return updateAsync(resourceGroupName, accountName, parameters).block(); + public Response updateWithResponse( + String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters, Context context) { + return updateWithResponseAsync(resourceGroupName, accountName, parameters, context).block(); } /** @@ -760,16 +754,15 @@ public BatchAccountInner update( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters Additional parameters for account update. - * @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 contains information about an Azure Batch account along with {@link Response}. + * @return contains information about an Azure Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response updateWithResponse( - String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters, Context context) { - return updateWithResponseAsync(resourceGroupName, accountName, parameters, context).block(); + public BatchAccountInner update( + String resourceGroupName, String accountName, BatchAccountUpdateParameters parameters) { + return updateWithResponse(resourceGroupName, accountName, parameters, Context.NONE).getValue(); } /** @@ -1108,14 +1101,7 @@ private Mono> getByResourceGroupWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono getByResourceGroupAsync(String resourceGroupName, String accountName) { return getByResourceGroupWithResponseAsync(resourceGroupName, accountName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -1123,14 +1109,16 @@ private Mono getByResourceGroupAsync(String resourceGroupName * * @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 information about the specified Batch account. + * @return information about the specified Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public BatchAccountInner getByResourceGroup(String resourceGroupName, String accountName) { - return getByResourceGroupAsync(resourceGroupName, accountName).block(); + public Response getByResourceGroupWithResponse( + String resourceGroupName, String accountName, Context context) { + return getByResourceGroupWithResponseAsync(resourceGroupName, accountName, context).block(); } /** @@ -1138,16 +1126,14 @@ public BatchAccountInner getByResourceGroup(String resourceGroupName, String acc * * @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 information about the specified Batch account along with {@link Response}. + * @return information about the specified Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getByResourceGroupWithResponse( - String resourceGroupName, String accountName, Context context) { - return getByResourceGroupWithResponseAsync(resourceGroupName, accountName, context).block(); + public BatchAccountInner getByResourceGroup(String resourceGroupName, String accountName) { + return getByResourceGroupWithResponse(resourceGroupName, accountName, Context.NONE).getValue(); } /** @@ -1575,7 +1561,7 @@ private Mono> synchronizeAutoStorageKeysWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono synchronizeAutoStorageKeysAsync(String resourceGroupName, String accountName) { return synchronizeAutoStorageKeysWithResponseAsync(resourceGroupName, accountName) - .flatMap((Response res) -> Mono.empty()); + .flatMap(ignored -> Mono.empty()); } /** @@ -1584,13 +1570,16 @@ private Mono synchronizeAutoStorageKeysAsync(String resourceGroupName, Str * * @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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public void synchronizeAutoStorageKeys(String resourceGroupName, String accountName) { - synchronizeAutoStorageKeysAsync(resourceGroupName, accountName).block(); + public Response synchronizeAutoStorageKeysWithResponse( + String resourceGroupName, String accountName, Context context) { + return synchronizeAutoStorageKeysWithResponseAsync(resourceGroupName, accountName, context).block(); } /** @@ -1599,20 +1588,19 @@ public void synchronizeAutoStorageKeys(String resourceGroupName, String accountN * * @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 the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response synchronizeAutoStorageKeysWithResponse( - String resourceGroupName, String accountName, Context context) { - return synchronizeAutoStorageKeysWithResponseAsync(resourceGroupName, accountName, context).block(); + public void synchronizeAutoStorageKeys(String resourceGroupName, String accountName) { + synchronizeAutoStorageKeysWithResponse(resourceGroupName, accountName, Context.NONE); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -1670,7 +1658,9 @@ private Mono> regenerateKeyWithResponseAsync( } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -1726,7 +1716,9 @@ private Mono> regenerateKeyWithResponseAsync( } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -1743,18 +1735,13 @@ private Mono> regenerateKeyWithResponseAsync( private Mono regenerateKeyAsync( String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters) { return regenerateKeyWithResponseAsync(resourceGroupName, accountName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -1762,19 +1749,22 @@ private Mono regenerateKeyAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public BatchAccountKeysInner regenerateKey( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters) { - return regenerateKeyAsync(resourceGroupName, accountName, parameters).block(); + public Response regenerateKeyWithResponse( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context) { + return regenerateKeyWithResponseAsync(resourceGroupName, accountName, parameters, context).block(); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -1782,20 +1772,21 @@ public BatchAccountKeysInner regenerateKey( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response regenerateKeyWithResponse( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context) { - return regenerateKeyWithResponseAsync(resourceGroupName, accountName, parameters, context).block(); + public BatchAccountKeysInner regenerateKey( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters) { + return regenerateKeyWithResponse(resourceGroupName, accountName, parameters, Context.NONE).getValue(); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, getting the keys will fail. * @@ -1845,7 +1836,9 @@ private Mono> getKeysWithResponseAsync( } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, getting the keys will fail. * @@ -1893,7 +1886,9 @@ private Mono> getKeysWithResponseAsync( } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, getting the keys will fail. * @@ -1907,50 +1902,47 @@ private Mono> getKeysWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono getKeysAsync(String resourceGroupName, String accountName) { return getKeysWithResponseAsync(resourceGroupName, accountName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public BatchAccountKeysInner getKeys(String resourceGroupName, String accountName) { - return getKeysAsync(resourceGroupName, accountName).block(); + public Response getKeysWithResponse( + String resourceGroupName, String accountName, Context context) { + return getKeysWithResponseAsync(resourceGroupName, accountName, context).block(); } /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getKeysWithResponse( - String resourceGroupName, String accountName, Context context) { - return getKeysWithResponseAsync(resourceGroupName, accountName, context).block(); + public BatchAccountKeysInner getKeys(String resourceGroupName, String accountName) { + return getKeysWithResponse(resourceGroupName, accountName, Context.NONE).getValue(); } /** @@ -2260,14 +2252,7 @@ private Mono> getDetectorWithResponseAsync( private Mono getDetectorAsync( String resourceGroupName, String accountName, String detectorId) { return getDetectorWithResponseAsync(resourceGroupName, accountName, detectorId) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -2276,14 +2261,16 @@ private Mono getDetectorAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. + * @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 information about the given detector for a given Batch account. + * @return information about the given detector for a given Batch account along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public DetectorResponseInner getDetector(String resourceGroupName, String accountName, String detectorId) { - return getDetectorAsync(resourceGroupName, accountName, detectorId).block(); + public Response getDetectorWithResponse( + String resourceGroupName, String accountName, String detectorId, Context context) { + return getDetectorWithResponseAsync(resourceGroupName, accountName, detectorId, context).block(); } /** @@ -2292,16 +2279,14 @@ public DetectorResponseInner getDetector(String resourceGroupName, String accoun * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. - * @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 information about the given detector for a given Batch account along with {@link Response}. + * @return information about the given detector for a given Batch account. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getDetectorWithResponse( - String resourceGroupName, String accountName, String detectorId, Context context) { - return getDetectorWithResponseAsync(resourceGroupName, accountName, detectorId, context).block(); + public DetectorResponseInner getDetector(String resourceGroupName, String accountName, String detectorId) { + return getDetectorWithResponse(resourceGroupName, accountName, detectorId, Context.NONE).getValue(); } /** @@ -2517,7 +2502,8 @@ public PagedIterable listOutboundNetworkDepend /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2553,7 +2539,8 @@ private Mono> listNextSinglePageAsync(String ne /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2590,7 +2577,8 @@ private Mono> listNextSinglePageAsync(String ne /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2627,7 +2615,8 @@ private Mono> listByResourceGroupNextSinglePage /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2665,7 +2654,8 @@ private Mono> listByResourceGroupNextSinglePage /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2701,7 +2691,8 @@ private Mono> listDetectorsNextSinglePageAs /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2739,7 +2730,8 @@ private Mono> listDetectorsNextSinglePageAs /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -2780,7 +2772,8 @@ private Mono> listDetectorsNextSinglePageAs /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. 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 d302aef0aa1e..85b0221e423c 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 @@ -42,15 +42,6 @@ public void delete(String resourceGroupName, String accountName, Context context this.serviceClient().delete(resourceGroupName, accountName, context); } - public BatchAccount getByResourceGroup(String resourceGroupName, String accountName) { - BatchAccountInner inner = this.serviceClient().getByResourceGroup(resourceGroupName, accountName); - if (inner != null) { - return new BatchAccountImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getByResourceGroupWithResponse( String resourceGroupName, String accountName, Context context) { Response inner = @@ -66,6 +57,15 @@ public Response getByResourceGroupWithResponse( } } + public BatchAccount getByResourceGroup(String resourceGroupName, String accountName) { + BatchAccountInner inner = this.serviceClient().getByResourceGroup(resourceGroupName, accountName); + if (inner != null) { + return new BatchAccountImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable list() { PagedIterable inner = this.serviceClient().list(); return Utils.mapPage(inner, inner1 -> new BatchAccountImpl(inner1, this.manager())); @@ -86,23 +86,13 @@ public PagedIterable listByResourceGroup(String resourceGroupName, return Utils.mapPage(inner, inner1 -> new BatchAccountImpl(inner1, this.manager())); } - public void synchronizeAutoStorageKeys(String resourceGroupName, String accountName) { - this.serviceClient().synchronizeAutoStorageKeys(resourceGroupName, accountName); - } - public Response synchronizeAutoStorageKeysWithResponse( String resourceGroupName, String accountName, Context context) { return this.serviceClient().synchronizeAutoStorageKeysWithResponse(resourceGroupName, accountName, context); } - public BatchAccountKeys regenerateKey( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters) { - BatchAccountKeysInner inner = this.serviceClient().regenerateKey(resourceGroupName, accountName, parameters); - if (inner != null) { - return new BatchAccountKeysImpl(inner, this.manager()); - } else { - return null; - } + public void synchronizeAutoStorageKeys(String resourceGroupName, String accountName) { + this.serviceClient().synchronizeAutoStorageKeys(resourceGroupName, accountName); } public Response regenerateKeyWithResponse( @@ -120,8 +110,9 @@ public Response regenerateKeyWithResponse( } } - public BatchAccountKeys getKeys(String resourceGroupName, String accountName) { - BatchAccountKeysInner inner = this.serviceClient().getKeys(resourceGroupName, accountName); + public BatchAccountKeys regenerateKey( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters) { + BatchAccountKeysInner inner = this.serviceClient().regenerateKey(resourceGroupName, accountName, parameters); if (inner != null) { return new BatchAccountKeysImpl(inner, this.manager()); } else { @@ -144,6 +135,15 @@ public Response getKeysWithResponse( } } + public BatchAccountKeys getKeys(String resourceGroupName, String accountName) { + BatchAccountKeysInner inner = this.serviceClient().getKeys(resourceGroupName, accountName); + if (inner != null) { + return new BatchAccountKeysImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable listDetectors(String resourceGroupName, String accountName) { PagedIterable inner = this.serviceClient().listDetectors(resourceGroupName, accountName); return Utils.mapPage(inner, inner1 -> new DetectorResponseImpl(inner1, this.manager())); @@ -156,15 +156,6 @@ public PagedIterable listDetectors( return Utils.mapPage(inner, inner1 -> new DetectorResponseImpl(inner1, this.manager())); } - public DetectorResponse getDetector(String resourceGroupName, String accountName, String detectorId) { - DetectorResponseInner inner = this.serviceClient().getDetector(resourceGroupName, accountName, detectorId); - if (inner != null) { - return new DetectorResponseImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getDetectorWithResponse( String resourceGroupName, String accountName, String detectorId, Context context) { Response inner = @@ -180,6 +171,15 @@ public Response getDetectorWithResponse( } } + public DetectorResponse getDetector(String resourceGroupName, String accountName, String detectorId) { + DetectorResponseInner inner = this.serviceClient().getDetector(resourceGroupName, accountName, detectorId); + if (inner != null) { + return new DetectorResponseImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable listOutboundNetworkDependenciesEndpoints( String resourceGroupName, String accountName) { PagedIterable inner = diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientBuilder.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientBuilder.java index b8c93ae89743..d5c9fc108f26 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientBuilder.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientBuilder.java @@ -7,7 +7,6 @@ import com.azure.core.annotation.ServiceClientBuilder; import com.azure.core.http.HttpPipeline; import com.azure.core.http.HttpPipelineBuilder; -import com.azure.core.http.policy.CookiePolicy; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; import com.azure.core.management.AzureEnvironment; @@ -19,8 +18,7 @@ @ServiceClientBuilder(serviceClients = {BatchManagementClientImpl.class}) public final class BatchManagementClientBuilder { /* - * The Azure subscription ID. This is a GUID-formatted string (e.g. - * 00000000-0000-0000-0000-000000000000) + * The Azure subscription ID. This is a GUID-formatted string (e.g. 00000000-0000-0000-0000-000000000000) */ private String subscriptionId; @@ -68,34 +66,34 @@ public BatchManagementClientBuilder environment(AzureEnvironment environment) { } /* - * The default poll interval for long-running operation + * The HTTP pipeline to send requests through */ - private Duration defaultPollInterval; + private HttpPipeline pipeline; /** - * Sets The default poll interval for long-running operation. + * Sets The HTTP pipeline to send requests through. * - * @param defaultPollInterval the defaultPollInterval value. + * @param pipeline the pipeline value. * @return the BatchManagementClientBuilder. */ - public BatchManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) { - this.defaultPollInterval = defaultPollInterval; + public BatchManagementClientBuilder pipeline(HttpPipeline pipeline) { + this.pipeline = pipeline; return this; } /* - * The HTTP pipeline to send requests through + * The default poll interval for long-running operation */ - private HttpPipeline pipeline; + private Duration defaultPollInterval; /** - * Sets The HTTP pipeline to send requests through. + * Sets The default poll interval for long-running operation. * - * @param pipeline the pipeline value. + * @param defaultPollInterval the defaultPollInterval value. * @return the BatchManagementClientBuilder. */ - public BatchManagementClientBuilder pipeline(HttpPipeline pipeline) { - this.pipeline = pipeline; + public BatchManagementClientBuilder defaultPollInterval(Duration defaultPollInterval) { + this.defaultPollInterval = defaultPollInterval; return this; } @@ -121,27 +119,26 @@ public BatchManagementClientBuilder serializerAdapter(SerializerAdapter serializ * @return an instance of BatchManagementClientImpl. */ public BatchManagementClientImpl buildClient() { - if (endpoint == null) { - this.endpoint = "https://management.azure.com"; - } - if (environment == null) { - this.environment = AzureEnvironment.AZURE; - } - if (defaultPollInterval == null) { - this.defaultPollInterval = Duration.ofSeconds(30); - } - if (pipeline == null) { - this.pipeline = - new HttpPipelineBuilder() - .policies(new UserAgentPolicy(), new RetryPolicy(), new CookiePolicy()) - .build(); - } - if (serializerAdapter == null) { - this.serializerAdapter = SerializerFactory.createDefaultManagementSerializerAdapter(); - } + String localEndpoint = (endpoint != null) ? endpoint : "https://management.azure.com"; + AzureEnvironment localEnvironment = (environment != null) ? environment : AzureEnvironment.AZURE; + HttpPipeline localPipeline = + (pipeline != null) + ? pipeline + : new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build(); + Duration localDefaultPollInterval = + (defaultPollInterval != null) ? defaultPollInterval : Duration.ofSeconds(30); + SerializerAdapter localSerializerAdapter = + (serializerAdapter != null) + ? serializerAdapter + : SerializerFactory.createDefaultManagementSerializerAdapter(); BatchManagementClientImpl client = new BatchManagementClientImpl( - pipeline, serializerAdapter, defaultPollInterval, environment, subscriptionId, endpoint); + localPipeline, + localSerializerAdapter, + localDefaultPollInterval, + localEnvironment, + subscriptionId, + localEndpoint); return client; } } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientImpl.java index 135451de7dac..74c88b27e64a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/BatchManagementClientImpl.java @@ -15,6 +15,7 @@ import com.azure.core.management.polling.PollResult; import com.azure.core.management.polling.PollerFactory; import com.azure.core.util.Context; +import com.azure.core.util.CoreUtils; import com.azure.core.util.logging.ClientLogger; import com.azure.core.util.polling.AsyncPollResponse; import com.azure.core.util.polling.LongRunningOperationStatus; @@ -37,7 +38,6 @@ import java.nio.charset.Charset; import java.nio.charset.StandardCharsets; import java.time.Duration; -import java.util.Map; import reactor.core.publisher.Flux; import reactor.core.publisher.Mono; @@ -247,7 +247,7 @@ public PoolsClient getPools() { this.defaultPollInterval = defaultPollInterval; this.subscriptionId = subscriptionId; this.endpoint = endpoint; - this.apiVersion = "2022-01-01"; + this.apiVersion = "2022-10-01"; this.batchAccounts = new BatchAccountsClientImpl(this); this.applicationPackages = new ApplicationPackagesClientImpl(this); this.applications = new ApplicationsClientImpl(this); @@ -275,10 +275,7 @@ public Context getContext() { * @return the merged context. */ public Context mergeContext(Context context) { - for (Map.Entry entry : this.getContext().getValues().entrySet()) { - context = context.addData(entry.getKey(), entry.getValue()); - } - return context; + return CoreUtils.mergeContexts(this.getContext(), context); } /** 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 27e2e73c8edc..316e7684798f 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 @@ -71,6 +71,10 @@ public CertificateFormat format() { return this.innerModel().format(); } + public String resourceGroupName() { + return resourceGroupName; + } + public CertificateInner innerModel() { return this.innerObject; } @@ -200,24 +204,14 @@ public Certificate refresh(Context context) { return this; } - public Certificate cancelDeletion() { - return serviceManager.certificates().cancelDeletion(resourceGroupName, accountName, certificateName); - } - public Response cancelDeletionWithResponse(Context context) { return serviceManager .certificates() .cancelDeletionWithResponse(resourceGroupName, accountName, certificateName, context); } - public CertificateImpl withData(String data) { - if (isInCreateMode()) { - this.createParameters.withData(data); - return this; - } else { - this.updateParameters.withData(data); - return this; - } + public Certificate cancelDeletion() { + return serviceManager.certificates().cancelDeletion(resourceGroupName, accountName, certificateName); } public CertificateImpl withPassword(String password) { @@ -275,6 +269,11 @@ public CertificateImpl withIfNoneMatch(String ifNoneMatch) { return this; } + public CertificateImpl withData(String data) { + this.updateParameters.withData(data); + 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/CertificatesClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesClientImpl.java index 502fa574292b..5c96c19cdef0 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesClientImpl.java @@ -188,6 +188,9 @@ Mono> listByBatchAccountNext( /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -254,6 +257,9 @@ private Mono> listByBatchAccountSinglePageAsync( /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -323,6 +329,9 @@ private Mono> listByBatchAccountSinglePageAsync( /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -346,6 +355,9 @@ private PagedFlux listByBatchAccountAsync( /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @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. @@ -366,6 +378,9 @@ private PagedFlux listByBatchAccountAsync(String resourceGroup /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -396,6 +411,9 @@ private PagedFlux listByBatchAccountAsync( /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @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. @@ -414,6 +432,9 @@ public PagedIterable listByBatchAccount(String resourceGroupNa /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -442,6 +463,9 @@ public PagedIterable listByBatchAccount( /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -515,6 +539,9 @@ private Mono createWithResponseAsync( /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -587,42 +614,8 @@ private Mono createWithResponseAsync( /** * Creates a new certificate inside the specified account. * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint - * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @param parameters Additional parameters for certificate creation. - * @param ifMatch The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply - * the operation only if the certificate already exists. If omitted, this operation will always be applied. - * @param ifNoneMatch Set to '*' to allow a new certificate to be created, but to prevent updating an existing - * certificate. Other values will be ignored. - * @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 contains information about a certificate on successful completion of {@link Mono}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( - String resourceGroupName, - String accountName, - String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch, - String ifNoneMatch) { - return createWithResponseAsync( - resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch) - .flatMap( - (CertificatesCreateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * Creates a new certificate inside the specified account. + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. @@ -644,75 +637,79 @@ private Mono createAsync( final String ifNoneMatch = null; return createWithResponseAsync( resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch) - .flatMap( - (CertificatesCreateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Additional parameters for certificate creation. + * @param ifMatch The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply + * the operation only if the certificate already exists. If omitted, this operation will always be applied. + * @param ifNoneMatch Set to '*' to allow a new certificate to be created, but to prevent updating an existing + * certificate. Other values will be ignored. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificateInner create( + public CertificatesCreateResponse createWithResponse( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters) { - final String ifMatch = null; - final String ifNoneMatch = null; - return createAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch).block(); + CertificateCreateOrUpdateParameters parameters, + String ifMatch, + String ifNoneMatch, + Context context) { + return createWithResponseAsync( + resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch, context) + .block(); } /** * Creates a new certificate inside the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Additional parameters for certificate creation. - * @param ifMatch The entity state (ETag) version of the certificate to update. A value of "*" can be used to apply - * the operation only if the certificate already exists. If omitted, this operation will always be applied. - * @param ifNoneMatch Set to '*' to allow a new certificate to be created, but to prevent updating an existing - * certificate. Other values will be ignored. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificatesCreateResponse createWithResponse( + public CertificateInner create( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch, - String ifNoneMatch, - Context context) { - return createWithResponseAsync( - resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch, context) - .block(); + CertificateCreateOrUpdateParameters parameters) { + final String ifMatch = null; + final String ifNoneMatch = null; + return createWithResponse( + resourceGroupName, accountName, certificateName, parameters, ifMatch, ifNoneMatch, Context.NONE) + .getValue(); } /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -782,6 +779,9 @@ private Mono updateWithResponseAsync( /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -850,38 +850,8 @@ private Mono updateWithResponseAsync( /** * Updates the properties of an existing certificate. * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint - * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @param parameters Certificate entity to update. - * @param ifMatch The entity state (ETag) version of the certificate to update. This value can be omitted or set to - * "*" to apply the operation unconditionally. - * @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 contains information about a certificate on successful completion of {@link Mono}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono updateAsync( - String resourceGroupName, - String accountName, - String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch) { - return updateWithResponseAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch) - .flatMap( - (CertificatesUpdateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * Updates the properties of an existing certificate. + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. @@ -901,70 +871,73 @@ private Mono updateAsync( CertificateCreateOrUpdateParameters parameters) { final String ifMatch = null; return updateWithResponseAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch) - .flatMap( - (CertificatesUpdateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Certificate entity to update. + * @param ifMatch The entity state (ETag) version of the certificate to update. This value can be omitted or set to + * "*" to apply the operation unconditionally. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificateInner update( + public CertificatesUpdateResponse updateWithResponse( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters) { - final String ifMatch = null; - return updateAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch).block(); + CertificateCreateOrUpdateParameters parameters, + String ifMatch, + Context context) { + return updateWithResponseAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch, context) + .block(); } /** * Updates the properties of an existing certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. * @param parameters Certificate entity to update. - * @param ifMatch The entity state (ETag) version of the certificate to update. This value can be omitted or set to - * "*" to apply the operation unconditionally. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificatesUpdateResponse updateWithResponse( + public CertificateInner update( String resourceGroupName, String accountName, String certificateName, - CertificateCreateOrUpdateParameters parameters, - String ifMatch, - Context context) { - return updateWithResponseAsync(resourceGroupName, accountName, certificateName, parameters, ifMatch, context) - .block(); + CertificateCreateOrUpdateParameters parameters) { + final String ifMatch = null; + return updateWithResponse(resourceGroupName, accountName, certificateName, parameters, ifMatch, Context.NONE) + .getValue(); } /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1020,6 +993,9 @@ private Mono>> deleteWithResponseAsync( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1073,6 +1049,9 @@ private Mono>> deleteWithResponseAsync( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1096,6 +1075,9 @@ private PollerFlux, Void> beginDeleteAsync( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1120,6 +1102,9 @@ private PollerFlux, Void> beginDeleteAsync( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1138,6 +1123,9 @@ public SyncPoller, Void> beginDelete( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1157,6 +1145,9 @@ public SyncPoller, Void> beginDelete( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1176,6 +1167,9 @@ private Mono deleteAsync(String resourceGroupName, String accountName, Str /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1197,6 +1191,9 @@ private Mono deleteAsync( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1213,6 +1210,9 @@ public void delete(String resourceGroupName, String accountName, String certific /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1230,6 +1230,9 @@ public void delete(String resourceGroupName, String accountName, String certific /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1237,7 +1240,7 @@ public void delete(String resourceGroupName, String accountName, String certific * @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 information about the specified certificate on successful completion of {@link Mono}. + * @return contains information about a certificate on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getWithResponseAsync( @@ -1285,6 +1288,9 @@ private Mono getWithResponseAsync( /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1293,7 +1299,7 @@ private Mono getWithResponseAsync( * @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 information about the specified certificate on successful completion of {@link Mono}. + * @return contains information about a certificate on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getWithResponseAsync( @@ -1338,6 +1344,9 @@ private Mono getWithResponseAsync( /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1345,64 +1354,68 @@ private Mono getWithResponseAsync( * @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 information about the specified certificate on successful completion of {@link Mono}. + * @return contains information about a certificate on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync(String resourceGroupName, String accountName, String certificateName) { return getWithResponseAsync(resourceGroupName, accountName, certificateName) - .flatMap( - (CertificatesGetResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 information about the specified certificate. + * @return contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificateInner get(String resourceGroupName, String accountName, String certificateName) { - return getAsync(resourceGroupName, accountName, certificateName).block(); + public CertificatesGetResponse getWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, certificateName, context).block(); } /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 information about the specified certificate. + * @return contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificatesGetResponse getWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, certificateName, context).block(); + public CertificateInner get(String resourceGroupName, String accountName, String certificateName) { + return getWithResponse(resourceGroupName, accountName, certificateName, Context.NONE).getValue(); } /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1456,12 +1469,17 @@ private Mono cancelDeletionWithResponseAsync } /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1513,12 +1531,17 @@ private Mono cancelDeletionWithResponseAsync } /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -1532,64 +1555,68 @@ private Mono cancelDeletionWithResponseAsync private Mono cancelDeletionAsync( String resourceGroupName, String accountName, String certificateName) { return cancelDeletionWithResponseAsync(resourceGroupName, accountName, certificateName) - .flatMap( - (CertificatesCancelDeletionResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificateInner cancelDeletion(String resourceGroupName, String accountName, String certificateName) { - return cancelDeletionAsync(resourceGroupName, accountName, certificateName).block(); + public CertificatesCancelDeletionResponse cancelDeletionWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context) { + return cancelDeletionWithResponseAsync(resourceGroupName, accountName, certificateName, context).block(); } /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 contains information about a certificate. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CertificatesCancelDeletionResponse cancelDeletionWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context) { - return cancelDeletionWithResponseAsync(resourceGroupName, accountName, certificateName, context).block(); + public CertificateInner cancelDeletion(String resourceGroupName, String accountName, String certificateName) { + return cancelDeletionWithResponse(resourceGroupName, accountName, certificateName, Context.NONE).getValue(); } /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -1626,7 +1653,8 @@ private Mono> listByBatchAccountNextSinglePageAs /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesImpl.java index ccdb5c4852b4..645967a112a5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/CertificatesImpl.java @@ -56,15 +56,6 @@ public void delete(String resourceGroupName, String accountName, String certific this.serviceClient().delete(resourceGroupName, accountName, certificateName, context); } - public Certificate get(String resourceGroupName, String accountName, String certificateName) { - CertificateInner inner = this.serviceClient().get(resourceGroupName, accountName, certificateName); - if (inner != null) { - return new CertificateImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getWithResponse( String resourceGroupName, String accountName, String certificateName, Context context) { CertificatesGetResponse inner = @@ -80,8 +71,8 @@ public Response getWithResponse( } } - public Certificate cancelDeletion(String resourceGroupName, String accountName, String certificateName) { - CertificateInner inner = this.serviceClient().cancelDeletion(resourceGroupName, accountName, certificateName); + public Certificate get(String resourceGroupName, String accountName, String certificateName) { + CertificateInner inner = this.serviceClient().get(resourceGroupName, accountName, certificateName); if (inner != null) { return new CertificateImpl(inner, this.manager()); } else { @@ -104,6 +95,15 @@ public Response cancelDeletionWithResponse( } } + public Certificate cancelDeletion(String resourceGroupName, String accountName, String certificateName) { + CertificateInner inner = this.serviceClient().cancelDeletion(resourceGroupName, accountName, certificateName); + if (inner != null) { + return new CertificateImpl(inner, this.manager()); + } else { + return null; + } + } + public Certificate 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/LocationsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/LocationsClientImpl.java index 4d842fcc962e..b3d8816f728c 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 @@ -230,45 +230,37 @@ private Mono> getQuotasWithResponseAsync(Strin */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getQuotasAsync(String locationName) { - return getQuotasWithResponseAsync(locationName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + return getQuotasWithResponseAsync(locationName).flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. + * @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 service quotas for the specified subscription at the given location. + * @return the Batch service quotas for the specified subscription at the given location along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public BatchLocationQuotaInner getQuotas(String locationName) { - return getQuotasAsync(locationName).block(); + public Response getQuotasWithResponse(String locationName, Context context) { + return getQuotasWithResponseAsync(locationName, context).block(); } /** * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. - * @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 service quotas for the specified subscription at the given location along with {@link - * Response}. + * @return the Batch service quotas for the specified subscription at the given location. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getQuotasWithResponse(String locationName, Context context) { - return getQuotasWithResponseAsync(locationName, context).block(); + public BatchLocationQuotaInner getQuotas(String locationName) { + return getQuotasWithResponse(locationName, Context.NONE).getValue(); } /** @@ -795,14 +787,7 @@ private Mono> checkNameAvailabilityWi private Mono checkNameAvailabilityAsync( String locationName, CheckNameAvailabilityParameters parameters) { return checkNameAvailabilityWithResponseAsync(locationName, parameters) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -810,15 +795,16 @@ private Mono checkNameAvailabilityAsync( * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. + * @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 CheckNameAvailability operation response. + * @return the CheckNameAvailability operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public CheckNameAvailabilityResultInner checkNameAvailability( - String locationName, CheckNameAvailabilityParameters parameters) { - return checkNameAvailabilityAsync(locationName, parameters).block(); + public Response checkNameAvailabilityWithResponse( + String locationName, CheckNameAvailabilityParameters parameters, Context context) { + return checkNameAvailabilityWithResponseAsync(locationName, parameters, context).block(); } /** @@ -826,22 +812,22 @@ public CheckNameAvailabilityResultInner checkNameAvailability( * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. - * @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 CheckNameAvailability operation response along with {@link Response}. + * @return the CheckNameAvailability operation response. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response checkNameAvailabilityWithResponse( - String locationName, CheckNameAvailabilityParameters parameters, Context context) { - return checkNameAvailabilityWithResponseAsync(locationName, parameters, context).block(); + public CheckNameAvailabilityResultInner checkNameAvailability( + String locationName, CheckNameAvailabilityParameters parameters) { + return checkNameAvailabilityWithResponse(locationName, parameters, Context.NONE).getValue(); } /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -879,7 +865,8 @@ private Mono> listSupportedVirtualMachineSkusNe /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -917,7 +904,8 @@ private Mono> listSupportedVirtualMachineSkusNe /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -955,7 +943,8 @@ private Mono> listSupportedCloudServiceSkusNext /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. 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 83203b95783e..2e0170ddd322 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 @@ -31,15 +31,6 @@ public LocationsImpl(LocationsClient innerClient, com.azure.resourcemanager.batc this.serviceManager = serviceManager; } - public BatchLocationQuota getQuotas(String locationName) { - BatchLocationQuotaInner inner = this.serviceClient().getQuotas(locationName); - if (inner != null) { - return new BatchLocationQuotaImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getQuotasWithResponse(String locationName, Context context) { Response inner = this.serviceClient().getQuotasWithResponse(locationName, context); if (inner != null) { @@ -53,6 +44,15 @@ public Response getQuotasWithResponse(String locationName, C } } + public BatchLocationQuota getQuotas(String locationName) { + BatchLocationQuotaInner inner = this.serviceClient().getQuotas(locationName); + if (inner != null) { + return new BatchLocationQuotaImpl(inner, this.manager()); + } else { + return null; + } + } + public PagedIterable listSupportedVirtualMachineSkus(String locationName) { PagedIterable inner = this.serviceClient().listSupportedVirtualMachineSkus(locationName); return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager())); @@ -77,16 +77,6 @@ public PagedIterable listSupportedCloudServiceSkus( return Utils.mapPage(inner, inner1 -> new SupportedSkuImpl(inner1, this.manager())); } - public CheckNameAvailabilityResult checkNameAvailability( - String locationName, CheckNameAvailabilityParameters parameters) { - CheckNameAvailabilityResultInner inner = this.serviceClient().checkNameAvailability(locationName, parameters); - if (inner != null) { - return new CheckNameAvailabilityResultImpl(inner, this.manager()); - } else { - return null; - } - } - public Response checkNameAvailabilityWithResponse( String locationName, CheckNameAvailabilityParameters parameters, Context context) { Response inner = @@ -102,6 +92,16 @@ public Response checkNameAvailabilityWithResponse( } } + public CheckNameAvailabilityResult checkNameAvailability( + String locationName, CheckNameAvailabilityParameters parameters) { + CheckNameAvailabilityResultInner inner = this.serviceClient().checkNameAvailability(locationName, parameters); + if (inner != null) { + return new CheckNameAvailabilityResultImpl(inner, this.manager()); + } else { + return null; + } + } + private LocationsClient serviceClient() { return this.innerClient; } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationsClientImpl.java index cf2835db87ed..96f137e6dfe3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationsClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/OperationsClientImpl.java @@ -198,7 +198,8 @@ public PagedIterable list(Context context) { /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -234,7 +235,8 @@ private Mono> listNextSinglePageAsync(String nextL /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. 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 e6029187b779..5ad8fab32f02 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 @@ -17,6 +17,7 @@ import com.azure.resourcemanager.batch.models.MetadataItem; import com.azure.resourcemanager.batch.models.MountConfiguration; import com.azure.resourcemanager.batch.models.NetworkConfiguration; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.Pool; import com.azure.resourcemanager.batch.models.PoolProvisioningState; import com.azure.resourcemanager.batch.models.ResizeOperationStatus; @@ -183,6 +184,18 @@ public List mountConfiguration() { } } + public NodeCommunicationMode targetNodeCommunicationMode() { + return this.innerModel().targetNodeCommunicationMode(); + } + + public NodeCommunicationMode currentNodeCommunicationMode() { + return this.innerModel().currentNodeCommunicationMode(); + } + + public String resourceGroupName() { + return resourceGroupName; + } + public PoolInner innerModel() { return this.innerObject; } @@ -305,22 +318,22 @@ public Pool refresh(Context context) { return this; } - public Pool disableAutoScale() { - return serviceManager.pools().disableAutoScale(resourceGroupName, accountName, poolName); - } - public Response disableAutoScaleWithResponse(Context context) { return serviceManager.pools().disableAutoScaleWithResponse(resourceGroupName, accountName, poolName, context); } - public Pool stopResize() { - return serviceManager.pools().stopResize(resourceGroupName, accountName, poolName); + public Pool disableAutoScale() { + return serviceManager.pools().disableAutoScale(resourceGroupName, accountName, poolName); } public Response stopResizeWithResponse(Context context) { return serviceManager.pools().stopResizeWithResponse(resourceGroupName, accountName, poolName, context); } + public Pool stopResize() { + return serviceManager.pools().stopResize(resourceGroupName, accountName, poolName); + } + public PoolImpl withIdentity(BatchPoolIdentity identity) { this.innerModel().withIdentity(identity); return this; @@ -401,6 +414,11 @@ public PoolImpl withMountConfiguration(List mountConfigurati return this; } + public PoolImpl withTargetNodeCommunicationMode(NodeCommunicationMode targetNodeCommunicationMode) { + this.innerModel().withTargetNodeCommunicationMode(targetNodeCommunicationMode); + return this; + } + public PoolImpl withIfMatch(String ifMatch) { if (isInCreateMode()) { this.createIfMatch = ifMatch; diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsClientImpl.java index 6994e69be9f8..8277813bd874 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsClientImpl.java @@ -610,41 +610,6 @@ private Mono createWithResponseAsync( context); } - /** - * Creates a new pool inside the specified account. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param poolName The pool name. This must be unique within the account. - * @param parameters Additional parameters for pool creation. - * @param ifMatch The entity state (ETag) version of the pool to update. A value of "*" can be used to apply the - * operation only if the pool already exists. If omitted, this operation will always be applied. - * @param ifNoneMatch Set to '*' to allow a new pool to be created, but to prevent updating an existing pool. Other - * values will be ignored. - * @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 contains information about a pool on successful completion of {@link Mono}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createAsync( - String resourceGroupName, - String accountName, - String poolName, - PoolInner parameters, - String ifMatch, - String ifNoneMatch) { - return createWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch, ifNoneMatch) - .flatMap( - (PoolsCreateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - /** * Creates a new pool inside the specified account. * @@ -663,33 +628,7 @@ private Mono createAsync( final String ifMatch = null; final String ifNoneMatch = null; return createWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch, ifNoneMatch) - .flatMap( - (PoolsCreateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * Creates a new pool inside the specified account. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param poolName The pool name. This must be unique within the account. - * @param parameters Additional parameters for pool creation. - * @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 contains information about a pool. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public PoolInner create(String resourceGroupName, String accountName, String poolName, PoolInner parameters) { - final String ifMatch = null; - final String ifNoneMatch = null; - return createAsync(resourceGroupName, accountName, poolName, parameters, ifMatch, ifNoneMatch).block(); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -723,6 +662,27 @@ public PoolsCreateResponse createWithResponse( .block(); } + /** + * Creates a new pool inside the specified account. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param poolName The pool name. This must be unique within the account. + * @param parameters Additional parameters for pool creation. + * @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 contains information about a pool. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public PoolInner create(String resourceGroupName, String accountName, String poolName, PoolInner parameters) { + final String ifMatch = null; + final String ifNoneMatch = null; + return createWithResponse( + resourceGroupName, accountName, poolName, parameters, ifMatch, ifNoneMatch, Context.NONE) + .getValue(); + } + /** * Updates the properties of an existing pool. * @@ -854,35 +814,6 @@ private Mono updateWithResponseAsync( context); } - /** - * Updates the properties of an existing pool. - * - * @param resourceGroupName The name of the resource group that contains the Batch account. - * @param accountName The name of the Batch account. - * @param poolName The pool name. This must be unique within the account. - * @param parameters Pool properties that should be updated. Properties that are supplied will be updated, any - * property not supplied will be unchanged. - * @param ifMatch The entity state (ETag) version of the pool to update. This value can be omitted or set to "*" to - * apply the operation unconditionally. - * @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 contains information about a pool on successful completion of {@link Mono}. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono updateAsync( - String resourceGroupName, String accountName, String poolName, PoolInner parameters, String ifMatch) { - return updateWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch) - .flatMap( - (PoolsUpdateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - /** * Updates the properties of an existing pool. * @@ -901,14 +832,7 @@ private Mono updateAsync( String resourceGroupName, String accountName, String poolName, PoolInner parameters) { final String ifMatch = null; return updateWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch) - .flatMap( - (PoolsUpdateResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -919,15 +843,23 @@ private Mono updateAsync( * @param poolName The pool name. This must be unique within the account. * @param parameters Pool properties that should be updated. Properties that are supplied will be updated, any * property not supplied will be unchanged. + * @param ifMatch The entity state (ETag) version of the pool to update. This value can be omitted or set to "*" to + * apply the operation unconditionally. + * @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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolInner update(String resourceGroupName, String accountName, String poolName, PoolInner parameters) { - final String ifMatch = null; - return updateAsync(resourceGroupName, accountName, poolName, parameters, ifMatch).block(); + public PoolsUpdateResponse updateWithResponse( + String resourceGroupName, + String accountName, + String poolName, + PoolInner parameters, + String ifMatch, + Context context) { + return updateWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch, context).block(); } /** @@ -938,23 +870,16 @@ public PoolInner update(String resourceGroupName, String accountName, String poo * @param poolName The pool name. This must be unique within the account. * @param parameters Pool properties that should be updated. Properties that are supplied will be updated, any * property not supplied will be unchanged. - * @param ifMatch The entity state (ETag) version of the pool to update. This value can be omitted or set to "*" to - * apply the operation unconditionally. - * @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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolsUpdateResponse updateWithResponse( - String resourceGroupName, - String accountName, - String poolName, - PoolInner parameters, - String ifMatch, - Context context) { - return updateWithResponseAsync(resourceGroupName, accountName, poolName, parameters, ifMatch, context).block(); + public PoolInner update(String resourceGroupName, String accountName, String poolName, PoolInner parameters) { + final String ifMatch = null; + return updateWithResponse(resourceGroupName, accountName, poolName, parameters, ifMatch, Context.NONE) + .getValue(); } /** @@ -1325,14 +1250,7 @@ private Mono getWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync(String resourceGroupName, String accountName, String poolName) { return getWithResponseAsync(resourceGroupName, accountName, poolName) - .flatMap( - (PoolsGetResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -1341,14 +1259,16 @@ private Mono getAsync(String resourceGroupName, String accountName, S * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolInner get(String resourceGroupName, String accountName, String poolName) { - return getAsync(resourceGroupName, accountName, poolName).block(); + public PoolsGetResponse getWithResponse( + String resourceGroupName, String accountName, String poolName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); } /** @@ -1357,16 +1277,14 @@ public PoolInner get(String resourceGroupName, String accountName, String poolNa * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolsGetResponse getWithResponse( - String resourceGroupName, String accountName, String poolName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); + public PoolInner get(String resourceGroupName, String accountName, String poolName) { + return getWithResponse(resourceGroupName, accountName, poolName, Context.NONE).getValue(); } /** @@ -1487,14 +1405,7 @@ private Mono disableAutoScaleWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono disableAutoScaleAsync(String resourceGroupName, String accountName, String poolName) { return disableAutoScaleWithResponseAsync(resourceGroupName, accountName, poolName) - .flatMap( - (PoolsDisableAutoScaleResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -1503,14 +1414,16 @@ private Mono disableAutoScaleAsync(String resourceGroupName, String a * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolInner disableAutoScale(String resourceGroupName, String accountName, String poolName) { - return disableAutoScaleAsync(resourceGroupName, accountName, poolName).block(); + public PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( + String resourceGroupName, String accountName, String poolName, Context context) { + return disableAutoScaleWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); } /** @@ -1519,20 +1432,20 @@ public PoolInner disableAutoScale(String resourceGroupName, String accountName, * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolsDisableAutoScaleResponse disableAutoScaleWithResponse( - String resourceGroupName, String accountName, String poolName, Context context) { - return disableAutoScaleWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); + public PoolInner disableAutoScale(String resourceGroupName, String accountName, String poolName) { + return disableAutoScaleWithResponse(resourceGroupName, accountName, poolName, Context.NONE).getValue(); } /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -1589,7 +1502,9 @@ private Mono stopResizeWithResponseAsync( } /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -1644,7 +1559,9 @@ private Mono stopResizeWithResponseAsync( } /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -1661,18 +1578,13 @@ private Mono stopResizeWithResponseAsync( @ServiceMethod(returns = ReturnType.SINGLE) private Mono stopResizeAsync(String resourceGroupName, String accountName, String poolName) { return stopResizeWithResponseAsync(resourceGroupName, accountName, poolName) - .flatMap( - (PoolsStopResizeResponse res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -1681,18 +1593,22 @@ private Mono stopResizeAsync(String resourceGroupName, String account * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolInner stopResize(String resourceGroupName, String accountName, String poolName) { - return stopResizeAsync(resourceGroupName, accountName, poolName).block(); + public PoolsStopResizeResponse stopResizeWithResponse( + String resourceGroupName, String accountName, String poolName, Context context) { + return stopResizeWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); } /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -1701,22 +1617,21 @@ public PoolInner stopResize(String resourceGroupName, String accountName, String * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PoolsStopResizeResponse stopResizeWithResponse( - String resourceGroupName, String accountName, String poolName, Context context) { - return stopResizeWithResponseAsync(resourceGroupName, accountName, poolName, context).block(); + public PoolInner stopResize(String resourceGroupName, String accountName, String poolName) { + return stopResizeWithResponse(resourceGroupName, accountName, poolName, Context.NONE).getValue(); } /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -1753,7 +1668,8 @@ private Mono> listByBatchAccountNextSinglePageAsync(Str /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsImpl.java index 20024d7f2133..a74fb9e49284 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PoolsImpl.java @@ -56,15 +56,6 @@ public void delete(String resourceGroupName, String accountName, String poolName this.serviceClient().delete(resourceGroupName, accountName, poolName, context); } - public Pool get(String resourceGroupName, String accountName, String poolName) { - PoolInner inner = this.serviceClient().get(resourceGroupName, accountName, poolName); - if (inner != null) { - return new PoolImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getWithResponse( String resourceGroupName, String accountName, String poolName, Context context) { PoolsGetResponse inner = @@ -80,8 +71,8 @@ public Response getWithResponse( } } - public Pool disableAutoScale(String resourceGroupName, String accountName, String poolName) { - PoolInner inner = this.serviceClient().disableAutoScale(resourceGroupName, accountName, poolName); + public Pool get(String resourceGroupName, String accountName, String poolName) { + PoolInner inner = this.serviceClient().get(resourceGroupName, accountName, poolName); if (inner != null) { return new PoolImpl(inner, this.manager()); } else { @@ -104,8 +95,8 @@ public Response disableAutoScaleWithResponse( } } - public Pool stopResize(String resourceGroupName, String accountName, String poolName) { - PoolInner inner = this.serviceClient().stopResize(resourceGroupName, accountName, poolName); + public Pool disableAutoScale(String resourceGroupName, String accountName, String poolName) { + PoolInner inner = this.serviceClient().disableAutoScale(resourceGroupName, accountName, poolName); if (inner != null) { return new PoolImpl(inner, this.manager()); } else { @@ -128,6 +119,15 @@ public Response stopResizeWithResponse( } } + public Pool stopResize(String resourceGroupName, String accountName, String poolName) { + PoolInner inner = this.serviceClient().stopResize(resourceGroupName, accountName, poolName); + if (inner != null) { + return new PoolImpl(inner, this.manager()); + } else { + return null; + } + } + public Pool 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/PrivateEndpointConnectionImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionImpl.java index 39923cff73b9..3786dd60ece7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionImpl.java @@ -9,6 +9,8 @@ import com.azure.resourcemanager.batch.models.PrivateEndpointConnection; import com.azure.resourcemanager.batch.models.PrivateEndpointConnectionProvisioningState; import com.azure.resourcemanager.batch.models.PrivateLinkServiceConnectionState; +import java.util.Collections; +import java.util.List; public final class PrivateEndpointConnectionImpl implements PrivateEndpointConnection { private PrivateEndpointConnectionInner innerObject; @@ -45,6 +47,15 @@ public PrivateEndpoint privateEndpoint() { return this.innerModel().privateEndpoint(); } + public List groupIds() { + List inner = this.innerModel().groupIds(); + if (inner != null) { + return Collections.unmodifiableList(inner); + } else { + return Collections.emptyList(); + } + } + public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { return this.innerModel().privateLinkServiceConnectionState(); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsClientImpl.java index 2ac9cdf6810e..5b85ee2a1f36 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsClientImpl.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.implementation; import com.azure.core.annotation.BodyParam; +import com.azure.core.annotation.Delete; import com.azure.core.annotation.ExpectedResponses; import com.azure.core.annotation.Get; import com.azure.core.annotation.HeaderParam; @@ -101,7 +102,7 @@ Mono> get( @Patch( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Batch/batchAccounts" + "/{accountName}/privateEndpointConnections/{privateEndpointConnectionName}") - @ExpectedResponses({200, 202, 204}) + @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> update( @HostParam("$host") String endpoint, @@ -115,6 +116,22 @@ Mono>> update( @HeaderParam("Accept") String accept, Context context); + @Headers({"Content-Type: application/json"}) + @Delete( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Batch/batchAccounts" + + "/{accountName}/privateEndpointConnections/{privateEndpointConnectionName}") + @ExpectedResponses({202, 204}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> delete( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("accountName") String accountName, + @PathParam("privateEndpointConnectionName") String privateEndpointConnectionName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + @Headers({"Content-Type: application/json"}) @Get("{nextLink}") @ExpectedResponses({200}) @@ -467,14 +484,7 @@ private Mono> getWithResponseAsync( private Mono getAsync( String resourceGroupName, String accountName, String privateEndpointConnectionName) { return getWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -484,15 +494,16 @@ private Mono getAsync( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection. + * @return information about the specified private endpoint connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PrivateEndpointConnectionInner get( - String resourceGroupName, String accountName, String privateEndpointConnectionName) { - return getAsync(resourceGroupName, accountName, privateEndpointConnectionName).block(); + public Response getWithResponse( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName, context).block(); } /** @@ -502,16 +513,15 @@ public PrivateEndpointConnectionInner get( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection along with {@link Response}. + * @return information about the specified private endpoint connection. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getWithResponse( - String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName, context).block(); + public PrivateEndpointConnectionInner get( + String resourceGroupName, String accountName, String privateEndpointConnectionName) { + return getWithResponse(resourceGroupName, accountName, privateEndpointConnectionName, Context.NONE).getValue(); } /** @@ -694,6 +704,39 @@ private PollerFlux, PrivateEndpointCo this.client.getContext()); } + /** + * Updates the properties of an existing private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * account. + * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will + * be updated, any property not supplied will be unchanged. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of contains information about a private link resource. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, PrivateEndpointConnectionInner> beginUpdateAsync( + String resourceGroupName, + String accountName, + String privateEndpointConnectionName, + PrivateEndpointConnectionInner parameters) { + final String ifMatch = null; + Mono>> mono = + updateWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + PrivateEndpointConnectionInner.class, + PrivateEndpointConnectionInner.class, + this.client.getContext()); + } + /** * Updates the properties of an existing private endpoint connection. * @@ -742,8 +785,6 @@ private PollerFlux, PrivateEndpointCo * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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. @@ -754,8 +795,8 @@ public SyncPoller, PrivateEndpointCon String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch) { + PrivateEndpointConnectionInner parameters) { + final String ifMatch = null; return beginUpdateAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch) .getSyncPoller(); } @@ -884,8 +925,6 @@ private Mono updateAsync( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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. @@ -896,8 +935,8 @@ public PrivateEndpointConnectionInner update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch) { + PrivateEndpointConnectionInner parameters) { + final String ifMatch = null; return updateAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch).block(); } @@ -910,6 +949,9 @@ public PrivateEndpointConnectionInner update( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. + * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted + * or set to "*" to apply the operation unconditionally. + * @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. @@ -920,44 +962,288 @@ public PrivateEndpointConnectionInner update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters) { - final String ifMatch = null; - return updateAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch).block(); + PrivateEndpointConnectionInner parameters, + String ifMatch, + Context context) { + return updateAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch, context) + .block(); } /** - * Updates the properties of an existing private endpoint connection. + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> deleteWithResponseAsync( + String resourceGroupName, String accountName, String privateEndpointConnectionName) { + if (this.client.getEndpoint() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + if (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 (privateEndpointConnectionName == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter privateEndpointConnectionName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + accountName, + privateEndpointConnectionName, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Deletes the specified private endpoint connection. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * account. - * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will - * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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 contains information about a private link resource. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PrivateEndpointConnectionInner update( - String resourceGroupName, - String accountName, - String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch, - Context context) { - return updateAsync(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch, context) - .block(); + private Mono>> deleteWithResponseAsync( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + if (this.client.getEndpoint() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + if (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 (privateEndpointConnectionName == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter privateEndpointConnectionName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .delete( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + accountName, + privateEndpointConnectionName, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String accountName, String privateEndpointConnectionName) { + Mono>> mono = + deleteWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName); + return this + .client + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginDeleteAsync( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + deleteWithResponseAsync(resourceGroupName, accountName, privateEndpointConnectionName, context); + return this + .client + .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginDelete( + String resourceGroupName, String accountName, String privateEndpointConnectionName) { + return beginDeleteAsync(resourceGroupName, accountName, privateEndpointConnectionName).getSyncPoller(); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginDelete( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + return beginDeleteAsync(resourceGroupName, accountName, privateEndpointConnectionName, context).getSyncPoller(); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono deleteAsync(String resourceGroupName, String accountName, String privateEndpointConnectionName) { + return beginDeleteAsync(resourceGroupName, accountName, privateEndpointConnectionName) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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 A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono deleteAsync( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + return beginDeleteAsync(resourceGroupName, accountName, privateEndpointConnectionName, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName) { + deleteAsync(resourceGroupName, accountName, privateEndpointConnectionName).block(); + } + + /** + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public void delete( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + deleteAsync(resourceGroupName, accountName, privateEndpointConnectionName, context).block(); } /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -994,7 +1280,8 @@ private Mono> listByBatchAccountNe /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsImpl.java index 2645e62a84e6..763151977f8e 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateEndpointConnectionsImpl.java @@ -40,17 +40,6 @@ public PagedIterable listByBatchAccount( return Utils.mapPage(inner, inner1 -> new PrivateEndpointConnectionImpl(inner1, this.manager())); } - public PrivateEndpointConnection get( - String resourceGroupName, String accountName, String privateEndpointConnectionName) { - PrivateEndpointConnectionInner inner = - this.serviceClient().get(resourceGroupName, accountName, privateEndpointConnectionName); - if (inner != null) { - return new PrivateEndpointConnectionImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getWithResponse( String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { Response inner = @@ -68,16 +57,10 @@ public Response getWithResponse( } } - public PrivateEndpointConnection update( - String resourceGroupName, - String accountName, - String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch) { + public PrivateEndpointConnection get( + String resourceGroupName, String accountName, String privateEndpointConnectionName) { PrivateEndpointConnectionInner inner = - this - .serviceClient() - .update(resourceGroupName, accountName, privateEndpointConnectionName, parameters, ifMatch); + this.serviceClient().get(resourceGroupName, accountName, privateEndpointConnectionName); if (inner != null) { return new PrivateEndpointConnectionImpl(inner, this.manager()); } else { @@ -117,6 +100,15 @@ public PrivateEndpointConnection update( } } + public void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName) { + this.serviceClient().delete(resourceGroupName, accountName, privateEndpointConnectionName); + } + + public void delete( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context) { + this.serviceClient().delete(resourceGroupName, accountName, privateEndpointConnectionName, context); + } + private PrivateEndpointConnectionsClient serviceClient() { return this.innerClient; } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesClientImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesClientImpl.java index 1407cd258e27..813a6aca47e9 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesClientImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesClientImpl.java @@ -434,14 +434,7 @@ private Mono> getWithResponseAsync( private Mono getAsync( String resourceGroupName, String accountName, String privateLinkResourceName) { return getWithResponseAsync(resourceGroupName, accountName, privateLinkResourceName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + .flatMap(res -> Mono.justOrEmpty(res.getValue())); } /** @@ -450,14 +443,16 @@ private Mono getAsync( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource. + * @return information about the specified private link resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PrivateLinkResourceInner get(String resourceGroupName, String accountName, String privateLinkResourceName) { - return getAsync(resourceGroupName, accountName, privateLinkResourceName).block(); + public Response getWithResponse( + String resourceGroupName, String accountName, String privateLinkResourceName, Context context) { + return getWithResponseAsync(resourceGroupName, accountName, privateLinkResourceName, context).block(); } /** @@ -466,22 +461,21 @@ public PrivateLinkResourceInner get(String resourceGroupName, String accountName * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource along with {@link Response}. + * @return information about the specified private link resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response getWithResponse( - String resourceGroupName, String accountName, String privateLinkResourceName, Context context) { - return getWithResponseAsync(resourceGroupName, accountName, privateLinkResourceName, context).block(); + public PrivateLinkResourceInner get(String resourceGroupName, String accountName, String privateLinkResourceName) { + return getWithResponse(resourceGroupName, accountName, privateLinkResourceName, Context.NONE).getValue(); } /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. @@ -518,7 +512,8 @@ private Mono> listByBatchAccountNextSing /** * Get the next page of items. * - * @param nextLink The nextLink parameter. + * @param nextLink The URL to get the next list of items + *

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. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesImpl.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesImpl.java index a977e2cfa0b8..96962461a629 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesImpl.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/implementation/PrivateLinkResourcesImpl.java @@ -40,16 +40,6 @@ public PagedIterable listByBatchAccount( return Utils.mapPage(inner, inner1 -> new PrivateLinkResourceImpl(inner1, this.manager())); } - public PrivateLinkResource get(String resourceGroupName, String accountName, String privateLinkResourceName) { - PrivateLinkResourceInner inner = - this.serviceClient().get(resourceGroupName, accountName, privateLinkResourceName); - if (inner != null) { - return new PrivateLinkResourceImpl(inner, this.manager()); - } else { - return null; - } - } - public Response getWithResponse( String resourceGroupName, String accountName, String privateLinkResourceName, Context context) { Response inner = @@ -65,6 +55,16 @@ public Response getWithResponse( } } + public PrivateLinkResource get(String resourceGroupName, String accountName, String privateLinkResourceName) { + PrivateLinkResourceInner inner = + this.serviceClient().get(resourceGroupName, accountName, privateLinkResourceName); + if (inner != null) { + return new PrivateLinkResourceImpl(inner, this.manager()); + } else { + return null; + } + } + private PrivateLinkResourcesClient serviceClient() { return this.innerClient; } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AccountKeyType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AccountKeyType.java index 13a40cce924a..b1647291cc80 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AccountKeyType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AccountKeyType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for AccountKeyType. */ +/** The type of account key to regenerate. */ public enum AccountKeyType { /** Enum value Primary. */ PRIMARY("Primary"), @@ -30,6 +30,9 @@ public enum AccountKeyType { */ @JsonCreator public static AccountKeyType fromString(String value) { + if (value == null) { + return null; + } AccountKeyType[] items = AccountKeyType.values(); for (AccountKeyType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static AccountKeyType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ActivateApplicationPackageParameters.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ActivateApplicationPackageParameters.java index 51307c9c73b0..166ceb7bbfd3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ActivateApplicationPackageParameters.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ActivateApplicationPackageParameters.java @@ -17,6 +17,10 @@ public final class ActivateApplicationPackageParameters { @JsonProperty(value = "format", required = true) private String format; + /** Creates an instance of ActivateApplicationPackageParameters class. */ + public ActivateApplicationPackageParameters() { + } + /** * Get the format property: The format of the application package binary file. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AllocationState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AllocationState.java index e1102204ef49..23d0b2345c48 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AllocationState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AllocationState.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for AllocationState. */ +/** Whether the pool is resizing. */ public enum AllocationState { /** Enum value Steady. */ STEADY("Steady"), @@ -33,6 +33,9 @@ public enum AllocationState { */ @JsonCreator public static AllocationState fromString(String value) { + if (value == null) { + return null; + } AllocationState[] items = AllocationState.values(); for (AllocationState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static AllocationState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Application.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Application.java index 1349913ca536..3bf82587d1d8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Application.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Application.java @@ -60,6 +60,13 @@ public interface Application { */ String defaultVersion(); + /** + * Gets the name of the resource group. + * + * @return the name of the resource group. + */ + String resourceGroupName(); + /** * Gets the inner com.azure.resourcemanager.batch.fluent.models.ApplicationInner object. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackage.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackage.java index 3d19fe0b9306..6cdaef878d41 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackage.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackage.java @@ -143,24 +143,24 @@ interface WithCreate { * uploaded. This needs to be done before an `ApplicationPackage` can be used on Pools or Tasks. * * @param parameters The parameters for the request. + * @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 an application package which represents a particular version of an application. + * @return an application package which represents a particular version of an application along with {@link + * Response}. */ - ApplicationPackage activate(ActivateApplicationPackageParameters parameters); + Response activateWithResponse(ActivateApplicationPackageParameters parameters, Context context); /** * Activates the specified application package. This should be done after the `ApplicationPackage` was created and * uploaded. This needs to be done before an `ApplicationPackage` can be used on Pools or Tasks. * * @param parameters The parameters for the request. - * @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 an application package which represents a particular version of an application along with {@link - * Response}. + * @return an application package which represents a particular version of an application. */ - Response activateWithResponse(ActivateApplicationPackageParameters parameters, Context context); + ApplicationPackage activate(ActivateApplicationPackageParameters parameters); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackageReference.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackageReference.java index 4a087b914d31..b6c0cae3378f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackageReference.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackageReference.java @@ -12,23 +12,25 @@ @Fluent public final class ApplicationPackageReference { /* - * The ID of the application package to install. This must be inside the - * same batch account as the pool. This can either be a reference to a - * specific version or the default version if one exists. + * The ID of the application package to install. This must be inside the same batch account as the pool. This can + * either be a reference to a specific version or the default version if one exists. */ @JsonProperty(value = "id", required = true) private String id; /* - * The version of the application to deploy. If omitted, the default - * version is deployed. If this is omitted, and no default version is - * specified for this application, the request fails with the error code - * InvalidApplicationPackageReferences. If you are calling the REST API - * directly, the HTTP status code is 409. + * The version of the application to deploy. If omitted, the default version is deployed. + * + * If this is omitted, and no default version is specified for this application, the request fails with the error + * code InvalidApplicationPackageReferences. If you are calling the REST API directly, the HTTP status code is 409. */ @JsonProperty(value = "version") private String version; + /** Creates an instance of ApplicationPackageReference class. */ + public ApplicationPackageReference() { + } + /** * Get the id property: The ID of the application package to install. This must be inside the same batch account as * the pool. This can either be a reference to a specific version or the default version if one exists. @@ -53,7 +55,8 @@ public ApplicationPackageReference withId(String id) { /** * Get the version property: The version of the application to deploy. If omitted, the default version is deployed. - * If this is omitted, and no default version is specified for this application, the request fails with the error + * + *

If this is omitted, and no default version is specified for this application, the request fails with the error * code InvalidApplicationPackageReferences. If you are calling the REST API directly, the HTTP status code is 409. * * @return the version value. @@ -64,7 +67,8 @@ public String version() { /** * Set the version property: The version of the application to deploy. If omitted, the default version is deployed. - * If this is omitted, and no default version is specified for this application, the request fails with the error + * + *

If this is omitted, and no default version is specified for this application, the request fails with the error * code InvalidApplicationPackageReferences. If you are calling the REST API directly, the HTTP status code is 409. * * @param version the version value to set. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackages.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackages.java index 10fafd57afb5..ba070e4b8cb0 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackages.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ApplicationPackages.java @@ -19,17 +19,20 @@ public interface ApplicationPackages { * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. * @param parameters The parameters for the request. + * @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 an application package which represents a particular version of an application. + * @return an application package which represents a particular version of an application along with {@link + * Response}. */ - ApplicationPackage activate( + Response activateWithResponse( String resourceGroupName, String accountName, String applicationName, String versionName, - ActivateApplicationPackageParameters parameters); + ActivateApplicationPackageParameters parameters, + Context context); /** * Activates the specified application package. This should be done after the `ApplicationPackage` was created and @@ -40,20 +43,17 @@ ApplicationPackage activate( * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. * @param parameters The parameters for the request. - * @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 an application package which represents a particular version of an application along with {@link - * Response}. + * @return an application package which represents a particular version of an application. */ - Response activateWithResponse( + ApplicationPackage activate( String resourceGroupName, String accountName, String applicationName, String versionName, - ActivateApplicationPackageParameters parameters, - Context context); + ActivateApplicationPackageParameters parameters); /** * Deletes an application package record and its associated binary file. @@ -62,11 +62,14 @@ Response activateWithResponse( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response}. */ - void delete(String resourceGroupName, String accountName, String applicationName, String versionName); + Response deleteWithResponse( + String resourceGroupName, String accountName, String applicationName, String versionName, Context context); /** * Deletes an application package record and its associated binary file. @@ -75,14 +78,11 @@ Response activateWithResponse( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. - * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the {@link Response}. */ - Response deleteWithResponse( - String resourceGroupName, String accountName, String applicationName, String versionName, Context context); + void delete(String resourceGroupName, String accountName, String applicationName, String versionName); /** * Gets information about the specified application package. @@ -91,12 +91,14 @@ Response deleteWithResponse( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. + * @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 information about the specified application package. + * @return information about the specified application package along with {@link Response}. */ - ApplicationPackage get(String resourceGroupName, String accountName, String applicationName, String versionName); + Response getWithResponse( + String resourceGroupName, String accountName, String applicationName, String versionName, Context context); /** * Gets information about the specified application package. @@ -105,14 +107,12 @@ Response deleteWithResponse( * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the account. * @param versionName The version of the application. - * @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 information about the specified application package along with {@link Response}. + * @return information about the specified application package. */ - Response getWithResponse( - String resourceGroupName, String accountName, String applicationName, String versionName, Context context); + ApplicationPackage get(String resourceGroupName, String accountName, String applicationName, String versionName); /** * Lists all of the application packages in the specified application. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Applications.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Applications.java index b019a9d86679..ad13ec281cd3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Applications.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Applications.java @@ -16,11 +16,14 @@ public interface Applications { * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 the {@link Response}. */ - void delete(String resourceGroupName, String accountName, String applicationName); + Response deleteWithResponse( + String resourceGroupName, String accountName, String applicationName, Context context); /** * Deletes an application. @@ -28,14 +31,11 @@ public interface Applications { * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 the {@link Response}. */ - Response deleteWithResponse( - String resourceGroupName, String accountName, String applicationName, Context context); + void delete(String resourceGroupName, String accountName, String applicationName); /** * Gets information about the specified application. @@ -43,12 +43,14 @@ Response deleteWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 information about the specified application. + * @return information about the specified application along with {@link Response}. */ - Application get(String resourceGroupName, String accountName, String applicationName); + Response getWithResponse( + String resourceGroupName, String accountName, String applicationName, Context context); /** * Gets information about the specified application. @@ -56,14 +58,12 @@ Response deleteWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param applicationName The name of the application. This must be unique within the 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 information about the specified application along with {@link Response}. + * @return information about the specified application. */ - Response getWithResponse( - String resourceGroupName, String accountName, String applicationName, Context context); + Application get(String resourceGroupName, String accountName, String applicationName); /** * Lists all of the applications in the specified account. 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 index 7c366c5b3486..b97a39f962af 100644 --- 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 @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for AuthenticationMode. */ +/** The authentication mode for the Batch account. */ public enum AuthenticationMode { /** Enum value SharedKey. */ SHARED_KEY("SharedKey"), @@ -33,6 +33,9 @@ public enum AuthenticationMode { */ @JsonCreator public static AuthenticationMode fromString(String value) { + if (value == null) { + return null; + } AuthenticationMode[] items = AuthenticationMode.values(); for (AuthenticationMode item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static AuthenticationMode fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRun.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRun.java index a1e178380a61..53ca8d775eab 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRun.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRun.java @@ -19,9 +19,9 @@ public final class AutoScaleRun { private OffsetDateTime evaluationTime; /* - * The final values of all variables used in the evaluation of the - * autoscale formula. Each variable value is returned in the form - * $variable=value, and variables are separated by semicolons. + * The final values of all variables used in the evaluation of the autoscale formula. + * + * Each variable value is returned in the form $variable=value, and variables are separated by semicolons. */ @JsonProperty(value = "results") private String results; @@ -32,6 +32,10 @@ public final class AutoScaleRun { @JsonProperty(value = "error") private AutoScaleRunError error; + /** Creates an instance of AutoScaleRun class. */ + public AutoScaleRun() { + } + /** * Get the evaluationTime property: The time at which the autoscale formula was last evaluated. * @@ -53,8 +57,9 @@ public AutoScaleRun withEvaluationTime(OffsetDateTime evaluationTime) { } /** - * Get the results property: The final values of all variables used in the evaluation of the autoscale formula. Each - * variable value is returned in the form $variable=value, and variables are separated by semicolons. + * Get the results property: The final values of all variables used in the evaluation of the autoscale formula. + * + *

Each variable value is returned in the form $variable=value, and variables are separated by semicolons. * * @return the results value. */ @@ -63,8 +68,9 @@ public String results() { } /** - * Set the results property: The final values of all variables used in the evaluation of the autoscale formula. Each - * variable value is returned in the form $variable=value, and variables are separated by semicolons. + * Set the results property: The final values of all variables used in the evaluation of the autoscale formula. + * + *

Each variable value is returned in the form $variable=value, and variables are separated by semicolons. * * @param results the results value to set. * @return the AutoScaleRun object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRunError.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRunError.java index dc1ea59600ee..dc9104499e23 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRunError.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleRunError.java @@ -13,15 +13,13 @@ @Fluent public final class AutoScaleRunError { /* - * An identifier for the error. Codes are invariant and are intended to be - * consumed programmatically. + * An identifier for the error. Codes are invariant and are intended to be consumed programmatically. */ @JsonProperty(value = "code", required = true) private String code; /* - * A message describing the error, intended to be suitable for display in a - * user interface. + * A message describing the error, intended to be suitable for display in a user interface. */ @JsonProperty(value = "message", required = true) private String message; @@ -32,6 +30,10 @@ public final class AutoScaleRunError { @JsonProperty(value = "details") private List details; + /** Creates an instance of AutoScaleRunError class. */ + public AutoScaleRunError() { + } + /** * Get the code property: An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleSettings.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleSettings.java index eb5607551355..866ba6f6cb23 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleSettings.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoScaleSettings.java @@ -19,13 +19,17 @@ public final class AutoScaleSettings { private String formula; /* - * The time interval at which to automatically adjust the pool size - * according to the autoscale formula. If omitted, the default value is 15 - * minutes (PT15M). + * The time interval at which to automatically adjust the pool size according to the autoscale formula. + * + * If omitted, the default value is 15 minutes (PT15M). */ @JsonProperty(value = "evaluationInterval") private Duration evaluationInterval; + /** Creates an instance of AutoScaleSettings class. */ + public AutoScaleSettings() { + } + /** * Get the formula property: A formula for the desired number of compute nodes in the pool. * @@ -48,7 +52,9 @@ public AutoScaleSettings withFormula(String formula) { /** * Get the evaluationInterval property: The time interval at which to automatically adjust the pool size according - * to the autoscale formula. If omitted, the default value is 15 minutes (PT15M). + * to the autoscale formula. + * + *

If omitted, the default value is 15 minutes (PT15M). * * @return the evaluationInterval value. */ @@ -58,7 +64,9 @@ public Duration evaluationInterval() { /** * Set the evaluationInterval property: The time interval at which to automatically adjust the pool size according - * to the autoscale formula. If omitted, the default value is 15 minutes (PT15M). + * to the autoscale formula. + * + *

If omitted, the default value is 15 minutes (PT15M). * * @param evaluationInterval the evaluationInterval value to set. * @return the AutoScaleSettings object itself. 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 index 773a3f15595d..3138fe1a69d6 100644 --- 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 @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for AutoStorageAuthenticationMode. */ +/** The authentication mode which the Batch service will use to manage the auto-storage account. */ public enum AutoStorageAuthenticationMode { /** Enum value StorageKeys. */ STORAGE_KEYS("StorageKeys"), @@ -30,6 +30,9 @@ public enum AutoStorageAuthenticationMode { */ @JsonCreator public static AutoStorageAuthenticationMode fromString(String value) { + if (value == null) { + return null; + } AutoStorageAuthenticationMode[] items = AutoStorageAuthenticationMode.values(); for (AutoStorageAuthenticationMode item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static AutoStorageAuthenticationMode fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 95902d795c79..9b097098825e 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 @@ -12,26 +12,28 @@ @Fluent public class AutoStorageBaseProperties { /* - * The resource ID of the storage account to be used for auto-storage - * account. + * The resource ID of the storage account to be used for auto-storage account. */ @JsonProperty(value = "storageAccountId", required = true) private String storageAccountId; /* - * The authentication mode which the Batch service will use to manage the - * auto-storage account. + * 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. + * 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; + /** Creates an instance of AutoStorageBaseProperties class. */ + public AutoStorageBaseProperties() { + } + /** * Get the storageAccountId property: The resource ID of the storage account to be used for auto-storage account. * 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 c1eb695b2681..4f6bc560c64b 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 @@ -13,12 +13,15 @@ @Fluent public final class AutoStorageProperties extends AutoStorageBaseProperties { /* - * The UTC time at which storage keys were last synchronized with the Batch - * account. + * The UTC time at which storage keys were last synchronized with the Batch account. */ @JsonProperty(value = "lastKeySync", required = true) private OffsetDateTime lastKeySync; + /** Creates an instance of AutoStorageProperties class. */ + public AutoStorageProperties() { + } + /** * Get the lastKeySync property: The UTC time at which storage keys were last synchronized with the Batch account. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserScope.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserScope.java index 5cc6b24d205b..f12fa7536608 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserScope.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserScope.java @@ -7,7 +7,14 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for AutoUserScope. */ +/** + * The scope for the auto user + * + *

The default value is Pool. If the pool is running Windows a value of Task should be specified if stricter + * isolation between tasks is required. For example, if the task mutates the registry in a way which could impact other + * tasks, or if certificates have been specified on the pool which should not be accessible by normal tasks but should + * be accessible by start tasks. + */ public enum AutoUserScope { /** Enum value Task. */ TASK("Task"), @@ -30,6 +37,9 @@ public enum AutoUserScope { */ @JsonCreator public static AutoUserScope fromString(String value) { + if (value == null) { + return null; + } AutoUserScope[] items = AutoUserScope.values(); for (AutoUserScope item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +49,7 @@ public static AutoUserScope fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserSpecification.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserSpecification.java index 61f49a6b1678..a97ce62817e9 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserSpecification.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AutoUserSpecification.java @@ -11,27 +11,35 @@ @Fluent public final class AutoUserSpecification { /* - * The scope for the auto user The default value is Pool. If the pool is - * running Windows a value of Task should be specified if stricter - * isolation between tasks is required. For example, if the task mutates - * the registry in a way which could impact other tasks, or if certificates - * have been specified on the pool which should not be accessible by normal - * tasks but should be accessible by start tasks. + * The scope for the auto user + * + * The default value is Pool. If the pool is running Windows a value of Task should be specified if stricter + * isolation between tasks is required. For example, if the task mutates the registry in a way which could impact + * other tasks, or if certificates have been specified on the pool which should not be accessible by normal tasks + * but should be accessible by start tasks. */ @JsonProperty(value = "scope") private AutoUserScope scope; /* - * The elevation level of the user. The default value is nonAdmin. + * The elevation level of the user. + * + * The default value is nonAdmin. */ @JsonProperty(value = "elevationLevel") private ElevationLevel elevationLevel; + /** Creates an instance of AutoUserSpecification class. */ + public AutoUserSpecification() { + } + /** - * Get the scope property: The scope for the auto user The default value is Pool. If the pool is running Windows a - * value of Task should be specified if stricter isolation between tasks is required. For example, if the task - * mutates the registry in a way which could impact other tasks, or if certificates have been specified on the pool - * which should not be accessible by normal tasks but should be accessible by start tasks. + * Get the scope property: The scope for the auto user + * + *

The default value is Pool. If the pool is running Windows a value of Task should be specified if stricter + * isolation between tasks is required. For example, if the task mutates the registry in a way which could impact + * other tasks, or if certificates have been specified on the pool which should not be accessible by normal tasks + * but should be accessible by start tasks. * * @return the scope value. */ @@ -40,10 +48,12 @@ public AutoUserScope scope() { } /** - * Set the scope property: The scope for the auto user The default value is Pool. If the pool is running Windows a - * value of Task should be specified if stricter isolation between tasks is required. For example, if the task - * mutates the registry in a way which could impact other tasks, or if certificates have been specified on the pool - * which should not be accessible by normal tasks but should be accessible by start tasks. + * Set the scope property: The scope for the auto user + * + *

The default value is Pool. If the pool is running Windows a value of Task should be specified if stricter + * isolation between tasks is required. For example, if the task mutates the registry in a way which could impact + * other tasks, or if certificates have been specified on the pool which should not be accessible by normal tasks + * but should be accessible by start tasks. * * @param scope the scope value to set. * @return the AutoUserSpecification object itself. @@ -54,7 +64,9 @@ public AutoUserSpecification withScope(AutoUserScope scope) { } /** - * Get the elevationLevel property: The elevation level of the user. The default value is nonAdmin. + * Get the elevationLevel property: The elevation level of the user. + * + *

The default value is nonAdmin. * * @return the elevationLevel value. */ @@ -63,7 +75,9 @@ public ElevationLevel elevationLevel() { } /** - * Set the elevationLevel property: The elevation level of the user. The default value is nonAdmin. + * Set the elevationLevel property: The elevation level of the user. + * + *

The default value is nonAdmin. * * @param elevationLevel the elevationLevel value to set. * @return the AutoUserSpecification object itself. 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 a66bdfd90dd6..a8b0ba25966f 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 @@ -24,42 +24,48 @@ public final class AzureBlobFileSystemConfiguration { private String containerName; /* - * The Azure Storage Account key. This property is mutually exclusive with - * both sasKey and identity; exactly one must be specified. + * The Azure Storage Account key. + * + * This property is mutually exclusive with both sasKey and identity; exactly one must be specified. */ @JsonProperty(value = "accountKey") private String accountKey; /* - * The Azure Storage SAS token. This property is mutually exclusive with - * both accountKey and identity; exactly one must be specified. + * The Azure Storage SAS token. + * + * This property is mutually exclusive with both accountKey and identity; exactly one must be specified. */ @JsonProperty(value = "sasKey") private String sasKey; /* - * Additional command line options to pass to the mount command. These are - * 'net use' options in Windows and 'mount' options in Linux. + * Additional command line options to pass to the mount command. + * + * These are 'net use' options in Windows and 'mount' options in Linux. */ @JsonProperty(value = "blobfuseOptions") private String blobfuseOptions; /* - * The relative path on the compute node where the file system will be - * mounted All file systems are mounted relative to the Batch mounts - * directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR environment - * variable. + * The relative path on the compute node where the file system will be mounted + * + * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR + * environment variable. */ @JsonProperty(value = "relativeMountPath", required = true) private String relativeMountPath; /* - * This property is mutually exclusive with both accountKey and sasKey; - * exactly one must be specified. + * This property is mutually exclusive with both accountKey and sasKey; exactly one must be specified. */ @JsonProperty(value = "identityReference") private ComputeNodeIdentityReference identityReference; + /** Creates an instance of AzureBlobFileSystemConfiguration class. */ + public AzureBlobFileSystemConfiguration() { + } + /** * Get the accountName property: The Azure Storage Account name. * @@ -101,8 +107,9 @@ public AzureBlobFileSystemConfiguration withContainerName(String containerName) } /** - * Get the accountKey property: The Azure Storage Account key. This property is mutually exclusive with both sasKey - * and identity; exactly one must be specified. + * Get the accountKey property: The Azure Storage Account key. + * + *

This property is mutually exclusive with both sasKey and identity; exactly one must be specified. * * @return the accountKey value. */ @@ -111,8 +118,9 @@ public String accountKey() { } /** - * Set the accountKey property: The Azure Storage Account key. This property is mutually exclusive with both sasKey - * and identity; exactly one must be specified. + * Set the accountKey property: The Azure Storage Account key. + * + *

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. @@ -123,8 +131,9 @@ public AzureBlobFileSystemConfiguration withAccountKey(String accountKey) { } /** - * Get the sasKey property: The Azure Storage SAS token. This property is mutually exclusive with both accountKey - * and identity; exactly one must be specified. + * Get the sasKey property: The Azure Storage SAS token. + * + *

This property is mutually exclusive with both accountKey and identity; exactly one must be specified. * * @return the sasKey value. */ @@ -133,8 +142,9 @@ public String sasKey() { } /** - * Set the sasKey property: The Azure Storage SAS token. This property is mutually exclusive with both accountKey - * and identity; exactly one must be specified. + * Set the sasKey property: The Azure Storage SAS token. + * + *

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. @@ -145,8 +155,9 @@ public AzureBlobFileSystemConfiguration withSasKey(String sasKey) { } /** - * Get the blobfuseOptions property: Additional command line options to pass to the mount command. These are 'net - * use' options in Windows and 'mount' options in Linux. + * Get the blobfuseOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @return the blobfuseOptions value. */ @@ -155,8 +166,9 @@ public String blobfuseOptions() { } /** - * Set the blobfuseOptions property: Additional command line options to pass to the mount command. These are 'net - * use' options in Windows and 'mount' options in Linux. + * Set the blobfuseOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @param blobfuseOptions the blobfuseOptions value to set. * @return the AzureBlobFileSystemConfiguration object itself. @@ -168,8 +180,9 @@ public AzureBlobFileSystemConfiguration withBlobfuseOptions(String blobfuseOptio /** * Get the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @return the relativeMountPath value. */ @@ -179,8 +192,9 @@ public String relativeMountPath() { /** * Set the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @param relativeMountPath the relativeMountPath value to set. * @return the AzureBlobFileSystemConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureFileShareConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureFileShareConfiguration.java index b143cdfa5d22..379604a12ce8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureFileShareConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/AzureFileShareConfiguration.java @@ -18,8 +18,9 @@ public final class AzureFileShareConfiguration { private String accountName; /* - * The Azure Files URL. This is of the form - * 'https://{account}.file.core.windows.net/'. + * The Azure Files URL. + * + * This is of the form 'https://{account}.file.core.windows.net/'. */ @JsonProperty(value = "azureFileUrl", required = true) private String azureFileUrl; @@ -27,25 +28,30 @@ public final class AzureFileShareConfiguration { /* * The Azure Storage account key. */ - @JsonProperty(value = "accountKey", required = true) + @JsonProperty(value = "accountKey") private String accountKey; /* - * The relative path on the compute node where the file system will be - * mounted All file systems are mounted relative to the Batch mounts - * directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR environment - * variable. + * The relative path on the compute node where the file system will be mounted + * + * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR + * environment variable. */ @JsonProperty(value = "relativeMountPath", required = true) private String relativeMountPath; /* - * Additional command line options to pass to the mount command. These are - * 'net use' options in Windows and 'mount' options in Linux. + * Additional command line options to pass to the mount command. + * + * These are 'net use' options in Windows and 'mount' options in Linux. */ @JsonProperty(value = "mountOptions") private String mountOptions; + /** Creates an instance of AzureFileShareConfiguration class. */ + public AzureFileShareConfiguration() { + } + /** * Get the accountName property: The Azure Storage account name. * @@ -67,8 +73,9 @@ public AzureFileShareConfiguration withAccountName(String accountName) { } /** - * Get the azureFileUrl property: The Azure Files URL. This is of the form - * 'https://{account}.file.core.windows.net/'. + * Get the azureFileUrl property: The Azure Files URL. + * + *

This is of the form 'https://{account}.file.core.windows.net/'. * * @return the azureFileUrl value. */ @@ -77,8 +84,9 @@ public String azureFileUrl() { } /** - * Set the azureFileUrl property: The Azure Files URL. This is of the form - * 'https://{account}.file.core.windows.net/'. + * Set the azureFileUrl property: The Azure Files URL. + * + *

This is of the form 'https://{account}.file.core.windows.net/'. * * @param azureFileUrl the azureFileUrl value to set. * @return the AzureFileShareConfiguration object itself. @@ -110,8 +118,9 @@ public AzureFileShareConfiguration withAccountKey(String accountKey) { /** * Get the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @return the relativeMountPath value. */ @@ -121,8 +130,9 @@ public String relativeMountPath() { /** * Set the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @param relativeMountPath the relativeMountPath value to set. * @return the AzureFileShareConfiguration object itself. @@ -133,8 +143,9 @@ public AzureFileShareConfiguration withRelativeMountPath(String relativeMountPat } /** - * Get the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Get the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @return the mountOptions value. */ @@ -143,8 +154,9 @@ public String mountOptions() { } /** - * Set the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Set the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @param mountOptions the mountOptions value to set. * @return the AzureFileShareConfiguration object itself. @@ -172,12 +184,6 @@ public void validate() { new IllegalArgumentException( "Missing required property azureFileUrl in model AzureFileShareConfiguration")); } - if (accountKey() == null) { - throw LOGGER - .logExceptionAsError( - new IllegalArgumentException( - "Missing required property accountKey in model AzureFileShareConfiguration")); - } if (relativeMountPath() == null) { throw LOGGER .logExceptionAsError( 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 3ca6e99452dd..e8dc107123b6 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 @@ -62,6 +62,14 @@ public interface BatchAccount { */ String accountEndpoint(); + /** + * Gets the nodeManagementEndpoint property: The endpoint used by compute node to connect to the Batch node + * management service. + * + * @return the nodeManagementEndpoint value. + */ + String nodeManagementEndpoint(); + /** * Gets the provisioningState property: The provisioned state of the resource. * @@ -90,6 +98,13 @@ public interface BatchAccount { */ PublicNetworkAccessType publicNetworkAccess(); + /** + * Gets the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + NetworkProfile networkProfile(); + /** * Gets the privateEndpointConnections property: List of private endpoint connections associated with the Batch * account. @@ -116,16 +131,20 @@ public interface BatchAccount { EncryptionProperties encryption(); /** - * Gets the dedicatedCoreQuota property: The dedicated core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Gets the dedicatedCoreQuota property: The dedicated core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the dedicatedCoreQuota value. */ Integer dedicatedCoreQuota(); /** - * Gets the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. For accounts with - * PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this value is not returned. + * Gets the lowPriorityCoreQuota property: The Spot/low-priority core quota for the Batch account. + * + *

For accounts with PoolAllocationMode set to UserSubscription, quota is managed on the subscription so this + * value is not returned. * * @return the lowPriorityCoreQuota value. */ @@ -142,12 +161,11 @@ public interface BatchAccount { /** * Gets the dedicatedCoreQuotaPerVMFamilyEnforced property: A value indicating whether core quotas per Virtual - * Machine family are enforced for this account Batch is transitioning its core quota system for dedicated cores to - * be enforced per Virtual Machine family. During this transitional phase, the dedicated core quota per Virtual - * Machine family may not yet be enforced. If this flag is false, dedicated core quota is enforced via the old - * dedicatedCoreQuota property on the account and does not consider Virtual Machine family. If this flag is true, - * dedicated core quota is enforced via the dedicatedCoreQuotaPerVMFamily property on the account, and the old - * dedicatedCoreQuota does not apply. + * Machine family are enforced for this account + * + *

If this flag is true, dedicated core quota is enforced via both the dedicatedCoreQuotaPerVMFamily and + * dedicatedCoreQuota properties on the account. If this flag is false, dedicated core quota is enforced only via + * the dedicatedCoreQuota property on the account and does not consider Virtual Machine family. * * @return the dedicatedCoreQuotaPerVMFamilyEnforced value. */ @@ -189,6 +207,13 @@ public interface BatchAccount { */ String regionName(); + /** + * Gets the name of the resource group. + * + * @return the name of the resource group. + */ + String resourceGroupName(); + /** * Gets the inner com.azure.resourcemanager.batch.fluent.models.BatchAccountInner object. * @@ -247,6 +272,7 @@ interface WithCreate DefinitionStages.WithPoolAllocationMode, DefinitionStages.WithKeyVaultReference, DefinitionStages.WithPublicNetworkAccess, + DefinitionStages.WithNetworkProfile, DefinitionStages.WithEncryption, DefinitionStages.WithAllowedAuthenticationModes { /** @@ -331,6 +357,17 @@ interface WithPublicNetworkAccess { */ WithCreate withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess); } + /** The stage of the BatchAccount definition allowing to specify networkProfile. */ + interface WithNetworkProfile { + /** + * Specifies the networkProfile property: The network profile only takes effect when publicNetworkAccess is + * enabled.. + * + * @param networkProfile The network profile only takes effect when publicNetworkAccess is enabled. + * @return the next definition stage. + */ + WithCreate withNetworkProfile(NetworkProfile networkProfile); + } /** The stage of the BatchAccount definition allowing to specify encryption. */ interface WithEncryption { /** @@ -372,7 +409,9 @@ interface Update UpdateStages.WithIdentity, UpdateStages.WithAutoStorage, UpdateStages.WithEncryption, - UpdateStages.WithAllowedAuthenticationModes { + UpdateStages.WithAllowedAuthenticationModes, + UpdateStages.WithPublicNetworkAccess, + UpdateStages.WithNetworkProfile { /** * Executes the update request. * @@ -447,6 +486,27 @@ interface WithAllowedAuthenticationModes { */ Update withAllowedAuthenticationModes(List allowedAuthenticationModes); } + /** The stage of the BatchAccount update allowing to specify publicNetworkAccess. */ + interface WithPublicNetworkAccess { + /** + * Specifies the publicNetworkAccess property: If not specified, the default value is 'enabled'.. + * + * @param publicNetworkAccess If not specified, the default value is 'enabled'. + * @return the next definition stage. + */ + Update withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess); + } + /** The stage of the BatchAccount update allowing to specify networkProfile. */ + interface WithNetworkProfile { + /** + * Specifies the networkProfile property: The network profile only takes effect when publicNetworkAccess is + * enabled.. + * + * @param networkProfile The network profile only takes effect when publicNetworkAccess is enabled. + * @return the next definition stage. + */ + Update withNetworkProfile(NetworkProfile networkProfile); + } } /** * Refreshes the resource to sync with Azure. @@ -467,74 +527,82 @@ interface WithAllowedAuthenticationModes { * 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. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response}. */ - void synchronizeAutoStorageKeys(); + Response synchronizeAutoStorageKeysWithResponse(Context context); /** * 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. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the {@link Response}. */ - Response synchronizeAutoStorageKeysWithResponse(Context context); + void synchronizeAutoStorageKeys(); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ - BatchAccountKeys regenerateKey(BatchAccountRegenerateKeyParameters parameters); + Response regenerateKeyWithResponse( + BatchAccountRegenerateKeyParameters parameters, Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ - Response regenerateKeyWithResponse( - BatchAccountRegenerateKeyParameters parameters, Context context); + BatchAccountKeys regenerateKey(BatchAccountRegenerateKeyParameters parameters); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, getting the keys will fail. * + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ - BatchAccountKeys getKeys(); + Response getKeysWithResponse(Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, getting the keys will fail. * - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ - Response getKeysWithResponse(Context context); + BatchAccountKeys getKeys(); } 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 29a0ee1024bd..e28d63552a8b 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 @@ -40,6 +40,10 @@ public final class BatchAccountCreateParameters { @JsonProperty(value = "identity") private BatchAccountIdentity identity; + /** Creates an instance of BatchAccountCreateParameters class. */ + public BatchAccountCreateParameters() { + } + /** * Get the location property: The region in which to create the account. * @@ -205,6 +209,29 @@ public BatchAccountCreateParameters withPublicNetworkAccess(PublicNetworkAccessT return this; } + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.innerProperties() == null ? null : this.innerProperties().networkProfile(); + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountCreateParameters object itself. + */ + public BatchAccountCreateParameters withNetworkProfile(NetworkProfile networkProfile) { + if (this.innerProperties() == null) { + this.innerProperties = new BatchAccountCreateProperties(); + } + this.innerProperties().withNetworkProfile(networkProfile); + return this; + } + /** * Get the encryption property: Configures how customer data is encrypted inside the Batch account. By default, * accounts are encrypted using a Microsoft managed key. For additional control, a customer-managed key can be used 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 09ac8371f0fd..5d4d1d67409a 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 @@ -17,15 +17,14 @@ @Fluent public class BatchAccountIdentity { /* - * The principal id of the Batch account. This property will only be - * provided for a system assigned identity. + * The principal id of the Batch account. This property will only be provided for a system assigned identity. */ @JsonProperty(value = "principalId", access = JsonProperty.Access.WRITE_ONLY) private String principalId; /* - * The tenant id associated with the Batch account. This property will only - * be provided for a system assigned identity. + * The tenant id associated with the Batch account. This property will only be provided for a system assigned + * identity. */ @JsonProperty(value = "tenantId", access = JsonProperty.Access.WRITE_ONLY) private String tenantId; @@ -43,6 +42,10 @@ public class BatchAccountIdentity { @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) private Map userAssignedIdentities; + /** Creates an instance of BatchAccountIdentity class. */ + public BatchAccountIdentity() { + } + /** * Get the principalId property: The principal id of the Batch account. This property will only be provided for a * system assigned identity. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountListResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountListResult.java index 7b46d015143d..42585ef539cf 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountListResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountListResult.java @@ -24,6 +24,10 @@ public final class BatchAccountListResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of BatchAccountListResult class. */ + public BatchAccountListResult() { + } + /** * Get the value property: The collection of Batch accounts returned by the listing operation. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountRegenerateKeyParameters.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountRegenerateKeyParameters.java index 2a84975a48a8..6ca03b3f6b95 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountRegenerateKeyParameters.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountRegenerateKeyParameters.java @@ -17,6 +17,10 @@ public final class BatchAccountRegenerateKeyParameters { @JsonProperty(value = "keyName", required = true) private AccountKeyType keyName; + /** Creates an instance of BatchAccountRegenerateKeyParameters class. */ + public BatchAccountRegenerateKeyParameters() { + } + /** * Get the keyName property: The type of account key to regenerate. * 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 d5777b4d0580..fa6ade400c40 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 @@ -33,6 +33,10 @@ public final class BatchAccountUpdateParameters { @JsonProperty(value = "identity") private BatchAccountIdentity identity; + /** Creates an instance of BatchAccountUpdateParameters class. */ + public BatchAccountUpdateParameters() { + } + /** * Get the tags property: The user-specified tags associated with the account. * @@ -158,6 +162,52 @@ public BatchAccountUpdateParameters withAllowedAuthenticationModes( return this; } + /** + * Get the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccessType publicNetworkAccess() { + return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess(); + } + + /** + * Set the publicNetworkAccess property: If not specified, the default value is 'enabled'. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the BatchAccountUpdateParameters object itself. + */ + public BatchAccountUpdateParameters withPublicNetworkAccess(PublicNetworkAccessType publicNetworkAccess) { + if (this.innerProperties() == null) { + this.innerProperties = new BatchAccountUpdateProperties(); + } + this.innerProperties().withPublicNetworkAccess(publicNetworkAccess); + return this; + } + + /** + * Get the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @return the networkProfile value. + */ + public NetworkProfile networkProfile() { + return this.innerProperties() == null ? null : this.innerProperties().networkProfile(); + } + + /** + * Set the networkProfile property: The network profile only takes effect when publicNetworkAccess is enabled. + * + * @param networkProfile the networkProfile value to set. + * @return the BatchAccountUpdateParameters object itself. + */ + public BatchAccountUpdateParameters withNetworkProfile(NetworkProfile networkProfile) { + if (this.innerProperties() == null) { + this.innerProperties = new BatchAccountUpdateProperties(); + } + this.innerProperties().withNetworkProfile(networkProfile); + 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 b74eecbaac3b..09c299698f31 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 @@ -38,26 +38,26 @@ public interface BatchAccounts { * * @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 information about the specified Batch account. + * @return information about the specified Batch account along with {@link Response}. */ - BatchAccount getByResourceGroup(String resourceGroupName, String accountName); + Response getByResourceGroupWithResponse( + String resourceGroupName, String accountName, Context context); /** * Gets information about the specified Batch account. * * @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 information about the specified Batch account along with {@link Response}. + * @return information about the specified Batch account. */ - Response getByResourceGroupWithResponse( - String resourceGroupName, String accountName, Context context); + BatchAccount getByResourceGroup(String resourceGroupName, String accountName); /** * Gets information about the Batch accounts associated with the subscription. @@ -112,11 +112,14 @@ Response getByResourceGroupWithResponse( * * @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 the {@link Response}. */ - void synchronizeAutoStorageKeys(String resourceGroupName, String accountName); + Response synchronizeAutoStorageKeysWithResponse( + String resourceGroupName, String accountName, Context context); /** * Synchronizes access keys for the auto-storage account configured for the specified Batch account, only if storage @@ -124,17 +127,16 @@ Response getByResourceGroupWithResponse( * * @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 the {@link Response}. */ - Response synchronizeAutoStorageKeysWithResponse( - String resourceGroupName, String accountName, Context context); + void synchronizeAutoStorageKeys(String resourceGroupName, String accountName); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -142,16 +144,19 @@ Response synchronizeAutoStorageKeysWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ - BatchAccountKeys regenerateKey( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters); + Response regenerateKeyWithResponse( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * 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. @@ -159,43 +164,46 @@ BatchAccountKeys regenerateKey( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param parameters The type of key to regenerate. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ - Response regenerateKeyWithResponse( - String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters, Context context); + BatchAccountKeys regenerateKey( + String resourceGroupName, String accountName, BatchAccountRegenerateKeyParameters parameters); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. + * @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 a set of Azure Batch account keys. + * @return a set of Azure Batch account keys along with {@link Response}. */ - BatchAccountKeys getKeys(String resourceGroupName, String accountName); + Response getKeysWithResponse(String resourceGroupName, String accountName, Context context); /** - * This operation applies only to Batch accounts with allowedAuthenticationModes containing 'SharedKey'. If the + * Gets the account keys for the specified 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, 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. - * @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 a set of Azure Batch account keys along with {@link Response}. + * @return a set of Azure Batch account keys. */ - Response getKeysWithResponse(String resourceGroupName, String accountName, Context context); + BatchAccountKeys getKeys(String resourceGroupName, String accountName); /** * Gets information about the detectors available for a given Batch account. @@ -230,12 +238,14 @@ Response regenerateKeyWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. + * @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 information about the given detector for a given Batch account. + * @return information about the given detector for a given Batch account along with {@link Response}. */ - DetectorResponse getDetector(String resourceGroupName, String accountName, String detectorId); + Response getDetectorWithResponse( + String resourceGroupName, String accountName, String detectorId, Context context); /** * Gets information about the given detector for a given Batch account. @@ -243,14 +253,12 @@ Response regenerateKeyWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param detectorId The name of the detector. - * @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 information about the given detector for a given Batch account along with {@link Response}. + * @return information about the given detector for a given Batch account. */ - Response getDetectorWithResponse( - String resourceGroupName, String accountName, String detectorId, Context context); + DetectorResponse getDetector(String resourceGroupName, String accountName, String detectorId); /** * Lists the endpoints that a Batch Compute Node under this Batch Account may call as part of Batch service diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsCreateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsCreateHeaders.java deleted file mode 100644 index d92e93f81c3b..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsCreateHeaders.java +++ /dev/null @@ -1,72 +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.Fluent; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The BatchAccountsCreateHeaders model. */ -@Fluent -public final class BatchAccountsCreateHeaders { - /* - * The Retry-After property. - */ - @JsonProperty(value = "Retry-After") - private Integer retryAfter; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the retryAfter property: The Retry-After property. - * - * @return the retryAfter value. - */ - public Integer retryAfter() { - return this.retryAfter; - } - - /** - * Set the retryAfter property: The Retry-After property. - * - * @param retryAfter the retryAfter value to set. - * @return the BatchAccountsCreateHeaders object itself. - */ - public BatchAccountsCreateHeaders withRetryAfter(Integer retryAfter) { - this.retryAfter = retryAfter; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the BatchAccountsCreateHeaders object itself. - */ - public BatchAccountsCreateHeaders withLocation(String location) { - this.location = location; - 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/BatchAccountsCreateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsCreateResponse.java deleted file mode 100644 index 3f39d82422d7..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsCreateResponse.java +++ /dev/null @@ -1,37 +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.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; -import com.azure.resourcemanager.batch.fluent.models.BatchAccountInner; - -/** Contains all response data for the create operation. */ -public final class BatchAccountsCreateResponse extends ResponseBase { - /** - * Creates an instance of BatchAccountsCreateResponse. - * - * @param request the request which resulted in this BatchAccountsCreateResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public BatchAccountsCreateResponse( - HttpRequest request, - int statusCode, - HttpHeaders rawHeaders, - BatchAccountInner value, - BatchAccountsCreateHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } - - /** @return the deserialized response body. */ - @Override - public BatchAccountInner getValue() { - return super.getValue(); - } -} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsDeleteHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsDeleteHeaders.java deleted file mode 100644 index 28f35818a115..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsDeleteHeaders.java +++ /dev/null @@ -1,72 +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.Fluent; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The BatchAccountsDeleteHeaders model. */ -@Fluent -public final class BatchAccountsDeleteHeaders { - /* - * The Retry-After property. - */ - @JsonProperty(value = "Retry-After") - private Integer retryAfter; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the retryAfter property: The Retry-After property. - * - * @return the retryAfter value. - */ - public Integer retryAfter() { - return this.retryAfter; - } - - /** - * Set the retryAfter property: The Retry-After property. - * - * @param retryAfter the retryAfter value to set. - * @return the BatchAccountsDeleteHeaders object itself. - */ - public BatchAccountsDeleteHeaders withRetryAfter(Integer retryAfter) { - this.retryAfter = retryAfter; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the BatchAccountsDeleteHeaders object itself. - */ - public BatchAccountsDeleteHeaders withLocation(String location) { - this.location = location; - 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/BatchAccountsDeleteResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsDeleteResponse.java deleted file mode 100644 index 7fb616d19e8b..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/BatchAccountsDeleteResponse.java +++ /dev/null @@ -1,26 +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.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; - -/** Contains all response data for the delete operation. */ -public final class BatchAccountsDeleteResponse extends ResponseBase { - /** - * Creates an instance of BatchAccountsDeleteResponse. - * - * @param request the request which resulted in this BatchAccountsDeleteResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public BatchAccountsDeleteResponse( - HttpRequest request, int statusCode, HttpHeaders rawHeaders, Void value, BatchAccountsDeleteHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } -} 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 fe91bdf12724..7ec5d5a75c8e 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 @@ -29,6 +29,10 @@ public class BatchPoolIdentity { @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) private Map userAssignedIdentities; + /** Creates an instance of BatchPoolIdentity class. */ + public BatchPoolIdentity() { + } + /** * Get the type property: The type of identity used for the Batch Pool. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CachingType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CachingType.java index b23941a5b231..0ae392d80662 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CachingType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CachingType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for CachingType. */ +/** The type of caching to enable for the disk. */ public enum CachingType { /** Enum value None. */ NONE("None"), @@ -33,6 +33,9 @@ public enum CachingType { */ @JsonCreator public static CachingType fromString(String value) { + if (value == null) { + return null; + } CachingType[] items = CachingType.values(); for (CachingType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static CachingType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 a539d210ef23..295fb339ef80 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 @@ -84,15 +84,18 @@ public interface Certificate { DeleteCertificateError deleteCertificateError(); /** - * Gets the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Gets the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @return the thumbprintAlgorithm value. */ String thumbprintAlgorithm(); /** - * Gets the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Gets the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @return the thumbprint value. */ @@ -105,6 +108,13 @@ public interface Certificate { */ CertificateFormat format(); + /** + * Gets the name of the resource group. + * + * @return the name of the resource group. + */ + String resourceGroupName(); + /** * Gets the inner com.azure.resourcemanager.batch.fluent.models.CertificateInner object. * @@ -137,8 +147,7 @@ interface WithParentResource { * to be created, but also allows for any other optional properties to be specified. */ interface WithCreate - extends DefinitionStages.WithData, - DefinitionStages.WithPassword, + extends DefinitionStages.WithPassword, DefinitionStages.WithThumbprintAlgorithm, DefinitionStages.WithThumbprint, DefinitionStages.WithFormat, @@ -159,24 +168,15 @@ interface WithCreate */ Certificate create(Context context); } - /** The stage of the Certificate definition allowing to specify data. */ - interface WithData { - /** - * Specifies the data property: The base64-encoded contents of the certificate. The maximum size is 10KB.. - * - * @param data The base64-encoded contents of the certificate. The maximum size is 10KB. - * @return the next definition stage. - */ - WithCreate withData(String data); - } /** The stage of the Certificate definition allowing to specify password. */ interface WithPassword { /** - * Specifies the password property: The password to access the certificate's private key. This must not be - * specified if the certificate format is Cer.. + * Specifies the password property: The password to access the certificate's private key. * - * @param password The password to access the certificate's private key. This must not be specified if the - * certificate format is Cer. + *

This must not be specified if the certificate format is Cer.. + * + * @param password The password to access the certificate's private key. + *

This must not be specified if the certificate format is Cer. * @return the next definition stage. */ WithCreate withPassword(String password); @@ -184,11 +184,12 @@ interface WithPassword { /** The stage of the Certificate definition allowing to specify thumbprintAlgorithm. */ interface WithThumbprintAlgorithm { /** - * Specifies the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match - * the first portion of the certificate name. Currently required to be 'SHA1'.. + * Specifies the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'.. * - * @param thumbprintAlgorithm The algorithm of the certificate thumbprint. This must match the first portion - * of the certificate name. Currently required to be 'SHA1'. + * @param thumbprintAlgorithm The algorithm of the certificate thumbprint. + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * @return the next definition stage. */ WithCreate withThumbprintAlgorithm(String thumbprintAlgorithm); @@ -196,10 +197,12 @@ interface WithThumbprintAlgorithm { /** The stage of the Certificate definition allowing to specify thumbprint. */ interface WithThumbprint { /** - * Specifies the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from - * the name.. + * Specifies the thumbprint property: The thumbprint of the certificate. * - * @param thumbprint The thumbprint of the certificate. This must match the thumbprint from the name. + *

This must match the thumbprint from the name.. + * + * @param thumbprint The thumbprint of the certificate. + *

This must match the thumbprint from the name. * @return the next definition stage. */ WithCreate withThumbprint(String thumbprint); @@ -277,9 +280,12 @@ interface UpdateStages { /** The stage of the Certificate update allowing to specify data. */ interface WithData { /** - * Specifies the data property: The base64-encoded contents of the certificate. The maximum size is 10KB.. + * Specifies the data property: The base64-encoded contents of the certificate. + * + *

The maximum size is 10KB.. * - * @param data The base64-encoded contents of the certificate. The maximum size is 10KB. + * @param data The base64-encoded contents of the certificate. + *

The maximum size is 10KB. * @return the next definition stage. */ Update withData(String data); @@ -287,11 +293,12 @@ interface WithData { /** The stage of the Certificate update allowing to specify password. */ interface WithPassword { /** - * Specifies the password property: The password to access the certificate's private key. This must not be - * specified if the certificate format is Cer.. + * Specifies the password property: The password to access the certificate's private key. * - * @param password The password to access the certificate's private key. This must not be specified if the - * certificate format is Cer. + *

This must not be specified if the certificate format is Cer.. + * + * @param password The password to access the certificate's private key. + *

This must not be specified if the certificate format is Cer. * @return the next definition stage. */ Update withPassword(String password); @@ -299,11 +306,12 @@ interface WithPassword { /** The stage of the Certificate update allowing to specify thumbprintAlgorithm. */ interface WithThumbprintAlgorithm { /** - * Specifies the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match - * the first portion of the certificate name. Currently required to be 'SHA1'.. + * Specifies the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'.. * - * @param thumbprintAlgorithm The algorithm of the certificate thumbprint. This must match the first portion - * of the certificate name. Currently required to be 'SHA1'. + * @param thumbprintAlgorithm The algorithm of the certificate thumbprint. + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * @return the next definition stage. */ Update withThumbprintAlgorithm(String thumbprintAlgorithm); @@ -311,10 +319,12 @@ interface WithThumbprintAlgorithm { /** The stage of the Certificate update allowing to specify thumbprint. */ interface WithThumbprint { /** - * Specifies the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from - * the name.. + * Specifies the thumbprint property: The thumbprint of the certificate. * - * @param thumbprint The thumbprint of the certificate. This must match the thumbprint from the name. + *

This must match the thumbprint from the name.. + * + * @param thumbprint The thumbprint of the certificate. + *

This must match the thumbprint from the name. * @return the next definition stage. */ Update withThumbprint(String thumbprint); @@ -359,30 +369,40 @@ interface WithIfMatch { Certificate refresh(Context context); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * + * @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 contains information about a certificate. */ - Certificate cancelDeletion(); + Response cancelDeletionWithResponse(Context context); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @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 contains information about a certificate. */ - Response cancelDeletionWithResponse(Context context); + Certificate cancelDeletion(); } 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 febee53ee23f..57ec8b1579aa 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 @@ -11,29 +11,35 @@ @Fluent public class CertificateBaseProperties { /* - * The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * The algorithm of the certificate thumbprint. + * + * This must match the first portion of the certificate name. Currently required to be 'SHA1'. */ @JsonProperty(value = "thumbprintAlgorithm") private String thumbprintAlgorithm; /* - * The thumbprint of the certificate. This must match the thumbprint from - * the name. + * The thumbprint of the certificate. + * + * This must match the thumbprint from the name. */ @JsonProperty(value = "thumbprint") private String thumbprint; /* - * The format of the certificate - either Pfx or Cer. If omitted, the - * default is Pfx. + * The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. */ @JsonProperty(value = "format") private CertificateFormat format; + /** Creates an instance of CertificateBaseProperties class. */ + public CertificateBaseProperties() { + } + /** - * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @return the thumbprintAlgorithm value. */ @@ -42,8 +48,9 @@ public String thumbprintAlgorithm() { } /** - * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @param thumbprintAlgorithm the thumbprintAlgorithm value to set. * @return the CertificateBaseProperties object itself. @@ -54,7 +61,9 @@ public CertificateBaseProperties withThumbprintAlgorithm(String thumbprintAlgori } /** - * Get the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Get the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @return the thumbprint value. */ @@ -63,7 +72,9 @@ public String thumbprint() { } /** - * Set the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Set the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @param thumbprint the thumbprint value to set. * @return the CertificateBaseProperties object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateCreateOrUpdateParameters.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateCreateOrUpdateParameters.java index d9596bfc632d..411f3d7f48c2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateCreateOrUpdateParameters.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateCreateOrUpdateParameters.java @@ -24,6 +24,10 @@ public final class CertificateCreateOrUpdateParameters extends ProxyResource { @JsonProperty(value = "etag", access = JsonProperty.Access.WRITE_ONLY) private String etag; + /** Creates an instance of CertificateCreateOrUpdateParameters class. */ + public CertificateCreateOrUpdateParameters() { + } + /** * Get the innerProperties property: The properties associated with the certificate. * @@ -43,7 +47,9 @@ public String etag() { } /** - * Get the data property: The base64-encoded contents of the certificate. The maximum size is 10KB. + * Get the data property: The base64-encoded contents of the certificate. + * + *

The maximum size is 10KB. * * @return the data value. */ @@ -52,7 +58,9 @@ public String data() { } /** - * Set the data property: The base64-encoded contents of the certificate. The maximum size is 10KB. + * Set the data property: The base64-encoded contents of the certificate. + * + *

The maximum size is 10KB. * * @param data the data value to set. * @return the CertificateCreateOrUpdateParameters object itself. @@ -66,8 +74,9 @@ public CertificateCreateOrUpdateParameters withData(String data) { } /** - * Get the password property: The password to access the certificate's private key. This must not be specified if - * the certificate format is Cer. + * Get the password property: The password to access the certificate's private key. + * + *

This must not be specified if the certificate format is Cer. * * @return the password value. */ @@ -76,8 +85,9 @@ public String password() { } /** - * Set the password property: The password to access the certificate's private key. This must not be specified if - * the certificate format is Cer. + * Set the password property: The password to access the certificate's private key. + * + *

This must not be specified if the certificate format is Cer. * * @param password the password value to set. * @return the CertificateCreateOrUpdateParameters object itself. @@ -91,8 +101,9 @@ public CertificateCreateOrUpdateParameters withPassword(String password) { } /** - * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Get the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @return the thumbprintAlgorithm value. */ @@ -101,8 +112,9 @@ public String thumbprintAlgorithm() { } /** - * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. This must match the first - * portion of the certificate name. Currently required to be 'SHA1'. + * Set the thumbprintAlgorithm property: The algorithm of the certificate thumbprint. + * + *

This must match the first portion of the certificate name. Currently required to be 'SHA1'. * * @param thumbprintAlgorithm the thumbprintAlgorithm value to set. * @return the CertificateCreateOrUpdateParameters object itself. @@ -116,7 +128,9 @@ public CertificateCreateOrUpdateParameters withThumbprintAlgorithm(String thumbp } /** - * Get the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Get the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @return the thumbprint value. */ @@ -125,7 +139,9 @@ public String thumbprint() { } /** - * Set the thumbprint property: The thumbprint of the certificate. This must match the thumbprint from the name. + * Set the thumbprint property: The thumbprint of the certificate. + * + *

This must match the thumbprint from the name. * * @param thumbprint the thumbprint value to set. * @return the CertificateCreateOrUpdateParameters object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateFormat.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateFormat.java index 001cb27180e2..d615af5477fe 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateFormat.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateFormat.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for CertificateFormat. */ +/** The format of the certificate - either Pfx or Cer. If omitted, the default is Pfx. */ public enum CertificateFormat { /** Enum value Pfx. */ PFX("Pfx"), @@ -30,6 +30,9 @@ public enum CertificateFormat { */ @JsonCreator public static CertificateFormat fromString(String value) { + if (value == null) { + return null; + } CertificateFormat[] items = CertificateFormat.values(); for (CertificateFormat item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static CertificateFormat fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProvisioningState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProvisioningState.java index eed1603e9e6b..92dffa181785 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProvisioningState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateProvisioningState.java @@ -33,6 +33,9 @@ public enum CertificateProvisioningState { */ @JsonCreator public static CertificateProvisioningState fromString(String value) { + if (value == null) { + return null; + } CertificateProvisioningState[] items = CertificateProvisioningState.values(); for (CertificateProvisioningState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static CertificateProvisioningState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateReference.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateReference.java index 2e86afe63d0a..15b959370251 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateReference.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateReference.java @@ -12,52 +12,53 @@ /** * A reference to a certificate to be installed on compute nodes in a pool. This must exist inside the same account as * the pool. + * + *

Warning: This object is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. */ @Fluent public final class CertificateReference { /* - * The fully qualified ID of the certificate to install on the pool. This - * must be inside the same batch account as the pool. + * The fully qualified ID of the certificate to install on the pool. This must be inside the same batch account as + * the pool. */ @JsonProperty(value = "id", required = true) private String id; /* - * The location of the certificate store on the compute node into which to - * install the certificate. The default value is currentUser. This property - * is applicable only for pools configured with Windows nodes (that is, - * created with cloudServiceConfiguration, or with - * virtualMachineConfiguration using a Windows image reference). For Linux - * compute nodes, the certificates are stored in a directory inside the - * task working directory and an environment variable - * AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this - * location. For certificates with visibility of 'remoteUser', a 'certs' - * directory is created in the user's home directory (e.g., - * /home/{user-name}/certs) and certificates are placed in that directory. + * The location of the certificate store on the compute node into which to install the certificate. + * + * The default value is currentUser. This property is applicable only for pools configured with Windows nodes (that + * is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image + * reference). For Linux compute nodes, the certificates are stored in a directory inside the task working + * directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this + * location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home + * directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. */ @JsonProperty(value = "storeLocation") private CertificateStoreLocation storeLocation; /* - * The name of the certificate store on the compute node into which to - * install the certificate. This property is applicable only for pools - * configured with Windows nodes (that is, created with - * cloudServiceConfiguration, or with virtualMachineConfiguration using a - * Windows image reference). Common store names include: My, Root, CA, - * Trust, Disallowed, TrustedPeople, TrustedPublisher, AuthRoot, - * AddressBook, but any custom store name can also be used. The default - * value is My. + * The name of the certificate store on the compute node into which to install the certificate. + * + * This property is applicable only for pools configured with Windows nodes (that is, created with + * cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image reference). Common store + * names include: My, Root, CA, Trust, Disallowed, TrustedPeople, TrustedPublisher, AuthRoot, AddressBook, but any + * custom store name can also be used. The default value is My. */ @JsonProperty(value = "storeName") private String storeName; /* - * Which user accounts on the compute node should have access to the - * private data of the certificate. + * Which user accounts on the compute node should have access to the private data of the certificate. */ @JsonProperty(value = "visibility") private List visibility; + /** Creates an instance of CertificateReference class. */ + public CertificateReference() { + } + /** * Get the id property: The fully qualified ID of the certificate to install on the pool. This must be inside the * same batch account as the pool. @@ -82,12 +83,14 @@ public CertificateReference withId(String id) { /** * Get the storeLocation property: The location of the certificate store on the compute node into which to install - * the certificate. The default value is currentUser. This property is applicable only for pools configured with - * Windows nodes (that is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a - * Windows image reference). For Linux compute nodes, the certificates are stored in a directory inside the task - * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this - * location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home - * directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. + * the certificate. + * + *

The default value is currentUser. This property is applicable only for pools configured with Windows nodes + * (that is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image + * reference). For Linux compute nodes, the certificates are stored in a directory inside the task working directory + * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For + * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., + * /home/{user-name}/certs) and certificates are placed in that directory. * * @return the storeLocation value. */ @@ -97,12 +100,14 @@ public CertificateStoreLocation storeLocation() { /** * Set the storeLocation property: The location of the certificate store on the compute node into which to install - * the certificate. The default value is currentUser. This property is applicable only for pools configured with - * Windows nodes (that is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a - * Windows image reference). For Linux compute nodes, the certificates are stored in a directory inside the task - * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this - * location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home - * directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. + * the certificate. + * + *

The default value is currentUser. This property is applicable only for pools configured with Windows nodes + * (that is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image + * reference). For Linux compute nodes, the certificates are stored in a directory inside the task working directory + * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For + * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., + * /home/{user-name}/certs) and certificates are placed in that directory. * * @param storeLocation the storeLocation value to set. * @return the CertificateReference object itself. @@ -114,7 +119,9 @@ public CertificateReference withStoreLocation(CertificateStoreLocation storeLoca /** * Get the storeName property: The name of the certificate store on the compute node into which to install the - * certificate. This property is applicable only for pools configured with Windows nodes (that is, created with + * certificate. + * + *

This property is applicable only for pools configured with Windows nodes (that is, created with * cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image reference). Common store * names include: My, Root, CA, Trust, Disallowed, TrustedPeople, TrustedPublisher, AuthRoot, AddressBook, but any * custom store name can also be used. The default value is My. @@ -127,7 +134,9 @@ public String storeName() { /** * Set the storeName property: The name of the certificate store on the compute node into which to install the - * certificate. This property is applicable only for pools configured with Windows nodes (that is, created with + * certificate. + * + *

This property is applicable only for pools configured with Windows nodes (that is, created with * cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image reference). Common store * names include: My, Root, CA, Trust, Disallowed, TrustedPeople, TrustedPublisher, AuthRoot, AddressBook, but any * custom store name can also be used. The default value is My. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateStoreLocation.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateStoreLocation.java index aed52f92e5da..820f1ac0e416 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateStoreLocation.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateStoreLocation.java @@ -7,7 +7,16 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for CertificateStoreLocation. */ +/** + * The location of the certificate store on the compute node into which to install the certificate. + * + *

The default value is currentUser. This property is applicable only for pools configured with Windows nodes (that + * is, created with cloudServiceConfiguration, or with virtualMachineConfiguration using a Windows image reference). For + * Linux compute nodes, the certificates are stored in a directory inside the task working directory and an environment + * variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For certificates with + * visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., + * /home/{user-name}/certs) and certificates are placed in that directory. + */ public enum CertificateStoreLocation { /** Enum value CurrentUser. */ CURRENT_USER("CurrentUser"), @@ -30,6 +39,9 @@ public enum CertificateStoreLocation { */ @JsonCreator public static CertificateStoreLocation fromString(String value) { + if (value == null) { + return null; + } CertificateStoreLocation[] items = CertificateStoreLocation.values(); for (CertificateStoreLocation item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +51,7 @@ public static CertificateStoreLocation fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateVisibility.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateVisibility.java index 9dd85eb59f06..5e5188d326e8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateVisibility.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificateVisibility.java @@ -33,6 +33,9 @@ public enum CertificateVisibility { */ @JsonCreator public static CertificateVisibility fromString(String value) { + if (value == null) { + return null; + } CertificateVisibility[] items = CertificateVisibility.values(); for (CertificateVisibility item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static CertificateVisibility fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificates.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificates.java index a262f305e838..a9e193bf276c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificates.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Certificates.java @@ -13,6 +13,9 @@ public interface Certificates { /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @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. @@ -25,6 +28,9 @@ public interface Certificates { /** * Lists all of the certificates in the specified account. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param maxresults The maximum number of items to return in the response. @@ -49,6 +55,9 @@ PagedIterable listByBatchAccount( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -62,6 +71,9 @@ PagedIterable listByBatchAccount( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint @@ -76,97 +88,122 @@ PagedIterable listByBatchAccount( /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 information about the specified certificate. + * @return contains information about a certificate. */ - Certificate get(String resourceGroupName, String accountName, String certificateName); + Response getWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context); /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 information about the specified certificate. + * @return contains information about a certificate. */ - Response getWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context); + Certificate get(String resourceGroupName, String accountName, String certificateName); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. + * @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 contains information about a certificate. */ - Certificate cancelDeletion(String resourceGroupName, String accountName, String certificateName); + Response cancelDeletionWithResponse( + String resourceGroupName, String accountName, String certificateName, Context context); /** - * If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate + * Cancels a failed deletion of a certificate from the specified account. + * + *

If you try to delete a certificate that is being used by a pool or compute node, the status of the certificate * changes to deleteFailed. If you decide that you want to continue using the certificate, you can use this * operation to set the status of the certificate back to active. If you intend to delete the certificate, you do * not need to run this operation after the deletion failed. You must make sure that the certificate is not being * used by any resources, and then you can try again to delete the certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param certificateName The identifier for the certificate. This must be made up of algorithm and thumbprint * separated by a dash, and must match the certificate data in the request. For example SHA1-a3d1c5. - * @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 contains information about a certificate. */ - Response cancelDeletionWithResponse( - String resourceGroupName, String accountName, String certificateName, Context context); + Certificate cancelDeletion(String resourceGroupName, String accountName, String certificateName); /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param id the resource ID. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return information about the specified certificate. + * @return contains information about a certificate. */ Certificate getById(String id); /** * Gets information about the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param id the resource ID. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return information about the specified certificate. + * @return contains information about a certificate. */ Response getByIdWithResponse(String id, Context context); /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param id the resource ID. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -177,6 +214,9 @@ Response cancelDeletionWithResponse( /** * Deletes the specified certificate. * + *

Warning: This operation is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @param id the resource ID. * @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/CertificatesCancelDeletionHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionHeaders.java index 7e2a5d85a500..15672ac78cb6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The CertificatesCancelDeletionHeaders model. */ @@ -16,6 +17,16 @@ public final class CertificatesCancelDeletionHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of CertificatesCancelDeletionHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public CertificatesCancelDeletionHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionResponse.java index c1a1b17048fc..6810f1ae6776 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCancelDeletionResponse.java @@ -30,7 +30,11 @@ public CertificatesCancelDeletionResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public CertificateInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateHeaders.java index f66b743e7238..44b2e08b9568 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The CertificatesCreateHeaders model. */ @@ -16,6 +17,16 @@ public final class CertificatesCreateHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of CertificatesCreateHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public CertificatesCreateHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateResponse.java index 190b8bd05497..16ff684f0791 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesCreateResponse.java @@ -29,7 +29,11 @@ public CertificatesCreateResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public CertificateInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesDeleteHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesDeleteHeaders.java deleted file mode 100644 index 4faed4f46b5b..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesDeleteHeaders.java +++ /dev/null @@ -1,72 +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.Fluent; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The CertificatesDeleteHeaders model. */ -@Fluent -public final class CertificatesDeleteHeaders { - /* - * The Retry-After property. - */ - @JsonProperty(value = "Retry-After") - private Integer retryAfter; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the retryAfter property: The Retry-After property. - * - * @return the retryAfter value. - */ - public Integer retryAfter() { - return this.retryAfter; - } - - /** - * Set the retryAfter property: The Retry-After property. - * - * @param retryAfter the retryAfter value to set. - * @return the CertificatesDeleteHeaders object itself. - */ - public CertificatesDeleteHeaders withRetryAfter(Integer retryAfter) { - this.retryAfter = retryAfter; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the CertificatesDeleteHeaders object itself. - */ - public CertificatesDeleteHeaders withLocation(String location) { - this.location = location; - 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/CertificatesDeleteResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesDeleteResponse.java deleted file mode 100644 index c4203bca6627..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesDeleteResponse.java +++ /dev/null @@ -1,26 +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.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; - -/** Contains all response data for the delete operation. */ -public final class CertificatesDeleteResponse extends ResponseBase { - /** - * Creates an instance of CertificatesDeleteResponse. - * - * @param request the request which resulted in this CertificatesDeleteResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public CertificatesDeleteResponse( - HttpRequest request, int statusCode, HttpHeaders rawHeaders, Void value, CertificatesDeleteHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } -} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetHeaders.java index 0acfac9fe7e6..abb6af643c3a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The CertificatesGetHeaders model. */ @@ -16,6 +17,16 @@ public final class CertificatesGetHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of CertificatesGetHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public CertificatesGetHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetResponse.java index 7f3da4712b33..58256f6e499b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesGetResponse.java @@ -29,7 +29,11 @@ public CertificatesGetResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public CertificateInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateHeaders.java index 86c2c3e4b00b..3993c7f53765 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The CertificatesUpdateHeaders model. */ @@ -16,6 +17,16 @@ public final class CertificatesUpdateHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of CertificatesUpdateHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public CertificatesUpdateHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateResponse.java index 6069707cc894..4507079390fb 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CertificatesUpdateResponse.java @@ -29,7 +29,11 @@ public CertificatesUpdateResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public CertificateInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CifsMountConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CifsMountConfiguration.java index c8c48613c9b8..c16717d09462 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CifsMountConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CifsMountConfiguration.java @@ -14,7 +14,7 @@ public final class CifsMountConfiguration { /* * The user to use for authentication against the CIFS file system. */ - @JsonProperty(value = "username", required = true) + @JsonProperty(value = "userName") private String username; /* @@ -24,17 +24,18 @@ public final class CifsMountConfiguration { private String source; /* - * The relative path on the compute node where the file system will be - * mounted All file systems are mounted relative to the Batch mounts - * directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR environment - * variable. + * The relative path on the compute node where the file system will be mounted + * + * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR + * environment variable. */ @JsonProperty(value = "relativeMountPath", required = true) private String relativeMountPath; /* - * Additional command line options to pass to the mount command. These are - * 'net use' options in Windows and 'mount' options in Linux. + * Additional command line options to pass to the mount command. + * + * These are 'net use' options in Windows and 'mount' options in Linux. */ @JsonProperty(value = "mountOptions") private String mountOptions; @@ -45,6 +46,10 @@ public final class CifsMountConfiguration { @JsonProperty(value = "password", required = true) private String password; + /** Creates an instance of CifsMountConfiguration class. */ + public CifsMountConfiguration() { + } + /** * Get the username property: The user to use for authentication against the CIFS file system. * @@ -87,8 +92,9 @@ public CifsMountConfiguration withSource(String source) { /** * Get the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @return the relativeMountPath value. */ @@ -98,8 +104,9 @@ public String relativeMountPath() { /** * Set the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @param relativeMountPath the relativeMountPath value to set. * @return the CifsMountConfiguration object itself. @@ -110,8 +117,9 @@ public CifsMountConfiguration withRelativeMountPath(String relativeMountPath) { } /** - * Get the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Get the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @return the mountOptions value. */ @@ -120,8 +128,9 @@ public String mountOptions() { } /** - * Set the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Set the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @param mountOptions the mountOptions value to set. * @return the CifsMountConfiguration object itself. @@ -157,11 +166,6 @@ public CifsMountConfiguration withPassword(String password) { * @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 CifsMountConfiguration")); - } if (source() == null) { throw LOGGER .logExceptionAsError( diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CloudServiceConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CloudServiceConfiguration.java index d80e6cc967be..1dff3b19a5c0 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CloudServiceConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/CloudServiceConfiguration.java @@ -12,28 +12,32 @@ @Fluent public final class CloudServiceConfiguration { /* - * The Azure Guest OS family to be installed on the virtual machines in the - * pool. Possible values are: 2 - OS Family 2, equivalent to Windows Server - * 2008 R2 SP1. 3 - OS Family 3, equivalent to Windows Server 2012. 4 - OS - * Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, - * equivalent to Windows Server 2016. 6 - OS Family 6, equivalent to - * Windows Server 2019. For more information, see Azure Guest OS Releases - * (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). + * The Azure Guest OS family to be installed on the virtual machines in the pool. + * + * Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 - OS Family 3, equivalent to + * Windows Server 2012. 4 - OS Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, equivalent to + * Windows Server 2016. 6 - OS Family 6, equivalent to Windows Server 2019. For more information, see Azure Guest + * OS Releases (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). */ @JsonProperty(value = "osFamily", required = true) private String osFamily; /* - * The Azure Guest OS version to be installed on the virtual machines in - * the pool. The default value is * which specifies the latest operating - * system version for the specified OS family. + * The Azure Guest OS version to be installed on the virtual machines in the pool. + * + * The default value is * which specifies the latest operating system version for the specified OS family. */ @JsonProperty(value = "osVersion") private String osVersion; + /** Creates an instance of CloudServiceConfiguration class. */ + public CloudServiceConfiguration() { + } + /** * Get the osFamily property: The Azure Guest OS family to be installed on the virtual machines in the pool. - * Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 - OS Family 3, equivalent to + * + *

Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 - OS Family 3, equivalent to * Windows Server 2012. 4 - OS Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, equivalent to * Windows Server 2016. 6 - OS Family 6, equivalent to Windows Server 2019. For more information, see Azure Guest OS * Releases (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). @@ -46,7 +50,8 @@ public String osFamily() { /** * Set the osFamily property: The Azure Guest OS family to be installed on the virtual machines in the pool. - * Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 - OS Family 3, equivalent to + * + *

Possible values are: 2 - OS Family 2, equivalent to Windows Server 2008 R2 SP1. 3 - OS Family 3, equivalent to * Windows Server 2012. 4 - OS Family 4, equivalent to Windows Server 2012 R2. 5 - OS Family 5, equivalent to * Windows Server 2016. 6 - OS Family 6, equivalent to Windows Server 2019. For more information, see Azure Guest OS * Releases (https://azure.microsoft.com/documentation/articles/cloud-services-guestos-update-matrix/#releases). @@ -60,8 +65,9 @@ public CloudServiceConfiguration withOsFamily(String osFamily) { } /** - * Get the osVersion property: The Azure Guest OS version to be installed on the virtual machines in the pool. The - * default value is * which specifies the latest operating system version for the specified OS family. + * Get the osVersion property: The Azure Guest OS version to be installed on the virtual machines in the pool. + * + *

The default value is * which specifies the latest operating system version for the specified OS family. * * @return the osVersion value. */ @@ -70,8 +76,9 @@ public String osVersion() { } /** - * Set the osVersion property: The Azure Guest OS version to be installed on the virtual machines in the pool. The - * default value is * which specifies the latest operating system version for the specified OS family. + * Set the osVersion property: The Azure Guest OS version to be installed on the virtual machines in the pool. + * + *

The default value is * which specifies the latest operating system version for the specified OS family. * * @param osVersion the osVersion value to set. * @return the CloudServiceConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeDeallocationOption.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeDeallocationOption.java index 592739dcd6b6..a796276da63c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeDeallocationOption.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeDeallocationOption.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ComputeNodeDeallocationOption. */ +/** Determines what to do with a node and its running task(s) after it has been selected for deallocation. */ public enum ComputeNodeDeallocationOption { /** Enum value Requeue. */ REQUEUE("Requeue"), @@ -36,6 +36,9 @@ public enum ComputeNodeDeallocationOption { */ @JsonCreator public static ComputeNodeDeallocationOption fromString(String value) { + if (value == null) { + return null; + } ComputeNodeDeallocationOption[] items = ComputeNodeDeallocationOption.values(); for (ComputeNodeDeallocationOption item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -45,6 +48,7 @@ public static ComputeNodeDeallocationOption fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeFillType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeFillType.java index 6b0a5bee7a35..1ab0ca97930b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeFillType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ComputeNodeFillType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ComputeNodeFillType. */ +/** How tasks should be distributed across compute nodes. */ public enum ComputeNodeFillType { /** Enum value Spread. */ SPREAD("Spread"), @@ -30,6 +30,9 @@ public enum ComputeNodeFillType { */ @JsonCreator public static ComputeNodeFillType fromString(String value) { + if (value == null) { + return null; + } ComputeNodeFillType[] items = ComputeNodeFillType.values(); for (ComputeNodeFillType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static ComputeNodeFillType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 index 5472e0eadeb9..1d6aac4f7e00 100644 --- 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 @@ -16,6 +16,10 @@ public final class ComputeNodeIdentityReference { @JsonProperty(value = "resourceId") private String resourceId; + /** Creates an instance of ComputeNodeIdentityReference class. */ + public ComputeNodeIdentityReference() { + } + /** * Get the resourceId property: The ARM resource id of the user assigned identity. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerConfiguration.java index 35a0fa5f3a59..96811efe7f46 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerConfiguration.java @@ -18,18 +18,19 @@ public final class ContainerConfiguration { private String type = "DockerCompatible"; /* - * The collection of container image names. This is the full image - * reference, as would be specified to "docker pull". An image will be - * sourced from the default Docker registry unless the image is fully - * qualified with an alternative registry. + * The collection of container image names. + * + * This is the full image reference, as would be specified to "docker pull". An image will be sourced from the + * default Docker registry unless the image is fully qualified with an alternative registry. */ @JsonProperty(value = "containerImageNames") private List containerImageNames; /* - * Additional private registries from which containers can be pulled. If - * any images must be downloaded from a private registry which requires - * credentials, then those credentials must be provided here. + * Additional private registries from which containers can be pulled. + * + * If any images must be downloaded from a private registry which requires credentials, then those credentials must + * be provided here. */ @JsonProperty(value = "containerRegistries") private List containerRegistries; @@ -60,9 +61,10 @@ public ContainerConfiguration withType(String type) { } /** - * Get the containerImageNames property: The collection of container image names. This is the full image reference, - * as would be specified to "docker pull". An image will be sourced from the default Docker registry unless the - * image is fully qualified with an alternative registry. + * Get the containerImageNames property: The collection of container image names. + * + *

This is the full image reference, as would be specified to "docker pull". An image will be sourced from the + * default Docker registry unless the image is fully qualified with an alternative registry. * * @return the containerImageNames value. */ @@ -71,9 +73,10 @@ public List containerImageNames() { } /** - * Set the containerImageNames property: The collection of container image names. This is the full image reference, - * as would be specified to "docker pull". An image will be sourced from the default Docker registry unless the - * image is fully qualified with an alternative registry. + * Set the containerImageNames property: The collection of container image names. + * + *

This is the full image reference, as would be specified to "docker pull". An image will be sourced from the + * default Docker registry unless the image is fully qualified with an alternative registry. * * @param containerImageNames the containerImageNames value to set. * @return the ContainerConfiguration object itself. @@ -84,9 +87,10 @@ public ContainerConfiguration withContainerImageNames(List containerImag } /** - * Get the containerRegistries property: Additional private registries from which containers can be pulled. If any - * images must be downloaded from a private registry which requires credentials, then those credentials must be - * provided here. + * Get the containerRegistries property: Additional private registries from which containers can be pulled. + * + *

If any images must be downloaded from a private registry which requires credentials, then those credentials + * must be provided here. * * @return the containerRegistries value. */ @@ -95,9 +99,10 @@ public List containerRegistries() { } /** - * Set the containerRegistries property: Additional private registries from which containers can be pulled. If any - * images must be downloaded from a private registry which requires credentials, then those credentials must be - * provided here. + * Set the containerRegistries property: Additional private registries from which containers can be pulled. + * + *

If any images must be downloaded from a private registry which requires credentials, then those credentials + * must be provided here. * * @param containerRegistries the containerRegistries value to set. * @return the ContainerConfiguration object itself. 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 aa170fe86be8..012e5b8f1dc3 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 @@ -23,18 +23,23 @@ public final class ContainerRegistry { private String password; /* - * The registry URL. If omitted, the default is "docker.io". + * The registry URL. + * + * If omitted, the default is "docker.io". */ @JsonProperty(value = "registryServer") private String registryServer; /* - * The reference to a user assigned identity associated with the Batch pool - * which a compute node will use. + * The reference to a user assigned identity associated with the Batch pool which a compute node will use. */ @JsonProperty(value = "identityReference") private ComputeNodeIdentityReference identityReference; + /** Creates an instance of ContainerRegistry class. */ + public ContainerRegistry() { + } + /** * Get the username property: The user name to log into the registry server. * @@ -76,7 +81,9 @@ public ContainerRegistry withPassword(String password) { } /** - * Get the registryServer property: The registry URL. If omitted, the default is "docker.io". + * Get the registryServer property: The registry URL. + * + *

If omitted, the default is "docker.io". * * @return the registryServer value. */ @@ -85,7 +92,9 @@ public String registryServer() { } /** - * Set the registryServer property: The registry URL. If omitted, the default is "docker.io". + * Set the registryServer property: The registry URL. + * + *

If omitted, the default is "docker.io". * * @param registryServer the registryServer value to set. * @return the ContainerRegistry object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerWorkingDirectory.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerWorkingDirectory.java index e0defa22c5fb..43ec9da651f1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerWorkingDirectory.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ContainerWorkingDirectory.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ContainerWorkingDirectory. */ +/** A flag to indicate where the container task working directory is. The default is 'taskWorkingDirectory'. */ public enum ContainerWorkingDirectory { /** Enum value TaskWorkingDirectory. */ TASK_WORKING_DIRECTORY("TaskWorkingDirectory"), @@ -30,6 +30,9 @@ public enum ContainerWorkingDirectory { */ @JsonCreator public static ContainerWorkingDirectory fromString(String value) { + if (value == null) { + return null; + } ContainerWorkingDirectory[] items = ContainerWorkingDirectory.values(); for (ContainerWorkingDirectory item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static ContainerWorkingDirectory fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DataDisk.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DataDisk.java index ba3b931ba115..69266168b708 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DataDisk.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DataDisk.java @@ -14,22 +14,24 @@ @Fluent public final class DataDisk { /* - * The logical unit number. The lun is used to uniquely identify each data - * disk. If attaching multiple disks, each should have a distinct lun. The - * value must be between 0 and 63, inclusive. + * The logical unit number. + * + * The lun is used to uniquely identify each data disk. If attaching multiple disks, each should have a distinct + * lun. The value must be between 0 and 63, inclusive. */ @JsonProperty(value = "lun", required = true) private int lun; /* - * The type of caching to enable for the disk. Values are: + * The type of caching to enable for the disk. + * + * Values are: * * none - The caching mode for the disk is not enabled. * readOnly - The caching mode for the disk is read only. * readWrite - The caching mode for the disk is read and write. * - * The default value for caching is none. For information about the caching - * options see: + * The default value for caching is none. For information about the caching options see: * https://blogs.msdn.microsoft.com/windowsazurestorage/2012/06/27/exploring-windows-azure-drives-disks-and-images/. */ @JsonProperty(value = "caching") @@ -42,20 +44,25 @@ public final class DataDisk { private int diskSizeGB; /* - * The storage account type for use in creating data disks. If omitted, the - * default is "Standard_LRS". Values are: + * The storage account type for use in creating data disks. + * + * If omitted, the default is "Standard_LRS". Values are: * - * Standard_LRS - The data disk should use standard locally redundant - * storage. - * Premium_LRS - The data disk should use premium locally redundant - * storage. + * Standard_LRS - The data disk should use standard locally redundant storage. + * Premium_LRS - The data disk should use premium locally redundant storage. */ @JsonProperty(value = "storageAccountType") private StorageAccountType storageAccountType; + /** Creates an instance of DataDisk class. */ + public DataDisk() { + } + /** - * Get the lun property: The logical unit number. The lun is used to uniquely identify each data disk. If attaching - * multiple disks, each should have a distinct lun. The value must be between 0 and 63, inclusive. + * Get the lun property: The logical unit number. + * + *

The lun is used to uniquely identify each data disk. If attaching multiple disks, each should have a distinct + * lun. The value must be between 0 and 63, inclusive. * * @return the lun value. */ @@ -64,8 +71,10 @@ public int lun() { } /** - * Set the lun property: The logical unit number. The lun is used to uniquely identify each data disk. If attaching - * multiple disks, each should have a distinct lun. The value must be between 0 and 63, inclusive. + * Set the lun property: The logical unit number. + * + *

The lun is used to uniquely identify each data disk. If attaching multiple disks, each should have a distinct + * lun. The value must be between 0 and 63, inclusive. * * @param lun the lun value to set. * @return the DataDisk object itself. @@ -76,7 +85,9 @@ public DataDisk withLun(int lun) { } /** - * Get the caching property: The type of caching to enable for the disk. Values are: + * Get the caching property: The type of caching to enable for the disk. + * + *

Values are: * *

none - The caching mode for the disk is not enabled. readOnly - The caching mode for the disk is read only. * readWrite - The caching mode for the disk is read and write. @@ -91,7 +102,9 @@ public CachingType caching() { } /** - * Set the caching property: The type of caching to enable for the disk. Values are: + * Set the caching property: The type of caching to enable for the disk. + * + *

Values are: * *

none - The caching mode for the disk is not enabled. readOnly - The caching mode for the disk is read only. * readWrite - The caching mode for the disk is read and write. @@ -128,8 +141,9 @@ public DataDisk withDiskSizeGB(int diskSizeGB) { } /** - * Get the storageAccountType property: The storage account type for use in creating data disks. If omitted, the - * default is "Standard_LRS". Values are: + * Get the storageAccountType property: The storage account type for use in creating data disks. + * + *

If omitted, the default is "Standard_LRS". Values are: * *

Standard_LRS - The data disk should use standard locally redundant storage. Premium_LRS - The data disk should * use premium locally redundant storage. @@ -141,8 +155,9 @@ public StorageAccountType storageAccountType() { } /** - * Set the storageAccountType property: The storage account type for use in creating data disks. If omitted, the - * default is "Standard_LRS". Values are: + * Set the storageAccountType property: The storage account type for use in creating data disks. + * + *

If omitted, the default is "Standard_LRS". Values are: * *

Standard_LRS - The data disk should use standard locally redundant storage. Premium_LRS - The data disk should * use premium locally redundant storage. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeleteCertificateError.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeleteCertificateError.java index cbd3b50ae77e..eda4c4224f3b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeleteCertificateError.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeleteCertificateError.java @@ -13,22 +13,19 @@ @Fluent public final class DeleteCertificateError { /* - * An identifier for the error. Codes are invariant and are intended to be - * consumed programmatically. + * An identifier for the error. Codes are invariant and are intended to be consumed programmatically. */ @JsonProperty(value = "code", required = true) private String code; /* - * A message describing the error, intended to be suitable for display in a - * user interface. + * A message describing the error, intended to be suitable for display in a user interface. */ @JsonProperty(value = "message", required = true) private String message; /* - * The target of the particular error. For example, the name of the - * property in error. + * The target of the particular error. For example, the name of the property in error. */ @JsonProperty(value = "target") private String target; @@ -39,6 +36,10 @@ public final class DeleteCertificateError { @JsonProperty(value = "details") private List details; + /** Creates an instance of DeleteCertificateError class. */ + public DeleteCertificateError() { + } + /** * Get the code property: An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeploymentConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeploymentConfiguration.java index b4127d1ff1c5..95e37b4fcdc2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeploymentConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DeploymentConfiguration.java @@ -11,27 +11,33 @@ @Fluent public final class DeploymentConfiguration { /* - * The configuration for nodes in a pool based on the Azure Cloud Services - * platform. This property and virtualMachineConfiguration are mutually - * exclusive and one of the properties must be specified. This property - * cannot be specified if the Batch account was created with its - * poolAllocationMode property set to 'UserSubscription'. + * The configuration for nodes in a pool based on the Azure Cloud Services platform. + * + * This property and virtualMachineConfiguration are mutually exclusive and one of the properties must be + * specified. This property cannot be specified if the Batch account was created with its poolAllocationMode + * property set to 'UserSubscription'. */ @JsonProperty(value = "cloudServiceConfiguration") private CloudServiceConfiguration cloudServiceConfiguration; /* - * The configuration for compute nodes in a pool based on the Azure Virtual - * Machines infrastructure. This property and cloudServiceConfiguration are - * mutually exclusive and one of the properties must be specified. + * The configuration for compute nodes in a pool based on the Azure Virtual Machines infrastructure. + * + * This property and cloudServiceConfiguration are mutually exclusive and one of the properties must be specified. */ @JsonProperty(value = "virtualMachineConfiguration") private VirtualMachineConfiguration virtualMachineConfiguration; + /** Creates an instance of DeploymentConfiguration class. */ + public DeploymentConfiguration() { + } + /** * Get the cloudServiceConfiguration property: The configuration for nodes in a pool based on the Azure Cloud - * Services platform. This property and virtualMachineConfiguration are mutually exclusive and one of the properties - * must be specified. This property cannot be specified if the Batch account was created with its poolAllocationMode + * Services platform. + * + *

This property and virtualMachineConfiguration are mutually exclusive and one of the properties must be + * specified. This property cannot be specified if the Batch account was created with its poolAllocationMode * property set to 'UserSubscription'. * * @return the cloudServiceConfiguration value. @@ -42,8 +48,10 @@ public CloudServiceConfiguration cloudServiceConfiguration() { /** * Set the cloudServiceConfiguration property: The configuration for nodes in a pool based on the Azure Cloud - * Services platform. This property and virtualMachineConfiguration are mutually exclusive and one of the properties - * must be specified. This property cannot be specified if the Batch account was created with its poolAllocationMode + * Services platform. + * + *

This property and virtualMachineConfiguration are mutually exclusive and one of the properties must be + * specified. This property cannot be specified if the Batch account was created with its poolAllocationMode * property set to 'UserSubscription'. * * @param cloudServiceConfiguration the cloudServiceConfiguration value to set. @@ -56,8 +64,10 @@ public DeploymentConfiguration withCloudServiceConfiguration(CloudServiceConfigu /** * Get the virtualMachineConfiguration property: The configuration for compute nodes in a pool based on the Azure - * Virtual Machines infrastructure. This property and cloudServiceConfiguration are mutually exclusive and one of - * the properties must be specified. + * Virtual Machines infrastructure. + * + *

This property and cloudServiceConfiguration are mutually exclusive and one of the properties must be + * specified. * * @return the virtualMachineConfiguration value. */ @@ -67,8 +77,10 @@ public VirtualMachineConfiguration virtualMachineConfiguration() { /** * Set the virtualMachineConfiguration property: The configuration for compute nodes in a pool based on the Azure - * Virtual Machines infrastructure. This property and cloudServiceConfiguration are mutually exclusive and one of - * the properties must be specified. + * Virtual Machines infrastructure. + * + *

This property and cloudServiceConfiguration are mutually exclusive and one of the properties must be + * specified. * * @param virtualMachineConfiguration the virtualMachineConfiguration value to set. * @return the DeploymentConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DetectorListResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DetectorListResult.java index 05591020a9a6..17cb0073d784 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DetectorListResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DetectorListResult.java @@ -13,8 +13,7 @@ @Fluent public final class DetectorListResult { /* - * The collection of Batch account detectors returned by the listing - * operation. + * The collection of Batch account detectors returned by the listing operation. */ @JsonProperty(value = "value") private List value; @@ -25,6 +24,10 @@ public final class DetectorListResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of DetectorListResult class. */ + public DetectorListResult() { + } + /** * Get the value property: The collection of Batch account detectors returned by the listing operation. * 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 index 9c9ba3e41e9a..ebf4b41b1a56 100644 --- 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 @@ -7,7 +7,15 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for DiffDiskPlacement. */ +/** + * Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. + * + *

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. + */ public enum DiffDiskPlacement { /** Enum value CacheDisk. */ CACHE_DISK("CacheDisk"); @@ -27,6 +35,9 @@ public enum DiffDiskPlacement { */ @JsonCreator public static DiffDiskPlacement fromString(String value) { + if (value == null) { + return null; + } DiffDiskPlacement[] items = DiffDiskPlacement.values(); for (DiffDiskPlacement item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -36,6 +47,7 @@ public static DiffDiskPlacement fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 index b6b70de2ee27..b45222623140 100644 --- 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 @@ -11,22 +11,28 @@ @Fluent public final class DiffDiskSettings { /* - * 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. + * Specifies the ephemeral disk placement for operating system disk for all VMs in the pool. + * + * 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; + /** Creates an instance of DiffDiskSettings class. */ + public DiffDiskSettings() { + } + /** - * 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 + * Get the placement property: Specifies the ephemeral disk placement for operating system disk for all VMs in the + * pool. + * + *

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. * @@ -37,9 +43,12 @@ public DiffDiskPlacement 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 + * Set the placement property: Specifies the ephemeral disk placement for operating system disk for all VMs in the + * pool. + * + *

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. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionConfiguration.java index 57b647cf16be..0b33dbe57cbc 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionConfiguration.java @@ -16,15 +16,22 @@ public final class DiskEncryptionConfiguration { /* * The list of disk targets Batch Service will encrypt on the compute node - * On Linux pool, only "TemporaryDisk" is supported; on Windows pool, - * "OsDisk" and "TemporaryDisk" must be specified. + * + * On Linux pool, only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and "TemporaryDisk" must be + * specified. */ @JsonProperty(value = "targets") private List targets; + /** Creates an instance of DiskEncryptionConfiguration class. */ + public DiskEncryptionConfiguration() { + } + /** - * Get the targets property: The list of disk targets Batch Service will encrypt on the compute node On Linux pool, - * only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and "TemporaryDisk" must be specified. + * Get the targets property: The list of disk targets Batch Service will encrypt on the compute node + * + *

On Linux pool, only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and "TemporaryDisk" must be + * specified. * * @return the targets value. */ @@ -33,8 +40,10 @@ public List targets() { } /** - * Set the targets property: The list of disk targets Batch Service will encrypt on the compute node On Linux pool, - * only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and "TemporaryDisk" must be specified. + * Set the targets property: The list of disk targets Batch Service will encrypt on the compute node + * + *

On Linux pool, only "TemporaryDisk" is supported; on Windows pool, "OsDisk" and "TemporaryDisk" must be + * specified. * * @param targets the targets value to set. * @return the DiskEncryptionConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionTarget.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionTarget.java index f7704335025b..061ee4cbf370 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionTarget.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DiskEncryptionTarget.java @@ -7,7 +7,11 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for DiskEncryptionTarget. */ +/** + * The disks to encrypt on each compute node. + * + *

If omitted, no disks on the compute nodes in the pool will be encrypted. + */ public enum DiskEncryptionTarget { /** Enum value OsDisk. */ OS_DISK("OsDisk"), @@ -30,6 +34,9 @@ public enum DiskEncryptionTarget { */ @JsonCreator public static DiskEncryptionTarget fromString(String value) { + if (value == null) { + return null; + } DiskEncryptionTarget[] items = DiskEncryptionTarget.values(); for (DiskEncryptionTarget item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +46,7 @@ public static DiskEncryptionTarget fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DynamicVNetAssignmentScope.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DynamicVNetAssignmentScope.java index 54195fbc5718..051fc9117cdf 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DynamicVNetAssignmentScope.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/DynamicVNetAssignmentScope.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for DynamicVNetAssignmentScope. */ +/** The scope of dynamic vnet assignment. */ public enum DynamicVNetAssignmentScope { /** Enum value none. */ NONE("none"), @@ -30,6 +30,9 @@ public enum DynamicVNetAssignmentScope { */ @JsonCreator public static DynamicVNetAssignmentScope fromString(String value) { + if (value == null) { + return null; + } DynamicVNetAssignmentScope[] items = DynamicVNetAssignmentScope.values(); for (DynamicVNetAssignmentScope item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static DynamicVNetAssignmentScope fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ElevationLevel.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ElevationLevel.java index f5482daaf99c..1f9bb4a856e8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ElevationLevel.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ElevationLevel.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ElevationLevel. */ +/** The elevation level of the user. */ public enum ElevationLevel { /** Enum value NonAdmin. */ NON_ADMIN("NonAdmin"), @@ -30,6 +30,9 @@ public enum ElevationLevel { */ @JsonCreator public static ElevationLevel fromString(String value) { + if (value == null) { + return null; + } ElevationLevel[] items = ElevationLevel.values(); for (ElevationLevel item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static ElevationLevel fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EncryptionProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EncryptionProperties.java index 97069097a0b7..08931b470349 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EncryptionProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EncryptionProperties.java @@ -25,6 +25,10 @@ public final class EncryptionProperties { @JsonProperty(value = "keyVaultProperties") private KeyVaultProperties keyVaultProperties; + /** Creates an instance of EncryptionProperties class. */ + public EncryptionProperties() { + } + /** * Get the keySource property: Type of the key source. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessDefaultAction.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessDefaultAction.java new file mode 100644 index 000000000000..cac2231176cb --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessDefaultAction.java @@ -0,0 +1,55 @@ +// 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; + +/** + * The default action when there is no IPRule matched. + * + *

Default action for endpoint access. It is only applicable when publicNetworkAccess is enabled. + */ +public enum EndpointAccessDefaultAction { + /** Enum value Allow. */ + ALLOW("Allow"), + + /** Enum value Deny. */ + DENY("Deny"); + + /** The actual serialized value for a EndpointAccessDefaultAction instance. */ + private final String value; + + EndpointAccessDefaultAction(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a EndpointAccessDefaultAction instance. + * + * @param value the serialized value to parse. + * @return the parsed EndpointAccessDefaultAction object, or null if unable to parse. + */ + @JsonCreator + public static EndpointAccessDefaultAction fromString(String value) { + if (value == null) { + return null; + } + EndpointAccessDefaultAction[] items = EndpointAccessDefaultAction.values(); + for (EndpointAccessDefaultAction item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + /** {@inheritDoc} */ + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessProfile.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessProfile.java new file mode 100644 index 000000000000..3942c11f9c93 --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EndpointAccessProfile.java @@ -0,0 +1,95 @@ +// 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.JsonProperty; +import java.util.List; + +/** Network access profile for Batch endpoint. */ +@Fluent +public final class EndpointAccessProfile { + /* + * The default action when there is no IPRule matched. + * + * Default action for endpoint access. It is only applicable when publicNetworkAccess is enabled. + */ + @JsonProperty(value = "defaultAction", required = true) + private EndpointAccessDefaultAction defaultAction; + + /* + * Array of IP ranges to filter client IP address. + */ + @JsonProperty(value = "ipRules") + private List ipRules; + + /** Creates an instance of EndpointAccessProfile class. */ + public EndpointAccessProfile() { + } + + /** + * Get the defaultAction property: The default action when there is no IPRule matched. + * + *

Default action for endpoint access. It is only applicable when publicNetworkAccess is enabled. + * + * @return the defaultAction value. + */ + public EndpointAccessDefaultAction defaultAction() { + return this.defaultAction; + } + + /** + * Set the defaultAction property: The default action when there is no IPRule matched. + * + *

Default action for endpoint access. It is only applicable when publicNetworkAccess is enabled. + * + * @param defaultAction the defaultAction value to set. + * @return the EndpointAccessProfile object itself. + */ + public EndpointAccessProfile withDefaultAction(EndpointAccessDefaultAction defaultAction) { + this.defaultAction = defaultAction; + return this; + } + + /** + * Get the ipRules property: Array of IP ranges to filter client IP address. + * + * @return the ipRules value. + */ + public List ipRules() { + return this.ipRules; + } + + /** + * Set the ipRules property: Array of IP ranges to filter client IP address. + * + * @param ipRules the ipRules value to set. + * @return the EndpointAccessProfile object itself. + */ + public EndpointAccessProfile withIpRules(List ipRules) { + this.ipRules = ipRules; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (defaultAction() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property defaultAction in model EndpointAccessProfile")); + } + if (ipRules() != null) { + ipRules().forEach(e -> e.validate()); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(EndpointAccessProfile.class); +} 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 index 654301aa31b4..b63ad8514dc3 100644 --- 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 @@ -12,15 +12,13 @@ @Immutable public final class EndpointDependency { /* - * The domain name of the dependency. Domain names may be fully qualified - * or may contain a * wildcard. + * 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. + * Human-readable supplemental information about the dependency and when it is applicable. */ @JsonProperty(value = "description", access = JsonProperty.Access.WRITE_ONLY) private String description; @@ -31,6 +29,10 @@ public final class EndpointDependency { @JsonProperty(value = "endpointDetails", access = JsonProperty.Access.WRITE_ONLY) private List endpointDetails; + /** Creates an instance of EndpointDependency class. */ + public EndpointDependency() { + } + /** * Get the domainName property: The domain name of the dependency. Domain names may be fully qualified or may * contain a * wildcard. 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 index 14f43f1bbdb4..80db0d9398f5 100644 --- 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 @@ -16,6 +16,10 @@ public final class EndpointDetail { @JsonProperty(value = "port", access = JsonProperty.Access.WRITE_ONLY) private Integer port; + /** Creates an instance of EndpointDetail class. */ + public EndpointDetail() { + } + /** * Get the port property: The port an endpoint is connected to. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EnvironmentSetting.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EnvironmentSetting.java index c44f2efdb525..6d741d894597 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EnvironmentSetting.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/EnvironmentSetting.java @@ -23,6 +23,10 @@ public final class EnvironmentSetting { @JsonProperty(value = "value") private String value; + /** Creates an instance of EnvironmentSetting class. */ + public EnvironmentSetting() { + } + /** * Get the name property: The name of the environment variable. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/FixedScaleSettings.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/FixedScaleSettings.java index 8a2f639c0280..4a21c2ee4e24 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/FixedScaleSettings.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/FixedScaleSettings.java @@ -12,43 +12,49 @@ @Fluent public final class FixedScaleSettings { /* - * The timeout for allocation of compute nodes to the pool. The default - * value is 15 minutes. Timeout values use ISO 8601 format. For example, - * use PT10M for 10 minutes. The minimum value is 5 minutes. If you specify - * a value less than 5 minutes, the Batch service rejects the request with - * an error; if you are calling the REST API directly, the HTTP status code - * is 400 (Bad Request). + * The timeout for allocation of compute nodes to the pool. + * + * The default value is 15 minutes. Timeout values use ISO 8601 format. For example, use PT10M for 10 minutes. The + * minimum value is 5 minutes. If you specify a value less than 5 minutes, the Batch service rejects the request + * with an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad Request). */ @JsonProperty(value = "resizeTimeout") private Duration resizeTimeout; /* - * The desired number of dedicated compute nodes in the pool. At least one - * of targetDedicatedNodes, targetLowPriorityNodes must be set. + * The desired number of dedicated compute nodes in the pool. + * + * At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. */ @JsonProperty(value = "targetDedicatedNodes") private Integer targetDedicatedNodes; /* - * The desired number of Spot/low-priority compute nodes in the pool. At - * least one of targetDedicatedNodes, targetLowPriorityNodes must be set. + * The desired number of Spot/low-priority compute nodes in the pool. + * + * At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. */ @JsonProperty(value = "targetLowPriorityNodes") private Integer targetLowPriorityNodes; /* - * Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. If omitted, the default value is - * Requeue. + * Determines what to do with a node and its running task(s) after it has been selected for deallocation. + * + * If omitted, the default value is Requeue. */ @JsonProperty(value = "nodeDeallocationOption") private ComputeNodeDeallocationOption nodeDeallocationOption; + /** Creates an instance of FixedScaleSettings class. */ + public FixedScaleSettings() { + } + /** - * Get the resizeTimeout property: The timeout for allocation of compute nodes to the pool. The default value is 15 - * minutes. Timeout values use ISO 8601 format. For example, use PT10M for 10 minutes. The minimum value is 5 - * minutes. If you specify a value less than 5 minutes, the Batch service rejects the request with an error; if you - * are calling the REST API directly, the HTTP status code is 400 (Bad Request). + * Get the resizeTimeout property: The timeout for allocation of compute nodes to the pool. + * + *

The default value is 15 minutes. Timeout values use ISO 8601 format. For example, use PT10M for 10 minutes. + * The minimum value is 5 minutes. If you specify a value less than 5 minutes, the Batch service rejects the request + * with an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad Request). * * @return the resizeTimeout value. */ @@ -57,10 +63,11 @@ public Duration resizeTimeout() { } /** - * Set the resizeTimeout property: The timeout for allocation of compute nodes to the pool. The default value is 15 - * minutes. Timeout values use ISO 8601 format. For example, use PT10M for 10 minutes. The minimum value is 5 - * minutes. If you specify a value less than 5 minutes, the Batch service rejects the request with an error; if you - * are calling the REST API directly, the HTTP status code is 400 (Bad Request). + * Set the resizeTimeout property: The timeout for allocation of compute nodes to the pool. + * + *

The default value is 15 minutes. Timeout values use ISO 8601 format. For example, use PT10M for 10 minutes. + * The minimum value is 5 minutes. If you specify a value less than 5 minutes, the Batch service rejects the request + * with an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad Request). * * @param resizeTimeout the resizeTimeout value to set. * @return the FixedScaleSettings object itself. @@ -71,8 +78,9 @@ public FixedScaleSettings withResizeTimeout(Duration resizeTimeout) { } /** - * Get the targetDedicatedNodes property: The desired number of dedicated compute nodes in the pool. At least one of - * targetDedicatedNodes, targetLowPriorityNodes must be set. + * Get the targetDedicatedNodes property: The desired number of dedicated compute nodes in the pool. + * + *

At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. * * @return the targetDedicatedNodes value. */ @@ -81,8 +89,9 @@ public Integer targetDedicatedNodes() { } /** - * Set the targetDedicatedNodes property: The desired number of dedicated compute nodes in the pool. At least one of - * targetDedicatedNodes, targetLowPriorityNodes must be set. + * Set the targetDedicatedNodes property: The desired number of dedicated compute nodes in the pool. + * + *

At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. * * @param targetDedicatedNodes the targetDedicatedNodes value to set. * @return the FixedScaleSettings object itself. @@ -93,8 +102,9 @@ public FixedScaleSettings withTargetDedicatedNodes(Integer targetDedicatedNodes) } /** - * Get the targetLowPriorityNodes property: The desired number of Spot/low-priority compute nodes in the pool. At - * least one of targetDedicatedNodes, targetLowPriorityNodes must be set. + * Get the targetLowPriorityNodes property: The desired number of Spot/low-priority compute nodes in the pool. + * + *

At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. * * @return the targetLowPriorityNodes value. */ @@ -103,8 +113,9 @@ public Integer targetLowPriorityNodes() { } /** - * Set the targetLowPriorityNodes property: The desired number of Spot/low-priority compute nodes in the pool. At - * least one of targetDedicatedNodes, targetLowPriorityNodes must be set. + * Set the targetLowPriorityNodes property: The desired number of Spot/low-priority compute nodes in the pool. + * + *

At least one of targetDedicatedNodes, targetLowPriorityNodes must be set. * * @param targetLowPriorityNodes the targetLowPriorityNodes value to set. * @return the FixedScaleSettings object itself. @@ -116,7 +127,9 @@ public FixedScaleSettings withTargetLowPriorityNodes(Integer targetLowPriorityNo /** * Get the nodeDeallocationOption property: Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. If omitted, the default value is Requeue. + * been selected for deallocation. + * + *

If omitted, the default value is Requeue. * * @return the nodeDeallocationOption value. */ @@ -126,7 +139,9 @@ public ComputeNodeDeallocationOption nodeDeallocationOption() { /** * Set the nodeDeallocationOption property: Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. If omitted, the default value is Requeue. + * been selected for deallocation. + * + *

If omitted, the default value is Requeue. * * @param nodeDeallocationOption the nodeDeallocationOption value to set. * @return the FixedScaleSettings object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ImageReference.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ImageReference.java index 0deb827e79ad..6c04877b6349 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ImageReference.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ImageReference.java @@ -14,51 +14,59 @@ @Fluent public final class ImageReference { /* - * The publisher of the Azure Virtual Machines Marketplace image. For - * example, Canonical or MicrosoftWindowsServer. + * The publisher of the Azure Virtual Machines Marketplace image. + * + * For example, Canonical or MicrosoftWindowsServer. */ @JsonProperty(value = "publisher") private String publisher; /* - * The offer type of the Azure Virtual Machines Marketplace image. For - * example, UbuntuServer or WindowsServer. + * The offer type of the Azure Virtual Machines Marketplace image. + * + * For example, UbuntuServer or WindowsServer. */ @JsonProperty(value = "offer") private String offer; /* - * The SKU of the Azure Virtual Machines Marketplace image. For example, - * 18.04-LTS or 2022-datacenter. + * The SKU of the Azure Virtual Machines Marketplace image. + * + * For example, 18.04-LTS or 2022-datacenter. */ @JsonProperty(value = "sku") private String sku; /* - * The version of the Azure Virtual Machines Marketplace image. A value of - * 'latest' can be specified to select the latest version of an image. If - * omitted, the default is 'latest'. + * The version of the Azure Virtual Machines Marketplace image. + * + * A value of 'latest' can be specified to select the latest version of an image. If omitted, the default is + * 'latest'. */ @JsonProperty(value = "version") private String version; /* - * The ARM resource identifier of the Shared Image Gallery Image. Compute - * Nodes in the Pool will be created using this Image Id. This is of the - * form + * The ARM resource identifier of the Shared Image Gallery Image. Compute Nodes in the Pool will be created using + * this Image Id. This is of the form * /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{versionId}. - * This property is mutually exclusive with other properties. The Shared - * Image Gallery image must have replicas in the same region as the Azure - * Batch account. For information about the firewall settings for the Batch - * node agent to communicate with the Batch service see + * + * This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas in + * the same region as the Azure Batch account. For information about the firewall settings for the Batch node agent + * to communicate with the Batch service see * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. */ @JsonProperty(value = "id") private String id; + /** Creates an instance of ImageReference class. */ + public ImageReference() { + } + /** - * Get the publisher property: The publisher of the Azure Virtual Machines Marketplace image. For example, Canonical - * or MicrosoftWindowsServer. + * Get the publisher property: The publisher of the Azure Virtual Machines Marketplace image. + * + *

For example, Canonical or MicrosoftWindowsServer. * * @return the publisher value. */ @@ -67,8 +75,9 @@ public String publisher() { } /** - * Set the publisher property: The publisher of the Azure Virtual Machines Marketplace image. For example, Canonical - * or MicrosoftWindowsServer. + * Set the publisher property: The publisher of the Azure Virtual Machines Marketplace image. + * + *

For example, Canonical or MicrosoftWindowsServer. * * @param publisher the publisher value to set. * @return the ImageReference object itself. @@ -79,8 +88,9 @@ public ImageReference withPublisher(String publisher) { } /** - * Get the offer property: The offer type of the Azure Virtual Machines Marketplace image. For example, UbuntuServer - * or WindowsServer. + * Get the offer property: The offer type of the Azure Virtual Machines Marketplace image. + * + *

For example, UbuntuServer or WindowsServer. * * @return the offer value. */ @@ -89,8 +99,9 @@ public String offer() { } /** - * Set the offer property: The offer type of the Azure Virtual Machines Marketplace image. For example, UbuntuServer - * or WindowsServer. + * Set the offer property: The offer type of the Azure Virtual Machines Marketplace image. + * + *

For example, UbuntuServer or WindowsServer. * * @param offer the offer value to set. * @return the ImageReference object itself. @@ -101,8 +112,9 @@ public ImageReference withOffer(String offer) { } /** - * Get the sku property: The SKU of the Azure Virtual Machines Marketplace image. For example, 18.04-LTS or - * 2022-datacenter. + * Get the sku property: The SKU of the Azure Virtual Machines Marketplace image. + * + *

For example, 18.04-LTS or 2022-datacenter. * * @return the sku value. */ @@ -111,8 +123,9 @@ public String sku() { } /** - * Set the sku property: The SKU of the Azure Virtual Machines Marketplace image. For example, 18.04-LTS or - * 2022-datacenter. + * Set the sku property: The SKU of the Azure Virtual Machines Marketplace image. + * + *

For example, 18.04-LTS or 2022-datacenter. * * @param sku the sku value to set. * @return the ImageReference object itself. @@ -123,8 +136,10 @@ public ImageReference withSku(String sku) { } /** - * Get the version property: The version of the Azure Virtual Machines Marketplace image. A value of 'latest' can be - * specified to select the latest version of an image. If omitted, the default is 'latest'. + * Get the version property: The version of the Azure Virtual Machines Marketplace image. + * + *

A value of 'latest' can be specified to select the latest version of an image. If omitted, the default is + * 'latest'. * * @return the version value. */ @@ -133,8 +148,10 @@ public String version() { } /** - * Set the version property: The version of the Azure Virtual Machines Marketplace image. A value of 'latest' can be - * specified to select the latest version of an image. If omitted, the default is 'latest'. + * Set the version property: The version of the Azure Virtual Machines Marketplace image. + * + *

A value of 'latest' can be specified to select the latest version of an image. If omitted, the default is + * 'latest'. * * @param version the version value to set. * @return the ImageReference object itself. @@ -148,9 +165,10 @@ public ImageReference withVersion(String version) { * Get the id property: The ARM resource identifier of the Shared Image Gallery Image. Compute Nodes in the Pool * will be created using this Image Id. This is of the form * /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{versionId}. - * This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas in - * the same region as the Azure Batch account. For information about the firewall settings for the Batch node agent - * to communicate with the Batch service see + * + *

This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas + * in the same region as the Azure Batch account. For information about the firewall settings for the Batch node + * agent to communicate with the Batch service see * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. * * @return the id value. @@ -163,9 +181,10 @@ public String id() { * Set the id property: The ARM resource identifier of the Shared Image Gallery Image. Compute Nodes in the Pool * will be created using this Image Id. This is of the form * /subscriptions/{subscriptionId}/resourceGroups/{resourceGroup}/providers/Microsoft.Compute/galleries/{galleryName}/images/{imageDefinitionName}/versions/{versionId}. - * This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas in - * the same region as the Azure Batch account. For information about the firewall settings for the Batch node agent - * to communicate with the Batch service see + * + *

This property is mutually exclusive with other properties. The Shared Image Gallery image must have replicas + * in the same region as the Azure Batch account. For information about the firewall settings for the Batch node + * agent to communicate with the Batch service see * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration. * * @param id the id value to set. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundEndpointProtocol.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundEndpointProtocol.java index 00e1bd366351..afe9ea0449a4 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundEndpointProtocol.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundEndpointProtocol.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for InboundEndpointProtocol. */ +/** The protocol of the endpoint. */ public enum InboundEndpointProtocol { /** Enum value TCP. */ TCP("TCP"), @@ -30,6 +30,9 @@ public enum InboundEndpointProtocol { */ @JsonCreator public static InboundEndpointProtocol fromString(String value) { + if (value == null) { + return null; + } InboundEndpointProtocol[] items = InboundEndpointProtocol.values(); for (InboundEndpointProtocol item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static InboundEndpointProtocol fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundNatPool.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundNatPool.java index 2abdc9e3c48a..bf7cf3efd030 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundNatPool.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InboundNatPool.java @@ -13,11 +13,11 @@ @Fluent public final class InboundNatPool { /* - * The name of the endpoint. The name must be unique within a Batch pool, - * can contain letters, numbers, underscores, periods, and hyphens. Names - * must start with a letter or number, must end with a letter, number, or - * underscore, and cannot exceed 77 characters. If any invalid values are - * provided the request fails with HTTP status code 400. + * The name of the endpoint. + * + * The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. + * Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 + * characters. If any invalid values are provided the request fails with HTTP status code 400. */ @JsonProperty(value = "name", required = true) private String name; @@ -29,52 +29,58 @@ public final class InboundNatPool { private InboundEndpointProtocol protocol; /* - * The port number on the compute node. This must be unique within a Batch - * pool. Acceptable values are between 1 and 65535 except for 22, 3389, - * 29876 and 29877 as these are reserved. If any reserved values are - * provided the request fails with HTTP status code 400. + * The port number on the compute node. + * + * This must be unique within a Batch pool. Acceptable values are between 1 and 65535 except for 22, 3389, 29876 + * and 29877 as these are reserved. If any reserved values are provided the request fails with HTTP status code + * 400. */ @JsonProperty(value = "backendPort", required = true) private int backendPort; /* - * The first port number in the range of external ports that will be used - * to provide inbound access to the backendPort on individual compute - * nodes. Acceptable values range between 1 and 65534 except ports from - * 50000 to 55000 which are reserved. All ranges within a pool must be - * distinct and cannot overlap. If any reserved or overlapping values are - * provided the request fails with HTTP status code 400. + * The first port number in the range of external ports that will be used to provide inbound access to the + * backendPort on individual compute nodes. + * + * Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved. All ranges + * within a pool must be distinct and cannot overlap. If any reserved or overlapping values are provided the + * request fails with HTTP status code 400. */ @JsonProperty(value = "frontendPortRangeStart", required = true) private int frontendPortRangeStart; /* - * The last port number in the range of external ports that will be used to - * provide inbound access to the backendPort on individual compute nodes. - * Acceptable values range between 1 and 65534 except ports from 50000 to - * 55000 which are reserved by the Batch service. All ranges within a pool - * must be distinct and cannot overlap. If any reserved or overlapping - * values are provided the request fails with HTTP status code 400. + * The last port number in the range of external ports that will be used to provide inbound access to the + * backendPort on individual compute nodes. + * + * Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved by the Batch + * service. All ranges within a pool must be distinct and cannot overlap. If any reserved or overlapping values are + * provided the request fails with HTTP status code 400. */ @JsonProperty(value = "frontendPortRangeEnd", required = true) private int frontendPortRangeEnd; /* - * A list of network security group rules that will be applied to the - * endpoint. The maximum number of rules that can be specified across all - * the endpoints on a Batch pool is 25. If no network security group rules - * are specified, a default rule will be created to allow inbound access to - * the specified backendPort. If the maximum number of network security - * group rules is exceeded the request fails with HTTP status code 400. + * A list of network security group rules that will be applied to the endpoint. + * + * The maximum number of rules that can be specified across all the endpoints on a Batch pool is 25. If no network + * security group rules are specified, a default rule will be created to allow inbound access to the specified + * backendPort. If the maximum number of network security group rules is exceeded the request fails with HTTP + * status code 400. */ @JsonProperty(value = "networkSecurityGroupRules") private List networkSecurityGroupRules; + /** Creates an instance of InboundNatPool class. */ + public InboundNatPool() { + } + /** - * Get the name property: The name of the endpoint. The name must be unique within a Batch pool, can contain - * letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a - * letter, number, or underscore, and cannot exceed 77 characters. If any invalid values are provided the request - * fails with HTTP status code 400. + * Get the name property: The name of the endpoint. + * + *

The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. + * Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 + * characters. If any invalid values are provided the request fails with HTTP status code 400. * * @return the name value. */ @@ -83,10 +89,11 @@ public String name() { } /** - * Set the name property: The name of the endpoint. The name must be unique within a Batch pool, can contain - * letters, numbers, underscores, periods, and hyphens. Names must start with a letter or number, must end with a - * letter, number, or underscore, and cannot exceed 77 characters. If any invalid values are provided the request - * fails with HTTP status code 400. + * Set the name property: The name of the endpoint. + * + *

The name must be unique within a Batch pool, can contain letters, numbers, underscores, periods, and hyphens. + * Names must start with a letter or number, must end with a letter, number, or underscore, and cannot exceed 77 + * characters. If any invalid values are provided the request fails with HTTP status code 400. * * @param name the name value to set. * @return the InboundNatPool object itself. @@ -117,9 +124,10 @@ public InboundNatPool withProtocol(InboundEndpointProtocol protocol) { } /** - * Get the backendPort property: The port number on the compute node. This must be unique within a Batch pool. - * Acceptable values are between 1 and 65535 except for 22, 3389, 29876 and 29877 as these are reserved. If any - * reserved values are provided the request fails with HTTP status code 400. + * Get the backendPort property: The port number on the compute node. + * + *

This must be unique within a Batch pool. Acceptable values are between 1 and 65535 except for 22, 3389, 29876 + * and 29877 as these are reserved. If any reserved values are provided the request fails with HTTP status code 400. * * @return the backendPort value. */ @@ -128,9 +136,10 @@ public int backendPort() { } /** - * Set the backendPort property: The port number on the compute node. This must be unique within a Batch pool. - * Acceptable values are between 1 and 65535 except for 22, 3389, 29876 and 29877 as these are reserved. If any - * reserved values are provided the request fails with HTTP status code 400. + * Set the backendPort property: The port number on the compute node. + * + *

This must be unique within a Batch pool. Acceptable values are between 1 and 65535 except for 22, 3389, 29876 + * and 29877 as these are reserved. If any reserved values are provided the request fails with HTTP status code 400. * * @param backendPort the backendPort value to set. * @return the InboundNatPool object itself. @@ -142,9 +151,11 @@ public InboundNatPool withBackendPort(int backendPort) { /** * Get the frontendPortRangeStart property: The first port number in the range of external ports that will be used - * to provide inbound access to the backendPort on individual compute nodes. Acceptable values range between 1 and - * 65534 except ports from 50000 to 55000 which are reserved. All ranges within a pool must be distinct and cannot - * overlap. If any reserved or overlapping values are provided the request fails with HTTP status code 400. + * to provide inbound access to the backendPort on individual compute nodes. + * + *

Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved. All ranges + * within a pool must be distinct and cannot overlap. If any reserved or overlapping values are provided the request + * fails with HTTP status code 400. * * @return the frontendPortRangeStart value. */ @@ -154,9 +165,11 @@ public int frontendPortRangeStart() { /** * Set the frontendPortRangeStart property: The first port number in the range of external ports that will be used - * to provide inbound access to the backendPort on individual compute nodes. Acceptable values range between 1 and - * 65534 except ports from 50000 to 55000 which are reserved. All ranges within a pool must be distinct and cannot - * overlap. If any reserved or overlapping values are provided the request fails with HTTP status code 400. + * to provide inbound access to the backendPort on individual compute nodes. + * + *

Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved. All ranges + * within a pool must be distinct and cannot overlap. If any reserved or overlapping values are provided the request + * fails with HTTP status code 400. * * @param frontendPortRangeStart the frontendPortRangeStart value to set. * @return the InboundNatPool object itself. @@ -168,10 +181,11 @@ public InboundNatPool withFrontendPortRangeStart(int frontendPortRangeStart) { /** * Get the frontendPortRangeEnd property: The last port number in the range of external ports that will be used to - * provide inbound access to the backendPort on individual compute nodes. Acceptable values range between 1 and - * 65534 except ports from 50000 to 55000 which are reserved by the Batch service. All ranges within a pool must be - * distinct and cannot overlap. If any reserved or overlapping values are provided the request fails with HTTP - * status code 400. + * provide inbound access to the backendPort on individual compute nodes. + * + *

Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved by the Batch + * service. All ranges within a pool must be distinct and cannot overlap. If any reserved or overlapping values are + * provided the request fails with HTTP status code 400. * * @return the frontendPortRangeEnd value. */ @@ -181,10 +195,11 @@ public int frontendPortRangeEnd() { /** * Set the frontendPortRangeEnd property: The last port number in the range of external ports that will be used to - * provide inbound access to the backendPort on individual compute nodes. Acceptable values range between 1 and - * 65534 except ports from 50000 to 55000 which are reserved by the Batch service. All ranges within a pool must be - * distinct and cannot overlap. If any reserved or overlapping values are provided the request fails with HTTP - * status code 400. + * provide inbound access to the backendPort on individual compute nodes. + * + *

Acceptable values range between 1 and 65534 except ports from 50000 to 55000 which are reserved by the Batch + * service. All ranges within a pool must be distinct and cannot overlap. If any reserved or overlapping values are + * provided the request fails with HTTP status code 400. * * @param frontendPortRangeEnd the frontendPortRangeEnd value to set. * @return the InboundNatPool object itself. @@ -196,7 +211,9 @@ public InboundNatPool withFrontendPortRangeEnd(int frontendPortRangeEnd) { /** * Get the networkSecurityGroupRules property: A list of network security group rules that will be applied to the - * endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is 25. If no + * endpoint. + * + *

The maximum number of rules that can be specified across all the endpoints on a Batch pool is 25. If no * network security group rules are specified, a default rule will be created to allow inbound access to the * specified backendPort. If the maximum number of network security group rules is exceeded the request fails with * HTTP status code 400. @@ -209,7 +226,9 @@ public List networkSecurityGroupRules() { /** * Set the networkSecurityGroupRules property: A list of network security group rules that will be applied to the - * endpoint. The maximum number of rules that can be specified across all the endpoints on a Batch pool is 25. If no + * endpoint. + * + *

The maximum number of rules that can be specified across all the endpoints on a Batch pool is 25. If no * network security group rules are specified, a default rule will be created to allow inbound access to the * specified backendPort. If the maximum number of network security group rules is exceeded the request fails with * HTTP status code 400. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InterNodeCommunicationState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InterNodeCommunicationState.java index a42644466d6f..ab2d21285a90 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InterNodeCommunicationState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/InterNodeCommunicationState.java @@ -7,7 +7,12 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for InterNodeCommunicationState. */ +/** + * Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of + * the requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + */ public enum InterNodeCommunicationState { /** Enum value Enabled. */ ENABLED("Enabled"), @@ -30,6 +35,9 @@ public enum InterNodeCommunicationState { */ @JsonCreator public static InterNodeCommunicationState fromString(String value) { + if (value == null) { + return null; + } InterNodeCommunicationState[] items = InterNodeCommunicationState.values(); for (InterNodeCommunicationState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +47,7 @@ public static InterNodeCommunicationState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpAddressProvisioningType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpAddressProvisioningType.java index a37b33c3dc98..2a0d35f77ec1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpAddressProvisioningType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpAddressProvisioningType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for IpAddressProvisioningType. */ +/** The provisioning type for Public IP Addresses for the Batch Pool. */ public enum IpAddressProvisioningType { /** Enum value BatchManaged. */ BATCH_MANAGED("BatchManaged"), @@ -33,6 +33,9 @@ public enum IpAddressProvisioningType { */ @JsonCreator public static IpAddressProvisioningType fromString(String value) { + if (value == null) { + return null; + } IpAddressProvisioningType[] items = IpAddressProvisioningType.values(); for (IpAddressProvisioningType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static IpAddressProvisioningType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpRule.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpRule.java new file mode 100644 index 000000000000..dde6296a1d22 --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/IpRule.java @@ -0,0 +1,90 @@ +// 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.JsonProperty; + +/** Rule to filter client IP address. */ +@Fluent +public final class IpRule { + /* + * Action when client IP address is matched. + */ + @JsonProperty(value = "action", required = true) + private String action = "Allow"; + + /* + * The IP address or IP address range to filter + * + * IPv4 address, or IPv4 address range in CIDR format. + */ + @JsonProperty(value = "value", required = true) + private String value; + + /** Creates an instance of IpRule class. */ + public IpRule() { + action = "Allow"; + } + + /** + * Get the action property: Action when client IP address is matched. + * + * @return the action value. + */ + public String action() { + return this.action; + } + + /** + * Set the action property: Action when client IP address is matched. + * + * @param action the action value to set. + * @return the IpRule object itself. + */ + public IpRule withAction(String action) { + this.action = action; + return this; + } + + /** + * Get the value property: The IP address or IP address range to filter + * + *

IPv4 address, or IPv4 address range in CIDR format. + * + * @return the value value. + */ + public String value() { + return this.value; + } + + /** + * Set the value property: The IP address or IP address range to filter + * + *

IPv4 address, or IPv4 address range in CIDR format. + * + * @param value the value value to set. + * @return the IpRule object itself. + */ + public IpRule withValue(String value) { + this.value = value; + return this; + } + + /** + * 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 IpRule")); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(IpRule.class); +} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeySource.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeySource.java index e5fcec5a99cf..f9d843f458f1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeySource.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeySource.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for KeySource. */ +/** Type of the key source. */ public enum KeySource { /** Enum value Microsoft.Batch. */ MICROSOFT_BATCH("Microsoft.Batch"), @@ -30,6 +30,9 @@ public enum KeySource { */ @JsonCreator public static KeySource fromString(String value) { + if (value == null) { + return null; + } KeySource[] items = KeySource.values(); for (KeySource item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static KeySource fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultProperties.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultProperties.java index 31c3bf132620..982172fa85fd 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultProperties.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultProperties.java @@ -12,17 +12,20 @@ public final class KeyVaultProperties { /* * Full path to the versioned secret. Example - * https://mykeyvault.vault.azure.net/keys/testkey/6e34a81fef704045975661e297a4c053. - * To be usable the following prerequisites must be met: + * https://mykeyvault.vault.azure.net/keys/testkey/6e34a81fef704045975661e297a4c053. To be usable the following + * prerequisites must be met: * * The Batch Account has a System Assigned identity - * The account identity has been granted Key/Get, Key/Unwrap and Key/Wrap - * permissions + * The account identity has been granted Key/Get, Key/Unwrap and Key/Wrap permissions * The KeyVault has soft-delete and purge protection enabled */ @JsonProperty(value = "keyIdentifier") private String keyIdentifier; + /** Creates an instance of KeyVaultProperties class. */ + public KeyVaultProperties() { + } + /** * Get the keyIdentifier property: Full path to the versioned secret. Example * https://mykeyvault.vault.azure.net/keys/testkey/6e34a81fef704045975661e297a4c053. To be usable the following diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultReference.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultReference.java index 87c8b49e0bcf..86e8a2b7264a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultReference.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/KeyVaultReference.java @@ -12,8 +12,7 @@ @Fluent public final class KeyVaultReference { /* - * The resource ID of the Azure key vault associated with the Batch - * account. + * The resource ID of the Azure key vault associated with the Batch account. */ @JsonProperty(value = "id", required = true) private String id; @@ -24,6 +23,10 @@ public final class KeyVaultReference { @JsonProperty(value = "url", required = true) private String url; + /** Creates an instance of KeyVaultReference class. */ + public KeyVaultReference() { + } + /** * Get the id property: The resource ID of the Azure key vault associated with the Batch account. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LinuxUserConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LinuxUserConfiguration.java index 1f7ad265d13e..42518b3ece87 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LinuxUserConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LinuxUserConfiguration.java @@ -11,37 +11,44 @@ @Fluent public final class LinuxUserConfiguration { /* - * The user ID of the user account. The uid and gid properties must be - * specified together or not at all. If not specified the underlying - * operating system picks the uid. + * The user ID of the user account. + * + * The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the uid. */ @JsonProperty(value = "uid") private Integer uid; /* - * The group ID for the user account. The uid and gid properties must be - * specified together or not at all. If not specified the underlying - * operating system picks the gid. + * The group ID for the user account. + * + * The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the gid. */ @JsonProperty(value = "gid") private Integer gid; /* - * The SSH private key for the user account. The private key must not be - * password protected. The private key is used to automatically configure - * asymmetric-key based authentication for SSH between nodes in a Linux - * pool when the pool's enableInterNodeCommunication property is true (it - * is ignored if enableInterNodeCommunication is false). It does this by - * placing the key pair into the user's .ssh directory. If not specified, - * password-less SSH is not configured between nodes (no modification of - * the user's .ssh directory is done). + * The SSH private key for the user account. + * + * The private key must not be password protected. The private key is used to automatically configure + * asymmetric-key based authentication for SSH between nodes in a Linux pool when the pool's + * enableInterNodeCommunication property is true (it is ignored if enableInterNodeCommunication is false). It does + * this by placing the key pair into the user's .ssh directory. If not specified, password-less SSH is not + * configured between nodes (no modification of the user's .ssh directory is done). */ @JsonProperty(value = "sshPrivateKey") private String sshPrivateKey; + /** Creates an instance of LinuxUserConfiguration class. */ + public LinuxUserConfiguration() { + } + /** - * Get the uid property: The user ID of the user account. The uid and gid properties must be specified together or - * not at all. If not specified the underlying operating system picks the uid. + * Get the uid property: The user ID of the user account. + * + *

The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the uid. * * @return the uid value. */ @@ -50,8 +57,10 @@ public Integer uid() { } /** - * Set the uid property: The user ID of the user account. The uid and gid properties must be specified together or - * not at all. If not specified the underlying operating system picks the uid. + * Set the uid property: The user ID of the user account. + * + *

The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the uid. * * @param uid the uid value to set. * @return the LinuxUserConfiguration object itself. @@ -62,8 +71,10 @@ public LinuxUserConfiguration withUid(Integer uid) { } /** - * Get the gid property: The group ID for the user account. The uid and gid properties must be specified together or - * not at all. If not specified the underlying operating system picks the gid. + * Get the gid property: The group ID for the user account. + * + *

The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the gid. * * @return the gid value. */ @@ -72,8 +83,10 @@ public Integer gid() { } /** - * Set the gid property: The group ID for the user account. The uid and gid properties must be specified together or - * not at all. If not specified the underlying operating system picks the gid. + * Set the gid property: The group ID for the user account. + * + *

The uid and gid properties must be specified together or not at all. If not specified the underlying operating + * system picks the gid. * * @param gid the gid value to set. * @return the LinuxUserConfiguration object itself. @@ -84,12 +97,13 @@ public LinuxUserConfiguration withGid(Integer gid) { } /** - * Get the sshPrivateKey property: The SSH private key for the user account. The private key must not be password - * protected. The private key is used to automatically configure asymmetric-key based authentication for SSH between - * nodes in a Linux pool when the pool's enableInterNodeCommunication property is true (it is ignored if - * enableInterNodeCommunication is false). It does this by placing the key pair into the user's .ssh directory. If - * not specified, password-less SSH is not configured between nodes (no modification of the user's .ssh directory is - * done). + * Get the sshPrivateKey property: The SSH private key for the user account. + * + *

The private key must not be password protected. The private key is used to automatically configure + * asymmetric-key based authentication for SSH between nodes in a Linux pool when the pool's + * enableInterNodeCommunication property is true (it is ignored if enableInterNodeCommunication is false). It does + * this by placing the key pair into the user's .ssh directory. If not specified, password-less SSH is not + * configured between nodes (no modification of the user's .ssh directory is done). * * @return the sshPrivateKey value. */ @@ -98,12 +112,13 @@ public String sshPrivateKey() { } /** - * Set the sshPrivateKey property: The SSH private key for the user account. The private key must not be password - * protected. The private key is used to automatically configure asymmetric-key based authentication for SSH between - * nodes in a Linux pool when the pool's enableInterNodeCommunication property is true (it is ignored if - * enableInterNodeCommunication is false). It does this by placing the key pair into the user's .ssh directory. If - * not specified, password-less SSH is not configured between nodes (no modification of the user's .ssh directory is - * done). + * Set the sshPrivateKey property: The SSH private key for the user account. + * + *

The private key must not be password protected. The private key is used to automatically configure + * asymmetric-key based authentication for SSH between nodes in a Linux pool when the pool's + * enableInterNodeCommunication property is true (it is ignored if enableInterNodeCommunication is false). It does + * this by placing the key pair into the user's .ssh directory. If not specified, password-less SSH is not + * configured between nodes (no modification of the user's .ssh directory is done). * * @param sshPrivateKey the sshPrivateKey value to set. * @return the LinuxUserConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationPackagesResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationPackagesResult.java index 43146ae9a66a..3fa6951403cd 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationPackagesResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationPackagesResult.java @@ -24,6 +24,10 @@ public final class ListApplicationPackagesResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListApplicationPackagesResult class. */ + public ListApplicationPackagesResult() { + } + /** * Get the value property: The list of application packages. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationsResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationsResult.java index bc1dab6f034b..41feb9d72bc2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationsResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListApplicationsResult.java @@ -24,6 +24,10 @@ public final class ListApplicationsResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListApplicationsResult class. */ + public ListApplicationsResult() { + } + /** * Get the value property: The list of applications. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListCertificatesResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListCertificatesResult.java index 02effdb7eeec..9138a78188e3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListCertificatesResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListCertificatesResult.java @@ -24,6 +24,10 @@ public final class ListCertificatesResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListCertificatesResult class. */ + public ListCertificatesResult() { + } + /** * Get the value property: The collection of returned certificates. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPoolsResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPoolsResult.java index 742f0e447fcf..5f19c4f252a7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPoolsResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPoolsResult.java @@ -24,6 +24,10 @@ public final class ListPoolsResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListPoolsResult class. */ + public ListPoolsResult() { + } + /** * Get the value property: The collection of returned pools. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateEndpointConnectionsResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateEndpointConnectionsResult.java index 58fe50bce5e4..9b285f25e6f3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateEndpointConnectionsResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateEndpointConnectionsResult.java @@ -24,6 +24,10 @@ public final class ListPrivateEndpointConnectionsResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListPrivateEndpointConnectionsResult class. */ + public ListPrivateEndpointConnectionsResult() { + } + /** * Get the value property: The collection of returned private endpoint connection. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateLinkResourcesResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateLinkResourcesResult.java index 32df64550e76..d48bd5ff61a7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateLinkResourcesResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ListPrivateLinkResourcesResult.java @@ -24,6 +24,10 @@ public final class ListPrivateLinkResourcesResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of ListPrivateLinkResourcesResult class. */ + public ListPrivateLinkResourcesResult() { + } + /** * Get the value property: The collection of returned private link resources. * 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 c15f6bf2a563..1b34235208a0 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 @@ -14,25 +14,25 @@ public interface Locations { * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. + * @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 Batch service quotas for the specified subscription at the given location. + * @return the Batch service quotas for the specified subscription at the given location along with {@link + * Response}. */ - BatchLocationQuota getQuotas(String locationName); + Response getQuotasWithResponse(String locationName, Context context); /** * Gets the Batch service quotas for the specified subscription at the given location. * * @param locationName The region for which to retrieve Batch service quotas. - * @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 Batch service quotas for the specified subscription at the given location along with {@link - * Response}. + * @return the Batch service quotas for the specified subscription at the given location. */ - Response getQuotasWithResponse(String locationName, Context context); + BatchLocationQuota getQuotas(String locationName); /** * Gets the list of Batch supported Virtual Machine VM sizes available at the given location. @@ -95,24 +95,24 @@ PagedIterable listSupportedCloudServiceSkus( * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. + * @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 CheckNameAvailability operation response. + * @return the CheckNameAvailability operation response along with {@link Response}. */ - CheckNameAvailabilityResult checkNameAvailability(String locationName, CheckNameAvailabilityParameters parameters); + Response checkNameAvailabilityWithResponse( + String locationName, CheckNameAvailabilityParameters parameters, Context context); /** * Checks whether the Batch account name is available in the specified region. * * @param locationName The desired region for the name check. * @param parameters Properties needed to check the availability of a name. - * @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 CheckNameAvailability operation response along with {@link Response}. + * @return the CheckNameAvailability operation response. */ - Response checkNameAvailabilityWithResponse( - String locationName, CheckNameAvailabilityParameters parameters, Context context); + CheckNameAvailabilityResult checkNameAvailability(String locationName, CheckNameAvailabilityParameters parameters); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LoginMode.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LoginMode.java index 1f04aff5ad71..592ae28ca7c5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LoginMode.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/LoginMode.java @@ -7,7 +7,12 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for LoginMode. */ +/** + * Login mode for user + * + *

Specifies login mode for the user. The default value for VirtualMachineConfiguration pools is interactive mode and + * for CloudServiceConfiguration pools is batch mode. + */ public enum LoginMode { /** Enum value Batch. */ BATCH("Batch"), @@ -30,6 +35,9 @@ public enum LoginMode { */ @JsonCreator public static LoginMode fromString(String value) { + if (value == null) { + return null; + } LoginMode[] items = LoginMode.values(); for (LoginMode item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +47,7 @@ public static LoginMode fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MetadataItem.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MetadataItem.java index 10580c8e4f56..5a88e170ebcd 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MetadataItem.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MetadataItem.java @@ -9,8 +9,9 @@ import com.fasterxml.jackson.annotation.JsonProperty; /** - * A name-value pair associated with a Batch service resource. The Batch service does not assign any meaning to this - * metadata; it is solely for the use of user code. + * A name-value pair associated with a Batch service resource. + * + *

The Batch service does not assign any meaning to this metadata; it is solely for the use of user code. */ @Fluent public final class MetadataItem { @@ -26,6 +27,10 @@ public final class MetadataItem { @JsonProperty(value = "value", required = true) private String value; + /** Creates an instance of MetadataItem class. */ + public MetadataItem() { + } + /** * Get the name property: The name of the metadata item. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MountConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MountConfiguration.java index 847d1230acbd..76c4c58f3851 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MountConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/MountConfiguration.java @@ -11,36 +11,46 @@ @Fluent public final class MountConfiguration { /* - * Information used to connect to an Azure Storage Container using - * Blobfuse. This property is mutually exclusive with all other properties. + * Information used to connect to an Azure Storage Container using Blobfuse. + * + * This property is mutually exclusive with all other properties. */ @JsonProperty(value = "azureBlobFileSystemConfiguration") private AzureBlobFileSystemConfiguration azureBlobFileSystemConfiguration; /* - * Information used to connect to an NFS file system. This property is - * mutually exclusive with all other properties. + * Information used to connect to an NFS file system. + * + * This property is mutually exclusive with all other properties. */ @JsonProperty(value = "nfsMountConfiguration") private NfsMountConfiguration nfsMountConfiguration; /* - * Information used to connect to a CIFS file system. This property is - * mutually exclusive with all other properties. + * Information used to connect to a CIFS file system. + * + * This property is mutually exclusive with all other properties. */ @JsonProperty(value = "cifsMountConfiguration") private CifsMountConfiguration cifsMountConfiguration; /* - * Information used to connect to an Azure Fileshare. This property is - * mutually exclusive with all other properties. + * Information used to connect to an Azure Fileshare. + * + * This property is mutually exclusive with all other properties. */ @JsonProperty(value = "azureFileShareConfiguration") private AzureFileShareConfiguration azureFileShareConfiguration; + /** Creates an instance of MountConfiguration class. */ + public MountConfiguration() { + } + /** * Get the azureBlobFileSystemConfiguration property: Information used to connect to an Azure Storage Container - * using Blobfuse. This property is mutually exclusive with all other properties. + * using Blobfuse. + * + *

This property is mutually exclusive with all other properties. * * @return the azureBlobFileSystemConfiguration value. */ @@ -50,7 +60,9 @@ public AzureBlobFileSystemConfiguration azureBlobFileSystemConfiguration() { /** * Set the azureBlobFileSystemConfiguration property: Information used to connect to an Azure Storage Container - * using Blobfuse. This property is mutually exclusive with all other properties. + * using Blobfuse. + * + *

This property is mutually exclusive with all other properties. * * @param azureBlobFileSystemConfiguration the azureBlobFileSystemConfiguration value to set. * @return the MountConfiguration object itself. @@ -62,8 +74,9 @@ public MountConfiguration withAzureBlobFileSystemConfiguration( } /** - * Get the nfsMountConfiguration property: Information used to connect to an NFS file system. This property is - * mutually exclusive with all other properties. + * Get the nfsMountConfiguration property: Information used to connect to an NFS file system. + * + *

This property is mutually exclusive with all other properties. * * @return the nfsMountConfiguration value. */ @@ -72,8 +85,9 @@ public NfsMountConfiguration nfsMountConfiguration() { } /** - * Set the nfsMountConfiguration property: Information used to connect to an NFS file system. This property is - * mutually exclusive with all other properties. + * Set the nfsMountConfiguration property: Information used to connect to an NFS file system. + * + *

This property is mutually exclusive with all other properties. * * @param nfsMountConfiguration the nfsMountConfiguration value to set. * @return the MountConfiguration object itself. @@ -84,8 +98,9 @@ public MountConfiguration withNfsMountConfiguration(NfsMountConfiguration nfsMou } /** - * Get the cifsMountConfiguration property: Information used to connect to a CIFS file system. This property is - * mutually exclusive with all other properties. + * Get the cifsMountConfiguration property: Information used to connect to a CIFS file system. + * + *

This property is mutually exclusive with all other properties. * * @return the cifsMountConfiguration value. */ @@ -94,8 +109,9 @@ public CifsMountConfiguration cifsMountConfiguration() { } /** - * Set the cifsMountConfiguration property: Information used to connect to a CIFS file system. This property is - * mutually exclusive with all other properties. + * Set the cifsMountConfiguration property: Information used to connect to a CIFS file system. + * + *

This property is mutually exclusive with all other properties. * * @param cifsMountConfiguration the cifsMountConfiguration value to set. * @return the MountConfiguration object itself. @@ -106,8 +122,9 @@ public MountConfiguration withCifsMountConfiguration(CifsMountConfiguration cifs } /** - * Get the azureFileShareConfiguration property: Information used to connect to an Azure Fileshare. This property is - * mutually exclusive with all other properties. + * Get the azureFileShareConfiguration property: Information used to connect to an Azure Fileshare. + * + *

This property is mutually exclusive with all other properties. * * @return the azureFileShareConfiguration value. */ @@ -116,8 +133,9 @@ public AzureFileShareConfiguration azureFileShareConfiguration() { } /** - * Set the azureFileShareConfiguration property: Information used to connect to an Azure Fileshare. This property is - * mutually exclusive with all other properties. + * Set the azureFileShareConfiguration property: Information used to connect to an Azure Fileshare. + * + *

This property is mutually exclusive with all other properties. * * @param azureFileShareConfiguration the azureFileShareConfiguration value to set. * @return the MountConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NameAvailabilityReason.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NameAvailabilityReason.java index b297758d3bbf..6a7d067cb972 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NameAvailabilityReason.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NameAvailabilityReason.java @@ -7,7 +7,10 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for NameAvailabilityReason. */ +/** + * Gets the reason that a Batch account name could not be used. The Reason element is only returned if NameAvailable is + * false. + */ public enum NameAvailabilityReason { /** Enum value Invalid. */ INVALID("Invalid"), @@ -30,6 +33,9 @@ public enum NameAvailabilityReason { */ @JsonCreator public static NameAvailabilityReason fromString(String value) { + if (value == null) { + return null; + } NameAvailabilityReason[] items = NameAvailabilityReason.values(); for (NameAvailabilityReason item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +45,7 @@ public static NameAvailabilityReason fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkConfiguration.java index d3b8693ad77d..acf05265bbb2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkConfiguration.java @@ -11,30 +11,23 @@ @Fluent public final class NetworkConfiguration { /* - * The ARM resource identifier of the virtual network subnet which the - * compute nodes of the pool will join. This is of the form + * The ARM resource identifier of the virtual network subnet which the compute nodes of the pool will join. This is + * of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. - * The virtual network must be in the same region and subscription as the - * Azure Batch account. The specified subnet should have enough free IP - * addresses to accommodate the number of nodes in the pool. If the subnet - * doesn't have enough free IP addresses, the pool will partially allocate - * compute nodes and a resize error will occur. The 'MicrosoftAzureBatch' - * service principal must have the 'Classic Virtual Machine Contributor' - * Role-Based Access Control (RBAC) role for the specified VNet. The - * specified subnet must allow communication from the Azure Batch service - * to be able to schedule tasks on the compute nodes. This can be verified - * by checking if the specified VNet has any associated Network Security - * Groups (NSG). If communication to the compute nodes in the specified - * subnet is denied by an NSG, then the Batch service will set the state of - * the compute nodes to unusable. If the specified VNet has any associated - * Network Security Groups (NSG), then a few reserved system ports must be - * enabled for inbound communication. For pools created with a virtual - * machine configuration, enable ports 29876 and 29877, as well as port 22 - * for Linux and port 3389 for Windows. For pools created with a cloud - * service configuration, enable ports 10100, 20100, and 30100. Also enable - * outbound connections to Azure Storage on port 443. For - * cloudServiceConfiguration pools, only 'classic' VNETs are supported. For - * more details see: + * + * The virtual network must be in the same region and subscription as the Azure Batch account. The specified subnet + * should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't have + * enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The + * 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access + * Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch + * service to be able to schedule tasks on the compute nodes. This can be verified by checking if the specified + * VNet has any associated Network Security Groups (NSG). If communication to the compute nodes in the specified + * subnet is denied by an NSG, then the Batch service will set the state of the compute nodes to unusable. If the + * specified VNet has any associated Network Security Groups (NSG), then a few reserved system ports must be + * enabled for inbound communication. For pools created with a virtual machine configuration, enable ports 29876 + * and 29877, as well as port 22 for Linux and port 3389 for Windows. For pools created with a cloud service + * configuration, enable ports 10100, 20100, and 30100. Also enable outbound connections to Azure Storage on port + * 443. For cloudServiceConfiguration pools, only 'classic' VNETs are supported. For more details see: * https://docs.microsoft.com/en-us/azure/batch/batch-api-basics#virtual-network-vnet-and-firewall-configuration */ @JsonProperty(value = "subnetId") @@ -43,30 +36,35 @@ public final class NetworkConfiguration { /* * The scope of dynamic vnet assignment. */ - @JsonProperty(value = "dynamicVNetAssignmentScope") - private DynamicVNetAssignmentScope dynamicVNetAssignmentScope; + @JsonProperty(value = "dynamicVnetAssignmentScope") + private DynamicVNetAssignmentScope dynamicVnetAssignmentScope; /* - * The endpoint configuration for a pool. Pool endpoint configuration is - * only supported on pools with the virtualMachineConfiguration property. + * The endpoint configuration for a pool. + * + * Pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property. */ @JsonProperty(value = "endpointConfiguration") private PoolEndpointConfiguration endpointConfiguration; /* - * This property is only supported on Pools with the - * virtualMachineConfiguration property. + * This property is only supported on Pools with the virtualMachineConfiguration property. */ @JsonProperty(value = "publicIPAddressConfiguration") private PublicIpAddressConfiguration publicIpAddressConfiguration; + /** Creates an instance of NetworkConfiguration class. */ + public NetworkConfiguration() { + } + /** * Get the subnetId property: The ARM resource identifier of the virtual network subnet which the compute nodes of * the pool will join. This is of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. - * The virtual network must be in the same region and subscription as the Azure Batch account. The specified subnet - * should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't have - * enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The + * + *

The virtual network must be in the same region and subscription as the Azure Batch account. The specified + * subnet should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't + * have enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The * 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access * Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch * service to be able to schedule tasks on the compute nodes. This can be verified by checking if the specified VNet @@ -89,9 +87,10 @@ public String subnetId() { * Set the subnetId property: The ARM resource identifier of the virtual network subnet which the compute nodes of * the pool will join. This is of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/{provider}/virtualNetworks/{network}/subnets/{subnet}. - * The virtual network must be in the same region and subscription as the Azure Batch account. The specified subnet - * should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't have - * enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The + * + *

The virtual network must be in the same region and subscription as the Azure Batch account. The specified + * subnet should have enough free IP addresses to accommodate the number of nodes in the pool. If the subnet doesn't + * have enough free IP addresses, the pool will partially allocate compute nodes and a resize error will occur. The * 'MicrosoftAzureBatch' service principal must have the 'Classic Virtual Machine Contributor' Role-Based Access * Control (RBAC) role for the specified VNet. The specified subnet must allow communication from the Azure Batch * service to be able to schedule tasks on the compute nodes. This can be verified by checking if the specified VNet @@ -113,28 +112,29 @@ public NetworkConfiguration withSubnetId(String subnetId) { } /** - * Get the dynamicVNetAssignmentScope property: The scope of dynamic vnet assignment. + * Get the dynamicVnetAssignmentScope property: The scope of dynamic vnet assignment. * - * @return the dynamicVNetAssignmentScope value. + * @return the dynamicVnetAssignmentScope value. */ - public DynamicVNetAssignmentScope dynamicVNetAssignmentScope() { - return this.dynamicVNetAssignmentScope; + public DynamicVNetAssignmentScope dynamicVnetAssignmentScope() { + return this.dynamicVnetAssignmentScope; } /** - * Set the dynamicVNetAssignmentScope property: The scope of dynamic vnet assignment. + * Set the dynamicVnetAssignmentScope property: The scope of dynamic vnet assignment. * - * @param dynamicVNetAssignmentScope the dynamicVNetAssignmentScope value to set. + * @param dynamicVnetAssignmentScope the dynamicVnetAssignmentScope value to set. * @return the NetworkConfiguration object itself. */ - public NetworkConfiguration withDynamicVNetAssignmentScope(DynamicVNetAssignmentScope dynamicVNetAssignmentScope) { - this.dynamicVNetAssignmentScope = dynamicVNetAssignmentScope; + public NetworkConfiguration withDynamicVnetAssignmentScope(DynamicVNetAssignmentScope dynamicVnetAssignmentScope) { + this.dynamicVnetAssignmentScope = dynamicVnetAssignmentScope; return this; } /** - * Get the endpointConfiguration property: The endpoint configuration for a pool. Pool endpoint configuration is - * only supported on pools with the virtualMachineConfiguration property. + * Get the endpointConfiguration property: The endpoint configuration for a pool. + * + *

Pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property. * * @return the endpointConfiguration value. */ @@ -143,8 +143,9 @@ public PoolEndpointConfiguration endpointConfiguration() { } /** - * Set the endpointConfiguration property: The endpoint configuration for a pool. Pool endpoint configuration is - * only supported on pools with the virtualMachineConfiguration property. + * Set the endpointConfiguration property: The endpoint configuration for a pool. + * + *

Pool endpoint configuration is only supported on pools with the virtualMachineConfiguration property. * * @param endpointConfiguration the endpointConfiguration value to set. * @return the NetworkConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkProfile.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkProfile.java new file mode 100644 index 000000000000..6102d9c51ca1 --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkProfile.java @@ -0,0 +1,84 @@ +// 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.fasterxml.jackson.annotation.JsonProperty; + +/** Network profile for Batch account, which contains network rule settings for each endpoint. */ +@Fluent +public final class NetworkProfile { + /* + * Network access profile for batchAccount endpoint (Batch account data plane API). + */ + @JsonProperty(value = "accountAccess") + private EndpointAccessProfile accountAccess; + + /* + * Network access profile for nodeManagement endpoint (Batch service managing compute nodes for Batch pools). + */ + @JsonProperty(value = "nodeManagementAccess") + private EndpointAccessProfile nodeManagementAccess; + + /** Creates an instance of NetworkProfile class. */ + public NetworkProfile() { + } + + /** + * Get the accountAccess property: Network access profile for batchAccount endpoint (Batch account data plane API). + * + * @return the accountAccess value. + */ + public EndpointAccessProfile accountAccess() { + return this.accountAccess; + } + + /** + * Set the accountAccess property: Network access profile for batchAccount endpoint (Batch account data plane API). + * + * @param accountAccess the accountAccess value to set. + * @return the NetworkProfile object itself. + */ + public NetworkProfile withAccountAccess(EndpointAccessProfile accountAccess) { + this.accountAccess = accountAccess; + return this; + } + + /** + * Get the nodeManagementAccess property: Network access profile for nodeManagement endpoint (Batch service managing + * compute nodes for Batch pools). + * + * @return the nodeManagementAccess value. + */ + public EndpointAccessProfile nodeManagementAccess() { + return this.nodeManagementAccess; + } + + /** + * Set the nodeManagementAccess property: Network access profile for nodeManagement endpoint (Batch service managing + * compute nodes for Batch pools). + * + * @param nodeManagementAccess the nodeManagementAccess value to set. + * @return the NetworkProfile object itself. + */ + public NetworkProfile withNodeManagementAccess(EndpointAccessProfile nodeManagementAccess) { + this.nodeManagementAccess = nodeManagementAccess; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (accountAccess() != null) { + accountAccess().validate(); + } + if (nodeManagementAccess() != null) { + nodeManagementAccess().validate(); + } + } +} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRule.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRule.java index ceace78c2d7f..0f1e71bce566 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRule.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRule.java @@ -13,49 +13,52 @@ @Fluent public final class NetworkSecurityGroupRule { /* - * The priority for this rule. Priorities within a pool must be unique and - * are evaluated in order of priority. The lower the number the higher the - * priority. For example, rules could be specified with order numbers of - * 150, 250, and 350. The rule with the order number of 150 takes - * precedence over the rule that has an order of 250. Allowed priorities - * are 150 to 4096. If any reserved or duplicate values are provided the - * request fails with HTTP status code 400. + * The priority for this rule. + * + * Priorities within a pool must be unique and are evaluated in order of priority. The lower the number the higher + * the priority. For example, rules could be specified with order numbers of 150, 250, and 350. The rule with the + * order number of 150 takes precedence over the rule that has an order of 250. Allowed priorities are 150 to 4096. + * If any reserved or duplicate values are provided the request fails with HTTP status code 400. */ @JsonProperty(value = "priority", required = true) private int priority; /* - * The action that should be taken for a specified IP address, subnet range - * or tag. + * The action that should be taken for a specified IP address, subnet range or tag. */ @JsonProperty(value = "access", required = true) private NetworkSecurityGroupRuleAccess access; /* - * The source address prefix or tag to match for the rule. Valid values are - * a single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), - * default tag, or * (for all addresses). If any other values are provided - * the request fails with HTTP status code 400. + * The source address prefix or tag to match for the rule. + * + * Valid values are a single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), default tag, or * (for + * all addresses). If any other values are provided the request fails with HTTP status code 400. */ @JsonProperty(value = "sourceAddressPrefix", required = true) private String sourceAddressPrefix; /* - * The source port ranges to match for the rule. Valid values are '*' (for - * all ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). - * The ports should in the range of 0 to 65535 and the port ranges or ports - * can't overlap. If any other values are provided the request fails with - * HTTP status code 400. Default value will be *. + * The source port ranges to match for the rule. + * + * Valid values are '*' (for all ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). The ports + * should in the range of 0 to 65535 and the port ranges or ports can't overlap. If any other values are provided + * the request fails with HTTP status code 400. Default value will be *. */ @JsonProperty(value = "sourcePortRanges") private List sourcePortRanges; + /** Creates an instance of NetworkSecurityGroupRule class. */ + public NetworkSecurityGroupRule() { + } + /** - * Get the priority property: The priority for this rule. Priorities within a pool must be unique and are evaluated - * in order of priority. The lower the number the higher the priority. For example, rules could be specified with - * order numbers of 150, 250, and 350. The rule with the order number of 150 takes precedence over the rule that has - * an order of 250. Allowed priorities are 150 to 4096. If any reserved or duplicate values are provided the request - * fails with HTTP status code 400. + * Get the priority property: The priority for this rule. + * + *

Priorities within a pool must be unique and are evaluated in order of priority. The lower the number the + * higher the priority. For example, rules could be specified with order numbers of 150, 250, and 350. The rule with + * the order number of 150 takes precedence over the rule that has an order of 250. Allowed priorities are 150 to + * 4096. If any reserved or duplicate values are provided the request fails with HTTP status code 400. * * @return the priority value. */ @@ -64,11 +67,12 @@ public int priority() { } /** - * Set the priority property: The priority for this rule. Priorities within a pool must be unique and are evaluated - * in order of priority. The lower the number the higher the priority. For example, rules could be specified with - * order numbers of 150, 250, and 350. The rule with the order number of 150 takes precedence over the rule that has - * an order of 250. Allowed priorities are 150 to 4096. If any reserved or duplicate values are provided the request - * fails with HTTP status code 400. + * Set the priority property: The priority for this rule. + * + *

Priorities within a pool must be unique and are evaluated in order of priority. The lower the number the + * higher the priority. For example, rules could be specified with order numbers of 150, 250, and 350. The rule with + * the order number of 150 takes precedence over the rule that has an order of 250. Allowed priorities are 150 to + * 4096. If any reserved or duplicate values are provided the request fails with HTTP status code 400. * * @param priority the priority value to set. * @return the NetworkSecurityGroupRule object itself. @@ -99,9 +103,10 @@ public NetworkSecurityGroupRule withAccess(NetworkSecurityGroupRuleAccess access } /** - * Get the sourceAddressPrefix property: The source address prefix or tag to match for the rule. Valid values are a - * single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), default tag, or * (for all addresses). If - * any other values are provided the request fails with HTTP status code 400. + * Get the sourceAddressPrefix property: The source address prefix or tag to match for the rule. + * + *

Valid values are a single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), default tag, or * + * (for all addresses). If any other values are provided the request fails with HTTP status code 400. * * @return the sourceAddressPrefix value. */ @@ -110,9 +115,10 @@ public String sourceAddressPrefix() { } /** - * Set the sourceAddressPrefix property: The source address prefix or tag to match for the rule. Valid values are a - * single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), default tag, or * (for all addresses). If - * any other values are provided the request fails with HTTP status code 400. + * Set the sourceAddressPrefix property: The source address prefix or tag to match for the rule. + * + *

Valid values are a single IP address (i.e. 10.10.10.10), IP subnet (i.e. 192.168.1.0/24), default tag, or * + * (for all addresses). If any other values are provided the request fails with HTTP status code 400. * * @param sourceAddressPrefix the sourceAddressPrefix value to set. * @return the NetworkSecurityGroupRule object itself. @@ -123,10 +129,11 @@ public NetworkSecurityGroupRule withSourceAddressPrefix(String sourceAddressPref } /** - * Get the sourcePortRanges property: The source port ranges to match for the rule. Valid values are '*' (for all - * ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). The ports should in the range of 0 to 65535 - * and the port ranges or ports can't overlap. If any other values are provided the request fails with HTTP status - * code 400. Default value will be *. + * Get the sourcePortRanges property: The source port ranges to match for the rule. + * + *

Valid values are '*' (for all ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). The ports + * should in the range of 0 to 65535 and the port ranges or ports can't overlap. If any other values are provided + * the request fails with HTTP status code 400. Default value will be *. * * @return the sourcePortRanges value. */ @@ -135,10 +142,11 @@ public List sourcePortRanges() { } /** - * Set the sourcePortRanges property: The source port ranges to match for the rule. Valid values are '*' (for all - * ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). The ports should in the range of 0 to 65535 - * and the port ranges or ports can't overlap. If any other values are provided the request fails with HTTP status - * code 400. Default value will be *. + * Set the sourcePortRanges property: The source port ranges to match for the rule. + * + *

Valid values are '*' (for all ports 0 - 65535) or arrays of ports or port ranges (i.e. 100-200). The ports + * should in the range of 0 to 65535 and the port ranges or ports can't overlap. If any other values are provided + * the request fails with HTTP status code 400. Default value will be *. * * @param sourcePortRanges the sourcePortRanges value to set. * @return the NetworkSecurityGroupRule object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRuleAccess.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRuleAccess.java index 35177ef78307..a08a25807146 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRuleAccess.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NetworkSecurityGroupRuleAccess.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for NetworkSecurityGroupRuleAccess. */ +/** The action that should be taken for a specified IP address, subnet range or tag. */ public enum NetworkSecurityGroupRuleAccess { /** Enum value Allow. */ ALLOW("Allow"), @@ -30,6 +30,9 @@ public enum NetworkSecurityGroupRuleAccess { */ @JsonCreator public static NetworkSecurityGroupRuleAccess fromString(String value) { + if (value == null) { + return null; + } NetworkSecurityGroupRuleAccess[] items = NetworkSecurityGroupRuleAccess.values(); for (NetworkSecurityGroupRuleAccess item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static NetworkSecurityGroupRuleAccess fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NfsMountConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NfsMountConfiguration.java index ef02d1eec58c..579de4295cb4 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NfsMountConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NfsMountConfiguration.java @@ -18,21 +18,26 @@ public final class NfsMountConfiguration { private String source; /* - * The relative path on the compute node where the file system will be - * mounted All file systems are mounted relative to the Batch mounts - * directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR environment - * variable. + * The relative path on the compute node where the file system will be mounted + * + * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR + * environment variable. */ @JsonProperty(value = "relativeMountPath", required = true) private String relativeMountPath; /* - * Additional command line options to pass to the mount command. These are - * 'net use' options in Windows and 'mount' options in Linux. + * Additional command line options to pass to the mount command. + * + * These are 'net use' options in Windows and 'mount' options in Linux. */ @JsonProperty(value = "mountOptions") private String mountOptions; + /** Creates an instance of NfsMountConfiguration class. */ + public NfsMountConfiguration() { + } + /** * Get the source property: The URI of the file system to mount. * @@ -55,8 +60,9 @@ public NfsMountConfiguration withSource(String source) { /** * Get the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @return the relativeMountPath value. */ @@ -66,8 +72,9 @@ public String relativeMountPath() { /** * Set the relativeMountPath property: The relative path on the compute node where the file system will be mounted - * All file systems are mounted relative to the Batch mounts directory, accessible via the AZ_BATCH_NODE_MOUNTS_DIR - * environment variable. + * + *

All file systems are mounted relative to the Batch mounts directory, accessible via the + * AZ_BATCH_NODE_MOUNTS_DIR environment variable. * * @param relativeMountPath the relativeMountPath value to set. * @return the NfsMountConfiguration object itself. @@ -78,8 +85,9 @@ public NfsMountConfiguration withRelativeMountPath(String relativeMountPath) { } /** - * Get the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Get the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @return the mountOptions value. */ @@ -88,8 +96,9 @@ public String mountOptions() { } /** - * Set the mountOptions property: Additional command line options to pass to the mount command. These are 'net use' - * options in Windows and 'mount' options in Linux. + * Set the mountOptions property: Additional command line options to pass to the mount command. + * + *

These are 'net use' options in Windows and 'mount' options in Linux. * * @param mountOptions the mountOptions value to set. * @return the NfsMountConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodeCommunicationMode.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodeCommunicationMode.java new file mode 100644 index 000000000000..45f30381b839 --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodeCommunicationMode.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.fasterxml.jackson.annotation.JsonCreator; +import com.fasterxml.jackson.annotation.JsonValue; + +/** Determines how a pool communicates with the Batch service. */ +public enum NodeCommunicationMode { + /** Enum value Default. */ + DEFAULT("Default"), + + /** Enum value Classic. */ + CLASSIC("Classic"), + + /** Enum value Simplified. */ + SIMPLIFIED("Simplified"); + + /** The actual serialized value for a NodeCommunicationMode instance. */ + private final String value; + + NodeCommunicationMode(String value) { + this.value = value; + } + + /** + * Parses a serialized value to a NodeCommunicationMode instance. + * + * @param value the serialized value to parse. + * @return the parsed NodeCommunicationMode object, or null if unable to parse. + */ + @JsonCreator + public static NodeCommunicationMode fromString(String value) { + if (value == null) { + return null; + } + NodeCommunicationMode[] items = NodeCommunicationMode.values(); + for (NodeCommunicationMode item : items) { + if (item.toString().equalsIgnoreCase(value)) { + return item; + } + } + return null; + } + + /** {@inheritDoc} */ + @JsonValue + @Override + public String toString() { + return this.value; + } +} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementConfiguration.java index 58673c1a29fa..983de2ec9f55 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementConfiguration.java @@ -8,21 +8,30 @@ import com.fasterxml.jackson.annotation.JsonProperty; /** - * Node placement configuration for batch pools. Allocation configuration used by Batch Service to provision the nodes. + * Node placement configuration for batch pools. + * + *

Allocation configuration used by Batch Service to provision the nodes. */ @Fluent public final class NodePlacementConfiguration { /* - * The placement policy for allocating nodes in the pool. Allocation policy - * used by Batch Service to provision the nodes. If not specified, Batch - * will use the regional policy. + * The placement policy for allocating nodes in the pool. + * + * Allocation policy used by Batch Service to provision the nodes. If not specified, Batch will use the regional + * policy. */ @JsonProperty(value = "policy") private NodePlacementPolicyType policy; + /** Creates an instance of NodePlacementConfiguration class. */ + public NodePlacementConfiguration() { + } + /** - * Get the policy property: The placement policy for allocating nodes in the pool. Allocation policy used by Batch - * Service to provision the nodes. If not specified, Batch will use the regional policy. + * Get the policy property: The placement policy for allocating nodes in the pool. + * + *

Allocation policy used by Batch Service to provision the nodes. If not specified, Batch will use the regional + * policy. * * @return the policy value. */ @@ -31,8 +40,10 @@ public NodePlacementPolicyType policy() { } /** - * Set the policy property: The placement policy for allocating nodes in the pool. Allocation policy used by Batch - * Service to provision the nodes. If not specified, Batch will use the regional policy. + * Set the policy property: The placement policy for allocating nodes in the pool. + * + *

Allocation policy used by Batch Service to provision the nodes. If not specified, Batch will use the regional + * policy. * * @param policy the policy value to set. * @return the NodePlacementConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementPolicyType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementPolicyType.java index 0f1ce680002b..272e88951ae6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementPolicyType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/NodePlacementPolicyType.java @@ -7,7 +7,11 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for NodePlacementPolicyType. */ +/** + * The placement policy for allocating nodes in the pool. + * + *

The default value is regional. + */ public enum NodePlacementPolicyType { /** Enum value Regional. */ REGIONAL("Regional"), @@ -30,6 +34,9 @@ public enum NodePlacementPolicyType { */ @JsonCreator public static NodePlacementPolicyType fromString(String value) { + if (value == null) { + return null; + } NodePlacementPolicyType[] items = NodePlacementPolicyType.values(); for (NodePlacementPolicyType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +46,7 @@ public static NodePlacementPolicyType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 index 628fffb40eb2..bc4fb2ab3c1f 100644 --- 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 @@ -11,12 +11,15 @@ @Fluent public final class OSDisk { /* - * Specifies the ephemeral Disk Settings for the operating system disk used - * by the virtual machine. + * Specifies the ephemeral Disk Settings for the operating system disk used by the virtual machine. */ @JsonProperty(value = "ephemeralOSDiskSettings") private DiffDiskSettings ephemeralOSDiskSettings; + /** Creates an instance of OSDisk class. */ + public OSDisk() { + } + /** * Get the ephemeralOSDiskSettings property: Specifies the ephemeral Disk Settings for the operating system disk * used by the virtual machine. 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 6626afd20634..6aa5b8559be6 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 @@ -9,7 +9,9 @@ /** An immutable client-side representation of Operation. */ public interface Operation { /** - * Gets the name property: The operation name. This is of the format {provider}/{resource}/{operation}. + * Gets the name property: The operation name. + * + *

This is of the format {provider}/{resource}/{operation}. * * @return the name value. */ @@ -37,7 +39,7 @@ public interface Operation { String origin(); /** - * Gets the properties property: Any object. + * Gets the properties property: Properties of the operation. * * @return the properties value. */ diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationDisplay.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationDisplay.java index 211bd2a096d0..34219be9d7d6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationDisplay.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationDisplay.java @@ -17,7 +17,9 @@ public final class OperationDisplay { private String provider; /* - * The operation type. For example: read, write, delete, or listKeys/action + * The operation type. + * + * For example: read, write, delete, or listKeys/action */ @JsonProperty(value = "operation") private String operation; @@ -34,6 +36,10 @@ public final class OperationDisplay { @JsonProperty(value = "description") private String description; + /** Creates an instance of OperationDisplay class. */ + public OperationDisplay() { + } + /** * Get the provider property: Friendly name of the resource provider. * @@ -55,7 +61,9 @@ public OperationDisplay withProvider(String provider) { } /** - * Get the operation property: The operation type. For example: read, write, delete, or listKeys/action. + * Get the operation property: The operation type. + * + *

For example: read, write, delete, or listKeys/action. * * @return the operation value. */ @@ -64,7 +72,9 @@ public String operation() { } /** - * Set the operation property: The operation type. For example: read, write, delete, or listKeys/action. + * Set the operation property: The operation type. + * + *

For example: read, write, delete, or listKeys/action. * * @param operation the operation value to set. * @return the OperationDisplay object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationListResult.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationListResult.java index 023d788a76a1..e65747eb19fa 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationListResult.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/OperationListResult.java @@ -27,6 +27,10 @@ public final class OperationListResult { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of OperationListResult class. */ + public OperationListResult() { + } + /** * Get the value property: The list of operations supported by the resource provider. * 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 index 03876e28f25e..d9517a04dec7 100644 --- 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 @@ -13,8 +13,7 @@ @Fluent public final class OutboundEnvironmentEndpointCollection { /* - * The collection of outbound network dependency endpoints returned by the - * listing operation. + * The collection of outbound network dependency endpoints returned by the listing operation. */ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY) private List value; @@ -25,6 +24,10 @@ public final class OutboundEnvironmentEndpointCollection { @JsonProperty(value = "nextLink") private String nextLink; + /** Creates an instance of OutboundEnvironmentEndpointCollection class. */ + public OutboundEnvironmentEndpointCollection() { + } + /** * Get the value property: The collection of outbound network dependency endpoints returned by the listing * operation. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PackageState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PackageState.java index 706bd45464ae..a114c60db4c2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PackageState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PackageState.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PackageState. */ +/** The current state of the application package. */ public enum PackageState { /** Enum value Pending. */ PENDING("Pending"), @@ -30,6 +30,9 @@ public enum PackageState { */ @JsonCreator public static PackageState fromString(String value) { + if (value == null) { + return null; + } PackageState[] items = PackageState.values(); for (PackageState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static PackageState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 9f615e97f2a0..c8ccc2e1cbe0 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 @@ -48,17 +48,19 @@ public interface Pool { String etag(); /** - * Gets the displayName property: The display name for the pool. The display name need not be unique and can contain - * any Unicode characters up to a maximum length of 1024. + * Gets the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of 1024. * * @return the displayName value. */ String displayName(); /** - * Gets the lastModified property: The last modified time of the pool. This is the last time at which the pool level - * data, such as the targetDedicatedNodes or autoScaleSettings, changed. It does not factor in node-level changes - * such as a compute node changing state. + * Gets the lastModified property: The last modified time of the pool. + * + *

This is the last time at which the pool level data, such as the targetDedicatedNodes or autoScaleSettings, + * changed. It does not factor in node-level changes such as a compute node changing state. * * @return the lastModified value. */ @@ -100,8 +102,9 @@ public interface Pool { OffsetDateTime allocationStateTransitionTime(); /** - * Gets the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with + * Gets the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all Cloud * Services VM sizes except ExtraSmall. For information about available VM sizes for pools using images from the @@ -116,16 +119,17 @@ public interface Pool { String vmSize(); /** - * Gets the deploymentConfiguration property: Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while VirtualMachineConfiguration - * uses Azure Virtual Machines (IaaS). + * Gets the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), + * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * * @return the deploymentConfiguration value. */ DeploymentConfiguration deploymentConfiguration(); /** - * Gets the currentDedicatedNodes property: The number of compute nodes currently in the pool. + * Gets the currentDedicatedNodes property: The number of dedicated compute nodes currently in the pool. * * @return the currentDedicatedNodes value. */ @@ -139,27 +143,31 @@ public interface Pool { Integer currentLowPriorityNodes(); /** - * Gets the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. This can - * either be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a - * formula which is periodically reevaluated. If this property is not specified, the pool will have a fixed scale - * with 0 targetDedicatedNodes. + * Gets the scaleSettings property: Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes + * is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. * * @return the scaleSettings value. */ ScaleSettings scaleSettings(); /** - * Gets the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. This - * property is set only if the pool automatically scales, i.e. autoScaleSettings are used. + * Gets the autoScaleRun property: The results and errors from an execution of a pool autoscale formula. + * + *

This property is set only if the pool automatically scales, i.e. autoScaleSettings are used. * * @return the autoScaleRun value. */ AutoScaleRun autoScaleRun(); /** - * Gets the interNodeCommunication property: Whether the pool permits direct communication between nodes. This - * imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of the - * requested number of nodes to be allocated in the pool. If not specified, this value defaults to 'Disabled'. + * Gets the interNodeCommunication property: Whether the pool permits direct communication between nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the + * chance of the requested number of nodes to be allocated in the pool. If not specified, this value defaults to + * 'Disabled'. * * @return the interNodeCommunication value. */ @@ -174,16 +182,19 @@ public interface Pool { /** * Gets the taskSlotsPerNode property: The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the number of cores - * of the vmSize of the pool or 256. + * compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize of the + * pool or 256. * * @return the taskSlotsPerNode value. */ Integer taskSlotsPerNode(); /** - * Gets the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * Gets the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute nodes. + * + *

If not specified, the default is spread. * * @return the taskSchedulingPolicy value. */ @@ -197,8 +208,9 @@ public interface Pool { List userAccounts(); /** - * Gets the metadata property: A list of name-value pairs associated with the pool as metadata. The Batch service - * does not assign any meaning to metadata; it is solely for the use of user code. + * Gets the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * * @return the metadata value. */ @@ -206,29 +218,37 @@ public interface Pool { /** * Gets the startTask property: A task which is run when a compute node joins a pool in the Azure Batch service, or - * when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to an - * empty object to remove the start task from the pool. + * when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task from the + * pool. * * @return the startTask value. */ StartTask startTask(); /** - * Gets the certificates property: The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store and + * Gets the certificates property: The list of certificates to be installed on each compute node in the pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate store and * location. For Linux compute nodes, the certificates are stored in a directory inside the task working directory * and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query for this location. For * certificates with visibility of 'remoteUser', a 'certs' directory is created in the user's home directory (e.g., * /home/{user-name}/certs) and certificates are placed in that directory. * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure KeyVault + * Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead. + * * @return the certificates value. */ List certificates(); /** * Gets the applicationPackages property: The list of application packages to be installed on each compute node in - * the pool. Changes to application package references affect all new compute nodes joining the pool, but do not - * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 + * the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not affect + * compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum of 10 * application package references on any given pool. * * @return the applicationPackages value. @@ -237,30 +257,57 @@ public interface Pool { /** * Gets the applicationLicenses property: The list of application licenses the Batch service will make available on - * each compute node in the pool. The list of application licenses must be a subset of available Batch service - * application licenses. If a license is requested which is not supported, pool creation will fail. + * each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If a + * license is requested which is not supported, pool creation will fail. * * @return the applicationLicenses value. */ List applicationLicenses(); /** - * Gets the resizeOperationStatus property: Details about the current or last completed resize operation. Describes - * either the current operation (if the pool AllocationState is Resizing) or the previously completed operation (if - * the AllocationState is Steady). + * Gets the resizeOperationStatus property: Details about the current or last completed resize operation. + * + *

Describes either the current operation (if the pool AllocationState is Resizing) or the previously completed + * operation (if the AllocationState is Steady). * * @return the resizeOperationStatus value. */ ResizeOperationStatus resizeOperationStatus(); /** - * Gets the mountConfiguration property: A list of file systems to mount on each node in the pool. This supports - * Azure Files, NFS, CIFS/SMB, and Blobfuse. + * Gets the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * * @return the mountConfiguration value. */ List mountConfiguration(); + /** + * Gets the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + *

If omitted, the default value is Default. + * + * @return the targetNodeCommunicationMode value. + */ + NodeCommunicationMode targetNodeCommunicationMode(); + + /** + * Gets the currentNodeCommunicationMode property: Determines how a pool communicates with the Batch service. + * + * @return the currentNodeCommunicationMode value. + */ + NodeCommunicationMode currentNodeCommunicationMode(); + + /** + * Gets the name of the resource group. + * + * @return the name of the resource group. + */ + String resourceGroupName(); + /** * Gets the inner com.azure.resourcemanager.batch.fluent.models.PoolInner object. * @@ -309,6 +356,7 @@ interface WithCreate DefinitionStages.WithApplicationPackages, DefinitionStages.WithApplicationLicenses, DefinitionStages.WithMountConfiguration, + DefinitionStages.WithTargetNodeCommunicationMode, DefinitionStages.WithIfMatch, DefinitionStages.WithIfNoneMatch { /** @@ -339,11 +387,14 @@ interface WithIdentity { /** The stage of the Pool definition allowing to specify displayName. */ interface WithDisplayName { /** - * Specifies the displayName property: The display name for the pool. The display name need not be unique - * and can contain any Unicode characters up to a maximum length of 1024.. + * Specifies the displayName property: The display name for the pool. + * + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of + * 1024.. * - * @param displayName The display name for the pool. The display name need not be unique and can contain any - * Unicode characters up to a maximum length of 1024. + * @param displayName The display name for the pool. + *

The display name need not be unique and can contain any Unicode characters up to a maximum length + * of 1024. * @return the next definition stage. */ WithCreate withDisplayName(String displayName); @@ -352,8 +403,10 @@ interface WithDisplayName { interface WithVmSize { /** * Specifies the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same - * size. For information about available sizes of virtual machines for Cloud Services pools (pools created - * with cloudServiceConfiguration), see Sizes for Cloud Services + * size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with + * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all * Cloud Services VM sizes except ExtraSmall. For information about available VM sizes for pools using * images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see Sizes @@ -363,9 +416,9 @@ interface WithVmSize { * Batch supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, * STANDARD_DS, and STANDARD_DSV2 series).. * - * @param vmSize The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with - * cloudServiceConfiguration), see Sizes for Cloud Services + * @param vmSize The size of virtual machines in the pool. All VMs in a pool are the same size. + *

For information about available sizes of virtual machines for Cloud Services pools (pools created + * with cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all * Cloud Services VM sizes except ExtraSmall. For information about available VM sizes for pools using * images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see @@ -382,13 +435,14 @@ interface WithVmSize { /** The stage of the Pool definition allowing to specify deploymentConfiguration. */ interface WithDeploymentConfiguration { /** - * Specifies the deploymentConfiguration property: Deployment configuration properties. Using - * CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), - * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS).. + * Specifies the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services + * (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS).. * - * @param deploymentConfiguration Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while - * VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). + * @param deploymentConfiguration Deployment configuration properties. + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud + * Services (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * @return the next definition stage. */ WithCreate withDeploymentConfiguration(DeploymentConfiguration deploymentConfiguration); @@ -396,15 +450,18 @@ interface WithDeploymentConfiguration { /** The stage of the Pool definition allowing to specify scaleSettings. */ interface WithScaleSettings { /** - * Specifies the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. - * This can either be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' - * which defines a formula which is periodically reevaluated. If this property is not specified, the pool - * will have a fixed scale with 0 targetDedicatedNodes.. + * Specifies the scaleSettings property: Scale settings for the pool * - * @param scaleSettings Scale settings for the pool Defines the desired size of the pool. This can either be - * 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a - * formula which is periodically reevaluated. If this property is not specified, the pool will have a - * fixed scale with 0 targetDedicatedNodes. + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested + * targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is periodically + * reevaluated. If this property is not specified, the pool will have a fixed scale with 0 + * targetDedicatedNodes.. + * + * @param scaleSettings Scale settings for the pool + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested + * targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is periodically + * reevaluated. If this property is not specified, the pool will have a fixed scale with 0 + * targetDedicatedNodes. * @return the next definition stage. */ WithCreate withScaleSettings(ScaleSettings scaleSettings); @@ -413,14 +470,16 @@ interface WithScaleSettings { interface WithInterNodeCommunication { /** * Specifies the interNodeCommunication property: Whether the pool permits direct communication between - * nodes. This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can - * reduce the chance of the requested number of nodes to be allocated in the pool. If not specified, this - * value defaults to 'Disabled'.. + * nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce + * the chance of the requested number of nodes to be allocated in the pool. If not specified, this value + * defaults to 'Disabled'.. * - * @param interNodeCommunication Whether the pool permits direct communication between nodes. This imposes - * restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of - * the requested number of nodes to be allocated in the pool. If not specified, this value defaults to - * 'Disabled'. + * @param interNodeCommunication Whether the pool permits direct communication between nodes. + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can + * reduce the chance of the requested number of nodes to be allocated in the pool. If not specified, + * this value defaults to 'Disabled'. * @return the next definition stage. */ WithCreate withInterNodeCommunication(InterNodeCommunicationState interNodeCommunication); @@ -439,12 +498,15 @@ interface WithNetworkConfiguration { interface WithTaskSlotsPerNode { /** * Specifies the taskSlotsPerNode property: The number of task slots that can be used to run concurrent - * tasks on a single compute node in the pool. The default value is 1. The maximum value is the smaller of 4 - * times the number of cores of the vmSize of the pool or 256.. + * tasks on a single compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize + * of the pool or 256.. * * @param taskSlotsPerNode The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the - * number of cores of the vmSize of the pool or 256. + * compute node in the pool. + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the + * vmSize of the pool or 256. * @return the next definition stage. */ WithCreate withTaskSlotsPerNode(Integer taskSlotsPerNode); @@ -453,10 +515,12 @@ interface WithTaskSlotsPerNode { interface WithTaskSchedulingPolicy { /** * Specifies the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute - * nodes. If not specified, the default is spread.. + * nodes. * - * @param taskSchedulingPolicy Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + *

If not specified, the default is spread.. + * + * @param taskSchedulingPolicy Specifies how tasks should be distributed across compute nodes. + *

If not specified, the default is spread. * @return the next definition stage. */ WithCreate withTaskSchedulingPolicy(TaskSchedulingPolicy taskSchedulingPolicy); @@ -474,11 +538,12 @@ interface WithUserAccounts { /** The stage of the Pool definition allowing to specify metadata. */ interface WithMetadata { /** - * Specifies the metadata property: A list of name-value pairs associated with the pool as metadata. The - * Batch service does not assign any meaning to metadata; it is solely for the use of user code.. + * Specifies the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code.. * - * @param metadata A list of name-value pairs associated with the pool as metadata. The Batch service does - * not assign any meaning to metadata; it is solely for the use of user code. + * @param metadata A list of name-value pairs associated with the pool as metadata. + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * @return the next definition stage. */ WithCreate withMetadata(List metadata); @@ -487,12 +552,15 @@ interface WithMetadata { interface WithStartTask { /** * Specifies the startTask property: A task which is run when a compute node joins a pool in the Azure Batch - * service, or when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property - * can be set to an empty object to remove the start task from the pool.. + * service, or when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task + * from the pool.. * * @param startTask A task which is run when a compute node joins a pool in the Azure Batch service, or when - * the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to - * an empty object to remove the start task from the pool. + * the compute node is rebooted or reimaged. + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start + * task from the pool. * @return the next definition stage. */ WithCreate withStartTask(StartTask startTask); @@ -501,19 +569,27 @@ interface WithStartTask { interface WithCertificates { /** * Specifies the certificates property: The list of certificates to be installed on each compute node in the - * pool. For Windows compute nodes, the Batch service installs the certificates to the specified certificate + * pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate * store and location. For Linux compute nodes, the certificates are stored in a directory inside the task * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query * for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in - * the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.. + * the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. + * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure + * KeyVault Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead.. * - * @param certificates The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store - * and location. For Linux compute nodes, the certificates are stored in a directory inside the task - * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to - * query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is - * created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in - * that directory. + * @param certificates The list of certificates to be installed on each compute node in the pool. + *

For Windows compute nodes, the Batch service installs the certificates to the specified + * certificate store and location. For Linux compute nodes, the certificates are stored in a directory + * inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied + * to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' + * directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates + * are placed in that directory. + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the + * [Azure KeyVault Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) + * instead. * @return the next definition stage. */ WithCreate withCertificates(List certificates); @@ -522,12 +598,15 @@ interface WithCertificates { interface WithApplicationPackages { /** * Specifies the applicationPackages property: The list of application packages to be installed on each - * compute node in the pool. Changes to application package references affect all new compute nodes joining - * the pool, but do not affect compute nodes that are already in the pool until they are rebooted or - * reimaged. There is a maximum of 10 application package references on any given pool.. + * compute node in the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not + * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum + * of 10 application package references on any given pool.. * * @param applicationPackages The list of application packages to be installed on each compute node in the - * pool. Changes to application package references affect all new compute nodes joining the pool, but do + * pool. + *

Changes to application package references affect all new compute nodes joining the pool, but do * not affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a * maximum of 10 application package references on any given pool. * @return the next definition stage. @@ -538,14 +617,15 @@ interface WithApplicationPackages { interface WithApplicationLicenses { /** * Specifies the applicationLicenses property: The list of application licenses the Batch service will make - * available on each compute node in the pool. The list of application licenses must be a subset of - * available Batch service application licenses. If a license is requested which is not supported, pool - * creation will fail.. + * available on each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If + * a license is requested which is not supported, pool creation will fail.. * * @param applicationLicenses The list of application licenses the Batch service will make available on each - * compute node in the pool. The list of application licenses must be a subset of available Batch - * service application licenses. If a license is requested which is not supported, pool creation will - * fail. + * compute node in the pool. + *

The list of application licenses must be a subset of available Batch service application licenses. + * If a license is requested which is not supported, pool creation will fail. * @return the next definition stage. */ WithCreate withApplicationLicenses(List applicationLicenses); @@ -553,15 +633,30 @@ interface WithApplicationLicenses { /** The stage of the Pool definition allowing to specify mountConfiguration. */ interface WithMountConfiguration { /** - * Specifies the mountConfiguration property: A list of file systems to mount on each node in the pool. This - * supports Azure Files, NFS, CIFS/SMB, and Blobfuse.. + * Specifies the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse.. * - * @param mountConfiguration A list of file systems to mount on each node in the pool. This supports Azure - * Files, NFS, CIFS/SMB, and Blobfuse. + * @param mountConfiguration A list of file systems to mount on each node in the pool. + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * @return the next definition stage. */ WithCreate withMountConfiguration(List mountConfiguration); } + /** The stage of the Pool definition allowing to specify targetNodeCommunicationMode. */ + interface WithTargetNodeCommunicationMode { + /** + * Specifies the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch + * service. + * + *

If omitted, the default value is Default.. + * + * @param targetNodeCommunicationMode Determines how a pool communicates with the Batch service. + *

If omitted, the default value is Default. + * @return the next definition stage. + */ + WithCreate withTargetNodeCommunicationMode(NodeCommunicationMode targetNodeCommunicationMode); + } /** The stage of the Pool definition allowing to specify ifMatch. */ interface WithIfMatch { /** @@ -613,6 +708,7 @@ interface Update UpdateStages.WithApplicationPackages, UpdateStages.WithApplicationLicenses, UpdateStages.WithMountConfiguration, + UpdateStages.WithTargetNodeCommunicationMode, UpdateStages.WithIfMatch { /** * Executes the update request. @@ -644,11 +740,14 @@ interface WithIdentity { /** The stage of the Pool update allowing to specify displayName. */ interface WithDisplayName { /** - * Specifies the displayName property: The display name for the pool. The display name need not be unique - * and can contain any Unicode characters up to a maximum length of 1024.. + * Specifies the displayName property: The display name for the pool. * - * @param displayName The display name for the pool. The display name need not be unique and can contain any - * Unicode characters up to a maximum length of 1024. + *

The display name need not be unique and can contain any Unicode characters up to a maximum length of + * 1024.. + * + * @param displayName The display name for the pool. + *

The display name need not be unique and can contain any Unicode characters up to a maximum length + * of 1024. * @return the next definition stage. */ Update withDisplayName(String displayName); @@ -657,8 +756,10 @@ interface WithDisplayName { interface WithVmSize { /** * Specifies the vmSize property: The size of virtual machines in the pool. All VMs in a pool are the same - * size. For information about available sizes of virtual machines for Cloud Services pools (pools created - * with cloudServiceConfiguration), see Sizes for Cloud Services + * size. + * + *

For information about available sizes of virtual machines for Cloud Services pools (pools created with + * cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all * Cloud Services VM sizes except ExtraSmall. For information about available VM sizes for pools using * images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see Sizes @@ -668,9 +769,9 @@ interface WithVmSize { * Batch supports all Azure VM sizes except STANDARD_A0 and those with premium storage (STANDARD_GS, * STANDARD_DS, and STANDARD_DSV2 series).. * - * @param vmSize The size of virtual machines in the pool. All VMs in a pool are the same size. For - * information about available sizes of virtual machines for Cloud Services pools (pools created with - * cloudServiceConfiguration), see Sizes for Cloud Services + * @param vmSize The size of virtual machines in the pool. All VMs in a pool are the same size. + *

For information about available sizes of virtual machines for Cloud Services pools (pools created + * with cloudServiceConfiguration), see Sizes for Cloud Services * (https://azure.microsoft.com/documentation/articles/cloud-services-sizes-specs/). Batch supports all * Cloud Services VM sizes except ExtraSmall. For information about available VM sizes for pools using * images from the Virtual Machines Marketplace (pools created with virtualMachineConfiguration) see @@ -687,13 +788,14 @@ interface WithVmSize { /** The stage of the Pool update allowing to specify deploymentConfiguration. */ interface WithDeploymentConfiguration { /** - * Specifies the deploymentConfiguration property: Deployment configuration properties. Using - * CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services (PaaS), - * while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS).. + * Specifies the deploymentConfiguration property: Deployment configuration properties. + * + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud Services + * (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS).. * - * @param deploymentConfiguration Deployment configuration properties. Using CloudServiceConfiguration - * specifies that the nodes should be creating using Azure Cloud Services (PaaS), while - * VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). + * @param deploymentConfiguration Deployment configuration properties. + *

Using CloudServiceConfiguration specifies that the nodes should be creating using Azure Cloud + * Services (PaaS), while VirtualMachineConfiguration uses Azure Virtual Machines (IaaS). * @return the next definition stage. */ Update withDeploymentConfiguration(DeploymentConfiguration deploymentConfiguration); @@ -701,15 +803,18 @@ interface WithDeploymentConfiguration { /** The stage of the Pool update allowing to specify scaleSettings. */ interface WithScaleSettings { /** - * Specifies the scaleSettings property: Scale settings for the pool Defines the desired size of the pool. - * This can either be 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' - * which defines a formula which is periodically reevaluated. If this property is not specified, the pool - * will have a fixed scale with 0 targetDedicatedNodes.. + * Specifies the scaleSettings property: Scale settings for the pool * - * @param scaleSettings Scale settings for the pool Defines the desired size of the pool. This can either be - * 'fixedScale' where the requested targetDedicatedNodes is specified, or 'autoScale' which defines a - * formula which is periodically reevaluated. If this property is not specified, the pool will have a - * fixed scale with 0 targetDedicatedNodes. + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested + * targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is periodically + * reevaluated. If this property is not specified, the pool will have a fixed scale with 0 + * targetDedicatedNodes.. + * + * @param scaleSettings Scale settings for the pool + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested + * targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is periodically + * reevaluated. If this property is not specified, the pool will have a fixed scale with 0 + * targetDedicatedNodes. * @return the next definition stage. */ Update withScaleSettings(ScaleSettings scaleSettings); @@ -718,14 +823,16 @@ interface WithScaleSettings { interface WithInterNodeCommunication { /** * Specifies the interNodeCommunication property: Whether the pool permits direct communication between - * nodes. This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can - * reduce the chance of the requested number of nodes to be allocated in the pool. If not specified, this - * value defaults to 'Disabled'.. + * nodes. + * + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can reduce + * the chance of the requested number of nodes to be allocated in the pool. If not specified, this value + * defaults to 'Disabled'.. * - * @param interNodeCommunication Whether the pool permits direct communication between nodes. This imposes - * restrictions on which nodes can be assigned to the pool. Enabling this value can reduce the chance of - * the requested number of nodes to be allocated in the pool. If not specified, this value defaults to - * 'Disabled'. + * @param interNodeCommunication Whether the pool permits direct communication between nodes. + *

This imposes restrictions on which nodes can be assigned to the pool. Enabling this value can + * reduce the chance of the requested number of nodes to be allocated in the pool. If not specified, + * this value defaults to 'Disabled'. * @return the next definition stage. */ Update withInterNodeCommunication(InterNodeCommunicationState interNodeCommunication); @@ -744,12 +851,15 @@ interface WithNetworkConfiguration { interface WithTaskSlotsPerNode { /** * Specifies the taskSlotsPerNode property: The number of task slots that can be used to run concurrent - * tasks on a single compute node in the pool. The default value is 1. The maximum value is the smaller of 4 - * times the number of cores of the vmSize of the pool or 256.. + * tasks on a single compute node in the pool. + * + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the vmSize + * of the pool or 256.. * * @param taskSlotsPerNode The number of task slots that can be used to run concurrent tasks on a single - * compute node in the pool. The default value is 1. The maximum value is the smaller of 4 times the - * number of cores of the vmSize of the pool or 256. + * compute node in the pool. + *

The default value is 1. The maximum value is the smaller of 4 times the number of cores of the + * vmSize of the pool or 256. * @return the next definition stage. */ Update withTaskSlotsPerNode(Integer taskSlotsPerNode); @@ -758,10 +868,12 @@ interface WithTaskSlotsPerNode { interface WithTaskSchedulingPolicy { /** * Specifies the taskSchedulingPolicy property: Specifies how tasks should be distributed across compute - * nodes. If not specified, the default is spread.. + * nodes. + * + *

If not specified, the default is spread.. * - * @param taskSchedulingPolicy Specifies how tasks should be distributed across compute nodes. If not - * specified, the default is spread. + * @param taskSchedulingPolicy Specifies how tasks should be distributed across compute nodes. + *

If not specified, the default is spread. * @return the next definition stage. */ Update withTaskSchedulingPolicy(TaskSchedulingPolicy taskSchedulingPolicy); @@ -779,11 +891,12 @@ interface WithUserAccounts { /** The stage of the Pool update allowing to specify metadata. */ interface WithMetadata { /** - * Specifies the metadata property: A list of name-value pairs associated with the pool as metadata. The - * Batch service does not assign any meaning to metadata; it is solely for the use of user code.. + * Specifies the metadata property: A list of name-value pairs associated with the pool as metadata. + * + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code.. * - * @param metadata A list of name-value pairs associated with the pool as metadata. The Batch service does - * not assign any meaning to metadata; it is solely for the use of user code. + * @param metadata A list of name-value pairs associated with the pool as metadata. + *

The Batch service does not assign any meaning to metadata; it is solely for the use of user code. * @return the next definition stage. */ Update withMetadata(List metadata); @@ -792,12 +905,15 @@ interface WithMetadata { interface WithStartTask { /** * Specifies the startTask property: A task which is run when a compute node joins a pool in the Azure Batch - * service, or when the compute node is rebooted or reimaged. In an PATCH (update) operation, this property - * can be set to an empty object to remove the start task from the pool.. + * service, or when the compute node is rebooted or reimaged. + * + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start task + * from the pool.. * * @param startTask A task which is run when a compute node joins a pool in the Azure Batch service, or when - * the compute node is rebooted or reimaged. In an PATCH (update) operation, this property can be set to - * an empty object to remove the start task from the pool. + * the compute node is rebooted or reimaged. + *

In an PATCH (update) operation, this property can be set to an empty object to remove the start + * task from the pool. * @return the next definition stage. */ Update withStartTask(StartTask startTask); @@ -806,19 +922,27 @@ interface WithStartTask { interface WithCertificates { /** * Specifies the certificates property: The list of certificates to be installed on each compute node in the - * pool. For Windows compute nodes, the Batch service installs the certificates to the specified certificate + * pool. + * + *

For Windows compute nodes, the Batch service installs the certificates to the specified certificate * store and location. For Linux compute nodes, the certificates are stored in a directory inside the task * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to query * for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is created in - * the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory.. + * the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in that directory. + * + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the [Azure + * KeyVault Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) instead.. * - * @param certificates The list of certificates to be installed on each compute node in the pool. For - * Windows compute nodes, the Batch service installs the certificates to the specified certificate store - * and location. For Linux compute nodes, the certificates are stored in a directory inside the task - * working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied to the task to - * query for this location. For certificates with visibility of 'remoteUser', a 'certs' directory is - * created in the user's home directory (e.g., /home/{user-name}/certs) and certificates are placed in - * that directory. + * @param certificates The list of certificates to be installed on each compute node in the pool. + *

For Windows compute nodes, the Batch service installs the certificates to the specified + * certificate store and location. For Linux compute nodes, the certificates are stored in a directory + * inside the task working directory and an environment variable AZ_BATCH_CERTIFICATES_DIR is supplied + * to the task to query for this location. For certificates with visibility of 'remoteUser', a 'certs' + * directory is created in the user's home directory (e.g., /home/{user-name}/certs) and certificates + * are placed in that directory. + *

Warning: This property is deprecated and will be removed after February, 2024. Please use the + * [Azure KeyVault Extension](https://learn.microsoft.com/azure/batch/batch-certificate-migration-guide) + * instead. * @return the next definition stage. */ Update withCertificates(List certificates); @@ -827,12 +951,15 @@ interface WithCertificates { interface WithApplicationPackages { /** * Specifies the applicationPackages property: The list of application packages to be installed on each - * compute node in the pool. Changes to application package references affect all new compute nodes joining - * the pool, but do not affect compute nodes that are already in the pool until they are rebooted or - * reimaged. There is a maximum of 10 application package references on any given pool.. + * compute node in the pool. + * + *

Changes to application package references affect all new compute nodes joining the pool, but do not + * affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a maximum + * of 10 application package references on any given pool.. * * @param applicationPackages The list of application packages to be installed on each compute node in the - * pool. Changes to application package references affect all new compute nodes joining the pool, but do + * pool. + *

Changes to application package references affect all new compute nodes joining the pool, but do * not affect compute nodes that are already in the pool until they are rebooted or reimaged. There is a * maximum of 10 application package references on any given pool. * @return the next definition stage. @@ -843,14 +970,15 @@ interface WithApplicationPackages { interface WithApplicationLicenses { /** * Specifies the applicationLicenses property: The list of application licenses the Batch service will make - * available on each compute node in the pool. The list of application licenses must be a subset of - * available Batch service application licenses. If a license is requested which is not supported, pool - * creation will fail.. + * available on each compute node in the pool. + * + *

The list of application licenses must be a subset of available Batch service application licenses. If + * a license is requested which is not supported, pool creation will fail.. * * @param applicationLicenses The list of application licenses the Batch service will make available on each - * compute node in the pool. The list of application licenses must be a subset of available Batch - * service application licenses. If a license is requested which is not supported, pool creation will - * fail. + * compute node in the pool. + *

The list of application licenses must be a subset of available Batch service application licenses. + * If a license is requested which is not supported, pool creation will fail. * @return the next definition stage. */ Update withApplicationLicenses(List applicationLicenses); @@ -858,15 +986,30 @@ interface WithApplicationLicenses { /** The stage of the Pool update allowing to specify mountConfiguration. */ interface WithMountConfiguration { /** - * Specifies the mountConfiguration property: A list of file systems to mount on each node in the pool. This - * supports Azure Files, NFS, CIFS/SMB, and Blobfuse.. + * Specifies the mountConfiguration property: A list of file systems to mount on each node in the pool. + * + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse.. * - * @param mountConfiguration A list of file systems to mount on each node in the pool. This supports Azure - * Files, NFS, CIFS/SMB, and Blobfuse. + * @param mountConfiguration A list of file systems to mount on each node in the pool. + *

This supports Azure Files, NFS, CIFS/SMB, and Blobfuse. * @return the next definition stage. */ Update withMountConfiguration(List mountConfiguration); } + /** The stage of the Pool update allowing to specify targetNodeCommunicationMode. */ + interface WithTargetNodeCommunicationMode { + /** + * Specifies the targetNodeCommunicationMode property: Determines how a pool communicates with the Batch + * service. + * + *

If omitted, the default value is Default.. + * + * @param targetNodeCommunicationMode Determines how a pool communicates with the Batch service. + *

If omitted, the default value is Default. + * @return the next definition stage. + */ + Update withTargetNodeCommunicationMode(NodeCommunicationMode targetNodeCommunicationMode); + } /** The stage of the Pool update allowing to specify ifMatch. */ interface WithIfMatch { /** @@ -898,48 +1041,52 @@ interface WithIfMatch { /** * Disables automatic scaling for a pool. * + * @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 contains information about a pool. */ - Pool disableAutoScale(); + Response disableAutoScaleWithResponse(Context context); /** * Disables automatic scaling for a pool. * - * @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 contains information about a pool. */ - Response disableAutoScaleWithResponse(Context context); + Pool disableAutoScale(); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API * can also be used to halt the initial sizing of the pool when it is created. * + * @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 contains information about a pool. */ - Pool stopResize(); + Response stopResizeWithResponse(Context context); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API * can also be used to halt the initial sizing of the pool when it is created. * - * @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 contains information about a pool. */ - Response stopResizeWithResponse(Context context); + Pool stopResize(); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolAllocationMode.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolAllocationMode.java index dba5139d6199..630e15fa82f3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolAllocationMode.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolAllocationMode.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PoolAllocationMode. */ +/** The allocation mode for creating pools in the Batch account. */ public enum PoolAllocationMode { /** Enum value BatchService. */ BATCH_SERVICE("BatchService"), @@ -30,6 +30,9 @@ public enum PoolAllocationMode { */ @JsonCreator public static PoolAllocationMode fromString(String value) { + if (value == null) { + return null; + } PoolAllocationMode[] items = PoolAllocationMode.values(); for (PoolAllocationMode item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static PoolAllocationMode fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolEndpointConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolEndpointConfiguration.java index aff32c78d50f..061bb62a9572 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolEndpointConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolEndpointConfiguration.java @@ -13,21 +13,26 @@ @Fluent public final class PoolEndpointConfiguration { /* - * A list of inbound NAT pools that can be used to address specific ports - * on an individual compute node externally. The maximum number of inbound - * NAT pools per Batch pool is 5. If the maximum number of inbound NAT - * pools is exceeded the request fails with HTTP status code 400. This - * cannot be specified if the IPAddressProvisioningType is - * NoPublicIPAddresses. + * A list of inbound NAT pools that can be used to address specific ports on an individual compute node externally. + * + * The maximum number of inbound NAT pools per Batch pool is 5. If the maximum number of inbound NAT pools is + * exceeded the request fails with HTTP status code 400. This cannot be specified if the IPAddressProvisioningType + * is NoPublicIPAddresses. */ @JsonProperty(value = "inboundNatPools", required = true) private List inboundNatPools; + /** Creates an instance of PoolEndpointConfiguration class. */ + public PoolEndpointConfiguration() { + } + /** * Get the inboundNatPools property: A list of inbound NAT pools that can be used to address specific ports on an - * individual compute node externally. The maximum number of inbound NAT pools per Batch pool is 5. If the maximum - * number of inbound NAT pools is exceeded the request fails with HTTP status code 400. This cannot be specified if - * the IPAddressProvisioningType is NoPublicIPAddresses. + * individual compute node externally. + * + *

The maximum number of inbound NAT pools per Batch pool is 5. If the maximum number of inbound NAT pools is + * exceeded the request fails with HTTP status code 400. This cannot be specified if the IPAddressProvisioningType + * is NoPublicIPAddresses. * * @return the inboundNatPools value. */ @@ -37,9 +42,11 @@ public List inboundNatPools() { /** * Set the inboundNatPools property: A list of inbound NAT pools that can be used to address specific ports on an - * individual compute node externally. The maximum number of inbound NAT pools per Batch pool is 5. If the maximum - * number of inbound NAT pools is exceeded the request fails with HTTP status code 400. This cannot be specified if - * the IPAddressProvisioningType is NoPublicIPAddresses. + * individual compute node externally. + * + *

The maximum number of inbound NAT pools per Batch pool is 5. If the maximum number of inbound NAT pools is + * exceeded the request fails with HTTP status code 400. This cannot be specified if the IPAddressProvisioningType + * is NoPublicIPAddresses. * * @param inboundNatPools the inboundNatPools value to set. * @return the PoolEndpointConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolIdentityType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolIdentityType.java index ff4103b59b19..afefb727e21d 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolIdentityType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolIdentityType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PoolIdentityType. */ +/** The type of identity used for the Batch Pool. */ public enum PoolIdentityType { /** Enum value UserAssigned. */ USER_ASSIGNED("UserAssigned"), @@ -30,6 +30,9 @@ public enum PoolIdentityType { */ @JsonCreator public static PoolIdentityType fromString(String value) { + if (value == null) { + return null; + } PoolIdentityType[] items = PoolIdentityType.values(); for (PoolIdentityType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static PoolIdentityType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolProvisioningState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolProvisioningState.java index 505e9c8009b8..b2daf56bf202 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolProvisioningState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolProvisioningState.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PoolProvisioningState. */ +/** The current state of the pool. */ public enum PoolProvisioningState { /** Enum value Succeeded. */ SUCCEEDED("Succeeded"), @@ -30,6 +30,9 @@ public enum PoolProvisioningState { */ @JsonCreator public static PoolProvisioningState fromString(String value) { + if (value == null) { + return null; + } PoolProvisioningState[] items = PoolProvisioningState.values(); for (PoolProvisioningState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static PoolProvisioningState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pools.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pools.java index 7e3bf90471ad..c848aa57c442 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pools.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/Pools.java @@ -80,12 +80,13 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ - Pool get(String resourceGroupName, String accountName, String poolName); + Response getWithResponse(String resourceGroupName, String accountName, String poolName, Context context); /** * Gets information about the specified pool. @@ -93,13 +94,12 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 information about the specified pool. */ - Response getWithResponse(String resourceGroupName, String accountName, String poolName, Context context); + Pool get(String resourceGroupName, String accountName, String poolName); /** * Disables automatic scaling for a pool. @@ -107,12 +107,14 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ - Pool disableAutoScale(String resourceGroupName, String accountName, String poolName); + Response disableAutoScaleWithResponse( + String resourceGroupName, String accountName, String poolName, Context context); /** * Disables automatic scaling for a pool. @@ -120,17 +122,17 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ - Response disableAutoScaleWithResponse( - String resourceGroupName, String accountName, String poolName, Context context); + Pool disableAutoScale(String resourceGroupName, String accountName, String poolName); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -139,15 +141,19 @@ Response disableAutoScaleWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ - Pool stopResize(String resourceGroupName, String accountName, String poolName); + Response stopResizeWithResponse( + String resourceGroupName, String accountName, String poolName, Context context); /** - * This does not restore the pool to its previous state before the resize operation: it only stops any further + * Stops an ongoing resize operation on the pool. + * + *

This does not restore the pool to its previous state before the resize operation: it only stops any further * changes being made, and the pool maintains its current state. After stopping, the pool stabilizes at the number * of nodes it was at when the stop operation was done. During the stop operation, the pool allocation state changes * first to stopping and then to steady. A resize operation need not be an explicit resize pool request; this API @@ -156,14 +162,12 @@ Response disableAutoScaleWithResponse( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param poolName The pool name. This must be unique within the 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 contains information about a pool. */ - Response stopResizeWithResponse( - String resourceGroupName, String accountName, String poolName, Context context); + Pool stopResize(String resourceGroupName, String accountName, String poolName); /** * Gets information about the specified pool. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateHeaders.java index 2f6fc79d2a2b..0676bfd16332 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The PoolsCreateHeaders model. */ @@ -16,6 +17,16 @@ public final class PoolsCreateHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of PoolsCreateHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public PoolsCreateHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateResponse.java index 4137d4355c34..0bf99009ec37 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsCreateResponse.java @@ -25,7 +25,11 @@ public PoolsCreateResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public PoolInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDeleteHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDeleteHeaders.java deleted file mode 100644 index ec6c63b6edbd..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDeleteHeaders.java +++ /dev/null @@ -1,72 +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.Fluent; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The PoolsDeleteHeaders model. */ -@Fluent -public final class PoolsDeleteHeaders { - /* - * The Retry-After property. - */ - @JsonProperty(value = "Retry-After") - private Integer retryAfter; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the retryAfter property: The Retry-After property. - * - * @return the retryAfter value. - */ - public Integer retryAfter() { - return this.retryAfter; - } - - /** - * Set the retryAfter property: The Retry-After property. - * - * @param retryAfter the retryAfter value to set. - * @return the PoolsDeleteHeaders object itself. - */ - public PoolsDeleteHeaders withRetryAfter(Integer retryAfter) { - this.retryAfter = retryAfter; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the PoolsDeleteHeaders object itself. - */ - public PoolsDeleteHeaders withLocation(String location) { - this.location = location; - 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/PoolsDeleteResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDeleteResponse.java deleted file mode 100644 index 6b90acdf24c5..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDeleteResponse.java +++ /dev/null @@ -1,26 +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.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; - -/** Contains all response data for the delete operation. */ -public final class PoolsDeleteResponse extends ResponseBase { - /** - * Creates an instance of PoolsDeleteResponse. - * - * @param request the request which resulted in this PoolsDeleteResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public PoolsDeleteResponse( - HttpRequest request, int statusCode, HttpHeaders rawHeaders, Void value, PoolsDeleteHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } -} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleHeaders.java index 37f5a8b89bfa..b8d12c862165 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The PoolsDisableAutoScaleHeaders model. */ @@ -16,6 +17,16 @@ public final class PoolsDisableAutoScaleHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of PoolsDisableAutoScaleHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public PoolsDisableAutoScaleHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleResponse.java index e828f6f2385d..e2963cb04173 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsDisableAutoScaleResponse.java @@ -29,7 +29,11 @@ public PoolsDisableAutoScaleResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public PoolInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetHeaders.java index cb6fce26ad0b..52b458653a3a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The PoolsGetHeaders model. */ @@ -16,6 +17,16 @@ public final class PoolsGetHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of PoolsGetHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public PoolsGetHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetResponse.java index 30fda7dd1b2c..e1be0ad4415a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsGetResponse.java @@ -25,7 +25,11 @@ public PoolsGetResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public PoolInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeHeaders.java index e6b68608bc5b..b9e4d228e071 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The PoolsStopResizeHeaders model. */ @@ -16,6 +17,16 @@ public final class PoolsStopResizeHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of PoolsStopResizeHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public PoolsStopResizeHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeResponse.java index 3273356b0315..e2753ee0060a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsStopResizeResponse.java @@ -25,7 +25,11 @@ public PoolsStopResizeResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public PoolInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateHeaders.java index 4cf79d88e76f..b3bb65ccd07f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateHeaders.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateHeaders.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.core.annotation.Fluent; +import com.azure.core.http.HttpHeaders; import com.fasterxml.jackson.annotation.JsonProperty; /** The PoolsUpdateHeaders model. */ @@ -16,6 +17,16 @@ public final class PoolsUpdateHeaders { @JsonProperty(value = "Etag") private String etag; + // HttpHeaders containing the raw property values. + /** + * Creates an instance of PoolsUpdateHeaders class. + * + * @param rawHeaders The raw HttpHeaders that will be used to create the property values. + */ + public PoolsUpdateHeaders(HttpHeaders rawHeaders) { + this.etag = rawHeaders.getValue("Etag"); + } + /** * Get the etag property: The Etag property. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateResponse.java index 33769f567010..8b622ae5066b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateResponse.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PoolsUpdateResponse.java @@ -25,7 +25,11 @@ public PoolsUpdateResponse( super(request, statusCode, rawHeaders, value, headers); } - /** @return the deserialized response body. */ + /** + * Gets the deserialized response body. + * + * @return the deserialized response body. + */ @Override public PoolInner getValue() { return super.getValue(); diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpoint.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpoint.java index 39e2f4230cdd..40a08429ee4b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpoint.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpoint.java @@ -17,6 +17,10 @@ public final class PrivateEndpoint { @JsonProperty(value = "id", access = JsonProperty.Access.WRITE_ONLY) private String id; + /** Creates an instance of PrivateEndpoint class. */ + public PrivateEndpoint() { + } + /** * Get the id property: The ARM resource identifier of the private endpoint. This is of the form * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/privateEndpoints/{privateEndpoint}. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnection.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnection.java index ab0c8597f6f1..d0ee2df126d2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnection.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnection.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.batch.models; import com.azure.resourcemanager.batch.fluent.models.PrivateEndpointConnectionInner; +import java.util.List; /** An immutable client-side representation of PrivateEndpointConnection. */ public interface PrivateEndpointConnection { @@ -50,6 +51,15 @@ public interface PrivateEndpointConnection { */ PrivateEndpoint privateEndpoint(); + /** + * Gets the groupIds property: The group id of the private endpoint connection. + * + *

The value has one and only one group id. + * + * @return the groupIds value. + */ + List groupIds(); + /** * Gets the privateLinkServiceConnectionState property: The private link service connection state of the private * endpoint connection. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionProvisioningState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionProvisioningState.java index 9888532c7b22..d2e950ce2161 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionProvisioningState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionProvisioningState.java @@ -7,16 +7,25 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PrivateEndpointConnectionProvisioningState. */ +/** The provisioning state of the private endpoint connection. */ public enum PrivateEndpointConnectionProvisioningState { - /** Enum value Succeeded. */ - SUCCEEDED("Succeeded"), + /** Enum value Creating. */ + CREATING("Creating"), /** Enum value Updating. */ UPDATING("Updating"), + /** Enum value Deleting. */ + DELETING("Deleting"), + + /** Enum value Succeeded. */ + SUCCEEDED("Succeeded"), + /** Enum value Failed. */ - FAILED("Failed"); + FAILED("Failed"), + + /** Enum value Cancelled. */ + CANCELLED("Cancelled"); /** The actual serialized value for a PrivateEndpointConnectionProvisioningState instance. */ private final String value; @@ -33,6 +42,9 @@ public enum PrivateEndpointConnectionProvisioningState { */ @JsonCreator public static PrivateEndpointConnectionProvisioningState fromString(String value) { + if (value == null) { + return null; + } PrivateEndpointConnectionProvisioningState[] items = PrivateEndpointConnectionProvisioningState.values(); for (PrivateEndpointConnectionProvisioningState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +54,7 @@ public static PrivateEndpointConnectionProvisioningState fromString(String value return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnections.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnections.java index 9f0270e4dea5..1a0b1e61c3f9 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnections.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnections.java @@ -45,12 +45,14 @@ PagedIterable listByBatchAccount( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection. + * @return information about the specified private endpoint connection along with {@link Response}. */ - PrivateEndpointConnection get(String resourceGroupName, String accountName, String privateEndpointConnectionName); + Response getWithResponse( + String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); /** * Gets information about the specified private endpoint connection. @@ -59,14 +61,12 @@ PagedIterable listByBatchAccount( * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * 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 information about the specified private endpoint connection along with {@link Response}. + * @return information about the specified private endpoint connection. */ - Response getWithResponse( - String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); + PrivateEndpointConnection get(String resourceGroupName, String accountName, String privateEndpointConnectionName); /** * Updates the properties of an existing private endpoint connection. @@ -77,8 +77,6 @@ Response getWithResponse( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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. @@ -88,8 +86,7 @@ PrivateEndpointConnection update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch); + PrivateEndpointConnectionInner parameters); /** * Updates the properties of an existing private endpoint connection. @@ -100,6 +97,9 @@ PrivateEndpointConnection update( * account. * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will * be updated, any property not supplied will be unchanged. + * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted + * or set to "*" to apply the operation unconditionally. + * @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. @@ -109,30 +109,34 @@ PrivateEndpointConnection update( String resourceGroupName, String accountName, String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters); + PrivateEndpointConnectionInner parameters, + String ifMatch, + Context context); /** - * Updates the properties of an existing private endpoint connection. + * Deletes the specified private endpoint connection. + * + * @param resourceGroupName The name of the resource group that contains the Batch account. + * @param accountName The name of the Batch account. + * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the + * 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. + */ + void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName); + + /** + * Deletes the specified private endpoint connection. * * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateEndpointConnectionName The private endpoint connection name. This must be unique within the * account. - * @param parameters PrivateEndpointConnection properties that should be updated. Properties that are supplied will - * be updated, any property not supplied will be unchanged. - * @param ifMatch The state (ETag) version of the private endpoint connection to update. This value can be omitted - * or set to "*" to apply the operation unconditionally. * @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 contains information about a private link resource. */ - PrivateEndpointConnection update( - String resourceGroupName, - String accountName, - String privateEndpointConnectionName, - PrivateEndpointConnectionInner parameters, - String ifMatch, - Context context); + void delete(String resourceGroupName, String accountName, String privateEndpointConnectionName, Context context); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionsUpdateHeaders.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionsUpdateHeaders.java deleted file mode 100644 index eb3acfc734d5..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionsUpdateHeaders.java +++ /dev/null @@ -1,72 +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.Fluent; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The PrivateEndpointConnectionsUpdateHeaders model. */ -@Fluent -public final class PrivateEndpointConnectionsUpdateHeaders { - /* - * The Retry-After property. - */ - @JsonProperty(value = "Retry-After") - private Integer retryAfter; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the retryAfter property: The Retry-After property. - * - * @return the retryAfter value. - */ - public Integer retryAfter() { - return this.retryAfter; - } - - /** - * Set the retryAfter property: The Retry-After property. - * - * @param retryAfter the retryAfter value to set. - * @return the PrivateEndpointConnectionsUpdateHeaders object itself. - */ - public PrivateEndpointConnectionsUpdateHeaders withRetryAfter(Integer retryAfter) { - this.retryAfter = retryAfter; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the PrivateEndpointConnectionsUpdateHeaders object itself. - */ - public PrivateEndpointConnectionsUpdateHeaders withLocation(String location) { - this.location = location; - 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/PrivateEndpointConnectionsUpdateResponse.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionsUpdateResponse.java deleted file mode 100644 index 7f3a02145be6..000000000000 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateEndpointConnectionsUpdateResponse.java +++ /dev/null @@ -1,38 +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.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; -import com.azure.resourcemanager.batch.fluent.models.PrivateEndpointConnectionInner; - -/** Contains all response data for the update operation. */ -public final class PrivateEndpointConnectionsUpdateResponse - extends ResponseBase { - /** - * Creates an instance of PrivateEndpointConnectionsUpdateResponse. - * - * @param request the request which resulted in this PrivateEndpointConnectionsUpdateResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public PrivateEndpointConnectionsUpdateResponse( - HttpRequest request, - int statusCode, - HttpHeaders rawHeaders, - PrivateEndpointConnectionInner value, - PrivateEndpointConnectionsUpdateHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } - - /** @return the deserialized response body. */ - @Override - public PrivateEndpointConnectionInner getValue() { - return super.getValue(); - } -} diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResource.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResource.java index c6dae0714f8a..25c99e2f5471 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResource.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResource.java @@ -38,8 +38,9 @@ public interface PrivateLinkResource { String etag(); /** - * Gets the groupId property: The group id of the private link resource. The group id is used to establish the - * private link connection. + * Gets the groupId property: The group id of the private link resource. + * + *

The group id is used to establish the private link connection. * * @return the groupId value. */ diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResources.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResources.java index f79ecad51e71..b83f48b610df 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResources.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkResources.java @@ -43,12 +43,14 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource. + * @return information about the specified private link resource along with {@link Response}. */ - PrivateLinkResource get(String resourceGroupName, String accountName, String privateLinkResourceName); + Response getWithResponse( + String resourceGroupName, String accountName, String privateLinkResourceName, Context context); /** * Gets information about the specified private link resource. @@ -56,12 +58,10 @@ PagedIterable listByBatchAccount( * @param resourceGroupName The name of the resource group that contains the Batch account. * @param accountName The name of the Batch account. * @param privateLinkResourceName The private link resource name. This must be unique within the 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 information about the specified private link resource along with {@link Response}. + * @return information about the specified private link resource. */ - Response getWithResponse( - String resourceGroupName, String accountName, String privateLinkResourceName, Context context); + PrivateLinkResource get(String resourceGroupName, String accountName, String privateLinkResourceName); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionState.java index 1c05dc45a662..012a520bffa6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionState.java @@ -26,8 +26,12 @@ public final class PrivateLinkServiceConnectionState { /* * Action required on the private connection state */ - @JsonProperty(value = "actionRequired", access = JsonProperty.Access.WRITE_ONLY) - private String actionRequired; + @JsonProperty(value = "actionsRequired", access = JsonProperty.Access.WRITE_ONLY) + private String actionsRequired; + + /** Creates an instance of PrivateLinkServiceConnectionState class. */ + public PrivateLinkServiceConnectionState() { + } /** * Get the status property: The status of the Batch private endpoint connection. @@ -70,12 +74,12 @@ public PrivateLinkServiceConnectionState withDescription(String description) { } /** - * Get the actionRequired property: Action required on the private connection state. + * Get the actionsRequired property: Action required on the private connection state. * - * @return the actionRequired value. + * @return the actionsRequired value. */ - public String actionRequired() { - return this.actionRequired; + public String actionsRequired() { + return this.actionsRequired; } /** diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionStatus.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionStatus.java index 242185c005c3..dbd7595e4436 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionStatus.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PrivateLinkServiceConnectionStatus.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PrivateLinkServiceConnectionStatus. */ +/** The status of the Batch private endpoint connection. */ public enum PrivateLinkServiceConnectionStatus { /** Enum value Approved. */ APPROVED("Approved"), @@ -36,6 +36,9 @@ public enum PrivateLinkServiceConnectionStatus { */ @JsonCreator public static PrivateLinkServiceConnectionStatus fromString(String value) { + if (value == null) { + return null; + } PrivateLinkServiceConnectionStatus[] items = PrivateLinkServiceConnectionStatus.values(); for (PrivateLinkServiceConnectionStatus item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -45,6 +48,7 @@ public static PrivateLinkServiceConnectionStatus fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ProvisioningState.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ProvisioningState.java index c439c9c778c1..8b4eafa6b96a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ProvisioningState.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ProvisioningState.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ProvisioningState. */ +/** The provisioned state of the resource. */ public enum ProvisioningState { /** Enum value Invalid. */ INVALID("Invalid"), @@ -42,6 +42,9 @@ public enum ProvisioningState { */ @JsonCreator public static ProvisioningState fromString(String value) { + if (value == null) { + return null; + } ProvisioningState[] items = ProvisioningState.values(); for (ProvisioningState item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -51,6 +54,7 @@ public static ProvisioningState fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicIpAddressConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicIpAddressConfiguration.java index f813d303235b..9ff767802887 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicIpAddressConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicIpAddressConfiguration.java @@ -12,27 +12,32 @@ @Fluent public final class PublicIpAddressConfiguration { /* - * The provisioning type for Public IP Addresses for the Batch Pool. The - * default value is BatchManaged + * The provisioning type for Public IP Addresses for the Batch Pool. + * + * The default value is BatchManaged */ @JsonProperty(value = "provision") private IpAddressProvisioningType provision; /* - * The list of public IPs which the Batch service will use when - * provisioning Compute Nodes. The number of IPs specified here limits the - * maximum size of the Pool - 100 dedicated nodes or 100 Spot/low-priority - * nodes can be allocated for each public IP. For example, a pool needing - * 250 dedicated VMs would need at least 3 public IPs specified. Each - * element of this collection is of the form: + * The list of public IPs which the Batch service will use when provisioning Compute Nodes. + * + * The number of IPs specified here limits the maximum size of the Pool - 100 dedicated nodes or 100 + * Spot/low-priority nodes can be allocated for each public IP. For example, a pool needing 250 dedicated VMs would + * need at least 3 public IPs specified. Each element of this collection is of the form: * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/publicIPAddresses/{ip}. */ @JsonProperty(value = "ipAddressIds") private List ipAddressIds; + /** Creates an instance of PublicIpAddressConfiguration class. */ + public PublicIpAddressConfiguration() { + } + /** - * Get the provision property: The provisioning type for Public IP Addresses for the Batch Pool. The default value - * is BatchManaged. + * Get the provision property: The provisioning type for Public IP Addresses for the Batch Pool. + * + *

The default value is BatchManaged. * * @return the provision value. */ @@ -41,8 +46,9 @@ public IpAddressProvisioningType provision() { } /** - * Set the provision property: The provisioning type for Public IP Addresses for the Batch Pool. The default value - * is BatchManaged. + * Set the provision property: The provisioning type for Public IP Addresses for the Batch Pool. + * + *

The default value is BatchManaged. * * @param provision the provision value to set. * @return the PublicIpAddressConfiguration object itself. @@ -54,7 +60,9 @@ public PublicIpAddressConfiguration withProvision(IpAddressProvisioningType prov /** * Get the ipAddressIds property: The list of public IPs which the Batch service will use when provisioning Compute - * Nodes. The number of IPs specified here limits the maximum size of the Pool - 100 dedicated nodes or 100 + * Nodes. + * + *

The number of IPs specified here limits the maximum size of the Pool - 100 dedicated nodes or 100 * Spot/low-priority nodes can be allocated for each public IP. For example, a pool needing 250 dedicated VMs would * need at least 3 public IPs specified. Each element of this collection is of the form: * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/publicIPAddresses/{ip}. @@ -67,7 +75,9 @@ public List ipAddressIds() { /** * Set the ipAddressIds property: The list of public IPs which the Batch service will use when provisioning Compute - * Nodes. The number of IPs specified here limits the maximum size of the Pool - 100 dedicated nodes or 100 + * Nodes. + * + *

The number of IPs specified here limits the maximum size of the Pool - 100 dedicated nodes or 100 * Spot/low-priority nodes can be allocated for each public IP. For example, a pool needing 250 dedicated VMs would * need at least 3 public IPs specified. Each element of this collection is of the form: * /subscriptions/{subscription}/resourceGroups/{group}/providers/Microsoft.Network/publicIPAddresses/{ip}. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicNetworkAccessType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicNetworkAccessType.java index 23c1f6feb954..0b2dc73415fa 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicNetworkAccessType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/PublicNetworkAccessType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for PublicNetworkAccessType. */ +/** The network access type for operating on the resources in the Batch account. */ public enum PublicNetworkAccessType { /** Enum value Enabled. */ ENABLED("Enabled"), @@ -30,6 +30,9 @@ public enum PublicNetworkAccessType { */ @JsonCreator public static PublicNetworkAccessType fromString(String value) { + if (value == null) { + return null; + } PublicNetworkAccessType[] items = PublicNetworkAccessType.values(); for (PublicNetworkAccessType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static PublicNetworkAccessType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeError.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeError.java index 0dbee6589d2b..efb96e52f347 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeError.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResizeError.java @@ -13,15 +13,13 @@ @Fluent public final class ResizeError { /* - * An identifier for the error. Codes are invariant and are intended to be - * consumed programmatically. + * An identifier for the error. Codes are invariant and are intended to be consumed programmatically. */ @JsonProperty(value = "code", required = true) private String code; /* - * A message describing the error, intended to be suitable for display in a - * user interface. + * A message describing the error, intended to be suitable for display in a user interface. */ @JsonProperty(value = "message", required = true) private String message; @@ -32,6 +30,10 @@ public final class ResizeError { @JsonProperty(value = "details") private List details; + /** Creates an instance of ResizeError class. */ + public ResizeError() { + } + /** * Get the code property: An identifier for the error. Codes are invariant and are intended to be consumed * programmatically. 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 c32120464226..11222613f865 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 @@ -11,8 +11,10 @@ import java.util.List; /** - * Details about the current or last completed resize operation. Describes either the current operation (if the pool - * AllocationState is Resizing) or the previously completed operation (if the AllocationState is Steady). + * Details about the current or last completed resize operation. + * + *

Describes either the current operation (if the pool AllocationState is Resizing) or the previously completed + * operation (if the AllocationState is Steady). */ @Fluent public final class ResizeOperationStatus { @@ -29,18 +31,19 @@ public final class ResizeOperationStatus { private Integer targetLowPriorityNodes; /* - * The timeout for allocation of compute nodes to the pool or removal of - * compute nodes from the pool. The default value is 15 minutes. The - * minimum value is 5 minutes. If you specify a value less than 5 minutes, - * the Batch service returns an error; if you are calling the REST API - * directly, the HTTP status code is 400 (Bad Request). + * The timeout for allocation of compute nodes to the pool or removal of compute nodes from the pool. + * + * The default value is 15 minutes. The minimum value is 5 minutes. If you specify a value less than 5 minutes, the + * Batch service returns an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad + * Request). */ @JsonProperty(value = "resizeTimeout") private Duration resizeTimeout; /* - * Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. The default value is requeue. + * Determines what to do with a node and its running task(s) after it has been selected for deallocation. + * + * The default value is requeue. */ @JsonProperty(value = "nodeDeallocationOption") private ComputeNodeDeallocationOption nodeDeallocationOption; @@ -52,13 +55,18 @@ public final class ResizeOperationStatus { private OffsetDateTime startTime; /* - * Details of any errors encountered while performing the last resize on - * the pool. This property is set only if an error occurred during the last - * pool resize, and only when the pool allocationState is Steady. + * Details of any errors encountered while performing the last resize on the pool. + * + * This property is set only if an error occurred during the last pool resize, and only when the pool + * allocationState is Steady. */ @JsonProperty(value = "errors") private List errors; + /** Creates an instance of ResizeOperationStatus class. */ + public ResizeOperationStatus() { + } + /** * Get the targetDedicatedNodes property: The desired number of dedicated compute nodes in the pool. * @@ -101,9 +109,11 @@ public ResizeOperationStatus withTargetLowPriorityNodes(Integer targetLowPriorit /** * Get the resizeTimeout property: The timeout for allocation of compute nodes to the pool or removal of compute - * nodes from the pool. The default value is 15 minutes. The minimum value is 5 minutes. If you specify a value less - * than 5 minutes, the Batch service returns an error; if you are calling the REST API directly, the HTTP status - * code is 400 (Bad Request). + * nodes from the pool. + * + *

The default value is 15 minutes. The minimum value is 5 minutes. If you specify a value less than 5 minutes, + * the Batch service returns an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad + * Request). * * @return the resizeTimeout value. */ @@ -113,9 +123,11 @@ public Duration resizeTimeout() { /** * Set the resizeTimeout property: The timeout for allocation of compute nodes to the pool or removal of compute - * nodes from the pool. The default value is 15 minutes. The minimum value is 5 minutes. If you specify a value less - * than 5 minutes, the Batch service returns an error; if you are calling the REST API directly, the HTTP status - * code is 400 (Bad Request). + * nodes from the pool. + * + *

The default value is 15 minutes. The minimum value is 5 minutes. If you specify a value less than 5 minutes, + * the Batch service returns an error; if you are calling the REST API directly, the HTTP status code is 400 (Bad + * Request). * * @param resizeTimeout the resizeTimeout value to set. * @return the ResizeOperationStatus object itself. @@ -127,7 +139,9 @@ public ResizeOperationStatus withResizeTimeout(Duration resizeTimeout) { /** * Get the nodeDeallocationOption property: Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. The default value is requeue. + * been selected for deallocation. + * + *

The default value is requeue. * * @return the nodeDeallocationOption value. */ @@ -137,7 +151,9 @@ public ComputeNodeDeallocationOption nodeDeallocationOption() { /** * Set the nodeDeallocationOption property: Determines what to do with a node and its running task(s) after it has - * been selected for deallocation. The default value is requeue. + * been selected for deallocation. + * + *

The default value is requeue. * * @param nodeDeallocationOption the nodeDeallocationOption value to set. * @return the ResizeOperationStatus object itself. @@ -168,9 +184,10 @@ public ResizeOperationStatus withStartTime(OffsetDateTime startTime) { } /** - * Get the errors property: Details of any errors encountered while performing the last resize on the pool. This - * property is set only if an error occurred during the last pool resize, and only when the pool allocationState is - * Steady. + * Get the errors property: Details of any errors encountered while performing the last resize on the pool. + * + *

This property is set only if an error occurred during the last pool resize, and only when the pool + * allocationState is Steady. * * @return the errors value. */ @@ -179,9 +196,10 @@ public List errors() { } /** - * Set the errors property: Details of any errors encountered while performing the last resize on the pool. This - * property is set only if an error occurred during the last pool resize, and only when the pool allocationState is - * Steady. + * Set the errors property: Details of any errors encountered while performing the last resize on the pool. + * + *

This property is set only if an error occurred during the last pool resize, and only when the pool + * allocationState is Steady. * * @param errors the errors 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 3c6674228970..1c243e5b7730 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 @@ -11,87 +11,87 @@ @Fluent public final class ResourceFile { /* - * The storage container name in the auto storage account. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties are - * mutually exclusive and one of them must be specified. + * The storage container name in the auto storage account. + * + * The autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually exclusive and one of them + * must be specified. */ @JsonProperty(value = "autoStorageContainerName") private String autoStorageContainerName; /* - * The URL of the blob container within Azure Blob Storage. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties 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. + * The URL of the blob container within Azure Blob Storage. + * + * The autoStorageContainerName, storageContainerUrl and httpUrl properties 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. */ @JsonProperty(value = "storageContainerUrl") private String storageContainerUrl; /* - * The URL of the file to download. The autoStorageContainerName, - * storageContainerUrl and httpUrl properties 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, use a managed identity with - * read permission, or set the ACL for the blob or its container to allow - * public access. + * The URL of the file to download. + * + * The autoStorageContainerName, storageContainerUrl and httpUrl properties 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, 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; /* - * The blob prefix to use when downloading blobs from an Azure Storage - * container. Only the blobs whose names begin with the specified prefix - * will be downloaded. The property is valid only when - * autoStorageContainerName or storageContainerUrl is used. This prefix can - * be a partial filename or a subdirectory. If a prefix is not specified, - * all the files in the container will be downloaded. + * The blob prefix to use when downloading blobs from an Azure Storage container. Only the blobs whose names begin + * with the specified prefix will be downloaded. + * + * The property is valid only when autoStorageContainerName or storageContainerUrl is used. This prefix can be a + * partial filename or a subdirectory. If a prefix is not specified, all the files in the container will be + * downloaded. */ @JsonProperty(value = "blobPrefix") private String blobPrefix; /* - * The location on the compute node to which to download the file, relative - * to the task's working directory. If the httpUrl property is specified, - * the filePath is required and describes the path which the file will be - * downloaded to, including the filename. Otherwise, if the - * autoStorageContainerName or storageContainerUrl property is specified, - * filePath is optional and is the directory to download the files to. In - * the case where filePath is used as a directory, any directory structure - * already associated with the input data will be retained in full and - * appended to the specified filePath directory. The specified relative - * path cannot break out of the task's working directory (for example by - * using '..'). + * The location on the compute node to which to download the file, relative to the task's working directory. + * + * If the httpUrl property is specified, the filePath is required and describes the path which the file will be + * downloaded to, including the filename. Otherwise, if the autoStorageContainerName or storageContainerUrl + * property is specified, filePath is optional and is the directory to download the files to. In the case where + * filePath is used as a directory, any directory structure already associated with the input data will be retained + * in full and appended to the specified filePath directory. The specified relative path cannot break out of the + * task's working directory (for example by using '..'). */ @JsonProperty(value = "filePath") private String filePath; /* - * The file permission mode attribute in octal format. This property - * applies only to files being downloaded to Linux compute nodes. It will - * be ignored if it is specified for a resourceFile which will be - * downloaded to a Windows node. If this property is not specified for a + * The file permission mode attribute in octal format. + * + * This property applies only to files being downloaded to Linux compute nodes. It will be ignored if it is + * specified for a resourceFile which will be downloaded to a Windows node. If this property is not specified for a * Linux node, then a default value of 0770 is applied to the file. */ @JsonProperty(value = "fileMode") private String fileMode; /* - * The reference to a user assigned identity associated with the Batch pool - * which a compute node will use. + * The reference to a user assigned identity associated with the Batch pool which a compute node will use. */ @JsonProperty(value = "identityReference") private ComputeNodeIdentityReference identityReference; + /** Creates an instance of ResourceFile class. */ + public ResourceFile() { + } + /** - * Get the autoStorageContainerName property: The storage container name in the auto storage account. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually exclusive and one of them must - * be specified. + * Get the autoStorageContainerName property: The storage container name in the auto storage account. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually exclusive and one of + * them must be specified. * * @return the autoStorageContainerName value. */ @@ -100,9 +100,10 @@ public String autoStorageContainerName() { } /** - * Set the autoStorageContainerName property: The storage container name in the auto storage account. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually exclusive and one of them must - * be specified. + * Set the autoStorageContainerName property: The storage container name in the auto storage account. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties are mutually exclusive and one of + * them must be specified. * * @param autoStorageContainerName the autoStorageContainerName value to set. * @return the ResourceFile object itself. @@ -113,12 +114,13 @@ public ResourceFile withAutoStorageContainerName(String autoStorageContainerName } /** - * Get the storageContainerUrl property: The URL of the blob container within Azure Blob Storage. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties 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. + * Get the storageContainerUrl property: The URL of the blob container within Azure Blob Storage. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties 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. */ @@ -127,12 +129,13 @@ public String storageContainerUrl() { } /** - * Set the storageContainerUrl property: The URL of the blob container within Azure Blob Storage. The - * autoStorageContainerName, storageContainerUrl and httpUrl properties 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. + * Set the storageContainerUrl property: The URL of the blob container within Azure Blob Storage. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties 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. @@ -143,11 +146,13 @@ public ResourceFile withStorageContainerUrl(String storageContainerUrl) { } /** - * Get the httpUrl property: The URL of the file to download. The autoStorageContainerName, storageContainerUrl and - * httpUrl properties 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, use a managed identity - * with read permission, or set the ACL for the blob or its container to allow public access. + * Get the httpUrl property: The URL of the file to download. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties 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, 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. */ @@ -156,11 +161,13 @@ public String httpUrl() { } /** - * Set the httpUrl property: The URL of the file to download. The autoStorageContainerName, storageContainerUrl and - * httpUrl properties 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, use a managed identity - * with read permission, or set the ACL for the blob or its container to allow public access. + * Set the httpUrl property: The URL of the file to download. + * + *

The autoStorageContainerName, storageContainerUrl and httpUrl properties 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, 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. @@ -172,9 +179,11 @@ public ResourceFile withHttpUrl(String httpUrl) { /** * Get the blobPrefix property: The blob prefix to use when downloading blobs from an Azure Storage container. Only - * the blobs whose names begin with the specified prefix will be downloaded. The property is valid only when - * autoStorageContainerName or storageContainerUrl is used. This prefix can be a partial filename or a subdirectory. - * If a prefix is not specified, all the files in the container will be downloaded. + * the blobs whose names begin with the specified prefix will be downloaded. + * + *

The property is valid only when autoStorageContainerName or storageContainerUrl is used. This prefix can be a + * partial filename or a subdirectory. If a prefix is not specified, all the files in the container will be + * downloaded. * * @return the blobPrefix value. */ @@ -184,9 +193,11 @@ public String blobPrefix() { /** * Set the blobPrefix property: The blob prefix to use when downloading blobs from an Azure Storage container. Only - * the blobs whose names begin with the specified prefix will be downloaded. The property is valid only when - * autoStorageContainerName or storageContainerUrl is used. This prefix can be a partial filename or a subdirectory. - * If a prefix is not specified, all the files in the container will be downloaded. + * the blobs whose names begin with the specified prefix will be downloaded. + * + *

The property is valid only when autoStorageContainerName or storageContainerUrl is used. This prefix can be a + * partial filename or a subdirectory. If a prefix is not specified, all the files in the container will be + * downloaded. * * @param blobPrefix the blobPrefix value to set. * @return the ResourceFile object itself. @@ -198,12 +209,14 @@ public ResourceFile withBlobPrefix(String blobPrefix) { /** * Get the filePath property: The location on the compute node to which to download the file, relative to the task's - * working directory. If the httpUrl property is specified, the filePath is required and describes the path which - * the file will be downloaded to, including the filename. Otherwise, if the autoStorageContainerName or - * storageContainerUrl property is specified, filePath is optional and is the directory to download the files to. In - * the case where filePath is used as a directory, any directory structure already associated with the input data - * will be retained in full and appended to the specified filePath directory. The specified relative path cannot - * break out of the task's working directory (for example by using '..'). + * working directory. + * + *

If the httpUrl property is specified, the filePath is required and describes the path which the file will be + * downloaded to, including the filename. Otherwise, if the autoStorageContainerName or storageContainerUrl property + * is specified, filePath is optional and is the directory to download the files to. In the case where filePath is + * used as a directory, any directory structure already associated with the input data will be retained in full and + * appended to the specified filePath directory. The specified relative path cannot break out of the task's working + * directory (for example by using '..'). * * @return the filePath value. */ @@ -213,12 +226,14 @@ public String filePath() { /** * Set the filePath property: The location on the compute node to which to download the file, relative to the task's - * working directory. If the httpUrl property is specified, the filePath is required and describes the path which - * the file will be downloaded to, including the filename. Otherwise, if the autoStorageContainerName or - * storageContainerUrl property is specified, filePath is optional and is the directory to download the files to. In - * the case where filePath is used as a directory, any directory structure already associated with the input data - * will be retained in full and appended to the specified filePath directory. The specified relative path cannot - * break out of the task's working directory (for example by using '..'). + * working directory. + * + *

If the httpUrl property is specified, the filePath is required and describes the path which the file will be + * downloaded to, including the filename. Otherwise, if the autoStorageContainerName or storageContainerUrl property + * is specified, filePath is optional and is the directory to download the files to. In the case where filePath is + * used as a directory, any directory structure already associated with the input data will be retained in full and + * appended to the specified filePath directory. The specified relative path cannot break out of the task's working + * directory (for example by using '..'). * * @param filePath the filePath value to set. * @return the ResourceFile object itself. @@ -229,10 +244,11 @@ public ResourceFile withFilePath(String filePath) { } /** - * Get the fileMode property: The file permission mode attribute in octal format. This property applies only to - * files being downloaded to Linux compute nodes. It will be ignored if it is specified for a resourceFile which - * will be downloaded to a Windows node. If this property is not specified for a Linux node, then a default value of - * 0770 is applied to the file. + * Get the fileMode property: The file permission mode attribute in octal format. + * + *

This property applies only to files being downloaded to Linux compute nodes. It will be ignored if it is + * specified for a resourceFile which will be downloaded to a Windows node. If this property is not specified for a + * Linux node, then a default value of 0770 is applied to the file. * * @return the fileMode value. */ @@ -241,10 +257,11 @@ public String fileMode() { } /** - * Set the fileMode property: The file permission mode attribute in octal format. This property applies only to - * files being downloaded to Linux compute nodes. It will be ignored if it is specified for a resourceFile which - * will be downloaded to a Windows node. If this property is not specified for a Linux node, then a default value of - * 0770 is applied to the file. + * Set the fileMode property: The file permission mode attribute in octal format. + * + *

This property applies only to files being downloaded to Linux compute nodes. It will be ignored if it is + * specified for a resourceFile which will be downloaded to a Windows node. If this property is not specified for a + * Linux node, then a default value of 0770 is applied to the file. * * @param fileMode the fileMode value to set. * @return the ResourceFile object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceIdentityType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceIdentityType.java index 66f23d3edbd0..0f9bd27a6729 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceIdentityType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ResourceIdentityType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for ResourceIdentityType. */ +/** The type of identity used for the Batch account. */ public enum ResourceIdentityType { /** Enum value SystemAssigned. */ SYSTEM_ASSIGNED("SystemAssigned"), @@ -33,6 +33,9 @@ public enum ResourceIdentityType { */ @JsonCreator public static ResourceIdentityType fromString(String value) { + if (value == null) { + return null; + } ResourceIdentityType[] items = ResourceIdentityType.values(); for (ResourceIdentityType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -42,6 +45,7 @@ public static ResourceIdentityType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ScaleSettings.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ScaleSettings.java index fa7e45deec4d..c49e31f13991 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ScaleSettings.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/ScaleSettings.java @@ -8,29 +8,38 @@ import com.fasterxml.jackson.annotation.JsonProperty; /** - * Scale settings for the pool Defines the desired size of the pool. This can either be 'fixedScale' where the requested - * targetDedicatedNodes is specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this - * property is not specified, the pool will have a fixed scale with 0 targetDedicatedNodes. + * Scale settings for the pool + * + *

Defines the desired size of the pool. This can either be 'fixedScale' where the requested targetDedicatedNodes is + * specified, or 'autoScale' which defines a formula which is periodically reevaluated. If this property is not + * specified, the pool will have a fixed scale with 0 targetDedicatedNodes. */ @Fluent public final class ScaleSettings { /* - * Fixed scale settings for the pool. This property and autoScale are - * mutually exclusive and one of the properties must be specified. + * Fixed scale settings for the pool. + * + * This property and autoScale are mutually exclusive and one of the properties must be specified. */ @JsonProperty(value = "fixedScale") private FixedScaleSettings fixedScale; /* - * AutoScale settings for the pool. This property and fixedScale are - * mutually exclusive and one of the properties must be specified. + * AutoScale settings for the pool. + * + * This property and fixedScale are mutually exclusive and one of the properties must be specified. */ @JsonProperty(value = "autoScale") private AutoScaleSettings autoScale; + /** Creates an instance of ScaleSettings class. */ + public ScaleSettings() { + } + /** - * Get the fixedScale property: Fixed scale settings for the pool. This property and autoScale are mutually - * exclusive and one of the properties must be specified. + * Get the fixedScale property: Fixed scale settings for the pool. + * + *

This property and autoScale are mutually exclusive and one of the properties must be specified. * * @return the fixedScale value. */ @@ -39,8 +48,9 @@ public FixedScaleSettings fixedScale() { } /** - * Set the fixedScale property: Fixed scale settings for the pool. This property and autoScale are mutually - * exclusive and one of the properties must be specified. + * Set the fixedScale property: Fixed scale settings for the pool. + * + *

This property and autoScale are mutually exclusive and one of the properties must be specified. * * @param fixedScale the fixedScale value to set. * @return the ScaleSettings object itself. @@ -51,8 +61,9 @@ public ScaleSettings withFixedScale(FixedScaleSettings fixedScale) { } /** - * Get the autoScale property: AutoScale settings for the pool. This property and fixedScale are mutually exclusive - * and one of the properties must be specified. + * Get the autoScale property: AutoScale settings for the pool. + * + *

This property and fixedScale are mutually exclusive and one of the properties must be specified. * * @return the autoScale value. */ @@ -61,8 +72,9 @@ public AutoScaleSettings autoScale() { } /** - * Set the autoScale property: AutoScale settings for the pool. This property and fixedScale are mutually exclusive - * and one of the properties must be specified. + * Set the autoScale property: AutoScale settings for the pool. + * + *

This property and fixedScale are mutually exclusive and one of the properties must be specified. * * @param autoScale the autoScale value to set. * @return the ScaleSettings object itself. 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 index eef6b9fe393a..f0233e1707f4 100644 --- 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 @@ -22,6 +22,10 @@ public final class SkuCapability { @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY) private String value; + /** Creates an instance of SkuCapability class. */ + public SkuCapability() { + } + /** * Get the name property: The name of the feature. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StartTask.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StartTask.java index 1d3767d31f9d..249bade908d7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StartTask.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StartTask.java @@ -10,27 +10,28 @@ /** * A task which is run when a compute node joins a pool in the Azure Batch service, or when the compute node is rebooted - * or reimaged. In some cases the start task may be re-run even though the node was not rebooted. Due to this, start - * tasks should be idempotent and exit gracefully if the setup they're performing has already been done. Special care - * should be taken to avoid start tasks which create breakaway process or install/launch services from the start task - * working directory, as this will block Batch from being able to re-run the start task. + * or reimaged. + * + *

In some cases the start task may be re-run even though the node was not rebooted. Due to this, start tasks should + * be idempotent and exit gracefully if the setup they're performing has already been done. Special care should be taken + * to avoid start tasks which create breakaway process or install/launch services from the start task working directory, + * as this will block Batch from being able to re-run the start task. */ @Fluent public final class StartTask { /* - * The command line of the start task. The command line does not run under - * a shell, and therefore cannot take advantage of shell features such as - * environment variable expansion. If you want to take advantage of such - * features, you should invoke the shell in the command line, for example - * using "cmd /c MyCommand" in Windows or "/bin/sh -c MyCommand" in Linux. - * Required if any other properties of the startTask are specified. + * The command line of the start task. + * + * The command line does not run under a shell, and therefore cannot take advantage of shell features such as + * environment variable expansion. If you want to take advantage of such features, you should invoke the shell in + * the command line, for example using "cmd /c MyCommand" in Windows or "/bin/sh -c MyCommand" in Linux. Required + * if any other properties of the startTask are specified. */ @JsonProperty(value = "commandLine") private String commandLine; /* - * A list of files that the Batch service will download to the compute node - * before running the command line. + * A list of files that the Batch service will download to the compute node before running the command line. */ @JsonProperty(value = "resourceFiles") private List resourceFiles; @@ -42,59 +43,61 @@ public final class StartTask { private List environmentSettings; /* - * The definition of the user identity under which the task is run. If - * omitted, the task runs as a non-administrative user unique to the task. + * The definition of the user identity under which the task is run. + * + * If omitted, the task runs as a non-administrative user unique to the task. */ @JsonProperty(value = "userIdentity") private UserIdentity userIdentity; /* - * The maximum number of times the task may be retried. The Batch service - * retries a task if its exit code is nonzero. Note that this value - * specifically controls the number of retries. The Batch service will try - * the task once, and may then retry up to this limit. For example, if the - * maximum retry count is 3, Batch tries the task up to 4 times (one - * initial try and 3 retries). If the maximum retry count is 0, the Batch - * service does not retry the task. If the maximum retry count is -1, the - * Batch service retries the task without limit, however this is not - * recommended for a start task or any task. The default value is 0 (no - * retries). + * The maximum number of times the task may be retried. + * + * The Batch service retries a task if its exit code is nonzero. Note that this value specifically controls the + * number of retries. The Batch service will try the task once, and may then retry up to this limit. For example, + * if the maximum retry count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the + * maximum retry count is 0, the Batch service does not retry the task. If the maximum retry count is -1, the Batch + * service retries the task without limit. */ @JsonProperty(value = "maxTaskRetryCount") private Integer maxTaskRetryCount; /* - * Whether the Batch service should wait for the start task to complete - * successfully (that is, to exit with exit code 0) before scheduling any - * tasks on the compute node. If true and the start task fails on a compute - * node, the Batch service retries the start task up to its maximum retry - * count (maxTaskRetryCount). If the task has still not completed - * successfully after all retries, then the Batch service marks the compute - * node unusable, and will not schedule tasks to it. This condition can be - * detected via the node state and scheduling error detail. If false, the - * Batch service will not wait for the start task to complete. In this - * case, other tasks can start executing on the compute node while the - * start task is still running; and even if the start task fails, new tasks - * will continue to be scheduled on the node. The default is true. + * Whether the Batch service should wait for the start task to complete successfully (that is, to exit with exit + * code 0) before scheduling any tasks on the compute node. + * + * If true and the start task fails on a compute node, the Batch service retries the start task up to its maximum + * retry count (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the + * Batch service marks the compute node unusable, and will not schedule tasks to it. This condition can be detected + * via the node state and scheduling error detail. If false, the Batch service will not wait for the start task to + * complete. In this case, other tasks can start executing on the compute node while the start task is still + * running; and even if the start task fails, new tasks will continue to be scheduled on the node. The default is + * true. */ @JsonProperty(value = "waitForSuccess") private Boolean waitForSuccess; /* - * The container settings for a task. When this is specified, all - * directories recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of - * Azure Batch directories on the node) are mapped into the container, all - * task environment variables are mapped into the container, and the task - * command line is executed in the container. + * The container settings for a task. + * + * When this is specified, all directories recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch + * directories on the node) are mapped into the container, all task environment variables are mapped into the + * container, and the task command line is executed in the container. */ @JsonProperty(value = "containerSettings") private TaskContainerSettings containerSettings; + /** Creates an instance of StartTask class. */ + public StartTask() { + } + /** - * Get the commandLine property: The command line of the start task. The command line does not run under a shell, - * and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take - * advantage of such features, you should invoke the shell in the command line, for example using "cmd /c MyCommand" - * in Windows or "/bin/sh -c MyCommand" in Linux. Required if any other properties of the startTask are specified. + * Get the commandLine property: The command line of the start task. + * + *

The command line does not run under a shell, and therefore cannot take advantage of shell features such as + * environment variable expansion. If you want to take advantage of such features, you should invoke the shell in + * the command line, for example using "cmd /c MyCommand" in Windows or "/bin/sh -c MyCommand" in Linux. Required if + * any other properties of the startTask are specified. * * @return the commandLine value. */ @@ -103,10 +106,12 @@ public String commandLine() { } /** - * Set the commandLine property: The command line of the start task. The command line does not run under a shell, - * and therefore cannot take advantage of shell features such as environment variable expansion. If you want to take - * advantage of such features, you should invoke the shell in the command line, for example using "cmd /c MyCommand" - * in Windows or "/bin/sh -c MyCommand" in Linux. Required if any other properties of the startTask are specified. + * Set the commandLine property: The command line of the start task. + * + *

The command line does not run under a shell, and therefore cannot take advantage of shell features such as + * environment variable expansion. If you want to take advantage of such features, you should invoke the shell in + * the command line, for example using "cmd /c MyCommand" in Windows or "/bin/sh -c MyCommand" in Linux. Required if + * any other properties of the startTask are specified. * * @param commandLine the commandLine value to set. * @return the StartTask object itself. @@ -159,8 +164,9 @@ public StartTask withEnvironmentSettings(List environmentSet } /** - * Get the userIdentity property: The definition of the user identity under which the task is run. If omitted, the - * task runs as a non-administrative user unique to the task. + * Get the userIdentity property: The definition of the user identity under which the task is run. + * + *

If omitted, the task runs as a non-administrative user unique to the task. * * @return the userIdentity value. */ @@ -169,8 +175,9 @@ public UserIdentity userIdentity() { } /** - * Set the userIdentity property: The definition of the user identity under which the task is run. If omitted, the - * task runs as a non-administrative user unique to the task. + * Set the userIdentity property: The definition of the user identity under which the task is run. + * + *

If omitted, the task runs as a non-administrative user unique to the task. * * @param userIdentity the userIdentity value to set. * @return the StartTask object itself. @@ -181,12 +188,13 @@ public StartTask withUserIdentity(UserIdentity userIdentity) { } /** - * Get the maxTaskRetryCount property: The maximum number of times the task may be retried. The Batch service - * retries a task if its exit code is nonzero. Note that this value specifically controls the number of retries. The - * Batch service will try the task once, and may then retry up to this limit. For example, if the maximum retry - * count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum retry count is 0, - * the Batch service does not retry the task. If the maximum retry count is -1, the Batch service retries the task - * without limit, however this is not recommended for a start task or any task. The default value is 0 (no retries). + * Get the maxTaskRetryCount property: The maximum number of times the task may be retried. + * + *

The Batch service retries a task if its exit code is nonzero. Note that this value specifically controls the + * number of retries. The Batch service will try the task once, and may then retry up to this limit. For example, if + * the maximum retry count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum + * retry count is 0, the Batch service does not retry the task. If the maximum retry count is -1, the Batch service + * retries the task without limit. * * @return the maxTaskRetryCount value. */ @@ -195,12 +203,13 @@ public Integer maxTaskRetryCount() { } /** - * Set the maxTaskRetryCount property: The maximum number of times the task may be retried. The Batch service - * retries a task if its exit code is nonzero. Note that this value specifically controls the number of retries. The - * Batch service will try the task once, and may then retry up to this limit. For example, if the maximum retry - * count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum retry count is 0, - * the Batch service does not retry the task. If the maximum retry count is -1, the Batch service retries the task - * without limit, however this is not recommended for a start task or any task. The default value is 0 (no retries). + * Set the maxTaskRetryCount property: The maximum number of times the task may be retried. + * + *

The Batch service retries a task if its exit code is nonzero. Note that this value specifically controls the + * number of retries. The Batch service will try the task once, and may then retry up to this limit. For example, if + * the maximum retry count is 3, Batch tries the task up to 4 times (one initial try and 3 retries). If the maximum + * retry count is 0, the Batch service does not retry the task. If the maximum retry count is -1, the Batch service + * retries the task without limit. * * @param maxTaskRetryCount the maxTaskRetryCount value to set. * @return the StartTask object itself. @@ -212,13 +221,15 @@ public StartTask withMaxTaskRetryCount(Integer maxTaskRetryCount) { /** * Get the waitForSuccess property: Whether the Batch service should wait for the start task to complete - * successfully (that is, to exit with exit code 0) before scheduling any tasks on the compute node. If true and the - * start task fails on a compute node, the Batch service retries the start task up to its maximum retry count - * (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the Batch service - * marks the compute node unusable, and will not schedule tasks to it. This condition can be detected via the node - * state and scheduling error detail. If false, the Batch service will not wait for the start task to complete. In - * this case, other tasks can start executing on the compute node while the start task is still running; and even if - * the start task fails, new tasks will continue to be scheduled on the node. The default is true. + * successfully (that is, to exit with exit code 0) before scheduling any tasks on the compute node. + * + *

If true and the start task fails on a compute node, the Batch service retries the start task up to its maximum + * retry count (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the + * Batch service marks the compute node unusable, and will not schedule tasks to it. This condition can be detected + * via the node state and scheduling error detail. If false, the Batch service will not wait for the start task to + * complete. In this case, other tasks can start executing on the compute node while the start task is still + * running; and even if the start task fails, new tasks will continue to be scheduled on the node. The default is + * true. * * @return the waitForSuccess value. */ @@ -228,13 +239,15 @@ public Boolean waitForSuccess() { /** * Set the waitForSuccess property: Whether the Batch service should wait for the start task to complete - * successfully (that is, to exit with exit code 0) before scheduling any tasks on the compute node. If true and the - * start task fails on a compute node, the Batch service retries the start task up to its maximum retry count - * (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the Batch service - * marks the compute node unusable, and will not schedule tasks to it. This condition can be detected via the node - * state and scheduling error detail. If false, the Batch service will not wait for the start task to complete. In - * this case, other tasks can start executing on the compute node while the start task is still running; and even if - * the start task fails, new tasks will continue to be scheduled on the node. The default is true. + * successfully (that is, to exit with exit code 0) before scheduling any tasks on the compute node. + * + *

If true and the start task fails on a compute node, the Batch service retries the start task up to its maximum + * retry count (maxTaskRetryCount). If the task has still not completed successfully after all retries, then the + * Batch service marks the compute node unusable, and will not schedule tasks to it. This condition can be detected + * via the node state and scheduling error detail. If false, the Batch service will not wait for the start task to + * complete. In this case, other tasks can start executing on the compute node while the start task is still + * running; and even if the start task fails, new tasks will continue to be scheduled on the node. The default is + * true. * * @param waitForSuccess the waitForSuccess value to set. * @return the StartTask object itself. @@ -245,10 +258,11 @@ public StartTask withWaitForSuccess(Boolean waitForSuccess) { } /** - * Get the containerSettings property: The container settings for a task. When this is specified, all directories - * recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch directories on the node) are mapped into - * the container, all task environment variables are mapped into the container, and the task command line is - * executed in the container. + * Get the containerSettings property: The container settings for a task. + * + *

When this is specified, all directories recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch + * directories on the node) are mapped into the container, all task environment variables are mapped into the + * container, and the task command line is executed in the container. * * @return the containerSettings value. */ @@ -257,10 +271,11 @@ public TaskContainerSettings containerSettings() { } /** - * Set the containerSettings property: The container settings for a task. When this is specified, all directories - * recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch directories on the node) are mapped into - * the container, all task environment variables are mapped into the container, and the task command line is - * executed in the container. + * Set the containerSettings property: The container settings for a task. + * + *

When this is specified, all directories recursively below the AZ_BATCH_NODE_ROOT_DIR (the root of Azure Batch + * directories on the node) are mapped into the container, all task environment variables are mapped into the + * container, and the task command line is executed in the container. * * @param containerSettings the containerSettings value to set. * @return the StartTask object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StorageAccountType.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StorageAccountType.java index 5494da969a06..7fe97cd6771c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StorageAccountType.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/StorageAccountType.java @@ -7,7 +7,7 @@ import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; -/** Defines values for StorageAccountType. */ +/** The storage account type for use in creating data disks. */ public enum StorageAccountType { /** Enum value Standard_LRS. */ STANDARD_LRS("Standard_LRS"), @@ -30,6 +30,9 @@ public enum StorageAccountType { */ @JsonCreator public static StorageAccountType fromString(String value) { + if (value == null) { + return null; + } StorageAccountType[] items = StorageAccountType.values(); for (StorageAccountType item : items) { if (item.toString().equalsIgnoreCase(value)) { @@ -39,6 +42,7 @@ public static StorageAccountType fromString(String value) { return null; } + /** {@inheritDoc} */ @JsonValue @Override public String toString() { 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 index b94e7110e8f0..0f4ca6b38f10 100644 --- 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 @@ -25,6 +25,10 @@ public final class SupportedSkusResult { @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY) private String nextLink; + /** Creates an instance of SupportedSkusResult class. */ + public SupportedSkusResult() { + } + /** * Get the value property: The list of SKUs available for the Batch service in the location. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskContainerSettings.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskContainerSettings.java index 2bebe29fdd81..9dddd66c059a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskContainerSettings.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskContainerSettings.java @@ -12,40 +12,46 @@ @Fluent public final class TaskContainerSettings { /* - * Additional options to the container create command. These additional - * options are supplied as arguments to the "docker create" command, in - * addition to those controlled by the Batch Service. + * Additional options to the container create command. + * + * These additional options are supplied as arguments to the "docker create" command, in addition to those + * controlled by the Batch Service. */ @JsonProperty(value = "containerRunOptions") private String containerRunOptions; /* * The image to use to create the container in which the task will run. - * This is the full image reference, as would be specified to "docker - * pull". If no tag is provided as part of the image name, the tag - * ":latest" is used as a default. + * + * This is the full image reference, as would be specified to "docker pull". If no tag is provided as part of the + * image name, the tag ":latest" is used as a default. */ @JsonProperty(value = "imageName", required = true) private String imageName; /* - * A private container registry. This setting can be omitted if was already - * provided at pool creation. + * A private container registry. + * + * This setting can be omitted if was already provided at pool creation. */ @JsonProperty(value = "registry") private ContainerRegistry registry; /* - * A flag to indicate where the container task working directory is. The - * default is 'taskWorkingDirectory'. + * A flag to indicate where the container task working directory is. The default is 'taskWorkingDirectory'. */ @JsonProperty(value = "workingDirectory") private ContainerWorkingDirectory workingDirectory; + /** Creates an instance of TaskContainerSettings class. */ + public TaskContainerSettings() { + } + /** - * Get the containerRunOptions property: Additional options to the container create command. These additional - * options are supplied as arguments to the "docker create" command, in addition to those controlled by the Batch - * Service. + * Get the containerRunOptions property: Additional options to the container create command. + * + *

These additional options are supplied as arguments to the "docker create" command, in addition to those + * controlled by the Batch Service. * * @return the containerRunOptions value. */ @@ -54,9 +60,10 @@ public String containerRunOptions() { } /** - * Set the containerRunOptions property: Additional options to the container create command. These additional - * options are supplied as arguments to the "docker create" command, in addition to those controlled by the Batch - * Service. + * Set the containerRunOptions property: Additional options to the container create command. + * + *

These additional options are supplied as arguments to the "docker create" command, in addition to those + * controlled by the Batch Service. * * @param containerRunOptions the containerRunOptions value to set. * @return the TaskContainerSettings object itself. @@ -67,9 +74,10 @@ public TaskContainerSettings withContainerRunOptions(String containerRunOptions) } /** - * Get the imageName property: The image to use to create the container in which the task will run. This is the full - * image reference, as would be specified to "docker pull". If no tag is provided as part of the image name, the tag - * ":latest" is used as a default. + * Get the imageName property: The image to use to create the container in which the task will run. + * + *

This is the full image reference, as would be specified to "docker pull". If no tag is provided as part of the + * image name, the tag ":latest" is used as a default. * * @return the imageName value. */ @@ -78,9 +86,10 @@ public String imageName() { } /** - * Set the imageName property: The image to use to create the container in which the task will run. This is the full - * image reference, as would be specified to "docker pull". If no tag is provided as part of the image name, the tag - * ":latest" is used as a default. + * Set the imageName property: The image to use to create the container in which the task will run. + * + *

This is the full image reference, as would be specified to "docker pull". If no tag is provided as part of the + * image name, the tag ":latest" is used as a default. * * @param imageName the imageName value to set. * @return the TaskContainerSettings object itself. @@ -91,8 +100,9 @@ public TaskContainerSettings withImageName(String imageName) { } /** - * Get the registry property: A private container registry. This setting can be omitted if was already provided at - * pool creation. + * Get the registry property: A private container registry. + * + *

This setting can be omitted if was already provided at pool creation. * * @return the registry value. */ @@ -101,8 +111,9 @@ public ContainerRegistry registry() { } /** - * Set the registry property: A private container registry. This setting can be omitted if was already provided at - * pool creation. + * Set the registry property: A private container registry. + * + *

This setting can be omitted if was already provided at pool creation. * * @param registry the registry value to set. * @return the TaskContainerSettings object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskSchedulingPolicy.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskSchedulingPolicy.java index bddd972b0a31..56bc1da78716 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskSchedulingPolicy.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/TaskSchedulingPolicy.java @@ -17,6 +17,10 @@ public final class TaskSchedulingPolicy { @JsonProperty(value = "nodeFillType", required = true) private ComputeNodeFillType nodeFillType; + /** Creates an instance of TaskSchedulingPolicy class. */ + public TaskSchedulingPolicy() { + } + /** * Get the nodeFillType property: How tasks should be distributed across compute nodes. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAccount.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAccount.java index 14d0e076329e..46937f8e2afa 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAccount.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAccount.java @@ -12,7 +12,7 @@ @Fluent public final class UserAccount { /* - * The name of the user account. + * The name of the user account. Names can contain any Unicode characters up to a maximum length of 20. */ @JsonProperty(value = "name", required = true) private String name; @@ -24,33 +24,39 @@ public final class UserAccount { private String password; /* - * The elevation level of the user. nonAdmin - The auto user is a standard - * user without elevated access. admin - The auto user is a user with - * elevated access and operates with full Administrator permissions. The - * default value is nonAdmin. + * The elevation level of the user. + * + * nonAdmin - The auto user is a standard user without elevated access. admin - The auto user is a user with + * elevated access and operates with full Administrator permissions. The default value is nonAdmin. */ @JsonProperty(value = "elevationLevel") private ElevationLevel elevationLevel; /* - * Properties used to create a user account on a Linux node. This property - * is ignored if specified on a Windows pool. If not specified, the user is - * created with the default options. + * Properties used to create a user account on a Linux node. + * + * This property is ignored if specified on a Windows pool. If not specified, the user is created with the default + * options. */ @JsonProperty(value = "linuxUserConfiguration") private LinuxUserConfiguration linuxUserConfiguration; /* - * Properties used to create a user account on a Windows node. This - * property can only be specified if the user is on a Windows pool. If not - * specified and on a Windows pool, the user is created with the default - * options. + * Properties used to create a user account on a Windows node. + * + * This property can only be specified if the user is on a Windows pool. If not specified and on a Windows pool, + * the user is created with the default options. */ @JsonProperty(value = "windowsUserConfiguration") private WindowsUserConfiguration windowsUserConfiguration; + /** Creates an instance of UserAccount class. */ + public UserAccount() { + } + /** - * Get the name property: The name of the user account. + * Get the name property: The name of the user account. Names can contain any Unicode characters up to a maximum + * length of 20. * * @return the name value. */ @@ -59,7 +65,8 @@ public String name() { } /** - * Set the name property: The name of the user account. + * Set the name property: The name of the user account. Names can contain any Unicode characters up to a maximum + * length of 20. * * @param name the name value to set. * @return the UserAccount object itself. @@ -90,9 +97,10 @@ public UserAccount withPassword(String password) { } /** - * Get the elevationLevel property: The elevation level of the user. nonAdmin - The auto user is a standard user - * without elevated access. admin - The auto user is a user with elevated access and operates with full - * Administrator permissions. The default value is nonAdmin. + * Get the elevationLevel property: The elevation level of the user. + * + *

nonAdmin - The auto user is a standard user without elevated access. admin - The auto user is a user with + * elevated access and operates with full Administrator permissions. The default value is nonAdmin. * * @return the elevationLevel value. */ @@ -101,9 +109,10 @@ public ElevationLevel elevationLevel() { } /** - * Set the elevationLevel property: The elevation level of the user. nonAdmin - The auto user is a standard user - * without elevated access. admin - The auto user is a user with elevated access and operates with full - * Administrator permissions. The default value is nonAdmin. + * Set the elevationLevel property: The elevation level of the user. + * + *

nonAdmin - The auto user is a standard user without elevated access. admin - The auto user is a user with + * elevated access and operates with full Administrator permissions. The default value is nonAdmin. * * @param elevationLevel the elevationLevel value to set. * @return the UserAccount object itself. @@ -114,8 +123,10 @@ public UserAccount withElevationLevel(ElevationLevel elevationLevel) { } /** - * Get the linuxUserConfiguration property: Properties used to create a user account on a Linux node. This property - * is ignored if specified on a Windows pool. If not specified, the user is created with the default options. + * Get the linuxUserConfiguration property: Properties used to create a user account on a Linux node. + * + *

This property is ignored if specified on a Windows pool. If not specified, the user is created with the + * default options. * * @return the linuxUserConfiguration value. */ @@ -124,8 +135,10 @@ public LinuxUserConfiguration linuxUserConfiguration() { } /** - * Set the linuxUserConfiguration property: Properties used to create a user account on a Linux node. This property - * is ignored if specified on a Windows pool. If not specified, the user is created with the default options. + * Set the linuxUserConfiguration property: Properties used to create a user account on a Linux node. + * + *

This property is ignored if specified on a Windows pool. If not specified, the user is created with the + * default options. * * @param linuxUserConfiguration the linuxUserConfiguration value to set. * @return the UserAccount object itself. @@ -136,9 +149,10 @@ public UserAccount withLinuxUserConfiguration(LinuxUserConfiguration linuxUserCo } /** - * Get the windowsUserConfiguration property: Properties used to create a user account on a Windows node. This - * property can only be specified if the user is on a Windows pool. If not specified and on a Windows pool, the user - * is created with the default options. + * Get the windowsUserConfiguration property: Properties used to create a user account on a Windows node. + * + *

This property can only be specified if the user is on a Windows pool. If not specified and on a Windows pool, + * the user is created with the default options. * * @return the windowsUserConfiguration value. */ @@ -147,9 +161,10 @@ public WindowsUserConfiguration windowsUserConfiguration() { } /** - * Set the windowsUserConfiguration property: Properties used to create a user account on a Windows node. This - * property can only be specified if the user is on a Windows pool. If not specified and on a Windows pool, the user - * is created with the default options. + * Set the windowsUserConfiguration property: Properties used to create a user account on a Windows node. + * + *

This property can only be specified if the user is on a Windows pool. If not specified and on a Windows pool, + * the user is created with the default options. * * @param windowsUserConfiguration the windowsUserConfiguration value to set. * @return the UserAccount object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java index 2b4716922826..81b6753ba2b1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserAssignedIdentities.java @@ -22,6 +22,10 @@ public final class UserAssignedIdentities { @JsonProperty(value = "clientId", access = JsonProperty.Access.WRITE_ONLY) private String clientId; + /** Creates an instance of UserAssignedIdentities class. */ + public UserAssignedIdentities() { + } + /** * Get the principalId property: The principal id of user assigned identity. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserIdentity.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserIdentity.java index c2363b710460..d0ee0d8875b5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserIdentity.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/UserIdentity.java @@ -8,30 +8,36 @@ import com.fasterxml.jackson.annotation.JsonProperty; /** - * The definition of the user identity under which the task is run. Specify either the userName or autoUser property, - * but not both. + * The definition of the user identity under which the task is run. + * + *

Specify either the userName or autoUser property, but not both. */ @Fluent public class UserIdentity { /* - * The name of the user identity under which the task is run. The userName - * and autoUser properties are mutually exclusive; you must specify one but - * not both. + * The name of the user identity under which the task is run. + * + * The userName and autoUser properties are mutually exclusive; you must specify one but not both. */ @JsonProperty(value = "userName") private String username; /* - * Specifies the parameters for the auto user that runs a task on the Batch - * service. The userName and autoUser properties are mutually exclusive; - * you must specify one but not both. + * Specifies the parameters for the auto user that runs a task on the Batch service. + * + * The userName and autoUser properties are mutually exclusive; you must specify one but not both. */ @JsonProperty(value = "autoUser") private AutoUserSpecification autoUser; + /** Creates an instance of UserIdentity class. */ + public UserIdentity() { + } + /** - * Get the username property: The name of the user identity under which the task is run. The userName and autoUser - * properties are mutually exclusive; you must specify one but not both. + * Get the username property: The name of the user identity under which the task is run. + * + *

The userName and autoUser properties are mutually exclusive; you must specify one but not both. * * @return the username value. */ @@ -40,8 +46,9 @@ public String username() { } /** - * Set the username property: The name of the user identity under which the task is run. The userName and autoUser - * properties are mutually exclusive; you must specify one but not both. + * Set the username property: The name of the user identity under which the task is run. + * + *

The userName and autoUser properties are mutually exclusive; you must specify one but not both. * * @param username the username value to set. * @return the UserIdentity object itself. @@ -52,8 +59,9 @@ public UserIdentity withUsername(String username) { } /** - * Get the autoUser property: Specifies the parameters for the auto user that runs a task on the Batch service. The - * userName and autoUser properties are mutually exclusive; you must specify one but not both. + * Get the autoUser property: Specifies the parameters for the auto user that runs a task on the Batch service. + * + *

The userName and autoUser properties are mutually exclusive; you must specify one but not both. * * @return the autoUser value. */ @@ -62,8 +70,9 @@ public AutoUserSpecification autoUser() { } /** - * Set the autoUser property: Specifies the parameters for the auto user that runs a task on the Batch service. The - * userName and autoUser properties are mutually exclusive; you must specify one but not both. + * Set the autoUser property: Specifies the parameters for the auto user that runs a task on the Batch service. + * + *

The userName and autoUser properties are mutually exclusive; you must specify one but not both. * * @param autoUser the autoUser value to set. * @return the UserIdentity object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VMExtension.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VMExtension.java index abb47ff917ad..4b06f8edfac0 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VMExtension.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VMExtension.java @@ -37,34 +37,38 @@ public final class VMExtension { private String typeHandlerVersion; /* - * Indicates whether the extension should use a newer minor version if one - * is available at deployment time. Once deployed, however, the extension - * will not upgrade minor versions unless redeployed, even with this - * property set to true. + * Indicates whether the extension should use a newer minor version if one is available at deployment time. Once + * deployed, however, the extension will not upgrade minor versions unless redeployed, even with this property set + * to true. */ @JsonProperty(value = "autoUpgradeMinorVersion") private Boolean autoUpgradeMinorVersion; /* - * Any object + * JSON formatted public settings for the extension. */ @JsonProperty(value = "settings") private Object settings; /* - * The extension can contain either protectedSettings or - * protectedSettingsFromKeyVault or no protected settings at all. + * The extension can contain either protectedSettings or protectedSettingsFromKeyVault or no protected settings at + * all. */ @JsonProperty(value = "protectedSettings") private Object protectedSettings; /* - * The collection of extension names. Collection of extension names after - * which this extension needs to be provisioned. + * The collection of extension names. + * + * Collection of extension names after which this extension needs to be provisioned. */ @JsonProperty(value = "provisionAfterExtensions") private List provisionAfterExtensions; + /** Creates an instance of VMExtension class. */ + public VMExtension() { + } + /** * Get the name property: The name of the virtual machine extension. * @@ -170,7 +174,7 @@ public VMExtension withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion) } /** - * Get the settings property: Any object. + * Get the settings property: JSON formatted public settings for the extension. * * @return the settings value. */ @@ -179,7 +183,7 @@ public Object settings() { } /** - * Set the settings property: Any object. + * Set the settings property: JSON formatted public settings for the extension. * * @param settings the settings value to set. * @return the VMExtension object itself. @@ -212,8 +216,9 @@ public VMExtension withProtectedSettings(Object protectedSettings) { } /** - * Get the provisionAfterExtensions property: The collection of extension names. Collection of extension names after - * which this extension needs to be provisioned. + * Get the provisionAfterExtensions property: The collection of extension names. + * + *

Collection of extension names after which this extension needs to be provisioned. * * @return the provisionAfterExtensions value. */ @@ -222,8 +227,9 @@ public List provisionAfterExtensions() { } /** - * Set the provisionAfterExtensions property: The collection of extension names. Collection of extension names after - * which this extension needs to be provisioned. + * Set the provisionAfterExtensions property: The collection of extension names. + * + *

Collection of extension names after which this extension needs to be provisioned. * * @param provisionAfterExtensions the provisionAfterExtensions value to set. * @return the VMExtension object itself. 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 e236704c6fd5..7b5f24b5a11c 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 @@ -13,50 +13,47 @@ @Fluent public final class VirtualMachineConfiguration { /* - * 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 'List supported node - * agent SKUs' operation. + * 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 'List supported node agent + * SKUs' operation. */ @JsonProperty(value = "imageReference", required = true) private ImageReference imageReference; /* - * The SKU of the Batch node agent to be provisioned on compute nodes in - * the pool. The Batch node agent is a program that runs on each node in - * the pool, and provides the command-and-control interface between the - * node and the Batch service. There are different implementations of the - * node agent, known as SKUs, for different operating systems. You must - * specify a node agent SKU which matches the selected image reference. To - * get the list of supported node agent SKUs along with their list of - * verified image references, see the 'List supported node agent SKUs' - * operation. + * The SKU of the Batch node agent to be provisioned on compute nodes in the pool. + * + * The Batch node agent is a program that runs on each node in the pool, and provides the command-and-control + * interface between the node and the Batch service. There are different implementations of the node agent, known + * as SKUs, for different operating systems. You must specify a node agent SKU which matches the selected image + * reference. To get the list of supported node agent SKUs along with their list of verified image references, see + * the 'List supported node agent SKUs' operation. */ @JsonProperty(value = "nodeAgentSkuId", required = true) private String nodeAgentSkuId; /* - * Windows operating system settings to apply to the virtual machine. This - * property must not be specified if the imageReference specifies a Linux - * OS image. + * Windows operating system settings to apply to the virtual machine. + * + * This property must not be specified if the imageReference specifies a Linux OS image. */ @JsonProperty(value = "windowsConfiguration") private WindowsConfiguration windowsConfiguration; /* - * The configuration for data disks attached to the compute nodes in the - * pool. This property must be specified if the compute nodes in the pool - * need to have empty data disks attached to them. + * The configuration for data disks attached to the compute nodes in the pool. + * + * This property must be specified if the compute nodes in the pool need to have empty data disks attached to them. */ @JsonProperty(value = "dataDisks") private List dataDisks; /* - * The type of on-premises license to be used when deploying the operating - * system. This only applies to images that contain the Windows operating - * system, and should only be used when you hold valid on-premises licenses - * for the nodes which will be deployed. If omitted, no on-premises - * licensing discount is applied. Values are: + * The type of on-premises license to be used when deploying the operating system. + * + * This only applies to images that contain the Windows operating system, and should only be used when you hold + * valid on-premises licenses for the nodes which will be deployed. If omitted, no on-premises licensing discount + * is applied. Values are: * * Windows_Server - The on-premises license is for Windows Server. * Windows_Client - The on-premises license is for Windows Client. @@ -66,42 +63,49 @@ public final class VirtualMachineConfiguration { private String licenseType; /* - * The configuration for container-enabled pools. If specified, setup is - * performed on each node in the pool to allow tasks to run in containers. - * All regular tasks and job manager tasks run on this pool must specify - * the containerSettings property, and all other tasks may specify it. + * The configuration for container-enabled pools. + * + * If specified, setup is performed on each node in the pool to allow tasks to run in containers. All regular tasks + * and job manager tasks run on this pool must specify the containerSettings property, and all other tasks may + * specify it. */ @JsonProperty(value = "containerConfiguration") private ContainerConfiguration containerConfiguration; /* - * If specified, encryption is performed on each node in the pool during - * node provisioning. + * If specified, encryption is performed on each node in the pool during node provisioning. */ @JsonProperty(value = "diskEncryptionConfiguration") private DiskEncryptionConfiguration diskEncryptionConfiguration; /* - * Node placement configuration for batch pools. This configuration will - * specify rules on how nodes in the pool will be physically allocated. + * Node placement configuration for batch pools. + * + * This configuration will specify rules on how nodes in the pool will be physically allocated. */ @JsonProperty(value = "nodePlacementConfiguration") private NodePlacementConfiguration nodePlacementConfiguration; /* - * The virtual machine extension for the pool. If specified, the extensions - * mentioned in this configuration will be installed on each node. + * The virtual machine extension for the pool. + * + * If specified, the extensions mentioned in this configuration will be installed on each node. */ @JsonProperty(value = "extensions") private List extensions; /* - * Settings for the operating system disk of the virtual machine. Contains - * configuration for ephemeral OSDisk settings. + * Settings for the operating system disk of the virtual machine. + * + * Contains configuration for ephemeral OSDisk settings. */ @JsonProperty(value = "osDisk") private OSDisk osDisk; + /** Creates an instance of VirtualMachineConfiguration class. */ + public VirtualMachineConfiguration() { + } + /** * 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 @@ -128,7 +132,8 @@ public VirtualMachineConfiguration withImageReference(ImageReference imageRefere /** * Get the nodeAgentSkuId property: The SKU of the Batch node agent to be provisioned on compute nodes in the pool. - * The Batch node agent is a program that runs on each node in the pool, and provides the command-and-control + * + *

The Batch node agent is a program that runs on each node in the pool, and provides the command-and-control * interface between the node and the Batch service. There are different implementations of the node agent, known as * SKUs, for different operating systems. You must specify a node agent SKU which matches the selected image * reference. To get the list of supported node agent SKUs along with their list of verified image references, see @@ -142,7 +147,8 @@ public String nodeAgentSkuId() { /** * Set the nodeAgentSkuId property: The SKU of the Batch node agent to be provisioned on compute nodes in the pool. - * The Batch node agent is a program that runs on each node in the pool, and provides the command-and-control + * + *

The Batch node agent is a program that runs on each node in the pool, and provides the command-and-control * interface between the node and the Batch service. There are different implementations of the node agent, known as * SKUs, for different operating systems. You must specify a node agent SKU which matches the selected image * reference. To get the list of supported node agent SKUs along with their list of verified image references, see @@ -157,8 +163,9 @@ public VirtualMachineConfiguration withNodeAgentSkuId(String nodeAgentSkuId) { } /** - * Get the windowsConfiguration property: Windows operating system settings to apply to the virtual machine. This - * property must not be specified if the imageReference specifies a Linux OS image. + * Get the windowsConfiguration property: Windows operating system settings to apply to the virtual machine. + * + *

This property must not be specified if the imageReference specifies a Linux OS image. * * @return the windowsConfiguration value. */ @@ -167,8 +174,9 @@ public WindowsConfiguration windowsConfiguration() { } /** - * Set the windowsConfiguration property: Windows operating system settings to apply to the virtual machine. This - * property must not be specified if the imageReference specifies a Linux OS image. + * Set the windowsConfiguration property: Windows operating system settings to apply to the virtual machine. + * + *

This property must not be specified if the imageReference specifies a Linux OS image. * * @param windowsConfiguration the windowsConfiguration value to set. * @return the VirtualMachineConfiguration object itself. @@ -179,8 +187,10 @@ public VirtualMachineConfiguration withWindowsConfiguration(WindowsConfiguration } /** - * Get the dataDisks property: The configuration for data disks attached to the compute nodes in the pool. This - * property must be specified if the compute nodes in the pool need to have empty data disks attached to them. + * Get the dataDisks property: The configuration for data disks attached to the compute nodes in the pool. + * + *

This property must be specified if the compute nodes in the pool need to have empty data disks attached to + * them. * * @return the dataDisks value. */ @@ -189,8 +199,10 @@ public List dataDisks() { } /** - * Set the dataDisks property: The configuration for data disks attached to the compute nodes in the pool. This - * property must be specified if the compute nodes in the pool need to have empty data disks attached to them. + * Set the dataDisks property: The configuration for data disks attached to the compute nodes in the pool. + * + *

This property must be specified if the compute nodes in the pool need to have empty data disks attached to + * them. * * @param dataDisks the dataDisks value to set. * @return the VirtualMachineConfiguration object itself. @@ -202,7 +214,8 @@ public VirtualMachineConfiguration withDataDisks(List dataDisks) { /** * Get the licenseType property: The type of on-premises license to be used when deploying the operating system. - * This only applies to images that contain the Windows operating system, and should only be used when you hold + * + *

This only applies to images that contain the Windows operating system, and should only be used when you hold * valid on-premises licenses for the nodes which will be deployed. If omitted, no on-premises licensing discount is * applied. Values are: * @@ -217,7 +230,8 @@ public String licenseType() { /** * Set the licenseType property: The type of on-premises license to be used when deploying the operating system. - * This only applies to images that contain the Windows operating system, and should only be used when you hold + * + *

This only applies to images that contain the Windows operating system, and should only be used when you hold * valid on-premises licenses for the nodes which will be deployed. If omitted, no on-premises licensing discount is * applied. Values are: * @@ -233,9 +247,11 @@ public VirtualMachineConfiguration withLicenseType(String licenseType) { } /** - * Get the containerConfiguration property: The configuration for container-enabled pools. If specified, setup is - * performed on each node in the pool to allow tasks to run in containers. All regular tasks and job manager tasks - * run on this pool must specify the containerSettings property, and all other tasks may specify it. + * Get the containerConfiguration property: The configuration for container-enabled pools. + * + *

If specified, setup is performed on each node in the pool to allow tasks to run in containers. All regular + * tasks and job manager tasks run on this pool must specify the containerSettings property, and all other tasks may + * specify it. * * @return the containerConfiguration value. */ @@ -244,9 +260,11 @@ public ContainerConfiguration containerConfiguration() { } /** - * Set the containerConfiguration property: The configuration for container-enabled pools. If specified, setup is - * performed on each node in the pool to allow tasks to run in containers. All regular tasks and job manager tasks - * run on this pool must specify the containerSettings property, and all other tasks may specify it. + * Set the containerConfiguration property: The configuration for container-enabled pools. + * + *

If specified, setup is performed on each node in the pool to allow tasks to run in containers. All regular + * tasks and job manager tasks run on this pool must specify the containerSettings property, and all other tasks may + * specify it. * * @param containerConfiguration the containerConfiguration value to set. * @return the VirtualMachineConfiguration object itself. @@ -280,8 +298,9 @@ public VirtualMachineConfiguration withDiskEncryptionConfiguration( } /** - * Get the nodePlacementConfiguration property: Node placement configuration for batch pools. This configuration - * will specify rules on how nodes in the pool will be physically allocated. + * Get the nodePlacementConfiguration property: Node placement configuration for batch pools. + * + *

This configuration will specify rules on how nodes in the pool will be physically allocated. * * @return the nodePlacementConfiguration value. */ @@ -290,8 +309,9 @@ public NodePlacementConfiguration nodePlacementConfiguration() { } /** - * Set the nodePlacementConfiguration property: Node placement configuration for batch pools. This configuration - * will specify rules on how nodes in the pool will be physically allocated. + * Set the nodePlacementConfiguration property: Node placement configuration for batch pools. + * + *

This configuration will specify rules on how nodes in the pool will be physically allocated. * * @param nodePlacementConfiguration the nodePlacementConfiguration value to set. * @return the VirtualMachineConfiguration object itself. @@ -303,8 +323,9 @@ public VirtualMachineConfiguration withNodePlacementConfiguration( } /** - * Get the extensions property: The virtual machine extension for the pool. If specified, the extensions mentioned - * in this configuration will be installed on each node. + * Get the extensions property: The virtual machine extension for the pool. + * + *

If specified, the extensions mentioned in this configuration will be installed on each node. * * @return the extensions value. */ @@ -313,8 +334,9 @@ public List extensions() { } /** - * Set the extensions property: The virtual machine extension for the pool. If specified, the extensions mentioned - * in this configuration will be installed on each node. + * Set the extensions property: The virtual machine extension for the pool. + * + *

If specified, the extensions mentioned in this configuration will be installed on each node. * * @param extensions the extensions value to set. * @return the VirtualMachineConfiguration object itself. @@ -325,8 +347,9 @@ public VirtualMachineConfiguration withExtensions(List extensions) } /** - * Get the osDisk property: Settings for the operating system disk of the virtual machine. Contains configuration - * for ephemeral OSDisk settings. + * Get the osDisk property: Settings for the operating system disk of the virtual machine. + * + *

Contains configuration for ephemeral OSDisk settings. * * @return the osDisk value. */ @@ -335,8 +358,9 @@ public OSDisk osDisk() { } /** - * Set the osDisk property: Settings for the operating system disk of the virtual machine. Contains configuration - * for ephemeral OSDisk settings. + * Set the osDisk property: Settings for the operating system disk of the virtual machine. + * + *

Contains configuration for ephemeral OSDisk settings. * * @param osDisk the osDisk value to set. * @return the VirtualMachineConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineFamilyCoreQuota.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineFamilyCoreQuota.java index 1acdcc55fc2d..0141f9f4f25c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineFamilyCoreQuota.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/VirtualMachineFamilyCoreQuota.java @@ -22,6 +22,10 @@ public final class VirtualMachineFamilyCoreQuota { @JsonProperty(value = "coreQuota", access = JsonProperty.Access.WRITE_ONLY) private Integer coreQuota; + /** Creates an instance of VirtualMachineFamilyCoreQuota class. */ + public VirtualMachineFamilyCoreQuota() { + } + /** * Get the name property: The Virtual Machine family name. * diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsConfiguration.java index fdfcc9ceeb8a..a7360b9fe088 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsConfiguration.java @@ -11,15 +11,21 @@ @Fluent public final class WindowsConfiguration { /* - * Whether automatic updates are enabled on the virtual machine. If - * omitted, the default value is true. + * Whether automatic updates are enabled on the virtual machine. + * + * If omitted, the default value is true. */ @JsonProperty(value = "enableAutomaticUpdates") private Boolean enableAutomaticUpdates; + /** Creates an instance of WindowsConfiguration class. */ + public WindowsConfiguration() { + } + /** - * Get the enableAutomaticUpdates property: Whether automatic updates are enabled on the virtual machine. If - * omitted, the default value is true. + * Get the enableAutomaticUpdates property: Whether automatic updates are enabled on the virtual machine. + * + *

If omitted, the default value is true. * * @return the enableAutomaticUpdates value. */ @@ -28,8 +34,9 @@ public Boolean enableAutomaticUpdates() { } /** - * Set the enableAutomaticUpdates property: Whether automatic updates are enabled on the virtual machine. If - * omitted, the default value is true. + * Set the enableAutomaticUpdates property: Whether automatic updates are enabled on the virtual machine. + * + *

If omitted, the default value is true. * * @param enableAutomaticUpdates the enableAutomaticUpdates value to set. * @return the WindowsConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsUserConfiguration.java b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsUserConfiguration.java index 37f67c3882d7..4d3bd23e47f3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsUserConfiguration.java +++ b/sdk/batch/azure-resourcemanager-batch/src/main/java/com/azure/resourcemanager/batch/models/WindowsUserConfiguration.java @@ -11,16 +11,23 @@ @Fluent public final class WindowsUserConfiguration { /* - * Login mode for user Specifies login mode for the user. The default value - * for VirtualMachineConfiguration pools is interactive mode and for - * CloudServiceConfiguration pools is batch mode. + * Login mode for user + * + * Specifies login mode for the user. The default value for VirtualMachineConfiguration pools is interactive mode + * and for CloudServiceConfiguration pools is batch mode. */ @JsonProperty(value = "loginMode") private LoginMode loginMode; + /** Creates an instance of WindowsUserConfiguration class. */ + public WindowsUserConfiguration() { + } + /** - * Get the loginMode property: Login mode for user Specifies login mode for the user. The default value for - * VirtualMachineConfiguration pools is interactive mode and for CloudServiceConfiguration pools is batch mode. + * Get the loginMode property: Login mode for user + * + *

Specifies login mode for the user. The default value for VirtualMachineConfiguration pools is interactive mode + * and for CloudServiceConfiguration pools is batch mode. * * @return the loginMode value. */ @@ -29,8 +36,10 @@ public LoginMode loginMode() { } /** - * Set the loginMode property: Login mode for user Specifies login mode for the user. The default value for - * VirtualMachineConfiguration pools is interactive mode and for CloudServiceConfiguration pools is batch mode. + * Set the loginMode property: Login mode for user + * + *

Specifies login mode for the user. The default value for VirtualMachineConfiguration pools is interactive mode + * and for CloudServiceConfiguration pools is batch mode. * * @param loginMode the loginMode value to set. * @return the WindowsUserConfiguration object itself. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationCreateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationCreateSamples.java index eefae5e29fd9..173953ca90ba 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationCreateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationCreateSamples.java @@ -7,7 +7,7 @@ /** Samples for Application Create. */ public final class ApplicationCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationCreate.json */ /** * Sample code: ApplicationCreate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationDeleteSamples.java index 805411b86541..12e304b03216 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationDeleteSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for Application Delete. */ public final class ApplicationDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationDelete.json */ /** * Sample code: ApplicationDelete. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationGetSamples.java index ad17f802ec8c..e84b46688d78 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationGetSamples.java @@ -9,7 +9,7 @@ /** Samples for Application Get. */ public final class ApplicationGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationGet.json */ /** * Sample code: ApplicationGet. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationListSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationListSamples.java index e0c7bcb26603..24e577e49574 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationListSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationListSamples.java @@ -9,7 +9,7 @@ /** Samples for Application List. */ public final class ApplicationListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationList.json */ /** * Sample code: ApplicationList. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageActivateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageActivateSamples.java index e3620e4554c4..314dcbcb8a8f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageActivateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageActivateSamples.java @@ -10,7 +10,7 @@ /** Samples for ApplicationPackage Activate. */ public final class ApplicationPackageActivateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageActivate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageActivate.json */ /** * Sample code: ApplicationPackageActivate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageCreateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageCreateSamples.java index 0d0733c20ddd..78ef9dbf73a4 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageCreateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageCreateSamples.java @@ -7,7 +7,7 @@ /** Samples for ApplicationPackage Create. */ public final class ApplicationPackageCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageCreate.json */ /** * Sample code: ApplicationPackageCreate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageDeleteSamples.java index 7622c5bb1322..d8048d09eb2f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageDeleteSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for ApplicationPackage Delete. */ public final class ApplicationPackageDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageDelete.json */ /** * Sample code: ApplicationPackageDelete. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageGetSamples.java index 51841383ea74..fe38389d92b6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageGetSamples.java @@ -9,7 +9,7 @@ /** Samples for ApplicationPackage Get. */ public final class ApplicationPackageGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageGet.json */ /** * Sample code: ApplicationPackageGet. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageListSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageListSamples.java index e2aa1fccb8b1..eaf3a61bf2a6 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageListSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationPackageListSamples.java @@ -9,7 +9,7 @@ /** Samples for ApplicationPackage List. */ public final class ApplicationPackageListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationPackageList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationPackageList.json */ /** * Sample code: ApplicationPackageList. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationUpdateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationUpdateSamples.java index f93068322322..950e8eff6ba4 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationUpdateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/ApplicationUpdateSamples.java @@ -10,7 +10,7 @@ /** Samples for Application Update. */ public final class ApplicationUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/ApplicationUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/ApplicationUpdate.json */ /** * Sample code: ApplicationUpdate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountCreateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountCreateSamples.java index 64944f99f8c4..da0733da72f1 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountCreateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountCreateSamples.java @@ -17,7 +17,7 @@ /** Samples for BatchAccount Create. */ public final class BatchAccountCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_BYOS.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_BYOS.json */ /** * Sample code: BatchAccountCreate_BYOS. @@ -44,7 +44,7 @@ public static void batchAccountCreateBYOS(com.azure.resourcemanager.batch.BatchM } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_UserAssignedIdentity.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_UserAssignedIdentity.json */ /** * Sample code: BatchAccountCreate_UserAssignedIdentity. @@ -72,7 +72,7 @@ public static void batchAccountCreateUserAssignedIdentity(com.azure.resourcemana } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateBatchAccountCreate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateBatchAccountCreate.json */ /** * Sample code: PrivateBatchAccountCreate. @@ -99,7 +99,7 @@ public static void privateBatchAccountCreate(com.azure.resourcemanager.batch.Bat } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_SystemAssignedIdentity.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_SystemAssignedIdentity.json */ /** * Sample code: BatchAccountCreate_SystemAssignedIdentity. @@ -121,7 +121,7 @@ public static void batchAccountCreateSystemAssignedIdentity(com.azure.resourcema } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountCreate_Default.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountCreate_Default.json */ /** * Sample code: BatchAccountCreate_Default. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountDeleteSamples.java index d9964c33077e..9d9a03abd30f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountDeleteSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount Delete. */ public final class BatchAccountDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountDelete.json */ /** * Sample code: BatchAccountDelete. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetByResourceGroupSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetByResourceGroupSamples.java index 304e186fccca..10b6f886cb5b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetByResourceGroupSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetByResourceGroupSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount GetByResourceGroup. */ public final class BatchAccountGetByResourceGroupSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateBatchAccountGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateBatchAccountGet.json */ /** * Sample code: PrivateBatchAccountGet. @@ -23,7 +23,7 @@ public static void privateBatchAccountGet(com.azure.resourcemanager.batch.BatchM } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountGet.json */ /** * Sample code: BatchAccountGet. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetDetectorSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetDetectorSamples.java index 41546ccd4ee0..d20062b3e2f7 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetDetectorSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetDetectorSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount GetDetector. */ public final class BatchAccountGetDetectorSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/DetectorGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/DetectorGet.json */ /** * Sample code: GetDetector. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetKeysSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetKeysSamples.java index 06bcd6b3f206..3d194fe75099 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetKeysSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountGetKeysSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount GetKeys. */ public final class BatchAccountGetKeysSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountGetKeys.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountGetKeys.json */ /** * Sample code: BatchAccountGetKeys. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListByResourceGroupSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListByResourceGroupSamples.java index ba6093afd84d..412865b0116e 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListByResourceGroupSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListByResourceGroupSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount ListByResourceGroup. */ public final class BatchAccountListByResourceGroupSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountListByResourceGroup.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountListByResourceGroup.json */ /** * Sample code: BatchAccountListByResourceGroup. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListDetectorsSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListDetectorsSamples.java index 1ec565749a49..77b437df5e36 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListDetectorsSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListDetectorsSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount ListDetectors. */ public final class BatchAccountListDetectorsSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/DetectorList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/DetectorList.json */ /** * Sample code: ListDetectors. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListOutboundNetworkDependenciesEndpointsSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListOutboundNetworkDependenciesEndpointsSamples.java index 5cef25f74769..01d3f89073c5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListOutboundNetworkDependenciesEndpointsSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListOutboundNetworkDependenciesEndpointsSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount ListOutboundNetworkDependenciesEndpoints. */ public final class BatchAccountListOutboundNetworkDependenciesEndpointsSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountListOutboundNetworkDependenciesEndpoints.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountListOutboundNetworkDependenciesEndpoints.json */ /** * Sample code: ListOutboundNetworkDependencies. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListSamples.java index 8c291663cbe5..94cf177ee438 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountListSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount List. */ public final class BatchAccountListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountList.json */ /** * Sample code: BatchAccountList. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountRegenerateKeySamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountRegenerateKeySamples.java index 0cb90d2161e9..a19b2398fa60 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountRegenerateKeySamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountRegenerateKeySamples.java @@ -11,7 +11,7 @@ /** Samples for BatchAccount RegenerateKey. */ public final class BatchAccountRegenerateKeySamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountRegenerateKey.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountRegenerateKey.json */ /** * Sample code: BatchAccountRegenerateKey. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountSynchronizeAutoStorageKeysSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountSynchronizeAutoStorageKeysSamples.java index 3933272d2e8f..43bf1dc7f50d 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountSynchronizeAutoStorageKeysSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountSynchronizeAutoStorageKeysSamples.java @@ -9,7 +9,7 @@ /** Samples for BatchAccount SynchronizeAutoStorageKeys. */ public final class BatchAccountSynchronizeAutoStorageKeysSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountSynchronizeAutoStorageKeys.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountSynchronizeAutoStorageKeys.json */ /** * Sample code: BatchAccountSynchronizeAutoStorageKeys. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountUpdateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountUpdateSamples.java index 147f68531bce..54b0d806b0c3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountUpdateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/BatchAccountUpdateSamples.java @@ -11,7 +11,7 @@ /** Samples for BatchAccount Update. */ public final class BatchAccountUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/BatchAccountUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/BatchAccountUpdate.json */ /** * Sample code: BatchAccountUpdate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCancelDeletionSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCancelDeletionSamples.java index 9950ac513e8f..7334101c67c2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCancelDeletionSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCancelDeletionSamples.java @@ -9,7 +9,7 @@ /** Samples for Certificate CancelDeletion. */ public final class CertificateCancelDeletionSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCancelDeletion.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCancelDeletion.json */ /** * Sample code: CertificateCancelDeletion. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCreateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCreateSamples.java index 0df6cba5a75f..3509ec369ee5 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCreateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateCreateSamples.java @@ -9,7 +9,7 @@ /** Samples for Certificate Create. */ public final class CertificateCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_Full.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_Full.json */ /** * Sample code: CreateCertificate - Full. @@ -21,7 +21,6 @@ public static void createCertificateFull(com.azure.resourcemanager.batch.BatchMa .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIIJsgIBAzCCCW4GCSqGSIb3DQE...") .withPassword("") .withThumbprintAlgorithm("sha1") .withThumbprint("0a0e4f50d51beadeac1d35afc5116098e7902e6e") @@ -30,7 +29,7 @@ public static void createCertificateFull(com.azure.resourcemanager.batch.BatchMa } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_Minimal.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_Minimal.json */ /** * Sample code: CreateCertificate - Minimal Pfx. @@ -42,13 +41,12 @@ public static void createCertificateMinimalPfx(com.azure.resourcemanager.batch.B .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIIJsgIBAzCCCW4GCSqGSIb3DQE...") .withPassword("") .create(); } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateCreate_MinimalCer.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateCreate_MinimalCer.json */ /** * Sample code: CreateCertificate - Minimal Cer. @@ -60,7 +58,6 @@ public static void createCertificateMinimalCer(com.azure.resourcemanager.batch.B .certificates() .define("sha1-0a0e4f50d51beadeac1d35afc5116098e7902e6e") .withExistingBatchAccount("default-azurebatch-japaneast", "sampleacct") - .withData("MIICrjCCAZagAwI...") .withFormat(CertificateFormat.CER) .create(); } diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateDeleteSamples.java index c72dd18be7fe..08257f805278 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateDeleteSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for Certificate Delete. */ public final class CertificateDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateDelete.json */ /** * Sample code: CertificateDelete. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateGetSamples.java index 5086cb4ddb04..6ae68e7bbe2c 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateGetSamples.java @@ -9,7 +9,7 @@ /** Samples for Certificate Get. */ public final class CertificateGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateGetWithDeletionError.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateGetWithDeletionError.json */ /** * Sample code: Get Certificate with Deletion Error. @@ -27,7 +27,7 @@ public static void getCertificateWithDeletionError(com.azure.resourcemanager.bat } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateGet.json */ /** * Sample code: Get Certificate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateListByBatchAccountSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateListByBatchAccountSamples.java index 221c63d70aa9..3c7acb289268 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateListByBatchAccountSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateListByBatchAccountSamples.java @@ -9,7 +9,7 @@ /** Samples for Certificate ListByBatchAccount. */ public final class CertificateListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateListWithFilter.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateListWithFilter.json */ /** * Sample code: ListCertificates - Filter and Select. @@ -30,7 +30,7 @@ public static void listCertificatesFilterAndSelect(com.azure.resourcemanager.bat } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateList.json */ /** * Sample code: ListCertificates. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateUpdateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateUpdateSamples.java index ac24588c0e6d..931c273f05d8 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateUpdateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/CertificateUpdateSamples.java @@ -10,7 +10,7 @@ /** Samples for Certificate Update. */ public final class CertificateUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/CertificateUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/CertificateUpdate.json */ /** * Sample code: UpdateCertificate. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationCheckNameAvailabilitySamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationCheckNameAvailabilitySamples.java index e704cd655bcb..ba1a0bd7c6f0 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationCheckNameAvailabilitySamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationCheckNameAvailabilitySamples.java @@ -10,7 +10,7 @@ /** Samples for Location CheckNameAvailability. */ public final class LocationCheckNameAvailabilitySamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationCheckNameAvailability_AlreadyExists.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationCheckNameAvailability_AlreadyExists.json */ /** * Sample code: LocationCheckNameAvailability_AlreadyExists. @@ -26,7 +26,7 @@ public static void locationCheckNameAvailabilityAlreadyExists( } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationCheckNameAvailability_Available.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationCheckNameAvailability_Available.json */ /** * Sample code: LocationCheckNameAvailability_Available. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationGetQuotasSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationGetQuotasSamples.java index 475d5f82d953..ce1b9ccf7062 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationGetQuotasSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationGetQuotasSamples.java @@ -9,7 +9,7 @@ /** Samples for Location GetQuotas. */ public final class LocationGetQuotasSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationGetQuotas.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationGetQuotas.json */ /** * Sample code: LocationGetQuotas. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedCloudServiceSkusSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedCloudServiceSkusSamples.java index 4d60ecfb5daa..a1f5fcf5bec2 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedCloudServiceSkusSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedCloudServiceSkusSamples.java @@ -9,7 +9,7 @@ /** Samples for Location ListSupportedCloudServiceSkus. */ public final class LocationListSupportedCloudServiceSkusSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationListCloudServiceSkus.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationListCloudServiceSkus.json */ /** * Sample code: LocationListCloudServiceSkus. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedVirtualMachineSkusSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedVirtualMachineSkusSamples.java index 476764b0de93..ff6f712c4b41 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedVirtualMachineSkusSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/LocationListSupportedVirtualMachineSkusSamples.java @@ -9,7 +9,7 @@ /** Samples for Location ListSupportedVirtualMachineSkus. */ public final class LocationListSupportedVirtualMachineSkusSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/LocationListVirtualMachineSkus.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/LocationListVirtualMachineSkus.json */ /** * Sample code: LocationListVirtualMachineSkus. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/OperationsListSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/OperationsListSamples.java index 1e5f57bfaa0e..eb1743c6c103 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/OperationsListSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/OperationsListSamples.java @@ -9,7 +9,7 @@ /** Samples for Operations List. */ public final class OperationsListSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/OperationsList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/OperationsList.json */ /** * Sample code: OperationsList. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolCreateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolCreateSamples.java index 90942b072bfa..52fcc7512e18 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolCreateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolCreateSamples.java @@ -37,6 +37,7 @@ import com.azure.resourcemanager.batch.models.NetworkConfiguration; import com.azure.resourcemanager.batch.models.NetworkSecurityGroupRule; import com.azure.resourcemanager.batch.models.NetworkSecurityGroupRuleAccess; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.NodePlacementConfiguration; import com.azure.resourcemanager.batch.models.NodePlacementPolicyType; import com.azure.resourcemanager.batch.models.OSDisk; @@ -63,7 +64,7 @@ /** Samples for Pool Create. */ public final class PoolCreateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_SharedImageGallery.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_SharedImageGallery.json */ /** * Sample code: CreatePool - Custom Image. @@ -89,7 +90,7 @@ public static void createPoolCustomImage(com.azure.resourcemanager.batch.BatchMa } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_CloudServiceConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_CloudServiceConfiguration.json */ /** * Sample code: CreatePool - Full CloudServiceConfiguration. @@ -188,7 +189,7 @@ public static void createPoolFullCloudServiceConfiguration(com.azure.resourceman } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_MinimalCloudServiceConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_MinimalCloudServiceConfiguration.json */ /** * Sample code: CreatePool - Minimal CloudServiceConfiguration. @@ -210,7 +211,7 @@ public static void createPoolMinimalCloudServiceConfiguration( } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_MinimalVirtualMachineConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_MinimalVirtualMachineConfiguration.json */ /** * Sample code: CreatePool - Minimal VirtualMachineConfiguration. @@ -245,7 +246,7 @@ public static void createPoolMinimalVirtualMachineConfiguration( } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_NoPublicIPAddresses.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_NoPublicIPAddresses.json */ /** * Sample code: CreatePool - No public IP. @@ -278,7 +279,7 @@ public static void createPoolNoPublicIP(com.azure.resourcemanager.batch.BatchMan } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_VirtualMachineConfiguration_Extensions.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_VirtualMachineConfiguration_Extensions.json */ /** * Sample code: CreatePool - VirtualMachineConfiguration Extensions. @@ -331,11 +332,12 @@ public static void createPoolVirtualMachineConfigurationExtensions( new AutoScaleSettings() .withFormula("$TargetDedicatedNodes=1") .withEvaluationInterval(Duration.parse("PT5M")))) + .withTargetNodeCommunicationMode(NodeCommunicationMode.DEFAULT) .create(); } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_UserAssignedIdentities.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_UserAssignedIdentities.json */ /** * Sample code: CreatePool - UserAssignedIdentities. @@ -378,7 +380,7 @@ public static void createPoolUserAssignedIdentities(com.azure.resourcemanager.ba } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_PublicIPs.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_PublicIPs.json */ /** * Sample code: CreatePool - Public IPs. @@ -415,7 +417,7 @@ public static void createPoolPublicIPs(com.azure.resourcemanager.batch.BatchMana } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolCreate_VirtualMachineConfiguration.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolCreate_VirtualMachineConfiguration.json */ /** * Sample code: CreatePool - Full VirtualMachineConfiguration. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDeleteSamples.java index bb581b3cacb6..a3ef98deef0a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDeleteSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDeleteSamples.java @@ -9,7 +9,7 @@ /** Samples for Pool Delete. */ public final class PoolDeleteSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolDelete.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolDelete.json */ /** * Sample code: DeletePool. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDisableAutoScaleSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDisableAutoScaleSamples.java index c56aad12913c..f0cddd5123ec 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDisableAutoScaleSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolDisableAutoScaleSamples.java @@ -9,7 +9,7 @@ /** Samples for Pool DisableAutoScale. */ public final class PoolDisableAutoScaleSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolDisableAutoScale.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolDisableAutoScale.json */ /** * Sample code: Disable AutoScale. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolGetSamples.java index 6f410492eca5..0f79569f6771 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolGetSamples.java @@ -9,7 +9,7 @@ /** Samples for Pool Get. */ public final class PoolGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolGet_VirtualMachineConfiguration_Extensions.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolGet_VirtualMachineConfiguration_Extensions.json */ /** * Sample code: GetPool - VirtualMachineConfiguration Extensions. @@ -22,7 +22,7 @@ public static void getPoolVirtualMachineConfigurationExtensions( } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolGet.json */ /** * Sample code: GetPool. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolListByBatchAccountSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolListByBatchAccountSamples.java index a5fbaa28741e..9aeaf71c5c5b 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolListByBatchAccountSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolListByBatchAccountSamples.java @@ -9,7 +9,7 @@ /** Samples for Pool ListByBatchAccount. */ public final class PoolListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolList.json */ /** * Sample code: ListPool. @@ -23,7 +23,7 @@ public static void listPool(com.azure.resourcemanager.batch.BatchManager manager } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolListWithFilter.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolListWithFilter.json */ /** * Sample code: ListPoolWithFilter. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolStopResizeSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolStopResizeSamples.java index 6fc64b313441..96873425b78a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolStopResizeSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolStopResizeSamples.java @@ -9,7 +9,7 @@ /** Samples for Pool StopResize. */ public final class PoolStopResizeSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolStopResize.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolStopResize.json */ /** * Sample code: StopPoolResize. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolUpdateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolUpdateSamples.java index 12cc2f5ec5c8..6ce182d5b99a 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolUpdateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PoolUpdateSamples.java @@ -12,6 +12,7 @@ import com.azure.resourcemanager.batch.models.ComputeNodeDeallocationOption; import com.azure.resourcemanager.batch.models.FixedScaleSettings; import com.azure.resourcemanager.batch.models.MetadataItem; +import com.azure.resourcemanager.batch.models.NodeCommunicationMode; import com.azure.resourcemanager.batch.models.Pool; import com.azure.resourcemanager.batch.models.ScaleSettings; import com.azure.resourcemanager.batch.models.StartTask; @@ -21,7 +22,7 @@ /** Samples for Pool Update. */ public final class PoolUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_EnableAutoScale.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_EnableAutoScale.json */ /** * Sample code: UpdatePool - Enable Autoscale. @@ -42,7 +43,7 @@ public static void updatePoolEnableAutoscale(com.azure.resourcemanager.batch.Bat } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_RemoveStartTask.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_RemoveStartTask.json */ /** * Sample code: UpdatePool - Remove Start Task. @@ -59,7 +60,7 @@ public static void updatePoolRemoveStartTask(com.azure.resourcemanager.batch.Bat } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_ResizePool.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_ResizePool.json */ /** * Sample code: UpdatePool - Resize Pool. @@ -86,7 +87,7 @@ public static void updatePoolResizePool(com.azure.resourcemanager.batch.BatchMan } /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PoolUpdate_OtherProperties.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PoolUpdate_OtherProperties.json */ /** * Sample code: UpdatePool - Other Properties. @@ -120,6 +121,7 @@ public static void updatePoolOtherProperties(com.azure.resourcemanager.batch.Bat .withId( "/subscriptions/subid/resourceGroups/default-azurebatch-japaneast/providers/Microsoft.Batch/batchAccounts/sampleacct/pools/testpool/applications/app_5678") .withVersion("1.0"))) + .withTargetNodeCommunicationMode(NodeCommunicationMode.SIMPLIFIED) .apply(); } } diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionDeleteSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionDeleteSamples.java new file mode 100644 index 000000000000..18aeb604b3b6 --- /dev/null +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionDeleteSamples.java @@ -0,0 +1,28 @@ +// 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.generated; + +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnection Delete. */ +public final class PrivateEndpointConnectionDeleteSamples { + /* + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionDelete.json + */ + /** + * Sample code: PrivateEndpointConnectionDelete. + * + * @param manager Entry point to BatchManager. + */ + public static void privateEndpointConnectionDelete(com.azure.resourcemanager.batch.BatchManager manager) { + manager + .privateEndpointConnections() + .delete( + "default-azurebatch-japaneast", + "sampleacct", + "testprivateEndpointConnection5testprivateEndpointConnection5.24d6b4b5-e65c-4330-bbe9-3a290d62f8e0", + Context.NONE); + } +} diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionGetSamples.java index 7309d274fe36..0f8c6872d7db 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionGetSamples.java @@ -9,7 +9,7 @@ /** Samples for PrivateEndpointConnection Get. */ public final class PrivateEndpointConnectionGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionGet.json */ /** * Sample code: GetPrivateEndpointConnection. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionListByBatchAccountSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionListByBatchAccountSamples.java index 0ab753fbe07c..d7a2d4eaa003 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionListByBatchAccountSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionListByBatchAccountSamples.java @@ -9,7 +9,7 @@ /** Samples for PrivateEndpointConnection ListByBatchAccount. */ public final class PrivateEndpointConnectionListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionsList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionsList.json */ /** * Sample code: ListPrivateEndpointConnections. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionUpdateSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionUpdateSamples.java index b204d45bca37..521db1986934 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionUpdateSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateEndpointConnectionUpdateSamples.java @@ -12,7 +12,7 @@ /** Samples for PrivateEndpointConnection Update. */ public final class PrivateEndpointConnectionUpdateSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateEndpointConnectionUpdate.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateEndpointConnectionUpdate.json */ /** * Sample code: UpdatePrivateEndpointConnection. diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceGetSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceGetSamples.java index eaa58efd61a8..688d6f9c51c3 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceGetSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceGetSamples.java @@ -9,7 +9,7 @@ /** Samples for PrivateLinkResource Get. */ public final class PrivateLinkResourceGetSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateLinkResourceGet.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateLinkResourceGet.json */ /** * Sample code: GetPrivateLinkResource. @@ -19,6 +19,6 @@ public final class PrivateLinkResourceGetSamples { public static void getPrivateLinkResource(com.azure.resourcemanager.batch.BatchManager manager) { manager .privateLinkResources() - .getWithResponse("default-azurebatch-japaneast", "sampleacct", "sampleacct", Context.NONE); + .getWithResponse("default-azurebatch-japaneast", "sampleacct", "batchAccount", Context.NONE); } } diff --git a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceListByBatchAccountSamples.java b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceListByBatchAccountSamples.java index 422472166287..23c7fffc9d4f 100644 --- a/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceListByBatchAccountSamples.java +++ b/sdk/batch/azure-resourcemanager-batch/src/samples/java/com/azure/resourcemanager/batch/generated/PrivateLinkResourceListByBatchAccountSamples.java @@ -9,7 +9,7 @@ /** Samples for PrivateLinkResource ListByBatchAccount. */ public final class PrivateLinkResourceListByBatchAccountSamples { /* - * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-01-01/examples/PrivateLinkResourcesList.json + * x-ms-original-file: specification/batch/resource-manager/Microsoft.Batch/stable/2022-10-01/examples/PrivateLinkResourcesList.json */ /** * Sample code: ListPrivateLinkResource.