diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/CHANGELOG.md b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/CHANGELOG.md index 5edce1db5e9f..ab66451a85c4 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/CHANGELOG.md +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/CHANGELOG.md @@ -1,14 +1,63 @@ # Release History -## 2.1.0-beta.3 (Unreleased) +## 2.1.0-beta.3 (2025-04-29) -### Features Added +- Azure Resource Manager RedisEnterprise client library for Java. This package contains Microsoft Azure SDK for RedisEnterprise Management SDK. REST API for managing Redis Enterprise resources in Azure. Package tag package-preview-2025-05-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ### Breaking Changes -### Bugs Fixed +#### `models.ForceLinkParameters` was modified + +* `withGroupNickname(java.lang.String)` was removed +* `groupNickname()` was removed +* `linkedDatabases()` was removed +* `withLinkedDatabases(java.util.List)` was removed + +#### `models.Database` was modified + +* `flush(models.FlushParameters)` was removed + +#### `models.Databases` was modified + +* `flush(java.lang.String,java.lang.String,java.lang.String,models.FlushParameters)` was removed + +### Features Added + +* `models.Kind` was added + +* `models.ForceLinkParametersGeoReplication` was added + +* `models.SkuDetailsList` was added + +* `models.SkuDetails` was added + +#### `models.RedisEnterprises` was modified + +* `listSkusForScalingWithResponse(java.lang.String,java.lang.String,com.azure.core.util.Context)` was added +* `listSkusForScaling(java.lang.String,java.lang.String)` was added + +#### `models.Database$Update` was modified + +* `withClusteringPolicy(models.ClusteringPolicy)` was added + +#### `models.ForceLinkParameters` was modified + +* `geoReplication()` was added +* `withGeoReplication(models.ForceLinkParametersGeoReplication)` was added + +#### `models.Database` was modified + +* `flush()` was added + +#### `models.Cluster` was modified + +* `listSkusForScalingWithResponse(com.azure.core.util.Context)` was added +* `listSkusForScaling()` was added +* `kind()` was added + +#### `models.Databases` was modified -### Other Changes +* `flush(java.lang.String,java.lang.String,java.lang.String)` was added ## 2.1.0-beta.2 (2024-10-21) diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/README.md b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/README.md index e3caadc151f6..71ec58210f79 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/README.md +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/README.md @@ -2,7 +2,7 @@ Azure Resource Manager RedisEnterprise client library for Java. -This package contains Microsoft Azure SDK for RedisEnterprise Management SDK. REST API for managing Redis Enterprise resources in Azure. Package tag package-preview-2024-09. 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 RedisEnterprise Management SDK. REST API for managing Redis Enterprise resources in Azure. Package tag package-preview-2025-05-01. 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 @@ -52,7 +52,7 @@ Azure subscription ID can be configured via `AZURE_SUBSCRIPTION_ID` environment Assuming the use of the `DefaultAzureCredential` credential class, the client can be authenticated using the following code: ```java -AzureProfile profile = new AzureProfile(AzureEnvironment.AZURE); +AzureProfile profile = new AzureProfile(AzureCloud.AZURE_PUBLIC_CLOUD); TokenCredential credential = new DefaultAzureCredentialBuilder() .authorityHost(profile.getEnvironment().getActiveDirectoryEndpoint()) .build(); @@ -60,7 +60,7 @@ RedisEnterpriseManager manager = RedisEnterpriseManager .authenticate(credential, profile); ``` -The sample code assumes global Azure. Please change `AzureEnvironment.AZURE` variable if otherwise. +The sample code assumes global Azure. Please change the `AzureCloud.AZURE_PUBLIC_CLOUD` variable if otherwise. See [Authentication][authenticate] for more options. @@ -110,5 +110,3 @@ This project has adopted the [Microsoft Open Source Code of Conduct][coc]. For m [cg]: https://github.com/Azure/azure-sdk-for-java/blob/main/CONTRIBUTING.md [coc]: https://opensource.microsoft.com/codeofconduct/ [coc_faq]: https://opensource.microsoft.com/codeofconduct/faq/ - - diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/SAMPLE.md b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/SAMPLE.md index f9fc31516c08..879efde52823 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/SAMPLE.md +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/SAMPLE.md @@ -50,34 +50,28 @@ - [GetByResourceGroup](#redisenterprise_getbyresourcegroup) - [List](#redisenterprise_list) - [ListByResourceGroup](#redisenterprise_listbyresourcegroup) +- [ListSkusForScaling](#redisenterprise_listskusforscaling) - [Update](#redisenterprise_update) ### AccessPolicyAssignment_CreateUpdate ```java -import com.azure.resourcemanager.redisenterprise.models.AccessPolicyAssignmentPropertiesUser; - /** - * Samples for AccessPolicyAssignment CreateUpdate. + * Samples for PrivateLinkResources ListByCluster. */ -public final class AccessPolicyAssignmentCreateUpdateSamples { +public final class PrivateLinkResourcesListByClusterSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseAccessPolicyAssignmentCreateUpdate.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseListPrivateLinkResources.json */ /** - * Sample code: RedisEnterpriseAccessPolicyAssignmentCreateUpdate. + * Sample code: RedisEnterpriseListPrivateLinkResources. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseAccessPolicyAssignmentCreateUpdate( + public static void redisEnterpriseListPrivateLinkResources( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.accessPolicyAssignments() - .define("defaultTestEntraApp1") - .withExistingDatabase("rg1", "cache1", "default") - .withAccessPolicyName("default") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("6497c918-11ad-41e7-1b0f-7c518a87d0b0")) - .create(); + manager.privateLinkResources().listByCluster("rg1", "cache1", com.azure.core.util.Context.NONE); } } ``` @@ -86,23 +80,22 @@ public final class AccessPolicyAssignmentCreateUpdateSamples { ```java /** - * Samples for AccessPolicyAssignment Delete. + * Samples for Databases Delete. */ -public final class AccessPolicyAssignmentDeleteSamples { +public final class DatabasesDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseAccessPolicyAssignmentDelete.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesDelete.json */ /** - * Sample code: RedisEnterpriseAccessPolicyAssignmentDelete. + * Sample code: RedisEnterpriseDatabasesDelete. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseAccessPolicyAssignmentDelete( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.accessPolicyAssignments() - .delete("rg1", "cache1", "default", "defaultTestEntraApp1", com.azure.core.util.Context.NONE); + public static void + redisEnterpriseDatabasesDelete(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases().delete("rg1", "cache1", "db1", com.azure.core.util.Context.NONE); } } ``` @@ -111,24 +104,21 @@ public final class AccessPolicyAssignmentDeleteSamples { ```java /** - * Samples for AccessPolicyAssignment Get. + * Samples for RedisEnterprise List. */ -public final class AccessPolicyAssignmentGetSamples { +public final class RedisEnterpriseListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseAccessPolicyAssignmentGet.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseList.json */ /** - * Sample code: RedisEnterpriseAccessPolicyAssignmentGet. + * Sample code: RedisEnterpriseList. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseAccessPolicyAssignmentGet( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.accessPolicyAssignments() - .getWithResponse("rg1", "cache1", "default", "accessPolicyAssignmentName1", - com.azure.core.util.Context.NONE); + public static void redisEnterpriseList(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises().list(com.azure.core.util.Context.NONE); } } ``` @@ -136,23 +126,28 @@ public final class AccessPolicyAssignmentGetSamples { ### AccessPolicyAssignment_List ```java +import com.azure.resourcemanager.redisenterprise.models.AccessKeyType; +import com.azure.resourcemanager.redisenterprise.models.RegenerateKeyParameters; + /** - * Samples for AccessPolicyAssignment List. + * Samples for Databases RegenerateKey. */ -public final class AccessPolicyAssignmentListSamples { +public final class DatabasesRegenerateKeySamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseAccessPolicyAssignmentsList.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesRegenerateKey.json */ /** - * Sample code: RedisEnterpriseAccessPolicyAssignmentList. + * Sample code: RedisEnterpriseDatabasesRegenerateKey. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseAccessPolicyAssignmentList( + public static void redisEnterpriseDatabasesRegenerateKey( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.accessPolicyAssignments().list("rg1", "cache1", "default", com.azure.core.util.Context.NONE); + manager.databases() + .regenerateKey("rg1", "cache1", "default", new RegenerateKeyParameters().withKeyType(AccessKeyType.PRIMARY), + com.azure.core.util.Context.NONE); } } ``` @@ -160,76 +155,67 @@ public final class AccessPolicyAssignmentListSamples { ### Databases_Create ```java -import com.azure.resourcemanager.redisenterprise.models.AccessKeysAuthentication; -import com.azure.resourcemanager.redisenterprise.models.AofFrequency; -import com.azure.resourcemanager.redisenterprise.models.ClusteringPolicy; -import com.azure.resourcemanager.redisenterprise.models.DatabasePropertiesGeoReplication; -import com.azure.resourcemanager.redisenterprise.models.DeferUpgradeSetting; -import com.azure.resourcemanager.redisenterprise.models.EvictionPolicy; -import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; -import com.azure.resourcemanager.redisenterprise.models.Module; -import com.azure.resourcemanager.redisenterprise.models.Persistence; -import com.azure.resourcemanager.redisenterprise.models.Protocol; +import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryption; +import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryptionCustomerManagedKeyEncryption; +import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity; +import com.azure.resourcemanager.redisenterprise.models.CmkIdentityType; +import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentity; +import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentityType; +import com.azure.resourcemanager.redisenterprise.models.Sku; +import com.azure.resourcemanager.redisenterprise.models.SkuName; +import com.azure.resourcemanager.redisenterprise.models.TlsVersion; +import com.azure.resourcemanager.redisenterprise.models.UserAssignedIdentity; import java.util.Arrays; +import java.util.HashMap; +import java.util.Map; /** - * Samples for Databases Create. + * Samples for RedisEnterprise Create. */ -public final class DatabasesCreateSamples { +public final class RedisEnterpriseCreateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesCreate.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseCreate.json */ /** - * Sample code: RedisEnterpriseDatabasesCreate. + * Sample code: RedisEnterpriseCreate. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void - redisEnterpriseDatabasesCreate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .define("default") - .withExistingRedisEnterprise("rg1", "cache1") - .withClientProtocol(Protocol.ENCRYPTED) - .withPort(10000) - .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) - .withEvictionPolicy(EvictionPolicy.ALL_KEYS_LRU) - .withPersistence(new Persistence().withAofEnabled(true).withAofFrequency(AofFrequency.ONES)) - .withModules(Arrays.asList(new Module().withName("RedisBloom").withArgs("ERROR_RATE 0.00 INITIAL_SIZE 400"), - new Module().withName("RedisTimeSeries").withArgs("RETENTION_POLICY 20"), - new Module().withName("RediSearch"))) - .withDeferUpgrade(DeferUpgradeSetting.NOT_DEFERRED) - .withAccessKeysAuthentication(AccessKeysAuthentication.ENABLED) + public static void redisEnterpriseCreate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises() + .define("cache1") + .withRegion("West US") + .withExistingResourceGroup("rg1") + .withSku(new Sku().withName(SkuName.ENTERPRISE_FLASH_F300).withCapacity(3)) + .withTags(mapOf("tag1", "value1")) + .withZones(Arrays.asList("1", "2", "3")) + .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED) + .withUserAssignedIdentities(mapOf( + "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity", + new UserAssignedIdentity()))) + .withMinimumTlsVersion(TlsVersion.ONE_TWO) + .withEncryption(new ClusterPropertiesEncryption().withCustomerManagedKeyEncryption( + new ClusterPropertiesEncryptionCustomerManagedKeyEncryption().withKeyEncryptionKeyIdentity( + new ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity() + .withUserAssignedIdentityResourceId( + "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity") + .withIdentityType(CmkIdentityType.USER_ASSIGNED_IDENTITY)) + .withKeyEncryptionKeyUrl("fakeTokenPlaceholder"))) .create(); } - /* - * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesCreateWithGeoReplication.json - */ - /** - * Sample code: RedisEnterpriseDatabasesCreate With Active Geo Replication. - * - * @param manager Entry point to RedisEnterpriseManager. - */ - public static void redisEnterpriseDatabasesCreateWithActiveGeoReplication( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .define("default") - .withExistingRedisEnterprise("rg1", "cache1") - .withClientProtocol(Protocol.ENCRYPTED) - .withPort(10000) - .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) - .withEvictionPolicy(EvictionPolicy.NO_EVICTION) - .withGeoReplication(new DatabasePropertiesGeoReplication().withGroupNickname("groupName") - .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( - "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), - new LinkedDatabase().withId( - "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8e/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")))) - .withAccessKeysAuthentication(AccessKeysAuthentication.ENABLED) - .create(); + // Use "Map.of" if available + @SuppressWarnings("unchecked") + private static Map mapOf(Object... inputs) { + Map map = new HashMap<>(); + for (int i = 0; i < inputs.length; i += 2) { + String key = (String) inputs[i]; + T value = (T) inputs[i + 1]; + map.put(key, value); + } + return map; } } ``` @@ -238,22 +224,22 @@ public final class DatabasesCreateSamples { ```java /** - * Samples for Databases Delete. + * Samples for RedisEnterprise ListSkusForScaling. */ -public final class DatabasesDeleteSamples { +public final class RedisEnterpriseListSkusForScalingSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesDelete.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseListSkusForScaling.json */ /** - * Sample code: RedisEnterpriseDatabasesDelete. + * Sample code: RedisEnterpriseListSkusForScaling. * * @param manager Entry point to RedisEnterpriseManager. */ public static void - redisEnterpriseDatabasesDelete(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases().delete("rg1", "cache1", "db1", com.azure.core.util.Context.NONE); + redisEnterpriseListSkusForScaling(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises().listSkusForScalingWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE); } } ``` @@ -261,28 +247,30 @@ public final class DatabasesDeleteSamples { ### Databases_Export ```java -import com.azure.resourcemanager.redisenterprise.models.ExportClusterParameters; +import com.azure.resourcemanager.redisenterprise.models.ImportClusterParameters; +import java.util.Arrays; /** - * Samples for Databases Export. + * Samples for Databases ImportMethod. */ -public final class DatabasesExportSamples { +public final class DatabasesImportMethodSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesExport.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesImport.json */ /** - * Sample code: RedisEnterpriseDatabasesExport. + * Sample code: RedisEnterpriseDatabasesImport. * * @param manager Entry point to RedisEnterpriseManager. */ public static void - redisEnterpriseDatabasesExport(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + redisEnterpriseDatabasesImport(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { manager.databases() - .export("rg1", "cache1", "default", - new ExportClusterParameters() - .withSasUri("https://contosostorage.blob.core.window.net/urlToBlobContainer?sasKeyParameters"), + .importMethod("rg1", "cache1", "default", + new ImportClusterParameters().withSasUris( + Arrays.asList("https://contosostorage.blob.core.window.net/urltoBlobFile1?sasKeyParameters", + "https://contosostorage.blob.core.window.net/urltoBlobFile2?sasKeyParameters")), com.azure.core.util.Context.NONE); } } @@ -291,29 +279,23 @@ public final class DatabasesExportSamples { ### Databases_Flush ```java -import com.azure.resourcemanager.redisenterprise.models.FlushParameters; -import java.util.Arrays; - /** - * Samples for Databases Flush. + * Samples for Databases ListKeys. */ -public final class DatabasesFlushSamples { +public final class DatabasesListKeysSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesFlush.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesListKeys.json */ /** - * Sample code: How to flush all the keys in the database. + * Sample code: RedisEnterpriseDatabasesListKeys. * * @param manager Entry point to RedisEnterpriseManager. */ public static void - howToFlushAllTheKeysInTheDatabase(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .flush("rg1", "cache1", "default", new FlushParameters().withIds(Arrays.asList( - "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")), - com.azure.core.util.Context.NONE); + redisEnterpriseDatabasesListKeys(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases().listKeysWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE); } } ``` @@ -321,34 +303,22 @@ public final class DatabasesFlushSamples { ### Databases_ForceLinkToReplicationGroup ```java -import com.azure.resourcemanager.redisenterprise.models.ForceLinkParameters; -import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; -import java.util.Arrays; - /** - * Samples for Databases ForceLinkToReplicationGroup. + * Samples for Operations List. */ -public final class DatabasesForceLinkToReplicationGroupSamples { +public final class OperationsListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesForceLink.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/OperationsList + * .json */ /** - * Sample code: How to relink a database after a regional outage. + * Sample code: OperationsList. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void howToRelinkADatabaseAfterARegionalOutage( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .forceLinkToReplicationGroup("rg1", "cache1", "default", new ForceLinkParameters() - .withGroupNickname("groupName") - .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), - new LinkedDatabase().withId( - "/subscriptions/11111111-1111-1111-1111-111111111111/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default"))), - com.azure.core.util.Context.NONE); + public static void operationsList(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.operations().list(com.azure.core.util.Context.NONE); } } ``` @@ -356,29 +326,24 @@ public final class DatabasesForceLinkToReplicationGroupSamples { ### Databases_ForceUnlink ```java -import com.azure.resourcemanager.redisenterprise.models.ForceUnlinkParameters; -import java.util.Arrays; - /** - * Samples for Databases ForceUnlink. + * Samples for AccessPolicyAssignment Delete. */ -public final class DatabasesForceUnlinkSamples { +public final class AccessPolicyAssignmentDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesForceUnlink.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseAccessPolicyAssignmentDelete.json */ /** - * Sample code: How to unlink a database during a regional outage. + * Sample code: RedisEnterpriseAccessPolicyAssignmentDelete. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void howToUnlinkADatabaseDuringARegionalOutage( + public static void redisEnterpriseAccessPolicyAssignmentDelete( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .forceUnlink("rg1", "cache1", "default", new ForceUnlinkParameters().withIds(Arrays.asList( - "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")), - com.azure.core.util.Context.NONE); + manager.accessPolicyAssignments() + .delete("rg1", "cache1", "default", "defaultTestEntraApp1", com.azure.core.util.Context.NONE); } } ``` @@ -387,22 +352,22 @@ public final class DatabasesForceUnlinkSamples { ```java /** - * Samples for Databases Get. + * Samples for Databases ListByCluster. */ -public final class DatabasesGetSamples { +public final class DatabasesListByClusterSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesGet.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesListByCluster.json */ /** - * Sample code: RedisEnterpriseDatabasesGet. + * Sample code: RedisEnterpriseDatabasesListByCluster. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void - redisEnterpriseDatabasesGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases().getWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE); + public static void redisEnterpriseDatabasesListByCluster( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases().listByCluster("rg1", "cache1", com.azure.core.util.Context.NONE); } } ``` @@ -410,30 +375,28 @@ public final class DatabasesGetSamples { ### Databases_ImportMethod ```java -import com.azure.resourcemanager.redisenterprise.models.ImportClusterParameters; +import com.azure.resourcemanager.redisenterprise.models.ForceUnlinkParameters; import java.util.Arrays; /** - * Samples for Databases ImportMethod. + * Samples for Databases ForceUnlink. */ -public final class DatabasesImportMethodSamples { +public final class DatabasesForceUnlinkSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesImport.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesForceUnlink.json */ /** - * Sample code: RedisEnterpriseDatabasesImport. + * Sample code: How to unlink a database during a regional outage. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void - redisEnterpriseDatabasesImport(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + public static void howToUnlinkADatabaseDuringARegionalOutage( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { manager.databases() - .importMethod("rg1", "cache1", "default", - new ImportClusterParameters().withSasUris( - Arrays.asList("https://contosostorage.blob.core.window.net/urltoBlobFile1?sasKeyParameters", - "https://contosostorage.blob.core.window.net/urltoBlobFile2?sasKeyParameters")), + .forceUnlink("rg1", "cache1", "default", new ForceUnlinkParameters().withIds(Arrays.asList( + "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")), com.azure.core.util.Context.NONE); } } @@ -443,22 +406,22 @@ public final class DatabasesImportMethodSamples { ```java /** - * Samples for Databases ListByCluster. + * Samples for PrivateEndpointConnections Delete. */ -public final class DatabasesListByClusterSamples { +public final class PrivateEndpointConnectionsDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesListByCluster.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDeletePrivateEndpointConnection.json */ /** - * Sample code: RedisEnterpriseDatabasesListByCluster. + * Sample code: RedisEnterpriseDeletePrivateEndpointConnection. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseDatabasesListByCluster( + public static void redisEnterpriseDeletePrivateEndpointConnection( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases().listByCluster("rg1", "cache1", com.azure.core.util.Context.NONE); + manager.privateEndpointConnections().delete("rg1", "cache1", "pectest01", com.azure.core.util.Context.NONE); } } ``` @@ -467,22 +430,22 @@ public final class DatabasesListByClusterSamples { ```java /** - * Samples for Databases ListKeys. + * Samples for Databases UpgradeDBRedisVersion. */ -public final class DatabasesListKeysSamples { +public final class DatabasesUpgradeDBRedisVersionSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesListKeys.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesUpgradeDBRedisVersion.json */ /** - * Sample code: RedisEnterpriseDatabasesListKeys. + * Sample code: How to upgrade your database Redis version. * * @param manager Entry point to RedisEnterpriseManager. */ public static void - redisEnterpriseDatabasesListKeys(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases().listKeysWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE); + howToUpgradeYourDatabaseRedisVersion(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases().upgradeDBRedisVersion("rg1", "cache1", "default", com.azure.core.util.Context.NONE); } } ``` @@ -490,28 +453,23 @@ public final class DatabasesListKeysSamples { ### Databases_RegenerateKey ```java -import com.azure.resourcemanager.redisenterprise.models.AccessKeyType; -import com.azure.resourcemanager.redisenterprise.models.RegenerateKeyParameters; - /** - * Samples for Databases RegenerateKey. + * Samples for PrivateEndpointConnections List. */ -public final class DatabasesRegenerateKeySamples { +public final class PrivateEndpointConnectionsListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesRegenerateKey.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseListPrivateEndpointConnections.json */ /** - * Sample code: RedisEnterpriseDatabasesRegenerateKey. + * Sample code: RedisEnterpriseListPrivateEndpointConnections. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseDatabasesRegenerateKey( + public static void redisEnterpriseListPrivateEndpointConnections( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases() - .regenerateKey("rg1", "cache1", "default", new RegenerateKeyParameters().withKeyType(AccessKeyType.PRIMARY), - com.azure.core.util.Context.NONE); + manager.privateEndpointConnections().list("rg1", "cache1", com.azure.core.util.Context.NONE); } } ``` @@ -520,6 +478,7 @@ public final class DatabasesRegenerateKeySamples { ```java import com.azure.resourcemanager.redisenterprise.models.AccessKeysAuthentication; +import com.azure.resourcemanager.redisenterprise.models.ClusteringPolicy; import com.azure.resourcemanager.redisenterprise.models.Database; import com.azure.resourcemanager.redisenterprise.models.EvictionPolicy; import com.azure.resourcemanager.redisenterprise.models.Persistence; @@ -532,7 +491,29 @@ import com.azure.resourcemanager.redisenterprise.models.RdbFrequency; public final class DatabasesUpdateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesNoClusterCacheUpdateClustering.json + */ + /** + * Sample code: RedisEnterpriseDatabasesUpdate Clustering on No Cluster Cache. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void redisEnterpriseDatabasesUpdateClusteringOnNoClusterCache( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + Database resource = manager.databases() + .getWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE) + .getValue(); + resource.update() + .withClientProtocol(Protocol.ENCRYPTED) + .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) + .withEvictionPolicy(EvictionPolicy.NO_EVICTION) + .apply(); + } + + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesUpdate.json */ /** @@ -559,22 +540,22 @@ public final class DatabasesUpdateSamples { ```java /** - * Samples for Databases UpgradeDBRedisVersion. + * Samples for Databases Get. */ -public final class DatabasesUpgradeDBRedisVersionSamples { +public final class DatabasesGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDatabasesUpgradeDBRedisVersion.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesGet.json */ /** - * Sample code: How to upgrade your database Redis version. + * Sample code: RedisEnterpriseDatabasesGet. * * @param manager Entry point to RedisEnterpriseManager. */ public static void - howToUpgradeYourDatabaseRedisVersion(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.databases().upgradeDBRedisVersion("rg1", "cache1", "default", com.azure.core.util.Context.NONE); + redisEnterpriseDatabasesGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases().getWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE); } } ``` @@ -582,22 +563,29 @@ public final class DatabasesUpgradeDBRedisVersionSamples { ### Operations_List ```java +import com.azure.resourcemanager.redisenterprise.models.FlushParameters; +import java.util.Arrays; + /** - * Samples for Operations List. + * Samples for Databases Flush. */ -public final class OperationsListSamples { +public final class DatabasesFlushSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/OperationsList - * .json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesFlush.json */ /** - * Sample code: OperationsList. + * Sample code: How to flush all the keys in the database. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void operationsList(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.operations().list(com.azure.core.util.Context.NONE); + public static void + howToFlushAllTheKeysInTheDatabase(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .flush("rg1", "cache1", "default", new FlushParameters().withIds(Arrays.asList( + "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f2/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")), + com.azure.core.util.Context.NONE); } } ``` @@ -606,99 +594,254 @@ public final class OperationsListSamples { ```java /** - * Samples for OperationsStatus Get. + * Samples for RedisEnterprise ListByResourceGroup. */ -public final class OperationsStatusGetSamples { +public final class RedisEnterpriseListByResourceGroupSamples { + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseListByResourceGroup.json + */ + /** + * Sample code: RedisEnterpriseListByResourceGroup. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void + redisEnterpriseListByResourceGroup(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises().listByResourceGroup("rg1", com.azure.core.util.Context.NONE); + } +} +``` + +### PrivateEndpointConnections_Delete + +```java +import com.azure.resourcemanager.redisenterprise.models.Cluster; +import com.azure.resourcemanager.redisenterprise.models.Sku; +import com.azure.resourcemanager.redisenterprise.models.SkuName; +import com.azure.resourcemanager.redisenterprise.models.TlsVersion; +import java.util.HashMap; +import java.util.Map; + +/** + * Samples for RedisEnterprise Update. + */ +public final class RedisEnterpriseUpdateSamples { + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseUpdate.json + */ + /** + * Sample code: RedisEnterpriseUpdate. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void redisEnterpriseUpdate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + Cluster resource = manager.redisEnterprises() + .getByResourceGroupWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE) + .getValue(); + resource.update() + .withTags(mapOf("tag1", "value1")) + .withSku(new Sku().withName(SkuName.ENTERPRISE_FLASH_F300).withCapacity(9)) + .withMinimumTlsVersion(TlsVersion.ONE_TWO) + .apply(); + } + + // Use "Map.of" if available + @SuppressWarnings("unchecked") + private static Map mapOf(Object... inputs) { + Map map = new HashMap<>(); + for (int i = 0; i < inputs.length; i += 2) { + String key = (String) inputs[i]; + T value = (T) inputs[i + 1]; + map.put(key, value); + } + return map; + } +} +``` + +### PrivateEndpointConnections_Get + +```java +import com.azure.resourcemanager.redisenterprise.models.AccessKeysAuthentication; +import com.azure.resourcemanager.redisenterprise.models.AofFrequency; +import com.azure.resourcemanager.redisenterprise.models.ClusteringPolicy; +import com.azure.resourcemanager.redisenterprise.models.DatabasePropertiesGeoReplication; +import com.azure.resourcemanager.redisenterprise.models.DeferUpgradeSetting; +import com.azure.resourcemanager.redisenterprise.models.EvictionPolicy; +import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; +import com.azure.resourcemanager.redisenterprise.models.Module; +import com.azure.resourcemanager.redisenterprise.models.Persistence; +import com.azure.resourcemanager.redisenterprise.models.Protocol; +import java.util.Arrays; + +/** + * Samples for Databases Create. + */ +public final class DatabasesCreateSamples { + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesNoClusterCacheCreate.json + */ + /** + * Sample code: RedisEnterpriseDatabasesCreate No Cluster Cache. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void redisEnterpriseDatabasesCreateNoClusterCache( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .define("default") + .withExistingRedisEnterprise("rg1", "cache1") + .withClientProtocol(Protocol.ENCRYPTED) + .withPort(10000) + .withClusteringPolicy(ClusteringPolicy.NO_CLUSTER) + .withEvictionPolicy(EvictionPolicy.NO_EVICTION) + .create(); + } + + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesCreate.json + */ + /** + * Sample code: RedisEnterpriseDatabasesCreate. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void + redisEnterpriseDatabasesCreate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .define("default") + .withExistingRedisEnterprise("rg1", "cache1") + .withClientProtocol(Protocol.ENCRYPTED) + .withPort(10000) + .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) + .withEvictionPolicy(EvictionPolicy.ALL_KEYS_LRU) + .withPersistence(new Persistence().withAofEnabled(true).withAofFrequency(AofFrequency.ONES)) + .withModules(Arrays.asList(new Module().withName("RedisBloom").withArgs("ERROR_RATE 0.00 INITIAL_SIZE 400"), + new Module().withName("RedisTimeSeries").withArgs("RETENTION_POLICY 20"), + new Module().withName("RediSearch"))) + .withDeferUpgrade(DeferUpgradeSetting.NOT_DEFERRED) + .withAccessKeysAuthentication(AccessKeysAuthentication.ENABLED) + .create(); + } + /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * OperationsStatusGet.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesCreateWithGeoReplication.json */ /** - * Sample code: OperationsStatusGet. + * Sample code: RedisEnterpriseDatabasesCreate With Active Geo Replication. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void operationsStatusGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.operationsStatus().getWithResponse("West US", "testoperationid", com.azure.core.util.Context.NONE); + public static void redisEnterpriseDatabasesCreateWithActiveGeoReplication( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .define("default") + .withExistingRedisEnterprise("rg1", "cache1") + .withClientProtocol(Protocol.ENCRYPTED) + .withPort(10000) + .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) + .withEvictionPolicy(EvictionPolicy.NO_EVICTION) + .withGeoReplication(new DatabasePropertiesGeoReplication().withGroupNickname("groupName") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( + "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8f/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), + new LinkedDatabase().withId( + "/subscriptions/e7b5a9d2-6b6a-4d2f-9143-20d9a10f5b8e/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")))) + .withAccessKeysAuthentication(AccessKeysAuthentication.ENABLED) + .create(); } } ``` -### PrivateEndpointConnections_Delete +### PrivateEndpointConnections_List ```java /** - * Samples for PrivateEndpointConnections Delete. + * Samples for RedisEnterprise GetByResourceGroup. */ -public final class PrivateEndpointConnectionsDeleteSamples { +public final class RedisEnterpriseGetByResourceGroupSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseDeletePrivateEndpointConnection.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseGet.json */ /** - * Sample code: RedisEnterpriseDeletePrivateEndpointConnection. + * Sample code: RedisEnterpriseGet. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseDeletePrivateEndpointConnection( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.privateEndpointConnections().delete("rg1", "cache1", "pectest01", com.azure.core.util.Context.NONE); + public static void redisEnterpriseGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises().getByResourceGroupWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE); } } ``` -### PrivateEndpointConnections_Get +### PrivateEndpointConnections_Put ```java /** - * Samples for PrivateEndpointConnections Get. + * Samples for AccessPolicyAssignment Get. */ -public final class PrivateEndpointConnectionsGetSamples { +public final class AccessPolicyAssignmentGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseGetPrivateEndpointConnection.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseAccessPolicyAssignmentGet.json */ /** - * Sample code: RedisEnterpriseGetPrivateEndpointConnection. + * Sample code: RedisEnterpriseAccessPolicyAssignmentGet. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseGetPrivateEndpointConnection( + public static void redisEnterpriseAccessPolicyAssignmentGet( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.privateEndpointConnections() - .getWithResponse("rg1", "cache1", "pectest01", com.azure.core.util.Context.NONE); + manager.accessPolicyAssignments() + .getWithResponse("rg1", "cache1", "default", "accessPolicyAssignmentName1", + com.azure.core.util.Context.NONE); } } ``` -### PrivateEndpointConnections_List +### PrivateLinkResources_ListByCluster ```java +import com.azure.resourcemanager.redisenterprise.models.ExportClusterParameters; + /** - * Samples for PrivateEndpointConnections List. + * Samples for Databases Export. */ -public final class PrivateEndpointConnectionsListSamples { +public final class DatabasesExportSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseListPrivateEndpointConnections.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesExport.json */ /** - * Sample code: RedisEnterpriseListPrivateEndpointConnections. + * Sample code: RedisEnterpriseDatabasesExport. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseListPrivateEndpointConnections( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.privateEndpointConnections().list("rg1", "cache1", com.azure.core.util.Context.NONE); + public static void + redisEnterpriseDatabasesExport(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .export("rg1", "cache1", "default", + new ExportClusterParameters() + .withSasUri("https://contosostorage.blob.core.window.net/urlToBlobContainer?sasKeyParameters"), + com.azure.core.util.Context.NONE); } } ``` -### PrivateEndpointConnections_Put +### RedisEnterprise_Create ```java import com.azure.resourcemanager.redisenterprise.models.PrivateEndpointServiceConnectionStatus; @@ -710,7 +853,7 @@ import com.azure.resourcemanager.redisenterprise.models.PrivateLinkServiceConnec public final class PrivateEndpointConnectionsPutSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterprisePutPrivateEndpointConnection.json */ /** @@ -731,99 +874,44 @@ public final class PrivateEndpointConnectionsPutSamples { } ``` -### PrivateLinkResources_ListByCluster - -```java -/** - * Samples for PrivateLinkResources ListByCluster. - */ -public final class PrivateLinkResourcesListByClusterSamples { - /* - * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseListPrivateLinkResources.json - */ - /** - * Sample code: RedisEnterpriseListPrivateLinkResources. - * - * @param manager Entry point to RedisEnterpriseManager. - */ - public static void redisEnterpriseListPrivateLinkResources( - com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.privateLinkResources().listByCluster("rg1", "cache1", com.azure.core.util.Context.NONE); - } -} -``` - -### RedisEnterprise_Create +### RedisEnterprise_Delete ```java -import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryption; -import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryptionCustomerManagedKeyEncryption; -import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity; -import com.azure.resourcemanager.redisenterprise.models.CmkIdentityType; -import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentity; -import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentityType; -import com.azure.resourcemanager.redisenterprise.models.Sku; -import com.azure.resourcemanager.redisenterprise.models.SkuName; -import com.azure.resourcemanager.redisenterprise.models.TlsVersion; -import com.azure.resourcemanager.redisenterprise.models.UserAssignedIdentity; +import com.azure.resourcemanager.redisenterprise.models.ForceLinkParameters; +import com.azure.resourcemanager.redisenterprise.models.ForceLinkParametersGeoReplication; +import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; import java.util.Arrays; -import java.util.HashMap; -import java.util.Map; /** - * Samples for RedisEnterprise Create. + * Samples for Databases ForceLinkToReplicationGroup. */ -public final class RedisEnterpriseCreateSamples { +public final class DatabasesForceLinkToReplicationGroupSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseCreate.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesForceLink.json */ /** - * Sample code: RedisEnterpriseCreate. + * Sample code: How to relink a database after a regional outage. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseCreate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.redisEnterprises() - .define("cache1") - .withRegion("West US") - .withExistingResourceGroup("rg1") - .withSku(new Sku().withName(SkuName.ENTERPRISE_FLASH_F300).withCapacity(3)) - .withTags(mapOf("tag1", "value1")) - .withZones(Arrays.asList("1", "2", "3")) - .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED) - .withUserAssignedIdentities(mapOf( - "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity", - new UserAssignedIdentity()))) - .withMinimumTlsVersion(TlsVersion.ONE_TWO) - .withEncryption(new ClusterPropertiesEncryption().withCustomerManagedKeyEncryption( - new ClusterPropertiesEncryptionCustomerManagedKeyEncryption().withKeyEncryptionKeyIdentity( - new ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity() - .withUserAssignedIdentityResourceId( - "/subscriptions/your-subscription/resourceGroups/your-rg/providers/Microsoft.ManagedIdentity/userAssignedIdentities/your-identity") - .withIdentityType(CmkIdentityType.USER_ASSIGNED_IDENTITY)) - .withKeyEncryptionKeyUrl("fakeTokenPlaceholder"))) - .create(); - } - - // Use "Map.of" if available - @SuppressWarnings("unchecked") - private static Map mapOf(Object... inputs) { - Map map = new HashMap<>(); - for (int i = 0; i < inputs.length; i += 2) { - String key = (String) inputs[i]; - T value = (T) inputs[i + 1]; - map.put(key, value); - } - return map; + public static void howToRelinkADatabaseAfterARegionalOutage( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .forceLinkToReplicationGroup("rg1", "cache1", "default", + new ForceLinkParameters().withGeoReplication(new ForceLinkParametersGeoReplication() + .withGroupNickname("groupName") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), + new LinkedDatabase().withId( + "/subscriptions/11111111-1111-1111-1111-111111111111/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")))), + com.azure.core.util.Context.NONE); } } ``` -### RedisEnterprise_Delete +### RedisEnterprise_GetByResourceGroup ```java /** @@ -832,7 +920,7 @@ public final class RedisEnterpriseCreateSamples { public final class RedisEnterpriseDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDelete.json */ /** @@ -846,72 +934,74 @@ public final class RedisEnterpriseDeleteSamples { } ``` -### RedisEnterprise_GetByResourceGroup +### RedisEnterprise_List ```java /** - * Samples for RedisEnterprise GetByResourceGroup. + * Samples for PrivateEndpointConnections Get. */ -public final class RedisEnterpriseGetByResourceGroupSamples { +public final class PrivateEndpointConnectionsGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseGet.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseGetPrivateEndpointConnection.json */ /** - * Sample code: RedisEnterpriseGet. + * Sample code: RedisEnterpriseGetPrivateEndpointConnection. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.redisEnterprises().getByResourceGroupWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE); + public static void redisEnterpriseGetPrivateEndpointConnection( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.privateEndpointConnections() + .getWithResponse("rg1", "cache1", "pectest01", com.azure.core.util.Context.NONE); } } ``` -### RedisEnterprise_List +### RedisEnterprise_ListByResourceGroup ```java /** - * Samples for RedisEnterprise List. + * Samples for AccessPolicyAssignment List. */ -public final class RedisEnterpriseListSamples { +public final class AccessPolicyAssignmentListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseList.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseAccessPolicyAssignmentsList.json */ /** - * Sample code: RedisEnterpriseList. + * Sample code: RedisEnterpriseAccessPolicyAssignmentList. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseList(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.redisEnterprises().list(com.azure.core.util.Context.NONE); + public static void redisEnterpriseAccessPolicyAssignmentList( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.accessPolicyAssignments().list("rg1", "cache1", "default", com.azure.core.util.Context.NONE); } } ``` -### RedisEnterprise_ListByResourceGroup +### RedisEnterprise_ListSkusForScaling ```java /** - * Samples for RedisEnterprise ListByResourceGroup. + * Samples for OperationsStatus Get. */ -public final class RedisEnterpriseListByResourceGroupSamples { +public final class OperationsStatusGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseListByResourceGroup.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * OperationsStatusGet.json */ /** - * Sample code: RedisEnterpriseListByResourceGroup. + * Sample code: OperationsStatusGet. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void - redisEnterpriseListByResourceGroup(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - manager.redisEnterprises().listByResourceGroup("rg1", com.azure.core.util.Context.NONE); + public static void operationsStatusGet(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.operationsStatus().getWithResponse("West US", "testoperationid", com.azure.core.util.Context.NONE); } } ``` @@ -919,48 +1009,30 @@ public final class RedisEnterpriseListByResourceGroupSamples { ### RedisEnterprise_Update ```java -import com.azure.resourcemanager.redisenterprise.models.Cluster; -import com.azure.resourcemanager.redisenterprise.models.Sku; -import com.azure.resourcemanager.redisenterprise.models.SkuName; -import com.azure.resourcemanager.redisenterprise.models.TlsVersion; -import java.util.HashMap; -import java.util.Map; +import com.azure.resourcemanager.redisenterprise.models.AccessPolicyAssignmentPropertiesUser; /** - * Samples for RedisEnterprise Update. + * Samples for AccessPolicyAssignment CreateUpdate. */ -public final class RedisEnterpriseUpdateSamples { +public final class AccessPolicyAssignmentCreateUpdateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ - * RedisEnterpriseUpdate.json + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseAccessPolicyAssignmentCreateUpdate.json */ /** - * Sample code: RedisEnterpriseUpdate. + * Sample code: RedisEnterpriseAccessPolicyAssignmentCreateUpdate. * * @param manager Entry point to RedisEnterpriseManager. */ - public static void redisEnterpriseUpdate(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { - Cluster resource = manager.redisEnterprises() - .getByResourceGroupWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE) - .getValue(); - resource.update() - .withTags(mapOf("tag1", "value1")) - .withSku(new Sku().withName(SkuName.ENTERPRISE_FLASH_F300).withCapacity(9)) - .withMinimumTlsVersion(TlsVersion.ONE_TWO) - .apply(); - } - - // Use "Map.of" if available - @SuppressWarnings("unchecked") - private static Map mapOf(Object... inputs) { - Map map = new HashMap<>(); - for (int i = 0; i < inputs.length; i += 2) { - String key = (String) inputs[i]; - T value = (T) inputs[i + 1]; - map.put(key, value); - } - return map; + public static void redisEnterpriseAccessPolicyAssignmentCreateUpdate( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.accessPolicyAssignments() + .define("defaultTestEntraApp1") + .withExistingDatabase("rg1", "cache1", "default") + .withAccessPolicyName("default") + .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("6497c918-11ad-41e7-1b0f-7c518a87d0b0")) + .create(); } } ``` diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/pom.xml b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/pom.xml index f410999c28ae..07a6b3985f31 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/pom.xml +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/pom.xml @@ -18,7 +18,7 @@ jar Microsoft Azure SDK for RedisEnterprise Management - This package contains Microsoft Azure SDK for RedisEnterprise Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for managing Redis Enterprise resources in Azure. Package tag package-preview-2024-09. + This package contains Microsoft Azure SDK for RedisEnterprise Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. REST API for managing Redis Enterprise resources in Azure. Package tag package-preview-2025-05-01. https://github.com/Azure/azure-sdk-for-java diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/RedisEnterpriseManager.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/RedisEnterpriseManager.java index 64d4295feb05..2f902dec57ce 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/RedisEnterpriseManager.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/RedisEnterpriseManager.java @@ -11,6 +11,7 @@ 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.BearerTokenAuthenticationPolicy; import com.azure.core.http.policy.HttpLogOptions; import com.azure.core.http.policy.HttpLoggingPolicy; import com.azure.core.http.policy.HttpPipelinePolicy; @@ -19,9 +20,9 @@ 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; import com.azure.core.management.profile.AzureProfile; import com.azure.core.util.Configuration; +import com.azure.core.util.CoreUtils; import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.redisenterprise.fluent.RedisEnterpriseManagementClient; import com.azure.resourcemanager.redisenterprise.implementation.AccessPolicyAssignmentsImpl; @@ -43,6 +44,7 @@ import java.time.temporal.ChronoUnit; import java.util.ArrayList; import java.util.List; +import java.util.Map; import java.util.Objects; import java.util.stream.Collectors; @@ -117,6 +119,9 @@ public static Configurable configure() { */ public static final class Configurable { private static final ClientLogger LOGGER = new ClientLogger(Configurable.class); + private static final String SDK_VERSION = "version"; + private static final Map PROPERTIES + = CoreUtils.getProperties("azure-resourcemanager-redisenterprise.properties"); private HttpClient httpClient; private HttpLogOptions httpLogOptions; @@ -224,12 +229,14 @@ public RedisEnterpriseManager authenticate(TokenCredential credential, AzureProf Objects.requireNonNull(credential, "'credential' cannot be null."); Objects.requireNonNull(profile, "'profile' cannot be null."); + String clientVersion = PROPERTIES.getOrDefault(SDK_VERSION, "UnknownVersion"); + StringBuilder userAgentBuilder = new StringBuilder(); userAgentBuilder.append("azsdk-java") .append("-") .append("com.azure.resourcemanager.redisenterprise") .append("/") - .append("2.1.0-beta.2"); + .append(clientVersion); if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) { userAgentBuilder.append(" (") .append(Configuration.getGlobalConfiguration().get("java.version")) @@ -262,7 +269,7 @@ public RedisEnterpriseManager authenticate(TokenCredential credential, AzureProf HttpPolicyProviders.addBeforeRetryPolicies(policies); policies.add(retryPolicy); policies.add(new AddDatePolicy()); - policies.add(new ArmChallengeAuthenticationPolicy(credential, scopes.toArray(new String[0]))); + policies.add(new BearerTokenAuthenticationPolicy(credential, scopes.toArray(new String[0]))); policies.addAll(this.policies.stream() .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY) .collect(Collectors.toList())); diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/AccessPolicyAssignmentsClient.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/AccessPolicyAssignmentsClient.java index 504d3e9d49a2..d7fc33028485 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/AccessPolicyAssignmentsClient.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/AccessPolicyAssignmentsClient.java @@ -21,7 +21,8 @@ public interface AccessPolicyAssignmentsClient { * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -40,7 +41,8 @@ SyncPoller, AccessPolicyAssignmentInner> * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -60,7 +62,8 @@ SyncPoller, AccessPolicyAssignmentInner> * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -77,7 +80,8 @@ AccessPolicyAssignmentInner createUpdate(String resourceGroupName, String cluste * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -95,7 +99,8 @@ AccessPolicyAssignmentInner createUpdate(String resourceGroupName, String cluste * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -112,7 +117,8 @@ Response getWithResponse(String resourceGroupName, * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -128,7 +134,8 @@ AccessPolicyAssignmentInner get(String resourceGroupName, String clusterName, St * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -144,7 +151,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -161,7 +169,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -175,7 +184,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -191,7 +201,8 @@ void delete(String resourceGroupName, String clusterName, String databaseName, S * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -205,7 +216,8 @@ void delete(String resourceGroupName, String clusterName, String databaseName, S * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/DatabasesClient.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/DatabasesClient.java index 367158fcc824..ea48f2f8ff97 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/DatabasesClient.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/DatabasesClient.java @@ -29,7 +29,8 @@ public interface DatabasesClient { * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -42,7 +43,8 @@ public interface DatabasesClient { * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -56,7 +58,8 @@ public interface DatabasesClient { * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -72,7 +75,8 @@ SyncPoller, DatabaseInner> beginCreate(String resource * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -89,7 +93,8 @@ SyncPoller, DatabaseInner> beginCreate(String resource * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -104,7 +109,8 @@ SyncPoller, DatabaseInner> beginCreate(String resource * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -121,7 +127,8 @@ DatabaseInner create(String resourceGroupName, String clusterName, String databa * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -137,7 +144,8 @@ SyncPoller, DatabaseInner> beginUpdate(String resource * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -154,7 +162,8 @@ SyncPoller, DatabaseInner> beginUpdate(String resource * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -169,7 +178,8 @@ SyncPoller, DatabaseInner> beginUpdate(String resource * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -186,7 +196,8 @@ DatabaseInner update(String resourceGroupName, String clusterName, String databa * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -202,7 +213,8 @@ Response getWithResponse(String resourceGroupName, String cluster * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -216,7 +228,8 @@ Response getWithResponse(String resourceGroupName, String cluster * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -230,7 +243,8 @@ Response getWithResponse(String resourceGroupName, String cluster * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -246,7 +260,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -259,7 +274,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -273,7 +289,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -289,7 +306,8 @@ Response listKeysWithResponse(String resourceGroupName, String * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -303,7 +321,8 @@ Response listKeysWithResponse(String resourceGroupName, String * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -319,7 +338,8 @@ SyncPoller, AccessKeysInner> beginRegenerateKey(Stri * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -336,7 +356,8 @@ SyncPoller, AccessKeysInner> beginRegenerateKey(Stri * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -352,7 +373,8 @@ AccessKeysInner regenerateKey(String resourceGroupName, String clusterName, Stri * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -369,7 +391,8 @@ AccessKeysInner regenerateKey(String resourceGroupName, String clusterName, Stri * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -385,7 +408,8 @@ SyncPoller, Void> beginImportMethod(String resourceGroupName, S * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -402,7 +426,8 @@ SyncPoller, Void> beginImportMethod(String resourceGroupName, S * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -417,7 +442,8 @@ void importMethod(String resourceGroupName, String clusterName, String databaseN * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -433,7 +459,8 @@ void importMethod(String resourceGroupName, String clusterName, String databaseN * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -449,7 +476,8 @@ SyncPoller, Void> beginExport(String resourceGroupName, String * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -466,7 +494,8 @@ SyncPoller, Void> beginExport(String resourceGroupName, String * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -480,7 +509,8 @@ SyncPoller, Void> beginExport(String resourceGroupName, String * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -496,7 +526,8 @@ void export(String resourceGroupName, String clusterName, String databaseName, E * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -512,7 +543,8 @@ SyncPoller, Void> beginForceUnlink(String resourceGroupName, St * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -529,7 +561,8 @@ SyncPoller, Void> beginForceUnlink(String resourceGroupName, St * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -544,7 +577,8 @@ void forceUnlink(String resourceGroupName, String clusterName, String databaseNa * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -562,7 +596,8 @@ void forceUnlink(String resourceGroupName, String clusterName, String databaseNa * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -580,7 +615,8 @@ SyncPoller, Void> beginForceLinkToReplicationGroup(String resou * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -599,7 +635,8 @@ SyncPoller, Void> beginForceLinkToReplicationGroup(String resou * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -616,7 +653,8 @@ void forceLinkToReplicationGroup(String resourceGroupName, String clusterName, S * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -632,23 +670,23 @@ void forceLinkToReplicationGroup(String resourceGroupName, String clusterName, S * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. - * @param parameters Information identifying the databases to be flushed. * @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> beginFlush(String resourceGroupName, String clusterName, String databaseName, - FlushParameters parameters); + SyncPoller, Void> beginFlush(String resourceGroupName, String clusterName, String databaseName); /** * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -665,21 +703,22 @@ SyncPoller, Void> beginFlush(String resourceGroupName, String c * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. - * @param parameters Information identifying the databases to be flushed. * @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 flush(String resourceGroupName, String clusterName, String databaseName, FlushParameters parameters); + void flush(String resourceGroupName, String clusterName, String databaseName); /** * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -695,7 +734,8 @@ void flush(String resourceGroupName, String clusterName, String databaseName, Fl * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -710,7 +750,8 @@ SyncPoller, Void> beginUpgradeDBRedisVersion(String resourceGro * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -726,7 +767,8 @@ SyncPoller, Void> beginUpgradeDBRedisVersion(String resourceGro * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -739,7 +781,8 @@ SyncPoller, Void> beginUpgradeDBRedisVersion(String resourceGro * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateEndpointConnectionsClient.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateEndpointConnectionsClient.java index 19ad96eb213b..87dd760bd957 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateEndpointConnectionsClient.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateEndpointConnectionsClient.java @@ -21,7 +21,8 @@ public interface PrivateEndpointConnectionsClient { * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -35,7 +36,8 @@ public interface PrivateEndpointConnectionsClient { * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -50,7 +52,8 @@ public interface PrivateEndpointConnectionsClient { * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -68,7 +71,8 @@ Response getWithResponse(String resourceGroupNam * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -84,7 +88,8 @@ PrivateEndpointConnectionInner get(String resourceGroupName, String clusterName, * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -102,7 +107,8 @@ SyncPoller, PrivateEndpointConnection * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -121,7 +127,8 @@ SyncPoller, PrivateEndpointConnection * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -138,7 +145,8 @@ PrivateEndpointConnectionInner put(String resourceGroupName, String clusterName, * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -156,7 +164,8 @@ PrivateEndpointConnectionInner put(String resourceGroupName, String clusterName, * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -172,7 +181,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -189,7 +199,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -203,7 +214,8 @@ SyncPoller, Void> beginDelete(String resourceGroupName, String * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateLinkResourcesClient.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateLinkResourcesClient.java index 6911d49020a4..aa64deea1acc 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateLinkResourcesClient.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/PrivateLinkResourcesClient.java @@ -18,7 +18,8 @@ public interface PrivateLinkResourcesClient { * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -32,7 +33,8 @@ public interface PrivateLinkResourcesClient { * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/RedisEnterprisesClient.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/RedisEnterprisesClient.java index e4681506e704..18cb840eb01b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/RedisEnterprisesClient.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/RedisEnterprisesClient.java @@ -12,6 +12,7 @@ import com.azure.core.util.Context; import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.redisenterprise.fluent.models.ClusterInner; +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; import com.azure.resourcemanager.redisenterprise.models.ClusterUpdate; /** @@ -22,7 +23,8 @@ public interface RedisEnterprisesClient { * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -37,7 +39,8 @@ SyncPoller, ClusterInner> beginCreate(String resourceGr * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -53,7 +56,8 @@ SyncPoller, ClusterInner> beginCreate(String resourceGr * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -67,7 +71,8 @@ SyncPoller, ClusterInner> beginCreate(String resourceGr * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -82,7 +87,8 @@ SyncPoller, ClusterInner> beginCreate(String resourceGr * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -97,7 +103,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -113,7 +120,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -127,7 +135,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -142,7 +151,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -155,7 +165,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -169,7 +180,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -181,7 +193,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -194,7 +207,8 @@ SyncPoller, ClusterInner> beginUpdate(String resourceGr * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -209,7 +223,8 @@ Response getByResourceGroupWithResponse(String resourceGroupName, * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -264,4 +279,34 @@ Response getByResourceGroupWithResponse(String resourceGroupName, */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(Context context); + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response listSkusForScalingWithResponse(String resourceGroupName, String clusterName, + Context context); + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + SkuDetailsListInner listSkusForScaling(String resourceGroupName, String clusterName); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/ClusterInner.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/ClusterInner.java index 6ecb0f447549..70deafee6890 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/ClusterInner.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/ClusterInner.java @@ -12,6 +12,7 @@ import com.azure.json.JsonWriter; import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryption; import com.azure.resourcemanager.redisenterprise.models.HighAvailability; +import com.azure.resourcemanager.redisenterprise.models.Kind; import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentity; import com.azure.resourcemanager.redisenterprise.models.ProvisioningState; import com.azure.resourcemanager.redisenterprise.models.RedundancyMode; @@ -27,6 +28,11 @@ */ @Fluent public final class ClusterInner extends Resource { + /* + * Distinguishes the kind of cluster. Read-only. + */ + private Kind kind; + /* * The SKU to create, which affects price, performance, and features. */ @@ -68,6 +74,15 @@ public final class ClusterInner extends Resource { public ClusterInner() { } + /** + * Get the kind property: Distinguishes the kind of cluster. Read-only. + * + * @return the kind value. + */ + public Kind kind() { + return this.kind; + } + /** * Get the sku property: The SKU to create, which affects price, performance, and features. * @@ -382,6 +397,8 @@ public static ClusterInner fromJson(JsonReader jsonReader) throws IOException { deserializedClusterInner.withTags(tags); } else if ("sku".equals(fieldName)) { deserializedClusterInner.sku = Sku.fromJson(reader); + } else if ("kind".equals(fieldName)) { + deserializedClusterInner.kind = Kind.fromString(reader.getString()); } else if ("zones".equals(fieldName)) { List zones = reader.readArray(reader1 -> reader1.getString()); deserializedClusterInner.zones = zones; diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseInner.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseInner.java index 24aada795b16..4a54ebe563ac 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseInner.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseInner.java @@ -176,8 +176,9 @@ public ResourceState resourceState() { } /** - * Get the clusteringPolicy property: Clustering policy - default is OSSCluster. This property must be chosen at - * create time, and cannot be changed without deleting the database. + * Get the clusteringPolicy property: Clustering policy - default is OSSCluster. This property can be updated only + * if the current value is NoCluster. If the value is OSSCluster or EnterpriseCluster, it cannot be updated without + * deleting the database. * * @return the clusteringPolicy value. */ @@ -186,8 +187,9 @@ public ClusteringPolicy clusteringPolicy() { } /** - * Set the clusteringPolicy property: Clustering policy - default is OSSCluster. This property must be chosen at - * create time, and cannot be changed without deleting the database. + * Set the clusteringPolicy property: Clustering policy - default is OSSCluster. This property can be updated only + * if the current value is NoCluster. If the value is OSSCluster or EnterpriseCluster, it cannot be updated without + * deleting the database. * * @param clusteringPolicy the clusteringPolicy value to set. * @return the DatabaseInner object itself. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseProperties.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseProperties.java index ff8f4e89c5e4..9ba3ebaf5d7a 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseProperties.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/fluent/models/DatabaseProperties.java @@ -51,8 +51,8 @@ public final class DatabaseProperties implements JsonSerializable { + /* + * List of SKUS available to scale up or scale down. + */ + private List skus; + + /** + * Creates an instance of SkuDetailsListInner class. + */ + public SkuDetailsListInner() { + } + + /** + * Get the skus property: List of SKUS available to scale up or scale down. + * + * @return the skus value. + */ + public List skus() { + return this.skus; + } + + /** + * Set the skus property: List of SKUS available to scale up or scale down. + * + * @param skus the skus value to set. + * @return the SkuDetailsListInner object itself. + */ + public SkuDetailsListInner withSkus(List skus) { + this.skus = skus; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (skus() != null) { + skus().forEach(e -> e.validate()); + } + } + + /** + * {@inheritDoc} + */ + @Override + public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { + jsonWriter.writeStartObject(); + jsonWriter.writeArrayField("skus", this.skus, (writer, element) -> writer.writeJson(element)); + return jsonWriter.writeEndObject(); + } + + /** + * Reads an instance of SkuDetailsListInner from the JsonReader. + * + * @param jsonReader The JsonReader being read. + * @return An instance of SkuDetailsListInner if the JsonReader was pointing to an instance of it, or null if it was + * pointing to JSON null. + * @throws IOException If an error occurs while reading the SkuDetailsListInner. + */ + public static SkuDetailsListInner fromJson(JsonReader jsonReader) throws IOException { + return jsonReader.readObject(reader -> { + SkuDetailsListInner deserializedSkuDetailsListInner = new SkuDetailsListInner(); + while (reader.nextToken() != JsonToken.END_OBJECT) { + String fieldName = reader.getFieldName(); + reader.nextToken(); + + if ("skus".equals(fieldName)) { + List skus = reader.readArray(reader1 -> SkuDetails.fromJson(reader1)); + deserializedSkuDetailsListInner.skus = skus; + } else { + reader.skipChildren(); + } + } + + return deserializedSkuDetailsListInner; + }); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/AccessPolicyAssignmentsClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/AccessPolicyAssignmentsClientImpl.java index 90a69388eb19..dca8e9f8f5eb 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/AccessPolicyAssignmentsClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/AccessPolicyAssignmentsClientImpl.java @@ -127,7 +127,8 @@ Mono> listNext( * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -179,7 +180,8 @@ private Mono>> createUpdateWithResponseAsync(String re * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -232,7 +234,8 @@ private Mono>> createUpdateWithResponseAsync(String re * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -257,7 +260,8 @@ private PollerFlux, AccessPolicyAssignme * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -284,7 +288,8 @@ private PollerFlux, AccessPolicyAssignme * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -308,7 +313,8 @@ public SyncPoller, AccessPolicyAssignmen * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -333,7 +339,8 @@ public SyncPoller, AccessPolicyAssignmen * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -354,7 +361,8 @@ private Mono createUpdateAsync(String resourceGroup * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -377,7 +385,8 @@ private Mono createUpdateAsync(String resourceGroup * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -397,7 +406,8 @@ public AccessPolicyAssignmentInner createUpdate(String resourceGroupName, String * Creates/Updates a particular access policy assignment for a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param parameters Parameters supplied to the create access policy assignment for database. @@ -418,7 +428,8 @@ public AccessPolicyAssignmentInner createUpdate(String resourceGroupName, String * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -464,7 +475,8 @@ private Mono> getWithResponseAsync(String * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -509,7 +521,8 @@ private Mono> getWithResponseAsync(String * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -528,7 +541,8 @@ private Mono getAsync(String resourceGroupName, Str * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -548,7 +562,8 @@ public Response getWithResponse(String resourceGrou * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -567,7 +582,8 @@ public AccessPolicyAssignmentInner get(String resourceGroupName, String clusterN * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -612,7 +628,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -656,7 +673,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -677,7 +695,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -700,7 +719,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -719,7 +739,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -739,7 +760,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -758,7 +780,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -779,7 +802,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -796,7 +820,8 @@ public void delete(String resourceGroupName, String clusterName, String database * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -814,7 +839,8 @@ public void delete(String resourceGroupName, String clusterName, String database * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -855,7 +881,8 @@ private Mono> listSinglePageAsync(Str * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -897,7 +924,8 @@ private Mono> listSinglePageAsync(Str * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -915,7 +943,8 @@ private PagedFlux listAsync(String resourceGroupNam * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -934,7 +963,8 @@ private PagedFlux listAsync(String resourceGroupNam * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -951,7 +981,8 @@ public PagedIterable list(String resourceGroupName, * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/ClusterImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/ClusterImpl.java index 6a56fb524eeb..13bfb8e0f3ea 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/ClusterImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/ClusterImpl.java @@ -4,6 +4,7 @@ package com.azure.resourcemanager.redisenterprise.implementation; +import com.azure.core.http.rest.Response; import com.azure.core.management.Region; import com.azure.core.util.Context; import com.azure.resourcemanager.redisenterprise.fluent.models.ClusterInner; @@ -12,12 +13,14 @@ import com.azure.resourcemanager.redisenterprise.models.ClusterPropertiesEncryption; import com.azure.resourcemanager.redisenterprise.models.ClusterUpdate; import com.azure.resourcemanager.redisenterprise.models.HighAvailability; +import com.azure.resourcemanager.redisenterprise.models.Kind; import com.azure.resourcemanager.redisenterprise.models.ManagedServiceIdentity; import com.azure.resourcemanager.redisenterprise.models.PrivateEndpointConnection; import com.azure.resourcemanager.redisenterprise.models.ProvisioningState; import com.azure.resourcemanager.redisenterprise.models.RedundancyMode; import com.azure.resourcemanager.redisenterprise.models.ResourceState; import com.azure.resourcemanager.redisenterprise.models.Sku; +import com.azure.resourcemanager.redisenterprise.models.SkuDetailsList; import com.azure.resourcemanager.redisenterprise.models.TlsVersion; import java.util.Collections; import java.util.List; @@ -54,6 +57,10 @@ public Map tags() { } } + public Kind kind() { + return this.innerModel().kind(); + } + public Sku sku() { return this.innerModel().sku(); } @@ -208,6 +215,15 @@ public Cluster refresh(Context context) { return this; } + public Response listSkusForScalingWithResponse(Context context) { + return serviceManager.redisEnterprises() + .listSkusForScalingWithResponse(resourceGroupName, clusterName, context); + } + + public SkuDetailsList listSkusForScaling() { + return serviceManager.redisEnterprises().listSkusForScaling(resourceGroupName, clusterName); + } + public ClusterImpl withRegion(Region location) { this.innerModel().withLocation(location.toString()); return this; diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabaseImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabaseImpl.java index ab38b8435a8d..dcf020610758 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabaseImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabaseImpl.java @@ -245,8 +245,8 @@ public void forceLinkToReplicationGroup(ForceLinkParameters parameters, Context .forceLinkToReplicationGroup(resourceGroupName, clusterName, databaseName, parameters, context); } - public void flush(FlushParameters parameters) { - serviceManager.databases().flush(resourceGroupName, clusterName, databaseName, parameters); + public void flush() { + serviceManager.databases().flush(resourceGroupName, clusterName, databaseName); } public void flush(FlushParameters parameters, Context context) { @@ -277,8 +277,13 @@ public DatabaseImpl withPort(Integer port) { } public DatabaseImpl withClusteringPolicy(ClusteringPolicy clusteringPolicy) { - this.innerModel().withClusteringPolicy(clusteringPolicy); - return this; + if (isInCreateMode()) { + this.innerModel().withClusteringPolicy(clusteringPolicy); + return this; + } else { + this.updateParameters.withClusteringPolicy(clusteringPolicy); + return this; + } } public DatabaseImpl withEvictionPolicy(EvictionPolicy evictionPolicy) { diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesClientImpl.java index 753214b0287e..5b045b5776aa 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesClientImpl.java @@ -224,7 +224,8 @@ Mono> listByClusterNext(@PathParam(value = "nextLink", en * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -262,7 +263,8 @@ private Mono> listByClusterSinglePageAsync(String r * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -301,7 +303,8 @@ private Mono> listByClusterSinglePageAsync(String r * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -317,7 +320,8 @@ private PagedFlux listByClusterAsync(String resourceGroupName, St * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -334,7 +338,8 @@ private PagedFlux listByClusterAsync(String resourceGroupName, St * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -349,7 +354,8 @@ public PagedIterable listByCluster(String resourceGroupName, Stri * Gets all databases in the specified Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -365,7 +371,8 @@ public PagedIterable listByCluster(String resourceGroupName, Stri * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -412,7 +419,8 @@ private Mono>> createWithResponseAsync(String resource * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -458,7 +466,8 @@ private Mono>> createWithResponseAsync(String resource * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -479,7 +488,8 @@ private PollerFlux, DatabaseInner> beginCreateAsync(St * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -502,7 +512,8 @@ private PollerFlux, DatabaseInner> beginCreateAsync(St * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -520,7 +531,8 @@ public SyncPoller, DatabaseInner> beginCreate(String r * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -539,7 +551,8 @@ public SyncPoller, DatabaseInner> beginCreate(String r * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -558,7 +571,8 @@ private Mono createAsync(String resourceGroupName, String cluster * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -578,7 +592,8 @@ private Mono createAsync(String resourceGroupName, String cluster * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -596,7 +611,8 @@ public DatabaseInner create(String resourceGroupName, String clusterName, String * Creates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -615,7 +631,8 @@ public DatabaseInner create(String resourceGroupName, String clusterName, String * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -662,7 +679,8 @@ private Mono>> updateWithResponseAsync(String resource * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -708,7 +726,8 @@ private Mono>> updateWithResponseAsync(String resource * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -729,7 +748,8 @@ private PollerFlux, DatabaseInner> beginUpdateAsync(St * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -752,7 +772,8 @@ private PollerFlux, DatabaseInner> beginUpdateAsync(St * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -770,7 +791,8 @@ public SyncPoller, DatabaseInner> beginUpdate(String r * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -789,7 +811,8 @@ public SyncPoller, DatabaseInner> beginUpdate(String r * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -808,7 +831,8 @@ private Mono updateAsync(String resourceGroupName, String cluster * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -828,7 +852,8 @@ private Mono updateAsync(String resourceGroupName, String cluster * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -846,7 +871,8 @@ public DatabaseInner update(String resourceGroupName, String clusterName, String * Updates a database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Parameters supplied to the create or update database operation. * @param context The context to associate with this operation. @@ -865,7 +891,8 @@ public DatabaseInner update(String resourceGroupName, String clusterName, String * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -905,7 +932,8 @@ private Mono> getWithResponseAsync(String resourceGroupN * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -945,7 +973,8 @@ private Mono> getWithResponseAsync(String resourceGroupN * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -962,7 +991,8 @@ private Mono getAsync(String resourceGroupName, String clusterNam * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -980,7 +1010,8 @@ public Response getWithResponse(String resourceGroupName, String * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -996,7 +1027,8 @@ public DatabaseInner get(String resourceGroupName, String clusterName, String da * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1035,7 +1067,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1074,7 +1107,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1093,7 +1127,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1115,7 +1150,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1132,7 +1168,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1150,7 +1187,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1167,7 +1205,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1185,7 +1224,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1200,7 +1240,8 @@ public void delete(String resourceGroupName, String clusterName, String database * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1216,7 +1257,8 @@ public void delete(String resourceGroupName, String clusterName, String database * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1255,7 +1297,8 @@ private Mono> listKeysWithResponseAsync(String resourc * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1294,7 +1337,8 @@ private Mono> listKeysWithResponseAsync(String resourc * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1311,7 +1355,8 @@ private Mono listKeysAsync(String resourceGroupName, String clu * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1329,7 +1374,8 @@ public Response listKeysWithResponse(String resourceGroupName, * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1345,7 +1391,8 @@ public AccessKeysInner listKeys(String resourceGroupName, String clusterName, St * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1391,7 +1438,8 @@ private Mono>> regenerateKeyWithResponseAsync(String r * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -1436,7 +1484,8 @@ private Mono>> regenerateKeyWithResponseAsync(String r * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1457,7 +1506,8 @@ private PollerFlux, AccessKeysInner> beginRegenerate * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -1480,7 +1530,8 @@ private PollerFlux, AccessKeysInner> beginRegenerate * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1498,7 +1549,8 @@ public SyncPoller, AccessKeysInner> beginRegenerateK * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -1518,7 +1570,8 @@ public SyncPoller, AccessKeysInner> beginRegenerateK * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1537,7 +1590,8 @@ private Mono regenerateKeyAsync(String resourceGroupName, Strin * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -1557,7 +1611,8 @@ private Mono regenerateKeyAsync(String resourceGroupName, Strin * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1575,7 +1630,8 @@ public AccessKeysInner regenerateKey(String resourceGroupName, String clusterNam * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -1594,7 +1650,8 @@ public AccessKeysInner regenerateKey(String resourceGroupName, String clusterNam * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1640,7 +1697,8 @@ private Mono>> importMethodWithResponseAsync(String re * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -1685,7 +1743,8 @@ private Mono>> importMethodWithResponseAsync(String re * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1706,7 +1765,8 @@ private PollerFlux, Void> beginImportMethodAsync(String resourc * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -1729,7 +1789,8 @@ private PollerFlux, Void> beginImportMethodAsync(String resourc * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1747,7 +1808,8 @@ public SyncPoller, Void> beginImportMethod(String resourceGroup * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -1767,7 +1829,8 @@ public SyncPoller, Void> beginImportMethod(String resourceGroup * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1786,7 +1849,8 @@ private Mono importMethodAsync(String resourceGroupName, String clusterNam * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -1806,7 +1870,8 @@ private Mono importMethodAsync(String resourceGroupName, String clusterNam * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1823,7 +1888,8 @@ public void importMethod(String resourceGroupName, String clusterName, String da * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -1841,7 +1907,8 @@ public void importMethod(String resourceGroupName, String clusterName, String da * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1887,7 +1954,8 @@ private Mono>> exportWithResponseAsync(String resource * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -1932,7 +2000,8 @@ private Mono>> exportWithResponseAsync(String resource * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1953,7 +2022,8 @@ private PollerFlux, Void> beginExportAsync(String resourceGroup * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -1976,7 +2046,8 @@ private PollerFlux, Void> beginExportAsync(String resourceGroup * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1994,7 +2065,8 @@ public SyncPoller, Void> beginExport(String resourceGroupName, * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -2013,7 +2085,8 @@ public SyncPoller, Void> beginExport(String resourceGroupName, * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2032,7 +2105,8 @@ private Mono exportAsync(String resourceGroupName, String clusterName, Str * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -2052,7 +2126,8 @@ private Mono exportAsync(String resourceGroupName, String clusterName, Str * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2069,7 +2144,8 @@ public void export(String resourceGroupName, String clusterName, String database * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -2087,7 +2163,8 @@ public void export(String resourceGroupName, String clusterName, String database * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2133,7 +2210,8 @@ private Mono>> forceUnlinkWithResponseAsync(String res * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2178,7 +2256,8 @@ private Mono>> forceUnlinkWithResponseAsync(String res * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2199,7 +2278,8 @@ private PollerFlux, Void> beginForceUnlinkAsync(String resource * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2222,7 +2302,8 @@ private PollerFlux, Void> beginForceUnlinkAsync(String resource * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2240,7 +2321,8 @@ public SyncPoller, Void> beginForceUnlink(String resourceGroupN * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2260,7 +2342,8 @@ public SyncPoller, Void> beginForceUnlink(String resourceGroupN * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2279,7 +2362,8 @@ private Mono forceUnlinkAsync(String resourceGroupName, String clusterName * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2299,7 +2383,8 @@ private Mono forceUnlinkAsync(String resourceGroupName, String clusterName * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2316,7 +2401,8 @@ public void forceUnlink(String resourceGroupName, String clusterName, String dat * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2336,7 +2422,8 @@ public void forceUnlink(String resourceGroupName, String clusterName, String dat * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2384,7 +2471,8 @@ private Mono>> forceLinkToReplicationGroupWithResponse * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2431,7 +2519,8 @@ private Mono>> forceLinkToReplicationGroupWithResponse * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2454,7 +2543,8 @@ private PollerFlux, Void> beginForceLinkToReplicationGroupAsync * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2479,7 +2569,8 @@ private PollerFlux, Void> beginForceLinkToReplicationGroupAsync * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2500,7 +2591,8 @@ public SyncPoller, Void> beginForceLinkToReplicationGroup(Strin * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2523,7 +2615,8 @@ public SyncPoller, Void> beginForceLinkToReplicationGroup(Strin * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2544,7 +2637,8 @@ private Mono forceLinkToReplicationGroupAsync(String resourceGroupName, St * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2567,7 +2661,8 @@ private Mono forceLinkToReplicationGroupAsync(String resourceGroupName, St * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2586,7 +2681,8 @@ public void forceLinkToReplicationGroup(String resourceGroupName, String cluster * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -2604,7 +2700,8 @@ public void forceLinkToReplicationGroup(String resourceGroupName, String cluster * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2633,9 +2730,7 @@ private Mono>> flushWithResponseAsync(String resourceG return Mono.error(new IllegalArgumentException( "Parameter this.client.getSubscriptionId() is required and cannot be null.")); } - if (parameters == null) { - return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null.")); - } else { + if (parameters != null) { parameters.validate(); } final String accept = "application/json"; @@ -2650,7 +2745,8 @@ private Mono>> flushWithResponseAsync(String resourceG * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -2680,9 +2776,7 @@ private Mono>> flushWithResponseAsync(String resourceG return Mono.error(new IllegalArgumentException( "Parameter this.client.getSubscriptionId() is required and cannot be null.")); } - if (parameters == null) { - return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null.")); - } else { + if (parameters != null) { parameters.validate(); } final String accept = "application/json"; @@ -2695,7 +2789,8 @@ private Mono>> flushWithResponseAsync(String resourceG * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2716,7 +2811,30 @@ private PollerFlux, Void> beginFlushAsync(String resourceGroupN * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @param databaseName The name of the Redis Enterprise database. + * @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> beginFlushAsync(String resourceGroupName, String clusterName, + String databaseName) { + final FlushParameters parameters = null; + Mono>> mono + = flushWithResponseAsync(resourceGroupName, clusterName, databaseName, parameters); + return this.client.getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, + this.client.getContext()); + } + + /** + * Flushes all the keys in this database and also from its linked databases. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -2739,9 +2857,9 @@ private PollerFlux, Void> beginFlushAsync(String resourceGroupN * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. - * @param parameters Information identifying the databases to be flushed. * @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. @@ -2749,7 +2867,8 @@ private PollerFlux, Void> beginFlushAsync(String resourceGroupN */ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginFlush(String resourceGroupName, String clusterName, - String databaseName, FlushParameters parameters) { + String databaseName) { + final FlushParameters parameters = null; return this.beginFlushAsync(resourceGroupName, clusterName, databaseName, parameters).getSyncPoller(); } @@ -2757,7 +2876,8 @@ public SyncPoller, Void> beginFlush(String resourceGroupName, S * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -2776,7 +2896,8 @@ public SyncPoller, Void> beginFlush(String resourceGroupName, S * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2795,7 +2916,27 @@ private Mono flushAsync(String resourceGroupName, String clusterName, Stri * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @param databaseName The name of the Redis Enterprise database. + * @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 flushAsync(String resourceGroupName, String clusterName, String databaseName) { + final FlushParameters parameters = null; + return beginFlushAsync(resourceGroupName, clusterName, databaseName, parameters).last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Flushes all the keys in this database and also from its linked databases. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -2815,15 +2956,16 @@ private Mono flushAsync(String resourceGroupName, String clusterName, Stri * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. - * @param parameters Information identifying the databases to be flushed. * @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 flush(String resourceGroupName, String clusterName, String databaseName, FlushParameters parameters) { + public void flush(String resourceGroupName, String clusterName, String databaseName) { + final FlushParameters parameters = null; flushAsync(resourceGroupName, clusterName, databaseName, parameters).block(); } @@ -2831,7 +2973,8 @@ public void flush(String resourceGroupName, String clusterName, String databaseN * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -2849,7 +2992,8 @@ public void flush(String resourceGroupName, String clusterName, String databaseN * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -2889,7 +3033,8 @@ private Mono>> upgradeDBRedisVersionWithResponseAsync( * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2928,7 +3073,8 @@ private Mono>> upgradeDBRedisVersionWithResponseAsync( * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -2948,7 +3094,8 @@ private PollerFlux, Void> beginUpgradeDBRedisVersionAsync(Strin * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2970,7 +3117,8 @@ private PollerFlux, Void> beginUpgradeDBRedisVersionAsync(Strin * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -2987,7 +3135,8 @@ public SyncPoller, Void> beginUpgradeDBRedisVersion(String reso * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -3006,7 +3155,8 @@ public SyncPoller, Void> beginUpgradeDBRedisVersion(String reso * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -3023,7 +3173,8 @@ private Mono upgradeDBRedisVersionAsync(String resourceGroupName, String c * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -3042,7 +3193,8 @@ private Mono upgradeDBRedisVersionAsync(String resourceGroupName, String c * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -3057,7 +3209,8 @@ public void upgradeDBRedisVersion(String resourceGroupName, String clusterName, * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesImpl.java index cd6ee023fc8b..0fb8b9f31b66 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/DatabasesImpl.java @@ -159,8 +159,8 @@ public void forceLinkToReplicationGroup(String resourceGroupName, String cluster .forceLinkToReplicationGroup(resourceGroupName, clusterName, databaseName, parameters, context); } - public void flush(String resourceGroupName, String clusterName, String databaseName, FlushParameters parameters) { - this.serviceClient().flush(resourceGroupName, clusterName, databaseName, parameters); + public void flush(String resourceGroupName, String clusterName, String databaseName) { + this.serviceClient().flush(resourceGroupName, clusterName, databaseName); } public void flush(String resourceGroupName, String clusterName, String databaseName, FlushParameters parameters, diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateEndpointConnectionsClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateEndpointConnectionsClientImpl.java index 66f5b9512022..706df8659896 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateEndpointConnectionsClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateEndpointConnectionsClientImpl.java @@ -115,7 +115,8 @@ Mono>> delete(@HostParam("$host") String endpoint, * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -153,7 +154,8 @@ private Mono> listSinglePageAsync( * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -192,7 +194,8 @@ private Mono> listSinglePageAsync( * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -208,7 +211,8 @@ private PagedFlux listAsync(String resourceGroup * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -226,7 +230,8 @@ private PagedFlux listAsync(String resourceGroup * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -242,7 +247,8 @@ public PagedIterable list(String resourceGroupNa * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -260,7 +266,8 @@ public PagedIterable list(String resourceGroupNa * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -303,7 +310,8 @@ private Mono> getWithResponseAsync(Stri * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -345,7 +353,8 @@ private Mono> getWithResponseAsync(Stri * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -365,7 +374,8 @@ private Mono getAsync(String resourceGroupName, * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -385,7 +395,8 @@ public Response getWithResponse(String resourceG * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -403,7 +414,8 @@ public PrivateEndpointConnectionInner get(String resourceGroupName, String clust * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -452,7 +464,8 @@ private Mono>> putWithResponseAsync(String resourceGro * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -500,7 +513,8 @@ private Mono>> putWithResponseAsync(String resourceGro * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -524,7 +538,8 @@ private PollerFlux, PrivateEndpointCo * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -550,7 +565,8 @@ private PollerFlux, PrivateEndpointCo * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -571,7 +587,8 @@ public SyncPoller, PrivateEndpointCon * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -593,7 +610,8 @@ public SyncPoller, PrivateEndpointCon * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -613,7 +631,8 @@ private Mono putAsync(String resourceGroupName, * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -634,7 +653,8 @@ private Mono putAsync(String resourceGroupName, * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -653,7 +673,8 @@ public PrivateEndpointConnectionInner put(String resourceGroupName, String clust * Updates the state of the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param properties The private endpoint connection properties. @@ -673,7 +694,8 @@ public PrivateEndpointConnectionInner put(String resourceGroupName, String clust * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -715,7 +737,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -756,7 +779,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -777,7 +801,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -800,7 +825,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -818,7 +844,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -838,7 +865,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -856,7 +884,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -876,7 +905,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Str * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -892,7 +922,8 @@ public void delete(String resourceGroupName, String clusterName, String privateE * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateLinkResourcesClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateLinkResourcesClientImpl.java index d9105f4adc70..28056dfd400f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateLinkResourcesClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/PrivateLinkResourcesClientImpl.java @@ -76,7 +76,8 @@ Mono> listByCluster(@HostParam("$host") * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -114,7 +115,8 @@ private Mono> listByClusterSinglePageAsy * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -153,7 +155,8 @@ private Mono> listByClusterSinglePageAsy * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -169,7 +172,8 @@ private PagedFlux listByClusterAsync(String resourceGr * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -187,7 +191,8 @@ private PagedFlux listByClusterAsync(String resourceGr * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -203,7 +208,8 @@ public PagedIterable listByCluster(String resourceGrou * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterpriseManagementClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterpriseManagementClientImpl.java index c6905b118fef..32832717d3a2 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterpriseManagementClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterpriseManagementClientImpl.java @@ -244,7 +244,7 @@ public PrivateLinkResourcesClient getPrivateLinkResources() { this.defaultPollInterval = defaultPollInterval; this.subscriptionId = subscriptionId; this.endpoint = endpoint; - this.apiVersion = "2024-09-01-preview"; + this.apiVersion = "2025-05-01-preview"; this.operations = new OperationsClientImpl(this); this.operationsStatus = new OperationsStatusClientImpl(this); this.redisEnterprises = new RedisEnterprisesClientImpl(this); diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesClientImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesClientImpl.java index 7af86609a099..5635ec4be2bb 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesClientImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesClientImpl.java @@ -14,6 +14,7 @@ import com.azure.core.annotation.HostParam; import com.azure.core.annotation.Patch; import com.azure.core.annotation.PathParam; +import com.azure.core.annotation.Post; import com.azure.core.annotation.Put; import com.azure.core.annotation.QueryParam; import com.azure.core.annotation.ReturnType; @@ -34,6 +35,7 @@ import com.azure.core.util.polling.SyncPoller; import com.azure.resourcemanager.redisenterprise.fluent.RedisEnterprisesClient; import com.azure.resourcemanager.redisenterprise.fluent.models.ClusterInner; +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; import com.azure.resourcemanager.redisenterprise.models.ClusterList; import com.azure.resourcemanager.redisenterprise.models.ClusterUpdate; import java.nio.ByteBuffer; @@ -126,6 +128,15 @@ Mono> list(@HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId, @HeaderParam("Accept") String accept, Context context); + @Headers({ "Content-Type: application/json" }) + @Post("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Cache/redisEnterprise/{clusterName}/listSkusForScaling") + @ExpectedResponses({ 200 }) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listSkusForScaling(@HostParam("$host") String endpoint, + @PathParam("resourceGroupName") String resourceGroupName, @PathParam("clusterName") String clusterName, + @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId, + @HeaderParam("Accept") String accept, Context context); + @Headers({ "Content-Type: application/json" }) @Get("{nextLink}") @ExpectedResponses({ 200 }) @@ -146,7 +157,8 @@ Mono> listNext(@PathParam(value = "nextLink", encoded = tr * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -188,7 +200,8 @@ private Mono>> createWithResponseAsync(String resource * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -230,7 +243,8 @@ private Mono>> createWithResponseAsync(String resource * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -249,7 +263,8 @@ private PollerFlux, ClusterInner> beginCreateAsync(Stri * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -271,7 +286,8 @@ private PollerFlux, ClusterInner> beginCreateAsync(Stri * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -288,7 +304,8 @@ public SyncPoller, ClusterInner> beginCreate(String res * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -306,7 +323,8 @@ public SyncPoller, ClusterInner> beginCreate(String res * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -323,7 +341,8 @@ private Mono createAsync(String resourceGroupName, String clusterN * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -342,7 +361,8 @@ private Mono createAsync(String resourceGroupName, String clusterN * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -358,7 +378,8 @@ public ClusterInner create(String resourceGroupName, String clusterName, Cluster * Creates or updates an existing (overwrite/recreate, with potential downtime) cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Create Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -375,7 +396,8 @@ public ClusterInner create(String resourceGroupName, String clusterName, Cluster * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -417,7 +439,8 @@ private Mono>> updateWithResponseAsync(String resource * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -459,7 +482,8 @@ private Mono>> updateWithResponseAsync(String resource * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -478,7 +502,8 @@ private PollerFlux, ClusterInner> beginUpdateAsync(Stri * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -500,7 +525,8 @@ private PollerFlux, ClusterInner> beginUpdateAsync(Stri * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -517,7 +543,8 @@ public SyncPoller, ClusterInner> beginUpdate(String res * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -535,7 +562,8 @@ public SyncPoller, ClusterInner> beginUpdate(String res * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -552,7 +580,8 @@ private Mono updateAsync(String resourceGroupName, String clusterN * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -571,7 +600,8 @@ private Mono updateAsync(String resourceGroupName, String clusterN * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -587,7 +617,8 @@ public ClusterInner update(String resourceGroupName, String clusterName, Cluster * Updates an existing Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param parameters Parameters supplied to the Update Redis Enterprise operation. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -605,7 +636,8 @@ public ClusterInner update(String resourceGroupName, String clusterName, Cluster * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -639,7 +671,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -674,7 +707,8 @@ private Mono>> deleteWithResponseAsync(String resource * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -691,7 +725,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -711,7 +746,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -726,7 +762,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -743,7 +780,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -758,7 +796,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName) { * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -775,7 +814,8 @@ private Mono deleteAsync(String resourceGroupName, String clusterName, Con * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -789,7 +829,8 @@ public void delete(String resourceGroupName, String clusterName) { * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -804,7 +845,8 @@ public void delete(String resourceGroupName, String clusterName, Context context * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -840,7 +882,8 @@ private Mono> getByResourceGroupWithResponseAsync(String * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -876,7 +919,8 @@ private Mono> getByResourceGroupWithResponseAsync(String * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -892,7 +936,8 @@ private Mono getByResourceGroupAsync(String resourceGroupName, Str * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -909,7 +954,8 @@ public Response getByResourceGroupWithResponse(String resourceGrou * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -1157,6 +1203,131 @@ public PagedIterable list(Context context) { return new PagedIterable<>(listAsync(context)); } + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation along with {@link Response} on successful completion of + * {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSkusForScalingWithResponseAsync(String resourceGroupName, + String clusterName) { + if (this.client.getEndpoint() == null) { + return Mono.error( + new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (resourceGroupName == null) { + return Mono + .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); + } + if (clusterName == null) { + return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono.error(new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext(context -> service.listSkusForScaling(this.client.getEndpoint(), resourceGroupName, + clusterName, this.client.getApiVersion(), this.client.getSubscriptionId(), accept, context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation along with {@link Response} on successful completion of + * {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSkusForScalingWithResponseAsync(String resourceGroupName, + String clusterName, Context context) { + if (this.client.getEndpoint() == null) { + return Mono.error( + new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (resourceGroupName == null) { + return Mono + .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); + } + if (clusterName == null) { + return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono.error(new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service.listSkusForScaling(this.client.getEndpoint(), resourceGroupName, clusterName, + this.client.getApiVersion(), this.client.getSubscriptionId(), accept, context); + } + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono listSkusForScalingAsync(String resourceGroupName, String clusterName) { + return listSkusForScalingWithResponseAsync(resourceGroupName, clusterName) + .flatMap(res -> Mono.justOrEmpty(res.getValue())); + } + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response listSkusForScalingWithResponse(String resourceGroupName, String clusterName, + Context context) { + return listSkusForScalingWithResponseAsync(resourceGroupName, clusterName, context).block(); + } + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public SkuDetailsListInner listSkusForScaling(String resourceGroupName, String clusterName) { + return listSkusForScalingWithResponse(resourceGroupName, clusterName, Context.NONE).getValue(); + } + /** * Get the next page of items. * diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesImpl.java index 2406c8984176..8a4c8407dc97 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesImpl.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/RedisEnterprisesImpl.java @@ -11,8 +11,10 @@ import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.redisenterprise.fluent.RedisEnterprisesClient; import com.azure.resourcemanager.redisenterprise.fluent.models.ClusterInner; +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; import com.azure.resourcemanager.redisenterprise.models.Cluster; import com.azure.resourcemanager.redisenterprise.models.RedisEnterprises; +import com.azure.resourcemanager.redisenterprise.models.SkuDetailsList; public final class RedisEnterprisesImpl implements RedisEnterprises { private static final ClientLogger LOGGER = new ClientLogger(RedisEnterprisesImpl.class); @@ -76,6 +78,27 @@ public PagedIterable list(Context context) { return ResourceManagerUtils.mapPage(inner, inner1 -> new ClusterImpl(inner1, this.manager())); } + public Response listSkusForScalingWithResponse(String resourceGroupName, String clusterName, + Context context) { + Response inner + = this.serviceClient().listSkusForScalingWithResponse(resourceGroupName, clusterName, context); + if (inner != null) { + return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(), + new SkuDetailsListImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + + public SkuDetailsList listSkusForScaling(String resourceGroupName, String clusterName) { + SkuDetailsListInner inner = this.serviceClient().listSkusForScaling(resourceGroupName, clusterName); + if (inner != null) { + return new SkuDetailsListImpl(inner, this.manager()); + } else { + return null; + } + } + public Cluster getById(String id) { String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/SkuDetailsListImpl.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/SkuDetailsListImpl.java new file mode 100644 index 000000000000..09e33212c99c --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/implementation/SkuDetailsListImpl.java @@ -0,0 +1,40 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.implementation; + +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; +import com.azure.resourcemanager.redisenterprise.models.SkuDetails; +import com.azure.resourcemanager.redisenterprise.models.SkuDetailsList; +import java.util.Collections; +import java.util.List; + +public final class SkuDetailsListImpl implements SkuDetailsList { + private SkuDetailsListInner innerObject; + + private final com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager serviceManager; + + SkuDetailsListImpl(SkuDetailsListInner innerObject, + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + } + + public List skus() { + List inner = this.innerModel().skus(); + if (inner != null) { + return Collections.unmodifiableList(inner); + } else { + return Collections.emptyList(); + } + } + + public SkuDetailsListInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager() { + return this.serviceManager; + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignment.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignment.java index 1d84f3d1f0dc..95e943f0f63f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignment.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignment.java @@ -93,7 +93,8 @@ interface WithParentResource { * Specifies resourceGroupName, clusterName, databaseName. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @return the next definition stage. */ diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignments.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignments.java index 9dde182fb631..8efd50c3d1b6 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignments.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/AccessPolicyAssignments.java @@ -16,7 +16,8 @@ public interface AccessPolicyAssignments { * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -32,7 +33,8 @@ Response getWithResponse(String resourceGroupName, Strin * Gets information about access policy assignment for database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -47,7 +49,8 @@ AccessPolicyAssignment get(String resourceGroupName, String clusterName, String * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -60,7 +63,8 @@ AccessPolicyAssignment get(String resourceGroupName, String clusterName, String * Deletes a single access policy assignment. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param accessPolicyAssignmentName The name of the Redis Enterprise database access policy assignment. * @param context The context to associate with this operation. @@ -75,7 +79,8 @@ void delete(String resourceGroupName, String clusterName, String databaseName, S * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -88,7 +93,8 @@ void delete(String resourceGroupName, String clusterName, String databaseName, S * Gets all access policy assignments.. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Cluster.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Cluster.java index 4a4f2dbe61d8..fab80ee9d78b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Cluster.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Cluster.java @@ -4,6 +4,7 @@ package com.azure.resourcemanager.redisenterprise.models; +import com.azure.core.http.rest.Response; import com.azure.core.management.Region; import com.azure.core.util.Context; import com.azure.resourcemanager.redisenterprise.fluent.models.ClusterInner; @@ -49,6 +50,13 @@ public interface Cluster { */ Map tags(); + /** + * Gets the kind property: Distinguishes the kind of cluster. Read-only. + * + * @return the kind value. + */ + Kind kind(); + /** * Gets the sku property: The SKU to create, which affects price, performance, and features. * @@ -469,4 +477,24 @@ interface WithEncryption { * @return the refreshed resource. */ Cluster refresh(Context context); + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @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 response of a listSkusForScaling operation along with {@link Response}. + */ + Response listSkusForScalingWithResponse(Context context); + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @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 response of a listSkusForScaling operation. + */ + SkuDetailsList listSkusForScaling(); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ClusteringPolicy.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ClusteringPolicy.java index bc3c017e6fa5..8412fcd9eb8e 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ClusteringPolicy.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ClusteringPolicy.java @@ -8,8 +8,8 @@ import java.util.Collection; /** - * Clustering policy - default is OSSCluster. This property must be chosen at create time, and cannot be changed without - * deleting the database. + * Clustering policy - default is OSSCluster. This property can be updated only if the current value is NoCluster. If + * the value is OSSCluster or EnterpriseCluster, it cannot be updated without deleting the database. */ public final class ClusteringPolicy extends ExpandableStringEnum { /** @@ -22,6 +22,11 @@ public final class ClusteringPolicy extends ExpandableStringEnum getWithResponse(String resourceGroupName, String clusterName, * Gets information about a database in a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -69,7 +73,8 @@ Response getWithResponse(String resourceGroupName, String clusterName, * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -81,7 +86,8 @@ Response getWithResponse(String resourceGroupName, String clusterName, * Deletes a single database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -94,7 +100,8 @@ Response getWithResponse(String resourceGroupName, String clusterName, * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -109,7 +116,8 @@ Response listKeysWithResponse(String resourceGroupName, String clust * Retrieves the access keys for the Redis Enterprise database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -122,7 +130,8 @@ Response listKeysWithResponse(String resourceGroupName, String clust * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -137,7 +146,8 @@ AccessKeys regenerateKey(String resourceGroupName, String clusterName, String da * Regenerates the Redis Enterprise database's access keys. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Specifies which key to regenerate. * @param context The context to associate with this operation. @@ -153,7 +163,8 @@ AccessKeys regenerateKey(String resourceGroupName, String clusterName, String da * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -167,7 +178,8 @@ void importMethod(String resourceGroupName, String clusterName, String databaseN * Imports database files to target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for importing into the cluster. * @param context The context to associate with this operation. @@ -182,7 +194,8 @@ void importMethod(String resourceGroupName, String clusterName, String databaseN * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -195,7 +208,8 @@ void importMethod(String resourceGroupName, String clusterName, String databaseN * Exports a database file from target database. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Storage information for exporting into the cluster. * @param context The context to associate with this operation. @@ -210,7 +224,8 @@ void export(String resourceGroupName, String clusterName, String databaseName, E * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -224,7 +239,8 @@ void forceUnlink(String resourceGroupName, String clusterName, String databaseNa * Forcibly removes the link to the specified database resource. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -241,7 +257,8 @@ void forceUnlink(String resourceGroupName, String clusterName, String databaseNa * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -257,7 +274,8 @@ void forceLinkToReplicationGroup(String resourceGroupName, String clusterName, S * unavailable while rejoining the replication group. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the database to be unlinked. * @param context The context to associate with this operation. @@ -272,20 +290,21 @@ void forceLinkToReplicationGroup(String resourceGroupName, String clusterName, S * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. - * @param parameters Information identifying the databases to be flushed. * @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 flush(String resourceGroupName, String clusterName, String databaseName, FlushParameters parameters); + void flush(String resourceGroupName, String clusterName, String databaseName); /** * Flushes all the keys in this database and also from its linked databases. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param parameters Information identifying the databases to be flushed. * @param context The context to associate with this operation. @@ -300,7 +319,8 @@ void flush(String resourceGroupName, String clusterName, String databaseName, Fl * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -312,7 +332,8 @@ void flush(String resourceGroupName, String clusterName, String databaseName, Fl * Upgrades the database Redis version to the latest available. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param databaseName The name of the Redis Enterprise database. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParameters.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParameters.java index ccf408aa7d4f..7452890b623d 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParameters.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParameters.java @@ -11,7 +11,6 @@ import com.azure.json.JsonToken; import com.azure.json.JsonWriter; import java.io.IOException; -import java.util.List; /** * Parameters for reconfiguring active geo-replication, of an existing database that was previously unlinked from a @@ -20,16 +19,9 @@ @Fluent public final class ForceLinkParameters implements JsonSerializable { /* - * The name of the group of linked database resources. This should match the existing replication group name. + * Properties to configure geo replication for this database. */ - private String groupNickname; - - /* - * The resource IDs of the databases that are expected to be linked and included in the replication group. This - * parameter is used to validate that the linking is to the expected (unlinked) part of the replication group, if it - * is splintered. - */ - private List linkedDatabases; + private ForceLinkParametersGeoReplication geoReplication; /** * Creates an instance of ForceLinkParameters class. @@ -38,48 +30,22 @@ public ForceLinkParameters() { } /** - * Get the groupNickname property: The name of the group of linked database resources. This should match the - * existing replication group name. - * - * @return the groupNickname value. - */ - public String groupNickname() { - return this.groupNickname; - } - - /** - * Set the groupNickname property: The name of the group of linked database resources. This should match the - * existing replication group name. - * - * @param groupNickname the groupNickname value to set. - * @return the ForceLinkParameters object itself. - */ - public ForceLinkParameters withGroupNickname(String groupNickname) { - this.groupNickname = groupNickname; - return this; - } - - /** - * Get the linkedDatabases property: The resource IDs of the databases that are expected to be linked and included - * in the replication group. This parameter is used to validate that the linking is to the expected (unlinked) part - * of the replication group, if it is splintered. + * Get the geoReplication property: Properties to configure geo replication for this database. * - * @return the linkedDatabases value. + * @return the geoReplication value. */ - public List linkedDatabases() { - return this.linkedDatabases; + public ForceLinkParametersGeoReplication geoReplication() { + return this.geoReplication; } /** - * Set the linkedDatabases property: The resource IDs of the databases that are expected to be linked and included - * in the replication group. This parameter is used to validate that the linking is to the expected (unlinked) part - * of the replication group, if it is splintered. + * Set the geoReplication property: Properties to configure geo replication for this database. * - * @param linkedDatabases the linkedDatabases value to set. + * @param geoReplication the geoReplication value to set. * @return the ForceLinkParameters object itself. */ - public ForceLinkParameters withLinkedDatabases(List linkedDatabases) { - this.linkedDatabases = linkedDatabases; + public ForceLinkParameters withGeoReplication(ForceLinkParametersGeoReplication geoReplication) { + this.geoReplication = geoReplication; return this; } @@ -89,17 +55,12 @@ public ForceLinkParameters withLinkedDatabases(List linkedDataba * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (groupNickname() == null) { - throw LOGGER.atError() - .log(new IllegalArgumentException( - "Missing required property groupNickname in model ForceLinkParameters")); - } - if (linkedDatabases() == null) { + if (geoReplication() == null) { throw LOGGER.atError() .log(new IllegalArgumentException( - "Missing required property linkedDatabases in model ForceLinkParameters")); + "Missing required property geoReplication in model ForceLinkParameters")); } else { - linkedDatabases().forEach(e -> e.validate()); + geoReplication().validate(); } } @@ -111,9 +72,7 @@ public void validate() { @Override public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { jsonWriter.writeStartObject(); - jsonWriter.writeStringField("groupNickname", this.groupNickname); - jsonWriter.writeArrayField("linkedDatabases", this.linkedDatabases, - (writer, element) -> writer.writeJson(element)); + jsonWriter.writeJsonField("geoReplication", this.geoReplication); return jsonWriter.writeEndObject(); } @@ -133,12 +92,8 @@ public static ForceLinkParameters fromJson(JsonReader jsonReader) throws IOExcep String fieldName = reader.getFieldName(); reader.nextToken(); - if ("groupNickname".equals(fieldName)) { - deserializedForceLinkParameters.groupNickname = reader.getString(); - } else if ("linkedDatabases".equals(fieldName)) { - List linkedDatabases - = reader.readArray(reader1 -> LinkedDatabase.fromJson(reader1)); - deserializedForceLinkParameters.linkedDatabases = linkedDatabases; + if ("geoReplication".equals(fieldName)) { + deserializedForceLinkParameters.geoReplication = ForceLinkParametersGeoReplication.fromJson(reader); } else { reader.skipChildren(); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParametersGeoReplication.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParametersGeoReplication.java new file mode 100644 index 000000000000..9d611ef50c1b --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceLinkParametersGeoReplication.java @@ -0,0 +1,137 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.models; + +import com.azure.core.annotation.Fluent; +import com.azure.json.JsonReader; +import com.azure.json.JsonSerializable; +import com.azure.json.JsonToken; +import com.azure.json.JsonWriter; +import java.io.IOException; +import java.util.List; + +/** + * Properties to configure geo replication for this database. + */ +@Fluent +public final class ForceLinkParametersGeoReplication implements JsonSerializable { + /* + * The name of the group of linked database resources. This should match the existing replication group name. + */ + private String groupNickname; + + /* + * The resource IDs of the databases that are expected to be linked and included in the replication group. This + * parameter is used to validate that the linking is to the expected (unlinked) part of the replication group, if it + * is splintered. + */ + private List linkedDatabases; + + /** + * Creates an instance of ForceLinkParametersGeoReplication class. + */ + public ForceLinkParametersGeoReplication() { + } + + /** + * Get the groupNickname property: The name of the group of linked database resources. This should match the + * existing replication group name. + * + * @return the groupNickname value. + */ + public String groupNickname() { + return this.groupNickname; + } + + /** + * Set the groupNickname property: The name of the group of linked database resources. This should match the + * existing replication group name. + * + * @param groupNickname the groupNickname value to set. + * @return the ForceLinkParametersGeoReplication object itself. + */ + public ForceLinkParametersGeoReplication withGroupNickname(String groupNickname) { + this.groupNickname = groupNickname; + return this; + } + + /** + * Get the linkedDatabases property: The resource IDs of the databases that are expected to be linked and included + * in the replication group. This parameter is used to validate that the linking is to the expected (unlinked) part + * of the replication group, if it is splintered. + * + * @return the linkedDatabases value. + */ + public List linkedDatabases() { + return this.linkedDatabases; + } + + /** + * Set the linkedDatabases property: The resource IDs of the databases that are expected to be linked and included + * in the replication group. This parameter is used to validate that the linking is to the expected (unlinked) part + * of the replication group, if it is splintered. + * + * @param linkedDatabases the linkedDatabases value to set. + * @return the ForceLinkParametersGeoReplication object itself. + */ + public ForceLinkParametersGeoReplication withLinkedDatabases(List linkedDatabases) { + this.linkedDatabases = linkedDatabases; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (linkedDatabases() != null) { + linkedDatabases().forEach(e -> e.validate()); + } + } + + /** + * {@inheritDoc} + */ + @Override + public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { + jsonWriter.writeStartObject(); + jsonWriter.writeStringField("groupNickname", this.groupNickname); + jsonWriter.writeArrayField("linkedDatabases", this.linkedDatabases, + (writer, element) -> writer.writeJson(element)); + return jsonWriter.writeEndObject(); + } + + /** + * Reads an instance of ForceLinkParametersGeoReplication from the JsonReader. + * + * @param jsonReader The JsonReader being read. + * @return An instance of ForceLinkParametersGeoReplication if the JsonReader was pointing to an instance of it, or + * null if it was pointing to JSON null. + * @throws IOException If an error occurs while reading the ForceLinkParametersGeoReplication. + */ + public static ForceLinkParametersGeoReplication fromJson(JsonReader jsonReader) throws IOException { + return jsonReader.readObject(reader -> { + ForceLinkParametersGeoReplication deserializedForceLinkParametersGeoReplication + = new ForceLinkParametersGeoReplication(); + while (reader.nextToken() != JsonToken.END_OBJECT) { + String fieldName = reader.getFieldName(); + reader.nextToken(); + + if ("groupNickname".equals(fieldName)) { + deserializedForceLinkParametersGeoReplication.groupNickname = reader.getString(); + } else if ("linkedDatabases".equals(fieldName)) { + List linkedDatabases + = reader.readArray(reader1 -> LinkedDatabase.fromJson(reader1)); + deserializedForceLinkParametersGeoReplication.linkedDatabases = linkedDatabases; + } else { + reader.skipChildren(); + } + } + + return deserializedForceLinkParametersGeoReplication; + }); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceUnlinkParameters.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceUnlinkParameters.java index 15890a62072b..a9adc1a3409d 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceUnlinkParameters.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ForceUnlinkParameters.java @@ -16,7 +16,7 @@ /** * Forcibly unlink another database from this database. * - * Parameters for a redis enterprise active geo-replication force unlink operation. + * Parameters for a Redis Enterprise Active Geo Replication Force Unlink operation. */ @Fluent public final class ForceUnlinkParameters implements JsonSerializable { diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Kind.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Kind.java new file mode 100644 index 000000000000..e9358c3f059e --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/Kind.java @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.models; + +import com.azure.core.util.ExpandableStringEnum; +import java.util.Collection; + +/** + * Distinguishes the kind of cluster. Read-only. + */ +public final class Kind extends ExpandableStringEnum { + /** + * Static value v1 for Kind. + */ + public static final Kind V1 = fromString("v1"); + + /** + * Static value v2 for Kind. + */ + public static final Kind V2 = fromString("v2"); + + /** + * Creates a new instance of Kind value. + * + * @deprecated Use the {@link #fromString(String)} factory method. + */ + @Deprecated + public Kind() { + } + + /** + * Creates or finds a Kind from its string representation. + * + * @param name a name to look for. + * @return the corresponding Kind. + */ + public static Kind fromString(String name) { + return fromString(name, Kind.class); + } + + /** + * Gets known Kind values. + * + * @return known Kind values. + */ + public static Collection values() { + return values(Kind.class); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnection.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnection.java index 214cf89d5b31..ee33840df7be 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnection.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnection.java @@ -93,7 +93,8 @@ interface WithParentResource { * Specifies resourceGroupName, clusterName. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @return the next definition stage. */ WithCreate withExistingRedisEnterprise(String resourceGroupName, String clusterName); diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnections.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnections.java index a6ab0bc463f8..e2b84574f0d8 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnections.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateEndpointConnections.java @@ -16,7 +16,8 @@ public interface PrivateEndpointConnections { * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -29,7 +30,8 @@ public interface PrivateEndpointConnections { * Lists all the private endpoint connections associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -43,7 +45,8 @@ public interface PrivateEndpointConnections { * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. @@ -60,7 +63,8 @@ Response getWithResponse(String resourceGroupName, St * Gets the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -74,7 +78,8 @@ Response getWithResponse(String resourceGroupName, St * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -87,7 +92,8 @@ Response getWithResponse(String resourceGroupName, St * Deletes the specified private endpoint connection associated with the Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the Azure * resource. * @param context The context to associate with this operation. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateLinkResources.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateLinkResources.java index 2b1cd723fd4d..e17dcf7c8251 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateLinkResources.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/PrivateLinkResources.java @@ -15,7 +15,8 @@ public interface PrivateLinkResources { * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -28,7 +29,8 @@ public interface PrivateLinkResources { * Gets the private link resources that need to be created for a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/RedisEnterprises.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/RedisEnterprises.java index e4ec8ca91da8..efcd70cdc09e 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/RedisEnterprises.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/RedisEnterprises.java @@ -16,7 +16,8 @@ public interface RedisEnterprises { * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -27,7 +28,8 @@ public interface RedisEnterprises { * Deletes a Redis Enterprise cache cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -39,7 +41,8 @@ public interface RedisEnterprises { * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -52,7 +55,8 @@ public interface RedisEnterprises { * Gets information about a Redis Enterprise cluster. * * @param resourceGroupName The name of the resource group. The name is case insensitive. - * @param clusterName The name of the Redis Enterprise cluster. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. * @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. @@ -103,6 +107,34 @@ public interface RedisEnterprises { */ PagedIterable list(Context context); + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation along with {@link Response}. + */ + Response listSkusForScalingWithResponse(String resourceGroupName, String clusterName, + Context context); + + /** + * Lists the available SKUs for scaling the Redis Enterprise cluster. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param clusterName The name of the Redis Enterprise cluster. Name must be 1-60 characters long. Allowed + * characters(A-Z, a-z, 0-9) and hyphen(-). There can be no leading nor trailing nor consecutive hyphens. + * @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 response of a listSkusForScaling operation. + */ + SkuDetailsList listSkusForScaling(String resourceGroupName, String clusterName); + /** * Gets information about a Redis Enterprise cluster. * diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ResourceState.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ResourceState.java index a1ea31462b84..224669048cd6 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ResourceState.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/ResourceState.java @@ -81,6 +81,11 @@ public final class ResourceState extends ExpandableStringEnum { */ public static final ResourceState SCALING_FAILED = fromString("ScalingFailed"); + /** + * Static value Moving for ResourceState. + */ + public static final ResourceState MOVING = fromString("Moving"); + /** * Creates a new instance of ResourceState value. * diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetails.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetails.java new file mode 100644 index 000000000000..ddd37c2259a6 --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetails.java @@ -0,0 +1,99 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.models; + +import com.azure.core.annotation.Immutable; +import com.azure.json.JsonReader; +import com.azure.json.JsonSerializable; +import com.azure.json.JsonToken; +import com.azure.json.JsonWriter; +import java.io.IOException; + +/** + * SKU details + * + * Details of a Redis Enterprise cluster SKU. + */ +@Immutable +public final class SkuDetails implements JsonSerializable { + /* + * The name of the SKU. + */ + private String name; + + /* + * The cache size in GB. + */ + private Float sizeInGB; + + /** + * Creates an instance of SkuDetails class. + */ + public SkuDetails() { + } + + /** + * Get the name property: The name of the SKU. + * + * @return the name value. + */ + public String name() { + return this.name; + } + + /** + * Get the sizeInGB property: The cache size in GB. + * + * @return the sizeInGB value. + */ + public Float sizeInGB() { + return this.sizeInGB; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } + + /** + * {@inheritDoc} + */ + @Override + public JsonWriter toJson(JsonWriter jsonWriter) throws IOException { + jsonWriter.writeStartObject(); + return jsonWriter.writeEndObject(); + } + + /** + * Reads an instance of SkuDetails from the JsonReader. + * + * @param jsonReader The JsonReader being read. + * @return An instance of SkuDetails if the JsonReader was pointing to an instance of it, or null if it was pointing + * to JSON null. + * @throws IOException If an error occurs while reading the SkuDetails. + */ + public static SkuDetails fromJson(JsonReader jsonReader) throws IOException { + return jsonReader.readObject(reader -> { + SkuDetails deserializedSkuDetails = new SkuDetails(); + while (reader.nextToken() != JsonToken.END_OBJECT) { + String fieldName = reader.getFieldName(); + reader.nextToken(); + + if ("name".equals(fieldName)) { + deserializedSkuDetails.name = reader.getString(); + } else if ("sizeInGB".equals(fieldName)) { + deserializedSkuDetails.sizeInGB = reader.getNullable(JsonReader::getFloat); + } else { + reader.skipChildren(); + } + } + + return deserializedSkuDetails; + }); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetailsList.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetailsList.java new file mode 100644 index 000000000000..59bc3a8ae603 --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/java/com/azure/resourcemanager/redisenterprise/models/SkuDetailsList.java @@ -0,0 +1,27 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.models; + +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; +import java.util.List; + +/** + * An immutable client-side representation of SkuDetailsList. + */ +public interface SkuDetailsList { + /** + * Gets the skus property: List of SKUS available to scale up or scale down. + * + * @return the skus value. + */ + List skus(); + + /** + * Gets the inner com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner object. + * + * @return the inner object. + */ + SkuDetailsListInner innerModel(); +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/resources/azure-resourcemanager-redisenterprise.properties b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/resources/azure-resourcemanager-redisenterprise.properties new file mode 100644 index 000000000000..defbd48204e4 --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/main/resources/azure-resourcemanager-redisenterprise.properties @@ -0,0 +1 @@ +version=${project.version} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentCreateUpdateSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentCreateUpdateSamples.java index dff12f6746b2..d2f4926a0eac 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentCreateUpdateSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentCreateUpdateSamples.java @@ -12,7 +12,7 @@ public final class AccessPolicyAssignmentCreateUpdateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseAccessPolicyAssignmentCreateUpdate.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentDeleteSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentDeleteSamples.java index 45ad72c3e8dc..1a169bf1c8e1 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentDeleteSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentDeleteSamples.java @@ -10,7 +10,7 @@ public final class AccessPolicyAssignmentDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseAccessPolicyAssignmentDelete.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentGetSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentGetSamples.java index 37c74ac54f35..594940cd6ebf 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentGetSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentGetSamples.java @@ -10,7 +10,7 @@ public final class AccessPolicyAssignmentGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseAccessPolicyAssignmentGet.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListSamples.java index ca715464d8a5..ab762cf3242a 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListSamples.java @@ -10,7 +10,7 @@ public final class AccessPolicyAssignmentListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseAccessPolicyAssignmentsList.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesCreateSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesCreateSamples.java index f907d88474ab..7b00e1367ca9 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesCreateSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesCreateSamples.java @@ -22,7 +22,29 @@ public final class DatabasesCreateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesNoClusterCacheCreate.json + */ + /** + * Sample code: RedisEnterpriseDatabasesCreate No Cluster Cache. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void redisEnterpriseDatabasesCreateNoClusterCache( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.databases() + .define("default") + .withExistingRedisEnterprise("rg1", "cache1") + .withClientProtocol(Protocol.ENCRYPTED) + .withPort(10000) + .withClusteringPolicy(ClusteringPolicy.NO_CLUSTER) + .withEvictionPolicy(EvictionPolicy.NO_EVICTION) + .create(); + } + + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesCreate.json */ /** @@ -50,7 +72,7 @@ public final class DatabasesCreateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesCreateWithGeoReplication.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteSamples.java index 751d4451a9e6..1fa74daea05f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteSamples.java @@ -10,7 +10,7 @@ public final class DatabasesDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesDelete.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportSamples.java index 0fc0965679cd..7c45a2b7f3ce 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportSamples.java @@ -12,7 +12,7 @@ public final class DatabasesExportSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesExport.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushSamples.java index 0a6cdf0573ec..d82f089f1273 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushSamples.java @@ -13,7 +13,7 @@ public final class DatabasesFlushSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesFlush.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceLinkToReplicationGroupSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceLinkToReplicationGroupSamples.java index 0daedac6faa9..7291ac863621 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceLinkToReplicationGroupSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceLinkToReplicationGroupSamples.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.redisenterprise.generated; import com.azure.resourcemanager.redisenterprise.models.ForceLinkParameters; +import com.azure.resourcemanager.redisenterprise.models.ForceLinkParametersGeoReplication; import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; import java.util.Arrays; @@ -14,7 +15,7 @@ public final class DatabasesForceLinkToReplicationGroupSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesForceLink.json */ /** @@ -25,12 +26,13 @@ public final class DatabasesForceLinkToReplicationGroupSamples { public static void howToRelinkADatabaseAfterARegionalOutage( com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { manager.databases() - .forceLinkToReplicationGroup("rg1", "cache1", "default", new ForceLinkParameters() - .withGroupNickname("groupName") - .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( - "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), - new LinkedDatabase().withId( - "/subscriptions/11111111-1111-1111-1111-111111111111/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default"))), + .forceLinkToReplicationGroup("rg1", "cache1", "default", + new ForceLinkParameters().withGeoReplication(new ForceLinkParametersGeoReplication() + .withGroupNickname("groupName") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Cache/redisEnterprise/cache1/databases/default"), + new LinkedDatabase().withId( + "/subscriptions/11111111-1111-1111-1111-111111111111/resourceGroups/rg2/providers/Microsoft.Cache/redisEnterprise/cache2/databases/default")))), com.azure.core.util.Context.NONE); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkSamples.java index df80e25d2cd0..18ed938792a0 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkSamples.java @@ -13,7 +13,7 @@ public final class DatabasesForceUnlinkSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesForceUnlink.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesGetSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesGetSamples.java index d6f40f954ed3..782d11ec8c8b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesGetSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesGetSamples.java @@ -10,7 +10,7 @@ public final class DatabasesGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesGet.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodSamples.java index 21b85e39e87c..68061f02c677 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodSamples.java @@ -13,7 +13,7 @@ public final class DatabasesImportMethodSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesImport.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListByClusterSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListByClusterSamples.java index c783abc1c0f1..5b96d153039f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListByClusterSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListByClusterSamples.java @@ -10,7 +10,7 @@ public final class DatabasesListByClusterSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesListByCluster.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListKeysSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListKeysSamples.java index 3863366009ff..fc3b2a50af83 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListKeysSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesListKeysSamples.java @@ -10,7 +10,7 @@ public final class DatabasesListKeysSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesListKeys.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesRegenerateKeySamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesRegenerateKeySamples.java index 89a19d7222fe..bfa74dd1c67b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesRegenerateKeySamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesRegenerateKeySamples.java @@ -13,7 +13,7 @@ public final class DatabasesRegenerateKeySamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesRegenerateKey.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpdateSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpdateSamples.java index 41d74d943ed5..ec96a3a9952a 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpdateSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpdateSamples.java @@ -5,6 +5,7 @@ package com.azure.resourcemanager.redisenterprise.generated; import com.azure.resourcemanager.redisenterprise.models.AccessKeysAuthentication; +import com.azure.resourcemanager.redisenterprise.models.ClusteringPolicy; import com.azure.resourcemanager.redisenterprise.models.Database; import com.azure.resourcemanager.redisenterprise.models.EvictionPolicy; import com.azure.resourcemanager.redisenterprise.models.Persistence; @@ -17,7 +18,29 @@ public final class DatabasesUpdateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseDatabasesNoClusterCacheUpdateClustering.json + */ + /** + * Sample code: RedisEnterpriseDatabasesUpdate Clustering on No Cluster Cache. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void redisEnterpriseDatabasesUpdateClusteringOnNoClusterCache( + com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + Database resource = manager.databases() + .getWithResponse("rg1", "cache1", "default", com.azure.core.util.Context.NONE) + .getValue(); + resource.update() + .withClientProtocol(Protocol.ENCRYPTED) + .withClusteringPolicy(ClusteringPolicy.ENTERPRISE_CLUSTER) + .withEvictionPolicy(EvictionPolicy.NO_EVICTION) + .apply(); + } + + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesUpdate.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpgradeDBRedisVersionSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpgradeDBRedisVersionSamples.java index 9c998f4b32fd..f47484eafc3f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpgradeDBRedisVersionSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesUpgradeDBRedisVersionSamples.java @@ -10,7 +10,7 @@ public final class DatabasesUpgradeDBRedisVersionSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDatabasesUpgradeDBRedisVersion.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListSamples.java index 0445a6c5d055..330faf8164d7 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListSamples.java @@ -10,7 +10,7 @@ public final class OperationsListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/OperationsList + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/OperationsList * .json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsStatusGetSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsStatusGetSamples.java index dbf91af2ee2d..dce97439c455 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsStatusGetSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/OperationsStatusGetSamples.java @@ -10,7 +10,7 @@ public final class OperationsStatusGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * OperationsStatusGet.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteSamples.java index a0a415710d7a..89e92a84e840 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteSamples.java @@ -10,7 +10,7 @@ public final class PrivateEndpointConnectionsDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDeletePrivateEndpointConnection.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetSamples.java index bb4c69962051..9a30131b1d20 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetSamples.java @@ -10,7 +10,7 @@ public final class PrivateEndpointConnectionsGetSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseGetPrivateEndpointConnection.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListSamples.java index e3dfbec47cb3..84ad63edba76 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListSamples.java @@ -10,7 +10,7 @@ public final class PrivateEndpointConnectionsListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseListPrivateEndpointConnections.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsPutSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsPutSamples.java index 26221cca0eec..3c12eaef5ba2 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsPutSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsPutSamples.java @@ -13,7 +13,7 @@ public final class PrivateEndpointConnectionsPutSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterprisePutPrivateEndpointConnection.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterSamples.java index f148702fe729..e123dc05a712 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterSamples.java @@ -10,7 +10,7 @@ public final class PrivateLinkResourcesListByClusterSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseListPrivateLinkResources.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseCreateSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseCreateSamples.java index d6031092a022..e570836772cc 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseCreateSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseCreateSamples.java @@ -24,7 +24,7 @@ public final class RedisEnterpriseCreateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseCreate.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseDeleteSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseDeleteSamples.java index fcf932ac98d6..207ef342b14b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseDeleteSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseDeleteSamples.java @@ -10,7 +10,7 @@ public final class RedisEnterpriseDeleteSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseDelete.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseGetByResourceGroupSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseGetByResourceGroupSamples.java index f52f577a4587..a484127570e4 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseGetByResourceGroupSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseGetByResourceGroupSamples.java @@ -10,7 +10,7 @@ public final class RedisEnterpriseGetByResourceGroupSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseGet.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListByResourceGroupSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListByResourceGroupSamples.java index 6ccadcc5604e..38d80f4f53c1 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListByResourceGroupSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListByResourceGroupSamples.java @@ -10,7 +10,7 @@ public final class RedisEnterpriseListByResourceGroupSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseListByResourceGroup.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSamples.java index bad1781874ce..283051d5ccbf 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSamples.java @@ -10,7 +10,7 @@ public final class RedisEnterpriseListSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseList.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSkusForScalingSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSkusForScalingSamples.java new file mode 100644 index 000000000000..f7697c723d8a --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseListSkusForScalingSamples.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.generated; + +/** + * Samples for RedisEnterprise ListSkusForScaling. + */ +public final class RedisEnterpriseListSkusForScalingSamples { + /* + * x-ms-original-file: + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ + * RedisEnterpriseListSkusForScaling.json + */ + /** + * Sample code: RedisEnterpriseListSkusForScaling. + * + * @param manager Entry point to RedisEnterpriseManager. + */ + public static void + redisEnterpriseListSkusForScaling(com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager manager) { + manager.redisEnterprises().listSkusForScalingWithResponse("rg1", "cache1", com.azure.core.util.Context.NONE); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseUpdateSamples.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseUpdateSamples.java index 9793adc74208..a39f6828c087 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseUpdateSamples.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/samples/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterpriseUpdateSamples.java @@ -17,7 +17,7 @@ public final class RedisEnterpriseUpdateSamples { /* * x-ms-original-file: - * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2024-09-01-preview/examples/ + * specification/redisenterprise/resource-manager/Microsoft.Cache/preview/2025-05-01-preview/examples/ * RedisEnterpriseUpdate.json */ /** diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentInnerTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentInnerTests.java index 724cf999c110..1d920a327896 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentInnerTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentInnerTests.java @@ -13,18 +13,18 @@ public final class AccessPolicyAssignmentInnerTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { AccessPolicyAssignmentInner model = BinaryData.fromString( - "{\"properties\":{\"provisioningState\":\"Updating\",\"accessPolicyName\":\"pxokajionp\",\"user\":{\"objectId\":\"ex\"}},\"id\":\"stxgc\",\"name\":\"odgmaajrmvdjwz\",\"type\":\"lovmclwhijcoe\"}") + "{\"properties\":{\"provisioningState\":\"Updating\",\"accessPolicyName\":\"jmkljavbqidtqajz\",\"user\":{\"objectId\":\"l\"}},\"id\":\"kudjkrlkhb\",\"name\":\"hfepgzgqex\",\"type\":\"locx\"}") .toObject(AccessPolicyAssignmentInner.class); - Assertions.assertEquals("pxokajionp", model.accessPolicyName()); - Assertions.assertEquals("ex", model.user().objectId()); + Assertions.assertEquals("jmkljavbqidtqajz", model.accessPolicyName()); + Assertions.assertEquals("l", model.user().objectId()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - AccessPolicyAssignmentInner model = new AccessPolicyAssignmentInner().withAccessPolicyName("pxokajionp") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("ex")); + AccessPolicyAssignmentInner model = new AccessPolicyAssignmentInner().withAccessPolicyName("jmkljavbqidtqajz") + .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("l")); model = BinaryData.fromObject(model).toObject(AccessPolicyAssignmentInner.class); - Assertions.assertEquals("pxokajionp", model.accessPolicyName()); - Assertions.assertEquals("ex", model.user().objectId()); + Assertions.assertEquals("jmkljavbqidtqajz", model.accessPolicyName()); + Assertions.assertEquals("l", model.user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListTests.java index a88c31ca2a6a..8853182b7c5b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentListTests.java @@ -15,25 +15,19 @@ public final class AccessPolicyAssignmentListTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { AccessPolicyAssignmentList model = BinaryData.fromString( - "{\"value\":[{\"properties\":{\"provisioningState\":\"Deleting\",\"accessPolicyName\":\"ddtocjjxhvp\",\"user\":{\"objectId\":\"uexhdzx\"}},\"id\":\"bqe\",\"name\":\"jnxqbzvddntwn\",\"type\":\"eic\"},{\"properties\":{\"provisioningState\":\"Canceled\",\"accessPolicyName\":\"pzaoqvuhr\",\"user\":{\"objectId\":\"f\"}},\"id\":\"cyddglmjthjqk\",\"name\":\"pyeicxm\",\"type\":\"ciwqvhk\"},{\"properties\":{\"provisioningState\":\"Creating\",\"accessPolicyName\":\"igdtopbob\",\"user\":{\"objectId\":\"ghmewuam\"}},\"id\":\"uhrzayvvt\",\"name\":\"gvdfgiotkftutq\",\"type\":\"ln\"},{\"properties\":{\"provisioningState\":\"Deleting\",\"accessPolicyName\":\"fgugnxkrxdqmid\",\"user\":{\"objectId\":\"hzrvqd\"}},\"id\":\"abhjybi\",\"name\":\"ehoqfbowskan\",\"type\":\"ktzlcuiywg\"}],\"nextLink\":\"wgndrvynhzgpp\"}") + "{\"value\":[{\"properties\":{\"provisioningState\":\"Updating\",\"accessPolicyName\":\"xobnbdxkqpxok\",\"user\":{\"objectId\":\"ionpimexg\"}},\"id\":\"txgcpodgmaajr\",\"name\":\"vdjwzrlovm\",\"type\":\"lwhijcoejctbzaq\"}],\"nextLink\":\"sycbkbfk\"}") .toObject(AccessPolicyAssignmentList.class); - Assertions.assertEquals("ddtocjjxhvp", model.value().get(0).accessPolicyName()); - Assertions.assertEquals("uexhdzx", model.value().get(0).user().objectId()); + Assertions.assertEquals("xobnbdxkqpxok", model.value().get(0).accessPolicyName()); + Assertions.assertEquals("ionpimexg", model.value().get(0).user().objectId()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - AccessPolicyAssignmentList model = new AccessPolicyAssignmentList().withValue(Arrays.asList( - new AccessPolicyAssignmentInner().withAccessPolicyName("ddtocjjxhvp") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("uexhdzx")), - new AccessPolicyAssignmentInner().withAccessPolicyName("pzaoqvuhr") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("f")), - new AccessPolicyAssignmentInner().withAccessPolicyName("igdtopbob") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("ghmewuam")), - new AccessPolicyAssignmentInner().withAccessPolicyName("fgugnxkrxdqmid") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("hzrvqd")))); + AccessPolicyAssignmentList model = new AccessPolicyAssignmentList() + .withValue(Arrays.asList(new AccessPolicyAssignmentInner().withAccessPolicyName("xobnbdxkqpxok") + .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("ionpimexg")))); model = BinaryData.fromObject(model).toObject(AccessPolicyAssignmentList.class); - Assertions.assertEquals("ddtocjjxhvp", model.value().get(0).accessPolicyName()); - Assertions.assertEquals("uexhdzx", model.value().get(0).user().objectId()); + Assertions.assertEquals("xobnbdxkqpxok", model.value().get(0).accessPolicyName()); + Assertions.assertEquals("ionpimexg", model.value().get(0).user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesTests.java index 1dea07b71cc8..06fc6212a3bd 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesTests.java @@ -12,20 +12,20 @@ public final class AccessPolicyAssignmentPropertiesTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - AccessPolicyAssignmentProperties model = BinaryData.fromString( - "{\"provisioningState\":\"Updating\",\"accessPolicyName\":\"bzaqsqsycbkbfk\",\"user\":{\"objectId\":\"kdkexxp\"}}") + AccessPolicyAssignmentProperties model = BinaryData + .fromString( + "{\"provisioningState\":\"Updating\",\"accessPolicyName\":\"aierhhb\",\"user\":{\"objectId\":\"glu\"}}") .toObject(AccessPolicyAssignmentProperties.class); - Assertions.assertEquals("bzaqsqsycbkbfk", model.accessPolicyName()); - Assertions.assertEquals("kdkexxp", model.user().objectId()); + Assertions.assertEquals("aierhhb", model.accessPolicyName()); + Assertions.assertEquals("glu", model.user().objectId()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - AccessPolicyAssignmentProperties model - = new AccessPolicyAssignmentProperties().withAccessPolicyName("bzaqsqsycbkbfk") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("kdkexxp")); + AccessPolicyAssignmentProperties model = new AccessPolicyAssignmentProperties().withAccessPolicyName("aierhhb") + .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("glu")); model = BinaryData.fromObject(model).toObject(AccessPolicyAssignmentProperties.class); - Assertions.assertEquals("bzaqsqsycbkbfk", model.accessPolicyName()); - Assertions.assertEquals("kdkexxp", model.user().objectId()); + Assertions.assertEquals("aierhhb", model.accessPolicyName()); + Assertions.assertEquals("glu", model.user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesUserTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesUserTests.java index b3aad160de91..f489505e8bde 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesUserTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentPropertiesUserTests.java @@ -12,14 +12,14 @@ public final class AccessPolicyAssignmentPropertiesUserTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { AccessPolicyAssignmentPropertiesUser model - = BinaryData.fromString("{\"objectId\":\"fmxa\"}").toObject(AccessPolicyAssignmentPropertiesUser.class); - Assertions.assertEquals("fmxa", model.objectId()); + = BinaryData.fromString("{\"objectId\":\"a\"}").toObject(AccessPolicyAssignmentPropertiesUser.class); + Assertions.assertEquals("a", model.objectId()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - AccessPolicyAssignmentPropertiesUser model = new AccessPolicyAssignmentPropertiesUser().withObjectId("fmxa"); + AccessPolicyAssignmentPropertiesUser model = new AccessPolicyAssignmentPropertiesUser().withObjectId("a"); model = BinaryData.fromObject(model).toObject(AccessPolicyAssignmentPropertiesUser.class); - Assertions.assertEquals("fmxa", model.objectId()); + Assertions.assertEquals("a", model.objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsCreateUpdateMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsCreateUpdateMockTests.java index e35a10b524f4..c4c6af4a4525 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsCreateUpdateMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsCreateUpdateMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.AccessPolicyAssignment; @@ -22,23 +22,23 @@ public final class AccessPolicyAssignmentsCreateUpdateMockTests { @Test public void testCreateUpdate() throws Exception { String responseStr - = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"accessPolicyName\":\"mvb\",\"user\":{\"objectId\":\"yjsflhhcaalnji\"}},\"id\":\"isxyawjoyaqcslyj\",\"name\":\"kiidzyex\",\"type\":\"nelixhnrztfo\"}"; + = "{\"properties\":{\"provisioningState\":\"Succeeded\",\"accessPolicyName\":\"vzunluthnnprnxi\",\"user\":{\"objectId\":\"ilpjzuaejxdult\"}},\"id\":\"kzbbtd\",\"name\":\"umveekgpwozuhkf\",\"type\":\"bsjyofdx\"}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); AccessPolicyAssignment response = manager.accessPolicyAssignments() - .define("ultskzbbtdz") - .withExistingDatabase("vawjvzunlu", "hnnpr", "xipeilpjzuaejx") - .withAccessPolicyName("ekg") - .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("ozuhkfp")) + .define("bexrmcq") + .withExistingDatabase("mtsavjcbpwxqp", "rknftguvriuhprwm", "yvxqtayriwwroy") + .withAccessPolicyName("nojvknmefqsg") + .withUser(new AccessPolicyAssignmentPropertiesUser().withObjectId("ah")) .create(); - Assertions.assertEquals("mvb", response.accessPolicyName()); - Assertions.assertEquals("yjsflhhcaalnji", response.user().objectId()); + Assertions.assertEquals("vzunluthnnprnxi", response.accessPolicyName()); + Assertions.assertEquals("ilpjzuaejxdult", response.user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsGetWithResponseMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsGetWithResponseMockTests.java index 13a42574333d..0832bd586627 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsGetWithResponseMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsGetWithResponseMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.AccessPolicyAssignment; @@ -21,20 +21,20 @@ public final class AccessPolicyAssignmentsGetWithResponseMockTests { @Test public void testGetWithResponse() throws Exception { String responseStr - = "{\"properties\":{\"provisioningState\":\"Failed\",\"accessPolicyName\":\"vlvqhjkbegi\",\"user\":{\"objectId\":\"nmxiebwwaloayqc\"}},\"id\":\"wrtz\",\"name\":\"uzgwyzmhtx\",\"type\":\"ngmtsavjcb\"}"; + = "{\"properties\":{\"provisioningState\":\"Creating\",\"accessPolicyName\":\"dauwhvylwzbtd\",\"user\":{\"objectId\":\"ujznb\"}},\"id\":\"pow\",\"name\":\"wpr\",\"type\":\"qlveualupjmkh\"}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); AccessPolicyAssignment response = manager.accessPolicyAssignments() - .getWithResponse("upjm", "hfxobbcswsrtj", "iplrbpbewtghfgb", "c", com.azure.core.util.Context.NONE) + .getWithResponse("gxhnisk", "fbkp", "cg", "lwn", com.azure.core.util.Context.NONE) .getValue(); - Assertions.assertEquals("vlvqhjkbegi", response.accessPolicyName()); - Assertions.assertEquals("nmxiebwwaloayqc", response.user().objectId()); + Assertions.assertEquals("dauwhvylwzbtd", response.accessPolicyName()); + Assertions.assertEquals("ujznb", response.user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsListMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsListMockTests.java index 2521a91a74ba..a451ac18871d 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsListMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/AccessPolicyAssignmentsListMockTests.java @@ -7,8 +7,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; import com.azure.core.http.rest.PagedIterable; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.AccessPolicyAssignment; @@ -22,19 +22,19 @@ public final class AccessPolicyAssignmentsListMockTests { @Test public void testList() throws Exception { String responseStr - = "{\"value\":[{\"properties\":{\"provisioningState\":\"Creating\",\"accessPolicyName\":\"yqbexrmcqibycno\",\"user\":{\"objectId\":\"knme\"}},\"id\":\"qsgzvahapj\",\"name\":\"zhpvgqzcjrvxd\",\"type\":\"zlmwlxkvugfhz\"}]}"; + = "{\"value\":[{\"properties\":{\"provisioningState\":\"Succeeded\",\"accessPolicyName\":\"xzvlvqhjkbegib\",\"user\":{\"objectId\":\"mxiebw\"}},\"id\":\"aloayqcgwrtzju\",\"name\":\"gwyzm\",\"type\":\"txon\"}]}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); PagedIterable response = manager.accessPolicyAssignments() - .list("wxqpsrknftguvri", "hprwmdyv", "qtayri", com.azure.core.util.Context.NONE); + .list("xobbcswsrt", "riplrbpbewtg", "fgb", com.azure.core.util.Context.NONE); - Assertions.assertEquals("yqbexrmcqibycno", response.iterator().next().accessPolicyName()); - Assertions.assertEquals("knme", response.iterator().next().user().objectId()); + Assertions.assertEquals("xzvlvqhjkbegib", response.iterator().next().accessPolicyName()); + Assertions.assertEquals("mxiebw", response.iterator().next().user().objectId()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentityTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentityTests.java index 2de5521405c4..f7807135f9e5 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentityTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentityTests.java @@ -13,9 +13,9 @@ public final class ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIde @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity model = BinaryData - .fromString("{\"userAssignedIdentityResourceId\":\"mdvpjhulsu\",\"identityType\":\"userAssignedIdentity\"}") + .fromString("{\"userAssignedIdentityResourceId\":\"osygex\",\"identityType\":\"userAssignedIdentity\"}") .toObject(ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity.class); - Assertions.assertEquals("mdvpjhulsu", model.userAssignedIdentityResourceId()); + Assertions.assertEquals("osygex", model.userAssignedIdentityResourceId()); Assertions.assertEquals(CmkIdentityType.USER_ASSIGNED_IDENTITY, model.identityType()); } @@ -23,11 +23,11 @@ public void testDeserialize() throws Exception { public void testSerialize() throws Exception { ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity model = new ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity() - .withUserAssignedIdentityResourceId("mdvpjhulsu") + .withUserAssignedIdentityResourceId("osygex") .withIdentityType(CmkIdentityType.USER_ASSIGNED_IDENTITY); model = BinaryData.fromObject(model) .toObject(ClusterPropertiesEncryptionCustomerManagedKeyEncryptionKeyIdentity.class); - Assertions.assertEquals("mdvpjhulsu", model.userAssignedIdentityResourceId()); + Assertions.assertEquals("osygex", model.userAssignedIdentityResourceId()); Assertions.assertEquals(CmkIdentityType.USER_ASSIGNED_IDENTITY, model.identityType()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasePropertiesGeoReplicationTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasePropertiesGeoReplicationTests.java index 2594ded1c81a..a15d40752ede 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasePropertiesGeoReplicationTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasePropertiesGeoReplicationTests.java @@ -13,20 +13,20 @@ public final class DatabasePropertiesGeoReplicationTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - DatabasePropertiesGeoReplication model = BinaryData - .fromString( - "{\"groupNickname\":\"c\",\"linkedDatabases\":[{\"id\":\"cufufsrpymz\",\"state\":\"Unlinking\"}]}") + DatabasePropertiesGeoReplication model = BinaryData.fromString( + "{\"groupNickname\":\"idf\",\"linkedDatabases\":[{\"id\":\"zuhtymwisdkfthwx\",\"state\":\"Linking\"},{\"id\":\"i\",\"state\":\"LinkFailed\"},{\"id\":\"vkmijcmmxdcuf\",\"state\":\"Unlinking\"}]}") .toObject(DatabasePropertiesGeoReplication.class); - Assertions.assertEquals("c", model.groupNickname()); - Assertions.assertEquals("cufufsrpymz", model.linkedDatabases().get(0).id()); + Assertions.assertEquals("idf", model.groupNickname()); + Assertions.assertEquals("zuhtymwisdkfthwx", model.linkedDatabases().get(0).id()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - DatabasePropertiesGeoReplication model = new DatabasePropertiesGeoReplication().withGroupNickname("c") - .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId("cufufsrpymz"))); + DatabasePropertiesGeoReplication model = new DatabasePropertiesGeoReplication().withGroupNickname("idf") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId("zuhtymwisdkfthwx"), + new LinkedDatabase().withId("i"), new LinkedDatabase().withId("vkmijcmmxdcuf"))); model = BinaryData.fromObject(model).toObject(DatabasePropertiesGeoReplication.class); - Assertions.assertEquals("c", model.groupNickname()); - Assertions.assertEquals("cufufsrpymz", model.linkedDatabases().get(0).id()); + Assertions.assertEquals("idf", model.groupNickname()); + Assertions.assertEquals("zuhtymwisdkfthwx", model.linkedDatabases().get(0).id()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteMockTests.java index 857e5c9a80a3..1188d3abb96b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesDeleteMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import java.nio.charset.StandardCharsets; @@ -25,9 +25,9 @@ public void testDelete() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); - manager.databases().delete("plpho", "uscrpabgyepsb", "tazqugxywpmueefj", com.azure.core.util.Context.NONE); + manager.databases().delete("mtxpsiebtfh", "pesapskrdqmhjj", "htldwk", com.azure.core.util.Context.NONE); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportMockTests.java index 48e78e536e75..b4dac5dfa114 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesExportMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.ExportClusterParameters; @@ -26,10 +26,10 @@ public void testExport() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); manager.databases() - .export("ehhseyvjusrts", "hspkdeemao", "mx", new ExportClusterParameters().withSasUri("gkvtmelmqkrhah"), + .export("qugxywpmueefjzwf", "kqujidsuyono", "glaocq", new ExportClusterParameters().withSasUri("tcc"), com.azure.core.util.Context.NONE); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushMockTests.java index c4211b79ea58..92fe05cbeb89 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesFlushMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.FlushParameters; @@ -27,11 +27,11 @@ public void testFlush() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); manager.databases() - .flush("isgwbnbbeldawkz", "ali", "urqhaka", - new FlushParameters().withIds(Arrays.asList("shsfwxosowzxcu", "i", "jooxdjebw")), + .flush("sbkyvpycanuzbp", "kafkuwbcrnwbm", "hhseyv", + new FlushParameters().withIds(Arrays.asList("rts", "hspkdeemao", "mx", "gkvtmelmqkrhah")), com.azure.core.util.Context.NONE); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkMockTests.java index be080f673205..a1c47856e4ae 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesForceUnlinkMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.ForceUnlinkParameters; @@ -27,12 +27,11 @@ public void testForceUnlink() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); manager.databases() - .forceUnlink("ljuahaquhcdh", "duala", "xqpvfadmw", - new ForceUnlinkParameters().withIds(Arrays.asList("crgvxpvgom", "lf")), - com.azure.core.util.Context.NONE); + .forceUnlink("g", "udxytlmoyrx", "wfudwpzntxhdzhl", + new ForceUnlinkParameters().withIds(Arrays.asList("jbhckfrlhr")), com.azure.core.util.Context.NONE); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodMockTests.java index 1d3d4926fb22..da5a14f9bbcc 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/DatabasesImportMethodMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.ImportClusterParameters; @@ -27,11 +27,11 @@ public void testImportMethod() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); manager.databases() - .importMethod("dzhlrq", "bh", "kfrlhrxsbky", - new ImportClusterParameters().withSasUris(Arrays.asList("ycanuzbpzkafku", "b", "rnwb")), + .importMethod("phywpnvj", "oqnermclfpl", "hoxus", + new ImportClusterParameters().withSasUris(Arrays.asList("pabgyeps", "jta")), com.azure.core.util.Context.NONE); } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ExportClusterParametersTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ExportClusterParametersTests.java index 57488abe01f1..e6639ae8af94 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ExportClusterParametersTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ExportClusterParametersTests.java @@ -12,14 +12,14 @@ public final class ExportClusterParametersTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { ExportClusterParameters model - = BinaryData.fromString("{\"sasUri\":\"tjaodxobnb\"}").toObject(ExportClusterParameters.class); - Assertions.assertEquals("tjaodxobnb", model.sasUri()); + = BinaryData.fromString("{\"sasUri\":\"jjgpb\"}").toObject(ExportClusterParameters.class); + Assertions.assertEquals("jjgpb", model.sasUri()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - ExportClusterParameters model = new ExportClusterParameters().withSasUri("tjaodxobnb"); + ExportClusterParameters model = new ExportClusterParameters().withSasUri("jjgpb"); model = BinaryData.fromObject(model).toObject(ExportClusterParameters.class); - Assertions.assertEquals("tjaodxobnb", model.sasUri()); + Assertions.assertEquals("jjgpb", model.sasUri()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/FlushParametersTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/FlushParametersTests.java index 56f3fe2e6467..876ef0a7bb1b 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/FlushParametersTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/FlushParametersTests.java @@ -12,15 +12,17 @@ public final class FlushParametersTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - FlushParameters model = BinaryData.fromString("{\"ids\":[\"cohslkev\",\"eggzfb\",\"hfmvfaxkffe\"]}") - .toObject(FlushParameters.class); - Assertions.assertEquals("cohslkev", model.ids().get(0)); + FlushParameters model + = BinaryData.fromString("{\"ids\":[\"xw\",\"ywqsmbsurexim\",\"ryocfsfksymdd\",\"stkiiuxhqyud\"]}") + .toObject(FlushParameters.class); + Assertions.assertEquals("xw", model.ids().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - FlushParameters model = new FlushParameters().withIds(Arrays.asList("cohslkev", "eggzfb", "hfmvfaxkffe")); + FlushParameters model + = new FlushParameters().withIds(Arrays.asList("xw", "ywqsmbsurexim", "ryocfsfksymdd", "stkiiuxhqyud")); model = BinaryData.fromObject(model).toObject(FlushParameters.class); - Assertions.assertEquals("cohslkev", model.ids().get(0)); + Assertions.assertEquals("xw", model.ids().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersGeoReplicationTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersGeoReplicationTests.java new file mode 100644 index 000000000000..d317b4896135 --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersGeoReplicationTests.java @@ -0,0 +1,33 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.generated; + +import com.azure.core.util.BinaryData; +import com.azure.resourcemanager.redisenterprise.models.ForceLinkParametersGeoReplication; +import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; +import java.util.Arrays; +import org.junit.jupiter.api.Assertions; + +public final class ForceLinkParametersGeoReplicationTests { + @org.junit.jupiter.api.Test + public void testDeserialize() throws Exception { + ForceLinkParametersGeoReplication model = BinaryData + .fromString( + "{\"groupNickname\":\"ozmyzydagfu\",\"linkedDatabases\":[{\"id\":\"zyiuokk\",\"state\":\"Linked\"}]}") + .toObject(ForceLinkParametersGeoReplication.class); + Assertions.assertEquals("ozmyzydagfu", model.groupNickname()); + Assertions.assertEquals("zyiuokk", model.linkedDatabases().get(0).id()); + } + + @org.junit.jupiter.api.Test + public void testSerialize() throws Exception { + ForceLinkParametersGeoReplication model + = new ForceLinkParametersGeoReplication().withGroupNickname("ozmyzydagfu") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId("zyiuokk"))); + model = BinaryData.fromObject(model).toObject(ForceLinkParametersGeoReplication.class); + Assertions.assertEquals("ozmyzydagfu", model.groupNickname()); + Assertions.assertEquals("zyiuokk", model.linkedDatabases().get(0).id()); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersTests.java index 9f317fb9c9ce..28239c79be51 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceLinkParametersTests.java @@ -6,6 +6,7 @@ import com.azure.core.util.BinaryData; import com.azure.resourcemanager.redisenterprise.models.ForceLinkParameters; +import com.azure.resourcemanager.redisenterprise.models.ForceLinkParametersGeoReplication; import com.azure.resourcemanager.redisenterprise.models.LinkedDatabase; import java.util.Arrays; import org.junit.jupiter.api.Assertions; @@ -14,19 +15,19 @@ public final class ForceLinkParametersTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { ForceLinkParameters model = BinaryData.fromString( - "{\"groupNickname\":\"oskg\",\"linkedDatabases\":[{\"id\":\"uuimjmvxieduug\",\"state\":\"UnlinkFailed\"},{\"id\":\"rrfbyaosvexcson\",\"state\":\"Linked\"}]}") + "{\"geoReplication\":{\"groupNickname\":\"fhyhltrpmopjmcma\",\"linkedDatabases\":[{\"id\":\"thfuiuaodsfcpkvx\",\"state\":\"Linked\"}]}}") .toObject(ForceLinkParameters.class); - Assertions.assertEquals("oskg", model.groupNickname()); - Assertions.assertEquals("uuimjmvxieduug", model.linkedDatabases().get(0).id()); + Assertions.assertEquals("fhyhltrpmopjmcma", model.geoReplication().groupNickname()); + Assertions.assertEquals("thfuiuaodsfcpkvx", model.geoReplication().linkedDatabases().get(0).id()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - ForceLinkParameters model = new ForceLinkParameters().withGroupNickname("oskg") - .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId("uuimjmvxieduug"), - new LinkedDatabase().withId("rrfbyaosvexcson"))); + ForceLinkParameters model = new ForceLinkParameters() + .withGeoReplication(new ForceLinkParametersGeoReplication().withGroupNickname("fhyhltrpmopjmcma") + .withLinkedDatabases(Arrays.asList(new LinkedDatabase().withId("thfuiuaodsfcpkvx")))); model = BinaryData.fromObject(model).toObject(ForceLinkParameters.class); - Assertions.assertEquals("oskg", model.groupNickname()); - Assertions.assertEquals("uuimjmvxieduug", model.linkedDatabases().get(0).id()); + Assertions.assertEquals("fhyhltrpmopjmcma", model.geoReplication().groupNickname()); + Assertions.assertEquals("thfuiuaodsfcpkvx", model.geoReplication().linkedDatabases().get(0).id()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceUnlinkParametersTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceUnlinkParametersTests.java index b0aab2548987..0d28c77b611f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceUnlinkParametersTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ForceUnlinkParametersTests.java @@ -13,16 +13,14 @@ public final class ForceUnlinkParametersTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { ForceUnlinkParameters model - = BinaryData.fromString("{\"ids\":[\"dobpxjmflbvvn\",\"hrk\",\"ciwwzjuqkhr\",\"ajiwkuo\"]}") - .toObject(ForceUnlinkParameters.class); - Assertions.assertEquals("dobpxjmflbvvn", model.ids().get(0)); + = BinaryData.fromString("{\"ids\":[\"noae\"]}").toObject(ForceUnlinkParameters.class); + Assertions.assertEquals("noae", model.ids().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - ForceUnlinkParameters model - = new ForceUnlinkParameters().withIds(Arrays.asList("dobpxjmflbvvn", "hrk", "ciwwzjuqkhr", "ajiwkuo")); + ForceUnlinkParameters model = new ForceUnlinkParameters().withIds(Arrays.asList("noae")); model = BinaryData.fromObject(model).toObject(ForceUnlinkParameters.class); - Assertions.assertEquals("dobpxjmflbvvn", model.ids().get(0)); + Assertions.assertEquals("noae", model.ids().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ImportClusterParametersTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ImportClusterParametersTests.java index a68f38d93b8a..749dfb7ecd71 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ImportClusterParametersTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ImportClusterParametersTests.java @@ -12,15 +12,16 @@ public final class ImportClusterParametersTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - ImportClusterParameters model - = BinaryData.fromString("{\"sasUris\":[\"aierhhb\",\"sglumma\"]}").toObject(ImportClusterParameters.class); - Assertions.assertEquals("aierhhb", model.sasUris().get(0)); + ImportClusterParameters model = BinaryData.fromString("{\"sasUris\":[\"abnmocpcyshu\",\"zafb\"]}") + .toObject(ImportClusterParameters.class); + Assertions.assertEquals("abnmocpcyshu", model.sasUris().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - ImportClusterParameters model = new ImportClusterParameters().withSasUris(Arrays.asList("aierhhb", "sglumma")); + ImportClusterParameters model + = new ImportClusterParameters().withSasUris(Arrays.asList("abnmocpcyshu", "zafb")); model = BinaryData.fromObject(model).toObject(ImportClusterParameters.class); - Assertions.assertEquals("aierhhb", model.sasUris().get(0)); + Assertions.assertEquals("abnmocpcyshu", model.sasUris().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/LinkedDatabaseTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/LinkedDatabaseTests.java index e629ebd2b5b8..2f370033727e 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/LinkedDatabaseTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/LinkedDatabaseTests.java @@ -11,15 +11,15 @@ public final class LinkedDatabaseTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - LinkedDatabase model = BinaryData.fromString("{\"id\":\"ezcxtbzsgfyccsne\",\"state\":\"Unlinking\"}") + LinkedDatabase model = BinaryData.fromString("{\"id\":\"pymzidnsezcxtbzs\",\"state\":\"Linking\"}") .toObject(LinkedDatabase.class); - Assertions.assertEquals("ezcxtbzsgfyccsne", model.id()); + Assertions.assertEquals("pymzidnsezcxtbzs", model.id()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - LinkedDatabase model = new LinkedDatabase().withId("ezcxtbzsgfyccsne"); + LinkedDatabase model = new LinkedDatabase().withId("pymzidnsezcxtbzs"); model = BinaryData.fromObject(model).toObject(LinkedDatabase.class); - Assertions.assertEquals("ezcxtbzsgfyccsne", model.id()); + Assertions.assertEquals("pymzidnsezcxtbzs", model.id()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ManagedServiceIdentityTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ManagedServiceIdentityTests.java index 7ebee3c2b52b..c85887bb4377 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ManagedServiceIdentityTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ManagedServiceIdentityTests.java @@ -16,18 +16,18 @@ public final class ManagedServiceIdentityTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { ManagedServiceIdentity model = BinaryData.fromString( - "{\"principalId\":\"fb83a83e-8793-49fc-abf9-c8fe61ad96d8\",\"tenantId\":\"9d864f5f-ffcb-43ba-addc-52d3d68168dd\",\"type\":\"SystemAssigned, UserAssigned\",\"userAssignedIdentities\":{\"chgejspodm\":{\"principalId\":\"810d54c7-ff54-4a55-a848-b5006a04747a\",\"clientId\":\"456aa80d-4c24-4e93-9fb5-37e96c88e0e1\"}}}") + "{\"principalId\":\"8275b0a7-de22-4bad-a397-49831f7d3db0\",\"tenantId\":\"866ef25c-3a7b-476d-bc26-8e0d3596ac3c\",\"type\":\"SystemAssigned\",\"userAssignedIdentities\":{\"utegjvwmfdats\":{\"principalId\":\"2de84376-66cf-4bfa-b0e1-94c251be5685\",\"clientId\":\"3d82e3e9-720d-4723-8653-12b15cd57e7a\"},\"vpjhulsuuv\":{\"principalId\":\"dbabae42-e39f-405e-8327-fb5722ada4c5\",\"clientId\":\"6f872669-d43b-430e-aa66-cd43ccc05877\"}}}") .toObject(ManagedServiceIdentity.class); - Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED, model.type()); + Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED, model.type()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - ManagedServiceIdentity model - = new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED) - .withUserAssignedIdentities(mapOf("chgejspodm", new UserAssignedIdentity())); + ManagedServiceIdentity model = new ManagedServiceIdentity().withType(ManagedServiceIdentityType.SYSTEM_ASSIGNED) + .withUserAssignedIdentities( + mapOf("utegjvwmfdats", new UserAssignedIdentity(), "vpjhulsuuv", new UserAssignedIdentity())); model = BinaryData.fromObject(model).toObject(ManagedServiceIdentity.class); - Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED, model.type()); + Assertions.assertEquals(ManagedServiceIdentityType.SYSTEM_ASSIGNED, model.type()); } // Use "Map.of" if available diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ModuleTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ModuleTests.java index 3df2e048cca2..7a0887e8ada0 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ModuleTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/ModuleTests.java @@ -12,17 +12,17 @@ public final class ModuleTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { Module model - = BinaryData.fromString("{\"name\":\"idf\",\"args\":\"wdzuhtymwisd\",\"version\":\"thwxmnteiwaopvkm\"}") + = BinaryData.fromString("{\"name\":\"hmuouqfprwzwbn\",\"args\":\"itnwuizgazxufi\",\"version\":\"ckyfih\"}") .toObject(Module.class); - Assertions.assertEquals("idf", model.name()); - Assertions.assertEquals("wdzuhtymwisd", model.args()); + Assertions.assertEquals("hmuouqfprwzwbn", model.name()); + Assertions.assertEquals("itnwuizgazxufi", model.args()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - Module model = new Module().withName("idf").withArgs("wdzuhtymwisd"); + Module model = new Module().withName("hmuouqfprwzwbn").withArgs("itnwuizgazxufi"); model = BinaryData.fromObject(model).toObject(Module.class); - Assertions.assertEquals("idf", model.name()); - Assertions.assertEquals("wdzuhtymwisd", model.args()); + Assertions.assertEquals("hmuouqfprwzwbn", model.name()); + Assertions.assertEquals("itnwuizgazxufi", model.args()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListMockTests.java index aca624d995e1..48135a4a3b9d 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/OperationsListMockTests.java @@ -7,8 +7,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; import com.azure.core.http.rest.PagedIterable; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.Operation; @@ -21,14 +21,14 @@ public final class OperationsListMockTests { @Test public void testList() throws Exception { String responseStr - = "{\"value\":[{\"name\":\"th\",\"isDataAction\":false,\"display\":{\"provider\":\"yvshxmz\",\"resource\":\"bzoggigrx\",\"operation\":\"ur\",\"description\":\"xxjnspydptk\"},\"origin\":\"system\",\"actionType\":\"Internal\"}]}"; + = "{\"value\":[{\"name\":\"rrqnbpoczvyifqrv\",\"isDataAction\":true,\"display\":{\"provider\":\"llr\",\"resource\":\"vdfwatkpn\",\"operation\":\"lexxbczwtru\",\"description\":\"qzbqjvsov\"},\"origin\":\"user\",\"actionType\":\"Internal\"}]}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); PagedIterable response = manager.operations().list(com.azure.core.util.Context.NONE); diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PersistenceTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PersistenceTests.java index 7fbf43bcfb06..e491988cebbb 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PersistenceTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PersistenceTests.java @@ -14,12 +14,12 @@ public final class PersistenceTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { Persistence model = BinaryData - .fromString("{\"aofEnabled\":false,\"rdbEnabled\":false,\"aofFrequency\":\"1s\",\"rdbFrequency\":\"1h\"}") + .fromString("{\"aofEnabled\":false,\"rdbEnabled\":false,\"aofFrequency\":\"1s\",\"rdbFrequency\":\"12h\"}") .toObject(Persistence.class); - Assertions.assertEquals(false, model.aofEnabled()); - Assertions.assertEquals(false, model.rdbEnabled()); + Assertions.assertFalse(model.aofEnabled()); + Assertions.assertFalse(model.rdbEnabled()); Assertions.assertEquals(AofFrequency.ONES, model.aofFrequency()); - Assertions.assertEquals(RdbFrequency.ONEH, model.rdbFrequency()); + Assertions.assertEquals(RdbFrequency.ONE_TWOH, model.rdbFrequency()); } @org.junit.jupiter.api.Test @@ -27,11 +27,11 @@ public void testSerialize() throws Exception { Persistence model = new Persistence().withAofEnabled(false) .withRdbEnabled(false) .withAofFrequency(AofFrequency.ONES) - .withRdbFrequency(RdbFrequency.ONEH); + .withRdbFrequency(RdbFrequency.ONE_TWOH); model = BinaryData.fromObject(model).toObject(Persistence.class); - Assertions.assertEquals(false, model.aofEnabled()); - Assertions.assertEquals(false, model.rdbEnabled()); + Assertions.assertFalse(model.aofEnabled()); + Assertions.assertFalse(model.rdbEnabled()); Assertions.assertEquals(AofFrequency.ONES, model.aofFrequency()); - Assertions.assertEquals(RdbFrequency.ONEH, model.rdbFrequency()); + Assertions.assertEquals(RdbFrequency.ONE_TWOH, model.rdbFrequency()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionInnerTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionInnerTests.java index 76ac51000218..8ca281c118b9 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionInnerTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionInnerTests.java @@ -15,12 +15,12 @@ public final class PrivateEndpointConnectionInnerTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateEndpointConnectionInner model = BinaryData.fromString( - "{\"properties\":{\"privateEndpoint\":{\"id\":\"zkrwfn\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"jpslwejd\",\"actionsRequired\":\"wryoqpsoacc\"},\"provisioningState\":\"Deleting\"},\"id\":\"akl\",\"name\":\"lahbcryff\",\"type\":\"fdosyg\"}") + "{\"properties\":{\"privateEndpoint\":{\"id\":\"hmsbzjhcrzevdp\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"olthqtrgqjbp\",\"actionsRequired\":\"fsinzgvfcjrwzoxx\"},\"provisioningState\":\"Failed\"},\"id\":\"elluwfziton\",\"name\":\"eqfpj\",\"type\":\"jlxofpdvhpfxxyp\"}") .toObject(PrivateEndpointConnectionInner.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, model.privateLinkServiceConnectionState().status()); - Assertions.assertEquals("jpslwejd", model.privateLinkServiceConnectionState().description()); - Assertions.assertEquals("wryoqpsoacc", model.privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("olthqtrgqjbp", model.privateLinkServiceConnectionState().description()); + Assertions.assertEquals("fsinzgvfcjrwzoxx", model.privateLinkServiceConnectionState().actionsRequired()); } @org.junit.jupiter.api.Test @@ -28,13 +28,13 @@ public void testSerialize() throws Exception { PrivateEndpointConnectionInner model = new PrivateEndpointConnectionInner().withPrivateEndpoint(new PrivateEndpoint()) .withPrivateLinkServiceConnectionState( - new PrivateLinkServiceConnectionState().withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) - .withDescription("jpslwejd") - .withActionsRequired("wryoqpsoacc")); + new PrivateLinkServiceConnectionState().withStatus(PrivateEndpointServiceConnectionStatus.REJECTED) + .withDescription("olthqtrgqjbp") + .withActionsRequired("fsinzgvfcjrwzoxx")); model = BinaryData.fromObject(model).toObject(PrivateEndpointConnectionInner.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, model.privateLinkServiceConnectionState().status()); - Assertions.assertEquals("jpslwejd", model.privateLinkServiceConnectionState().description()); - Assertions.assertEquals("wryoqpsoacc", model.privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("olthqtrgqjbp", model.privateLinkServiceConnectionState().description()); + Assertions.assertEquals("fsinzgvfcjrwzoxx", model.privateLinkServiceConnectionState().actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionListResultTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionListResultTests.java index bcdb77007dba..60f7a246bac6 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionListResultTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionListResultTests.java @@ -17,13 +17,13 @@ public final class PrivateEndpointConnectionListResultTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateEndpointConnectionListResult model = BinaryData.fromString( - "{\"value\":[{\"properties\":{\"privateEndpoint\":{\"id\":\"cocpecfvmmcoofsx\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"gbmqjqabcypmiv\",\"actionsRequired\":\"lzu\"},\"provisioningState\":\"Succeeded\"},\"id\":\"fwnfnb\",\"name\":\"cfionl\",\"type\":\"bxetqgtzxdpn\"},{\"properties\":{\"privateEndpoint\":{\"id\":\"wxrjfeallnwsub\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"ampmngnz\",\"actionsRequired\":\"xaqwoochcbonqv\"},\"provisioningState\":\"Failed\"},\"id\":\"lrxnjeaseiphe\",\"name\":\"f\",\"type\":\"okeyyienj\"},{\"properties\":{\"privateEndpoint\":{\"id\":\"tgrhpdjpjumas\"},\"privateLinkServiceConnectionState\":{\"status\":\"Pending\",\"description\":\"pqyegualhbxxh\",\"actionsRequired\":\"jzzvdud\"},\"provisioningState\":\"Deleting\"},\"id\":\"slfhotwm\",\"name\":\"ynpwlbj\",\"type\":\"pgacftadehxnlty\"}]}") + "{\"value\":[{\"properties\":{\"privateEndpoint\":{\"id\":\"xibqeojnx\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"ddntwndei\",\"actionsRequired\":\"twnpzaoqvuhrhcf\"},\"provisioningState\":\"Succeeded\"},\"id\":\"ddglm\",\"name\":\"t\",\"type\":\"jqkwpyeicx\"},{\"properties\":{\"privateEndpoint\":{\"id\":\"wqvhkhixuigdt\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"bjoghmewuamau\",\"actionsRequired\":\"z\"},\"provisioningState\":\"Deleting\"},\"id\":\"vtpgvdfgiotkf\",\"name\":\"utqxlngx\",\"type\":\"efgugnxk\"},{\"properties\":{\"privateEndpoint\":{\"id\":\"mi\"},\"privateLinkServiceConnectionState\":{\"status\":\"Pending\",\"description\":\"zrvqdr\",\"actionsRequired\":\"hjybigehoqfbo\"},\"provisioningState\":\"Failed\"},\"id\":\"anyktzlcuiywg\",\"name\":\"ywgndrv\",\"type\":\"nhzgpphrcgyn\"},{\"properties\":{\"privateEndpoint\":{\"id\":\"ecfvmm\"},\"privateLinkServiceConnectionState\":{\"status\":\"Pending\",\"description\":\"sxlzevgbmqj\",\"actionsRequired\":\"bcypmi\"},\"provisioningState\":\"Succeeded\"},\"id\":\"lzu\",\"name\":\"ccfwnfnbacfion\",\"type\":\"ebxetqgtzxdp\"}]}") .toObject(PrivateEndpointConnectionListResult.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, model.value().get(0).privateLinkServiceConnectionState().status()); - Assertions.assertEquals("gbmqjqabcypmiv", - model.value().get(0).privateLinkServiceConnectionState().description()); - Assertions.assertEquals("lzu", model.value().get(0).privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("ddntwndei", model.value().get(0).privateLinkServiceConnectionState().description()); + Assertions.assertEquals("twnpzaoqvuhrhcf", + model.value().get(0).privateLinkServiceConnectionState().actionsRequired()); } @org.junit.jupiter.api.Test @@ -33,24 +33,29 @@ public void testSerialize() throws Exception { .withValue(Arrays.asList( new PrivateEndpointConnectionInner().withPrivateEndpoint(new PrivateEndpoint()) .withPrivateLinkServiceConnectionState(new PrivateLinkServiceConnectionState() - .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) - .withDescription("gbmqjqabcypmiv") - .withActionsRequired("lzu")), + .withStatus(PrivateEndpointServiceConnectionStatus.REJECTED) + .withDescription("ddntwndei") + .withActionsRequired("twnpzaoqvuhrhcf")), new PrivateEndpointConnectionInner().withPrivateEndpoint(new PrivateEndpoint()) .withPrivateLinkServiceConnectionState(new PrivateLinkServiceConnectionState() .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) - .withDescription("ampmngnz") - .withActionsRequired("xaqwoochcbonqv")), + .withDescription("bjoghmewuamau") + .withActionsRequired("z")), + new PrivateEndpointConnectionInner().withPrivateEndpoint(new PrivateEndpoint()) + .withPrivateLinkServiceConnectionState(new PrivateLinkServiceConnectionState() + .withStatus(PrivateEndpointServiceConnectionStatus.PENDING) + .withDescription("zrvqdr") + .withActionsRequired("hjybigehoqfbo")), new PrivateEndpointConnectionInner().withPrivateEndpoint(new PrivateEndpoint()) .withPrivateLinkServiceConnectionState(new PrivateLinkServiceConnectionState() .withStatus(PrivateEndpointServiceConnectionStatus.PENDING) - .withDescription("pqyegualhbxxh") - .withActionsRequired("jzzvdud")))); + .withDescription("sxlzevgbmqj") + .withActionsRequired("bcypmi")))); model = BinaryData.fromObject(model).toObject(PrivateEndpointConnectionListResult.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, model.value().get(0).privateLinkServiceConnectionState().status()); - Assertions.assertEquals("gbmqjqabcypmiv", - model.value().get(0).privateLinkServiceConnectionState().description()); - Assertions.assertEquals("lzu", model.value().get(0).privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("ddntwndei", model.value().get(0).privateLinkServiceConnectionState().description()); + Assertions.assertEquals("twnpzaoqvuhrhcf", + model.value().get(0).privateLinkServiceConnectionState().actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionPropertiesTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionPropertiesTests.java index db1a78d77153..facb7fdd54aa 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionPropertiesTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionPropertiesTests.java @@ -15,12 +15,12 @@ public final class PrivateEndpointConnectionPropertiesTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateEndpointConnectionProperties model = BinaryData.fromString( - "{\"privateEndpoint\":{\"id\":\"aojakhmsbzjhcrz\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"hlxaolthqtr\",\"actionsRequired\":\"jbp\"},\"provisioningState\":\"Failed\"}") + "{\"privateEndpoint\":{\"id\":\"nmayhuybb\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"epoo\",\"actionsRequired\":\"nuvamiheogna\"},\"provisioningState\":\"Failed\"}") .toObject(PrivateEndpointConnectionProperties.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, model.privateLinkServiceConnectionState().status()); - Assertions.assertEquals("hlxaolthqtr", model.privateLinkServiceConnectionState().description()); - Assertions.assertEquals("jbp", model.privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("epoo", model.privateLinkServiceConnectionState().description()); + Assertions.assertEquals("nuvamiheogna", model.privateLinkServiceConnectionState().actionsRequired()); } @org.junit.jupiter.api.Test @@ -28,13 +28,13 @@ public void testSerialize() throws Exception { PrivateEndpointConnectionProperties model = new PrivateEndpointConnectionProperties().withPrivateEndpoint(new PrivateEndpoint()) .withPrivateLinkServiceConnectionState( - new PrivateLinkServiceConnectionState().withStatus(PrivateEndpointServiceConnectionStatus.REJECTED) - .withDescription("hlxaolthqtr") - .withActionsRequired("jbp")); + new PrivateLinkServiceConnectionState().withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) + .withDescription("epoo") + .withActionsRequired("nuvamiheogna")); model = BinaryData.fromObject(model).toObject(PrivateEndpointConnectionProperties.class); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, model.privateLinkServiceConnectionState().status()); - Assertions.assertEquals("hlxaolthqtr", model.privateLinkServiceConnectionState().description()); - Assertions.assertEquals("jbp", model.privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("epoo", model.privateLinkServiceConnectionState().description()); + Assertions.assertEquals("nuvamiheogna", model.privateLinkServiceConnectionState().actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteMockTests.java index 11e80cdd1845..a361d1f5483f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsDeleteMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import java.nio.charset.StandardCharsets; @@ -25,10 +25,9 @@ public void testDelete() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); - manager.privateEndpointConnections() - .delete("szjfauvjfdxxivet", "t", "qaqtdoqmcbxvwvxy", com.azure.core.util.Context.NONE); + manager.privateEndpointConnections().delete("qeqxo", "z", "ahzxctobgbk", com.azure.core.util.Context.NONE); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetWithResponseMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetWithResponseMockTests.java index 9d24347b9f0e..e7d2a29e558c 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetWithResponseMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsGetWithResponseMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.PrivateEndpointConnection; @@ -22,22 +22,22 @@ public final class PrivateEndpointConnectionsGetWithResponseMockTests { @Test public void testGetWithResponse() throws Exception { String responseStr - = "{\"properties\":{\"privateEndpoint\":{\"id\":\"pcqeqx\"},\"privateLinkServiceConnectionState\":{\"status\":\"Approved\",\"description\":\"ahzxctobgbk\",\"actionsRequired\":\"oizpostmgrcfbun\"},\"provisioningState\":\"Failed\"},\"id\":\"qjhhkxbpv\",\"name\":\"ymjhxxjyngudivkr\",\"type\":\"swbxqz\"}"; + = "{\"properties\":{\"privateEndpoint\":{\"id\":\"gylgqgitxmedjvcs\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"wwncwzzhxgk\",\"actionsRequired\":\"mgucna\"},\"provisioningState\":\"Succeeded\"},\"id\":\"eoellwptfdygp\",\"name\":\"qbuaceopzfqr\",\"type\":\"huaoppp\"}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); PrivateEndpointConnection response = manager.privateEndpointConnections() - .getWithResponse("oellwp", "fdygpfqbuaceopz", "qrhhu", com.azure.core.util.Context.NONE) + .getWithResponse("hb", "xknalaulppg", "dtpnapnyiropuhp", com.azure.core.util.Context.NONE) .getValue(); - Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.APPROVED, + Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, response.privateLinkServiceConnectionState().status()); - Assertions.assertEquals("ahzxctobgbk", response.privateLinkServiceConnectionState().description()); - Assertions.assertEquals("oizpostmgrcfbun", response.privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("wwncwzzhxgk", response.privateLinkServiceConnectionState().description()); + Assertions.assertEquals("mgucna", response.privateLinkServiceConnectionState().actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListMockTests.java index 9b8529edc0e6..48c50acc16f9 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointConnectionsListMockTests.java @@ -7,8 +7,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; import com.azure.core.http.rest.PagedIterable; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.PrivateEndpointConnection; @@ -23,23 +23,22 @@ public final class PrivateEndpointConnectionsListMockTests { @Test public void testList() throws Exception { String responseStr - = "{\"value\":[{\"properties\":{\"privateEndpoint\":{\"id\":\"napnyiropuhpigv\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"gqgitxmedjvcsl\",\"actionsRequired\":\"qwwncw\"},\"provisioningState\":\"Succeeded\"},\"id\":\"xgk\",\"name\":\"rmgucnap\",\"type\":\"t\"}]}"; + = "{\"value\":[{\"properties\":{\"privateEndpoint\":{\"id\":\"mvb\"},\"privateLinkServiceConnectionState\":{\"status\":\"Rejected\",\"description\":\"sflhhca\",\"actionsRequired\":\"n\"},\"provisioningState\":\"Failed\"},\"id\":\"isxyawjoyaqcslyj\",\"name\":\"kiidzyex\",\"type\":\"nelixhnrztfo\"}]}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); PagedIterable response - = manager.privateEndpointConnections().list("hb", "xknalaulppg", com.azure.core.util.Context.NONE); + = manager.privateEndpointConnections().list("uusdttouwa", "oekqvk", com.azure.core.util.Context.NONE); Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.REJECTED, response.iterator().next().privateLinkServiceConnectionState().status()); - Assertions.assertEquals("gqgitxmedjvcsl", + Assertions.assertEquals("sflhhca", response.iterator().next().privateLinkServiceConnectionState().description()); - Assertions.assertEquals("qwwncw", - response.iterator().next().privateLinkServiceConnectionState().actionsRequired()); + Assertions.assertEquals("n", response.iterator().next().privateLinkServiceConnectionState().actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointTests.java index c17c8c68eacc..434fb59d8dba 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateEndpointTests.java @@ -10,7 +10,7 @@ public final class PrivateEndpointTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { - PrivateEndpoint model = BinaryData.fromString("{\"id\":\"inzgvfcj\"}").toObject(PrivateEndpoint.class); + PrivateEndpoint model = BinaryData.fromString("{\"id\":\"theotusiv\"}").toObject(PrivateEndpoint.class); } @org.junit.jupiter.api.Test diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceInnerTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceInnerTests.java index 263f7098a966..2ba0a1a48a23 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceInnerTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceInnerTests.java @@ -13,15 +13,16 @@ public final class PrivateLinkResourceInnerTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateLinkResourceInner model = BinaryData.fromString( - "{\"properties\":{\"groupId\":\"fu\",\"requiredMembers\":[\"odsfcpkvxodpuozm\",\"zydagfuaxbezyiuo\",\"ktwh\"],\"requiredZoneNames\":[\"wz\"]},\"id\":\"wqsmbsur\",\"name\":\"xim\",\"type\":\"ryocfsfksymdd\"}") + "{\"properties\":{\"groupId\":\"zj\",\"requiredMembers\":[\"gdtjixhbkuofqwey\"],\"requiredZoneNames\":[\"enevfyexfwhybci\",\"vyvdcs\",\"tynnaamdectehfi\"]},\"id\":\"scjeypv\",\"name\":\"ezrkgqhcjrefo\",\"type\":\"gm\"}") .toObject(PrivateLinkResourceInner.class); - Assertions.assertEquals("wz", model.requiredZoneNames().get(0)); + Assertions.assertEquals("enevfyexfwhybci", model.requiredZoneNames().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - PrivateLinkResourceInner model = new PrivateLinkResourceInner().withRequiredZoneNames(Arrays.asList("wz")); + PrivateLinkResourceInner model = new PrivateLinkResourceInner() + .withRequiredZoneNames(Arrays.asList("enevfyexfwhybci", "vyvdcs", "tynnaamdectehfi")); model = BinaryData.fromObject(model).toObject(PrivateLinkResourceInner.class); - Assertions.assertEquals("wz", model.requiredZoneNames().get(0)); + Assertions.assertEquals("enevfyexfwhybci", model.requiredZoneNames().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceListResultTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceListResultTests.java index 1b9068800a40..239ed23740a5 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceListResultTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourceListResultTests.java @@ -14,19 +14,18 @@ public final class PrivateLinkResourceListResultTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateLinkResourceListResult model = BinaryData.fromString( - "{\"value\":[{\"properties\":{\"groupId\":\"usue\",\"requiredMembers\":[\"wd\",\"jbavorxzdm\",\"hctbqvudwxdn\"],\"requiredZoneNames\":[\"owgujjugwdkcglhs\"]},\"id\":\"azjdyggd\",\"name\":\"jixhbk\",\"type\":\"ofqweykhmenevfye\"},{\"properties\":{\"groupId\":\"hybcibv\",\"requiredMembers\":[\"c\"],\"requiredZoneNames\":[\"ynnaam\",\"ectehf\",\"qsc\",\"eypvhezrkg\"]},\"id\":\"hcjrefovgmk\",\"name\":\"sle\",\"type\":\"yvxyqjp\"},{\"properties\":{\"groupId\":\"t\",\"requiredMembers\":[\"gjcrcczsqpjhvm\"],\"requiredZoneNames\":[\"v\",\"ysou\",\"q\"]},\"id\":\"canoaeupf\",\"name\":\"yhltrpmopjmcm\",\"type\":\"tuo\"}]}") + "{\"value\":[{\"properties\":{\"groupId\":\"wxrjfeallnwsub\",\"requiredMembers\":[\"jampmngnzscxaqw\",\"ochcbonqvpkvl\"],\"requiredZoneNames\":[\"jease\",\"pheoflokeyy\",\"enjbdlwtgrhp\",\"jp\"]},\"id\":\"umasxazjpq\",\"name\":\"e\",\"type\":\"ualhbxxhejj\"},{\"properties\":{\"groupId\":\"dudgwdslfhot\",\"requiredMembers\":[\"ynpwlbj\",\"pgacftadehxnlty\",\"sop\"],\"requiredZoneNames\":[\"uesnzwdejbavo\",\"xzdmohctb\"]},\"id\":\"vudwx\",\"name\":\"ndnvo\",\"type\":\"gujjugwdkcglh\"}]}") .toObject(PrivateLinkResourceListResult.class); - Assertions.assertEquals("owgujjugwdkcglhs", model.value().get(0).requiredZoneNames().get(0)); + Assertions.assertEquals("jease", model.value().get(0).requiredZoneNames().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - PrivateLinkResourceListResult model = new PrivateLinkResourceListResult().withValue( - Arrays.asList(new PrivateLinkResourceInner().withRequiredZoneNames(Arrays.asList("owgujjugwdkcglhs")), - new PrivateLinkResourceInner() - .withRequiredZoneNames(Arrays.asList("ynnaam", "ectehf", "qsc", "eypvhezrkg")), - new PrivateLinkResourceInner().withRequiredZoneNames(Arrays.asList("v", "ysou", "q")))); + PrivateLinkResourceListResult model = new PrivateLinkResourceListResult().withValue(Arrays.asList( + new PrivateLinkResourceInner() + .withRequiredZoneNames(Arrays.asList("jease", "pheoflokeyy", "enjbdlwtgrhp", "jp")), + new PrivateLinkResourceInner().withRequiredZoneNames(Arrays.asList("uesnzwdejbavo", "xzdmohctb")))); model = BinaryData.fromObject(model).toObject(PrivateLinkResourceListResult.class); - Assertions.assertEquals("owgujjugwdkcglhs", model.value().get(0).requiredZoneNames().get(0)); + Assertions.assertEquals("jease", model.value().get(0).requiredZoneNames().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcePropertiesTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcePropertiesTests.java index d7258c44e05a..a8d5a88c0346 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcePropertiesTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcePropertiesTests.java @@ -13,16 +13,16 @@ public final class PrivateLinkResourcePropertiesTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateLinkResourceProperties model = BinaryData.fromString( - "{\"groupId\":\"tki\",\"requiredMembers\":[\"hqyudxorrqnbpoc\",\"vyifqrvkdvjsl\",\"rm\",\"vdfwatkpn\"],\"requiredZoneNames\":[\"exxbczwtr\",\"wiqzbqjvsovmyo\",\"acspkwl\"]}") + "{\"groupId\":\"sle\",\"requiredMembers\":[\"xyqj\",\"k\",\"attpngjcrcczsq\",\"jh\"],\"requiredZoneNames\":[\"ajvnysounqe\"]}") .toObject(PrivateLinkResourceProperties.class); - Assertions.assertEquals("exxbczwtr", model.requiredZoneNames().get(0)); + Assertions.assertEquals("ajvnysounqe", model.requiredZoneNames().get(0)); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - PrivateLinkResourceProperties model = new PrivateLinkResourceProperties() - .withRequiredZoneNames(Arrays.asList("exxbczwtr", "wiqzbqjvsovmyo", "acspkwl")); + PrivateLinkResourceProperties model + = new PrivateLinkResourceProperties().withRequiredZoneNames(Arrays.asList("ajvnysounqe")); model = BinaryData.fromObject(model).toObject(PrivateLinkResourceProperties.class); - Assertions.assertEquals("exxbczwtr", model.requiredZoneNames().get(0)); + Assertions.assertEquals("ajvnysounqe", model.requiredZoneNames().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterMockTests.java index 260513f1bee3..c756827548c5 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkResourcesListByClusterMockTests.java @@ -7,8 +7,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; import com.azure.core.http.rest.PagedIterable; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import com.azure.resourcemanager.redisenterprise.models.PrivateLinkResource; @@ -22,18 +22,18 @@ public final class PrivateLinkResourcesListByClusterMockTests { @Test public void testListByCluster() throws Exception { String responseStr - = "{\"value\":[{\"properties\":{\"groupId\":\"blmpewww\",\"requiredMembers\":[\"rvrnsvshqjohxc\",\"sbfov\"],\"requiredZoneNames\":[\"ruvw\",\"hsqfsubcgjbirxbp\",\"bsrfbj\"]},\"id\":\"dtws\",\"name\":\"otftpvjzbexilz\",\"type\":\"nfqqnvwp\"}]}"; + = "{\"value\":[{\"properties\":{\"groupId\":\"fqjhhkxbpvjymj\",\"requiredMembers\":[\"j\",\"n\",\"u\"],\"requiredZoneNames\":[\"krtswbxqz\"]},\"id\":\"szjfauvjfdxxivet\",\"name\":\"t\",\"type\":\"qaqtdoqmcbxvwvxy\"}]}"; HttpClient httpClient = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); PagedIterable response - = manager.privateLinkResources().listByCluster("lqbhsf", "obl", com.azure.core.util.Context.NONE); + = manager.privateLinkResources().listByCluster("moizpos", "mgrcfbu", com.azure.core.util.Context.NONE); - Assertions.assertEquals("ruvw", response.iterator().next().requiredZoneNames().get(0)); + Assertions.assertEquals("krtswbxqz", response.iterator().next().requiredZoneNames().get(0)); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkServiceConnectionStateTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkServiceConnectionStateTests.java index 027efb0dcec9..a1361d324c7f 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkServiceConnectionStateTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/PrivateLinkServiceConnectionStateTests.java @@ -13,22 +13,22 @@ public final class PrivateLinkServiceConnectionStateTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { PrivateLinkServiceConnectionState model = BinaryData - .fromString("{\"status\":\"Pending\",\"description\":\"xxjtfe\",\"actionsRequired\":\"uwfzitonpe\"}") + .fromString("{\"status\":\"Pending\",\"description\":\"ciqihnhung\",\"actionsRequired\":\"jzrnf\"}") .toObject(PrivateLinkServiceConnectionState.class); Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.PENDING, model.status()); - Assertions.assertEquals("xxjtfe", model.description()); - Assertions.assertEquals("uwfzitonpe", model.actionsRequired()); + Assertions.assertEquals("ciqihnhung", model.description()); + Assertions.assertEquals("jzrnf", model.actionsRequired()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { PrivateLinkServiceConnectionState model = new PrivateLinkServiceConnectionState().withStatus(PrivateEndpointServiceConnectionStatus.PENDING) - .withDescription("xxjtfe") - .withActionsRequired("uwfzitonpe"); + .withDescription("ciqihnhung") + .withActionsRequired("jzrnf"); model = BinaryData.fromObject(model).toObject(PrivateLinkServiceConnectionState.class); Assertions.assertEquals(PrivateEndpointServiceConnectionStatus.PENDING, model.status()); - Assertions.assertEquals("xxjtfe", model.description()); - Assertions.assertEquals("uwfzitonpe", model.actionsRequired()); + Assertions.assertEquals("ciqihnhung", model.description()); + Assertions.assertEquals("jzrnf", model.actionsRequired()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesDeleteMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesDeleteMockTests.java index f4c88d56bf85..3dafbdb2cc51 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesDeleteMockTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesDeleteMockTests.java @@ -6,8 +6,8 @@ import com.azure.core.credential.AccessToken; import com.azure.core.http.HttpClient; -import com.azure.core.management.AzureEnvironment; import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; import com.azure.core.test.http.MockHttpResponse; import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; import java.nio.charset.StandardCharsets; @@ -25,9 +25,9 @@ public void testDelete() throws Exception { RedisEnterpriseManager manager = RedisEnterpriseManager.configure() .withHttpClient(httpClient) .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), - new AzureProfile("", "", AzureEnvironment.AZURE)); + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); - manager.redisEnterprises().delete("alpbuxwgipwhon", "wkgshwa", com.azure.core.util.Context.NONE); + manager.redisEnterprises().delete("e", "csonpclhoco", com.azure.core.util.Context.NONE); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesListSkusForScalingWithResponseMockTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesListSkusForScalingWithResponseMockTests.java new file mode 100644 index 000000000000..7befca1629ce --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/RedisEnterprisesListSkusForScalingWithResponseMockTests.java @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.generated; + +import com.azure.core.credential.AccessToken; +import com.azure.core.http.HttpClient; +import com.azure.core.management.profile.AzureProfile; +import com.azure.core.models.AzureCloud; +import com.azure.core.test.http.MockHttpResponse; +import com.azure.resourcemanager.redisenterprise.RedisEnterpriseManager; +import com.azure.resourcemanager.redisenterprise.models.SkuDetailsList; +import java.nio.charset.StandardCharsets; +import java.time.OffsetDateTime; +import org.junit.jupiter.api.Test; +import reactor.core.publisher.Mono; + +public final class RedisEnterprisesListSkusForScalingWithResponseMockTests { + @Test + public void testListSkusForScalingWithResponse() throws Exception { + String responseStr + = "{\"skus\":[{\"name\":\"nuqszfkbey\",\"sizeInGB\":80.61801},{\"name\":\"mjmwvvjektcx\",\"sizeInGB\":86.37973},{\"name\":\"wlrsffrzpwv\",\"sizeInGB\":91.72675},{\"name\":\"gbiqylihkaet\",\"sizeInGB\":56.222622}]}"; + + HttpClient httpClient + = response -> Mono.just(new MockHttpResponse(response, 200, responseStr.getBytes(StandardCharsets.UTF_8))); + RedisEnterpriseManager manager = RedisEnterpriseManager.configure() + .withHttpClient(httpClient) + .authenticate(tokenRequestContext -> Mono.just(new AccessToken("this_is_a_token", OffsetDateTime.MAX)), + new AzureProfile("", "", AzureCloud.AZURE_PUBLIC_CLOUD)); + + SkuDetailsList response = manager.redisEnterprises() + .listSkusForScalingWithResponse("noc", "koklya", com.azure.core.util.Context.NONE) + .getValue(); + + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsListInnerTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsListInnerTests.java new file mode 100644 index 000000000000..dc3eeb4480c3 --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsListInnerTests.java @@ -0,0 +1,27 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.generated; + +import com.azure.core.util.BinaryData; +import com.azure.resourcemanager.redisenterprise.fluent.models.SkuDetailsListInner; +import com.azure.resourcemanager.redisenterprise.models.SkuDetails; +import java.util.Arrays; + +public final class SkuDetailsListInnerTests { + @org.junit.jupiter.api.Test + public void testDeserialize() throws Exception { + SkuDetailsListInner model = BinaryData + .fromString( + "{\"skus\":[{\"name\":\"kexxppof\",\"sizeInGB\":93.731895},{\"name\":\"c\",\"sizeInGB\":9.220636}]}") + .toObject(SkuDetailsListInner.class); + } + + @org.junit.jupiter.api.Test + public void testSerialize() throws Exception { + SkuDetailsListInner model + = new SkuDetailsListInner().withSkus(Arrays.asList(new SkuDetails(), new SkuDetails())); + model = BinaryData.fromObject(model).toObject(SkuDetailsListInner.class); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsTests.java new file mode 100644 index 000000000000..fe533f70c7dc --- /dev/null +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuDetailsTests.java @@ -0,0 +1,22 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.redisenterprise.generated; + +import com.azure.core.util.BinaryData; +import com.azure.resourcemanager.redisenterprise.models.SkuDetails; + +public final class SkuDetailsTests { + @org.junit.jupiter.api.Test + public void testDeserialize() throws Exception { + SkuDetails model + = BinaryData.fromString("{\"name\":\"ddtocjjxhvp\",\"sizeInGB\":41.112267}").toObject(SkuDetails.class); + } + + @org.junit.jupiter.api.Test + public void testSerialize() throws Exception { + SkuDetails model = new SkuDetails(); + model = BinaryData.fromObject(model).toObject(SkuDetails.class); + } +} diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuTests.java index cfe0e6638d80..39827aa613c8 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/SkuTests.java @@ -13,16 +13,16 @@ public final class SkuTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { Sku model - = BinaryData.fromString("{\"name\":\"MemoryOptimized_M50\",\"capacity\":1373520670}").toObject(Sku.class); - Assertions.assertEquals(SkuName.MEMORY_OPTIMIZED_M50, model.name()); - Assertions.assertEquals(1373520670, model.capacity()); + = BinaryData.fromString("{\"name\":\"FlashOptimized_A500\",\"capacity\":355528987}").toObject(Sku.class); + Assertions.assertEquals(SkuName.FLASH_OPTIMIZED_A500, model.name()); + Assertions.assertEquals(355528987, model.capacity()); } @org.junit.jupiter.api.Test public void testSerialize() throws Exception { - Sku model = new Sku().withName(SkuName.MEMORY_OPTIMIZED_M50).withCapacity(1373520670); + Sku model = new Sku().withName(SkuName.FLASH_OPTIMIZED_A500).withCapacity(355528987); model = BinaryData.fromObject(model).toObject(Sku.class); - Assertions.assertEquals(SkuName.MEMORY_OPTIMIZED_M50, model.name()); - Assertions.assertEquals(1373520670, model.capacity()); + Assertions.assertEquals(SkuName.FLASH_OPTIMIZED_A500, model.name()); + Assertions.assertEquals(355528987, model.capacity()); } } diff --git a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/UserAssignedIdentityTests.java b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/UserAssignedIdentityTests.java index 61be7cf205f7..b56a7d085f01 100644 --- a/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/UserAssignedIdentityTests.java +++ b/sdk/redisenterprise/azure-resourcemanager-redisenterprise/src/test/java/com/azure/resourcemanager/redisenterprise/generated/UserAssignedIdentityTests.java @@ -11,7 +11,7 @@ public final class UserAssignedIdentityTests { @org.junit.jupiter.api.Test public void testDeserialize() throws Exception { UserAssignedIdentity model = BinaryData.fromString( - "{\"principalId\":\"75a303e1-7d83-4eb2-bc8c-0b5172196464\",\"clientId\":\"f496c6eb-768f-447a-b799-74a1db57c2bb\"}") + "{\"principalId\":\"9407890f-4fdb-4374-9882-3e628501d403\",\"clientId\":\"c47b80d9-a76a-4fd3-a02a-c2265ffc5340\"}") .toObject(UserAssignedIdentity.class); }