diff --git a/eng/versioning/version_client.txt b/eng/versioning/version_client.txt
index a6fc6182a515..7f4b09d35838 100644
--- a/eng/versioning/version_client.txt
+++ b/eng/versioning/version_client.txt
@@ -475,7 +475,7 @@ com.azure.resourcemanager:azure-resourcemanager-mongocluster;1.1.0;1.2.0-beta.2
com.azure.resourcemanager:azure-resourcemanager-computefleet;1.0.0;1.1.0-beta.4
com.azure.resourcemanager:azure-resourcemanager-servicefabricmanagedclusters;1.1.0;1.2.0-beta.1
com.azure.resourcemanager:azure-resourcemanager-healthdataaiservices;1.0.0;1.1.0-beta.1
-com.azure.resourcemanager:azure-resourcemanager-redhatopenshift;1.0.0-beta.1;1.0.0-beta.2
+com.azure.resourcemanager:azure-resourcemanager-redhatopenshift;1.0.0-beta.1;1.0.0
com.azure.resourcemanager:azure-resourcemanager-fabric;1.0.0;1.1.0-beta.1
com.azure.resourcemanager:azure-resourcemanager-computeschedule;1.1.0;1.2.0-beta.2
com.azure.resourcemanager:azure-resourcemanager-trustedsigning;1.0.0-beta.2;1.0.0-beta.3
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/CHANGELOG.md b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/CHANGELOG.md
index 9c37b9e9819f..4941bfaaa0d5 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/CHANGELOG.md
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/CHANGELOG.md
@@ -1,14 +1,204 @@
# Release History
-## 1.0.0-beta.2 (Unreleased)
+## 1.0.0 (2026-06-23)
-### Features Added
+- Azure Resource Manager RedHatOpenShift client library for Java. This package contains Microsoft Azure SDK for RedHatOpenShift Management SDK. Rest API for Azure Red Hat OpenShift 4. Package api-version 2025-07-25. 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.SyncIdentityProviders` was removed
+
+#### `models.SyncSet$Update` was removed
+
+#### `models.MachinePoolList` was removed
+
+#### `models.MachinePools` was removed
+
+#### `models.SyncIdentityProvider$DefinitionStages` was removed
+
+#### `models.Secret$UpdateStages` was removed
+
+#### `models.SyncSet$UpdateStages` was removed
+
+#### `models.SyncIdentityProviderUpdate` was removed
+
+#### `models.MachinePool$Update` was removed
+
+#### `models.SyncSet` was removed
+
+#### `models.SyncSetList` was removed
+
+#### `models.MachinePool$UpdateStages` was removed
+
+#### `models.Secret` was removed
+
+#### `models.OperationList` was removed
+
+#### `models.SecretList` was removed
+
+#### `models.SyncIdentityProviderList` was removed
+
+#### `models.Secrets` was removed
+
+#### `models.OpenShiftClusterList` was removed
+
+#### `models.SyncIdentityProvider$UpdateStages` was removed
+
+#### `models.SyncSets` was removed
+
+#### `models.MachinePool$Definition` was removed
+
+#### `models.Secret$Update` was removed
+
+#### `models.Secret$DefinitionStages` was removed
+
+#### `models.SyncIdentityProvider$Update` was removed
+
+#### `models.SyncSetUpdate` was removed
+
+#### `models.OpenShiftVersionList` was removed
+
+#### `models.SyncSet$DefinitionStages` was removed
+
+#### `models.MachinePool` was removed
+
+#### `models.MachinePoolUpdate` was removed
+
+#### `models.Secret$Definition` was removed
+
+#### `models.SecretUpdate` was removed
+
+#### `models.SyncSet$Definition` was removed
+
+#### `models.MachinePool$DefinitionStages` was removed
+
+#### `models.SyncIdentityProvider$Definition` was removed
+
+#### `models.SyncIdentityProvider` was removed
+
+#### `models.WorkerProfile` was modified
+
+* `validate()` was removed
+
+#### `models.MasterProfile` was modified
+
+* `validate()` was removed
+
+#### `models.NetworkProfile` was modified
+
+* `validate()` was removed
+
+#### `models.ServicePrincipalProfile` was modified
+
+* `validate()` was removed
+
+#### `models.ManagedOutboundIPs` was modified
+
+* `validate()` was removed
+
+#### `models.EffectiveOutboundIp` was modified
+
+* `EffectiveOutboundIp()` was changed to private access
+* `validate()` was removed
+* `withId(java.lang.String)` was removed
+
+#### `models.ApiServerProfile` was modified
+
+* `validate()` was removed
+
+#### `models.IngressProfile` was modified
+
+* `validate()` was removed
+
+#### `RedHatOpenShiftManager` was modified
+
+* `fluent.AzureRedHatOpenShiftClient serviceClient()` -> `fluent.RedHatOpenShiftManagementClient serviceClient()`
+* `syncSets()` was removed
+* `syncIdentityProviders()` was removed
+* `machinePools()` was removed
+* `secrets()` was removed
+
+#### `models.ClusterProfile` was modified
+
+* `validate()` was removed
+
+#### `models.OpenShiftClusterUpdate` was modified
+
+* `validate()` was removed
+* `systemData()` was removed
+
+#### `models.LoadBalancerProfile` was modified
+
+* `validate()` was removed
+
+#### `models.Display` was modified
+
+* `Display()` was changed to private access
+* `validate()` was removed
+* `withOperation(java.lang.String)` was removed
+* `withProvider(java.lang.String)` was removed
+* `withResource(java.lang.String)` was removed
+* `withDescription(java.lang.String)` was removed
+
+#### `models.ConsoleProfile` was modified
+
+* `validate()` was removed
+
+### Features Added
+
+* `models.PlatformWorkloadIdentityRoleSetOperations` was added
+
+* `models.PlatformWorkloadIdentityProfile` was added
+
+* `models.PlatformWorkloadIdentityRoleSets` was added
+
+* `models.UserAssignedIdentity` was added
+
+* `models.PlatformWorkloadIdentityRole` was added
+
+* `models.ManagedServiceIdentityType` was added
+
+* `models.PlatformWorkloadIdentity` was added
+
+* `models.ManagedServiceIdentity` was added
+
+* `models.PlatformWorkloadIdentityRoleSet` was added
+
+#### `models.OpenShiftCluster$Definition` was modified
+
+* `withIdentity(models.ManagedServiceIdentity)` was added
+* `withPlatformWorkloadIdentityProfile(models.PlatformWorkloadIdentityProfile)` was added
+
+#### `models.OpenShiftCluster$Update` was modified
+
+* `withPlatformWorkloadIdentityProfile(models.PlatformWorkloadIdentityProfile)` was added
+* `withIdentity(models.ManagedServiceIdentity)` was added
+
+#### `models.OpenShiftVersions` was modified
+
+* `getWithResponse(java.lang.String,java.lang.String,com.azure.core.util.Context)` was added
+* `get(java.lang.String,java.lang.String)` was added
+
+#### `models.OpenShiftCluster` was modified
+
+* `identity()` was added
+* `platformWorkloadIdentityProfile()` was added
+
+#### `RedHatOpenShiftManager` was modified
+
+* `platformWorkloadIdentityRoleSets()` was added
+* `platformWorkloadIdentityRoleSetOperations()` was added
+
+#### `models.ClusterProfile` was modified
+
+* `oidcIssuer()` was added
+
+#### `models.OpenShiftClusterUpdate` was modified
-### Other Changes
+* `withPlatformWorkloadIdentityProfile(models.PlatformWorkloadIdentityProfile)` was added
+* `platformWorkloadIdentityProfile()` was added
+* `withIdentity(models.ManagedServiceIdentity)` was added
+* `identity()` was added
## 1.0.0-beta.1 (2024-08-21)
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/README.md b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/README.md
index 709fa11c38de..6bd888dbf6d8 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/README.md
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/README.md
@@ -1,8 +1,8 @@
-# Azure Resource Manager Red Hat Open Shift client library for Java
+# Azure Resource Manager RedHatOpenShift client library for Java
-Azure Resource Manager Red Hat Open Shift client library for Java.
+Azure Resource Manager RedHatOpenShift client library for Java.
-This package contains Microsoft Azure SDK for Red Hat Open Shift Management SDK. Rest API for Azure Red Hat OpenShift 4. Package tag package-2023-11. 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 RedHatOpenShift Management SDK. Rest API for Azure Red Hat OpenShift 4. Package api-version 2025-07-25. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## We'd love to hear your feedback
@@ -32,7 +32,7 @@ Various documentation is available to help you get started
com.azure.resourcemanager
azure-resourcemanager-redhatopenshift
- 1.0.0-beta.2
+ 1.0.0
```
[//]: # ({x-version-update-end})
@@ -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 @@ RedHatOpenShiftManager manager = RedHatOpenShiftManager
.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.
@@ -100,5 +100,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/redhatopenshift/azure-resourcemanager-redhatopenshift/SAMPLE.md b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/SAMPLE.md
index 94921946c93e..78b227486631 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/SAMPLE.md
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/SAMPLE.md
@@ -1,14 +1,6 @@
# Code snippets and samples
-## MachinePools
-
-- [CreateOrUpdate](#machinepools_createorupdate)
-- [Delete](#machinepools_delete)
-- [Get](#machinepools_get)
-- [List](#machinepools_list)
-- [Update](#machinepools_update)
-
## OpenShiftClusters
- [CreateOrUpdate](#openshiftclusters_createorupdate)
@@ -22,170 +14,20 @@
## OpenShiftVersions
+- [Get](#openshiftversions_get)
- [List](#openshiftversions_list)
## Operations
- [List](#operations_list)
-## Secrets
-
-- [CreateOrUpdate](#secrets_createorupdate)
-- [Delete](#secrets_delete)
-- [Get](#secrets_get)
-- [List](#secrets_list)
-- [Update](#secrets_update)
-
-## SyncIdentityProviders
-
-- [CreateOrUpdate](#syncidentityproviders_createorupdate)
-- [Delete](#syncidentityproviders_delete)
-- [Get](#syncidentityproviders_get)
-- [List](#syncidentityproviders_list)
-- [Update](#syncidentityproviders_update)
-
-## SyncSets
-
-- [CreateOrUpdate](#syncsets_createorupdate)
-- [Delete](#syncsets_delete)
-- [Get](#syncsets_get)
-- [List](#syncsets_list)
-- [Update](#syncsets_update)
-### MachinePools_CreateOrUpdate
-
-```java
-/**
- * Samples for MachinePools CreateOrUpdate.
- */
-public final class MachinePoolsCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/MachinePools_CreateOrUpdate.json
- */
- /**
- * Sample code: Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void createsOrUpdatesAMachinePoolWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.machinePools()
- .define("childResourceName")
- .withExistingOpenshiftcluster("resourceGroup", "resourceName")
- .withResources(
- "ewogICAgImFwaVZlcnNpb24iOiAiaGl2ZS5vcGVuc2hpZnQuaW8vdjEiLAogICAgImtpbmQiOiAiTWFjaGluZVBvb2wiLAogICAgIm1ldGFkYXRhIjogewogICAgICAgICJuYW1lIjogInRlc3QtY2x1c3Rlci13b3JrZXIiLAogICAgICAgICJuYW1lc3BhY2UiOiAiYXJvLWY2MGFlOGEyLWJjYTEtNDk4Ny05MDU2LVhYWFhYWFhYWFhYWCIKICAgIH0sCiAgICAic3BlYyI6IHsKICAgICAgICAiY2x1c3RlckRlcGxveW1lbnRSZWYiOiB7CiAgICAgICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIKICAgICAgICB9LAogICAgICAgICJuYW1lIjogIndvcmtlciIsCiAgICAgICAgInBsYXRmb3JtIjogewogICAgICAgICAgICAiYXdzIjogewogICAgICAgICAgICAgICAgInJvb3RWb2x1bWUiOiB7CiAgICAgICAgICAgICAgICAgICAgImlvcHMiOiAwLAogICAgICAgICAgICAgICAgICAgICJzaXplIjogMzAwLAogICAgICAgICAgICAgICAgICAgICJ0eXBlIjogImdwMyIKICAgICAgICAgICAgICAgIH0sCiAgICAgICAgICAgICAgICAidHlwZSI6ICJtNS54bGFyZ2UiLAogICAgICAgICAgICAgICAgInpvbmVzIjogWwogICAgICAgICAgICAgICAgICAgICJ1cy1lYXN0LTFhIgogICAgICAgICAgICAgICAgXQogICAgICAgICAgICB9CiAgICAgICAgfSwKICAgICAgICAicmVwbGljYXMiOiAyCiAgICB9LAogICAgInN0YXR1cyI6IHsKICAgICAgICAiY29uZGl0aW9ucyI6IFsKICAgICAgICBdCiAgICB9Cn0K")
- .create();
- }
-}
-```
-
-### MachinePools_Delete
-
-```java
-/**
- * Samples for MachinePools Delete.
- */
-public final class MachinePoolsDeleteSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/MachinePools_Delete.json
- */
- /**
- * Sample code: Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void deletesAMachinePoolWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.machinePools()
- .deleteWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### MachinePools_Get
-
-```java
-/**
- * Samples for MachinePools Get.
- */
-public final class MachinePoolsGetSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/MachinePools_Get.json
- */
- /**
- * Sample code: Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void getsAMachinePoolWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.machinePools()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
+## PlatformWorkloadIdentityRoleSetOperation
-### MachinePools_List
+- [Get](#platformworkloadidentityrolesetoperation_get)
-```java
-/**
- * Samples for MachinePools List.
- */
-public final class MachinePoolsListSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/MachinePools_List.json
- */
- /**
- * Sample code: Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void listsMachinePoolsThatBelongToThatAzureRedHatOpenShiftCluster(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.machinePools().list("resourceGroup", "resourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### MachinePools_Update
-
-```java
-import com.azure.resourcemanager.redhatopenshift.models.MachinePool;
-
-/**
- * Samples for MachinePools Update.
- */
-public final class MachinePoolsUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/MachinePools_Update.json
- */
- /**
- * Sample code: Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void updatesAMachinePoolWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- MachinePool resource = manager.machinePools()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE)
- .getValue();
- resource.update()
- .withResources(
- "ewogICAgImFwaVZlcnNpb24iOiAiaGl2ZS5vcGVuc2hpZnQuaW8vdjEiLAogICAgImtpbmQiOiAiTWFjaGluZVBvb2wiLAogICAgIm1ldGFkYXRhIjogewogICAgICAgICJuYW1lIjogInRlc3QtY2x1c3Rlci13b3JrZXIiLAogICAgICAgICJuYW1lc3BhY2UiOiAiYXJvLWY2MGFlOGEyLWJjYTEtNDk4Ny05MDU2LVhYWFhYWFhYWFhYWCIKICAgIH0sCiAgICAic3BlYyI6IHsKICAgICAgICAiY2x1c3RlckRlcGxveW1lbnRSZWYiOiB7CiAgICAgICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIKICAgICAgICB9LAogICAgICAgICJuYW1lIjogIndvcmtlciIsCiAgICAgICAgInBsYXRmb3JtIjogewogICAgICAgICAgICAiYXdzIjogewogICAgICAgICAgICAgICAgInJvb3RWb2x1bWUiOiB7CiAgICAgICAgICAgICAgICAgICAgImlvcHMiOiAwLAogICAgICAgICAgICAgICAgICAgICJzaXplIjogMzAwLAogICAgICAgICAgICAgICAgICAgICJ0eXBlIjogImdwMyIKICAgICAgICAgICAgICAgIH0sCiAgICAgICAgICAgICAgICAidHlwZSI6ICJtNS54bGFyZ2UiLAogICAgICAgICAgICAgICAgInpvbmVzIjogWwogICAgICAgICAgICAgICAgICAgICJ1cy1lYXN0LTFhIgogICAgICAgICAgICAgICAgXQogICAgICAgICAgICB9CiAgICAgICAgfSwKICAgICAgICAicmVwbGljYXMiOiAyCiAgICB9LAogICAgInN0YXR1cyI6IHsKICAgICAgICAiY29uZGl0aW9ucyI6IFsKICAgICAgICBdCiAgICB9Cn0K")
- .apply();
- }
-}
-```
+## PlatformWorkloadIdentityRoleSets
+- [List](#platformworkloadidentityrolesets_list)
### OpenShiftClusters_CreateOrUpdate
```java
@@ -197,10 +39,15 @@ import com.azure.resourcemanager.redhatopenshift.models.FipsValidatedModules;
import com.azure.resourcemanager.redhatopenshift.models.IngressProfile;
import com.azure.resourcemanager.redhatopenshift.models.LoadBalancerProfile;
import com.azure.resourcemanager.redhatopenshift.models.ManagedOutboundIPs;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentity;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentityType;
import com.azure.resourcemanager.redhatopenshift.models.MasterProfile;
import com.azure.resourcemanager.redhatopenshift.models.NetworkProfile;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentity;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityProfile;
import com.azure.resourcemanager.redhatopenshift.models.PreconfiguredNsg;
import com.azure.resourcemanager.redhatopenshift.models.ServicePrincipalProfile;
+import com.azure.resourcemanager.redhatopenshift.models.UserAssignedIdentity;
import com.azure.resourcemanager.redhatopenshift.models.Visibility;
import com.azure.resourcemanager.redhatopenshift.models.WorkerProfile;
import java.util.Arrays;
@@ -212,9 +59,7 @@ import java.util.Map;
*/
public final class OpenShiftClustersCreateOrUpdateSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_CreateOrUpdate.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_CreateOrUpdate.json
*/
/**
* Sample code: Creates or updates a OpenShift cluster with the specified subscription, resource group and resource
@@ -229,13 +74,18 @@ public final class OpenShiftClustersCreateOrUpdateSamples {
.withRegion("location")
.withExistingResourceGroup("resourceGroup")
.withTags(mapOf("key", "fakeTokenPlaceholder"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED)
+ .withUserAssignedIdentities(mapOf("", new UserAssignedIdentity())))
.withClusterProfile(new ClusterProfile().withPullSecret("fakeTokenPlaceholder")
.withDomain("cluster.location.aroapp.io")
- .withResourceGroupId("/subscriptions/subscriptionId/resourceGroups/clusterResourceGroup")
+ .withResourceGroupId(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clusterResourceGroup")
.withFipsValidatedModules(FipsValidatedModules.ENABLED))
.withConsoleProfile(new ConsoleProfile())
.withServicePrincipalProfile(
new ServicePrincipalProfile().withClientId("clientId").withClientSecret("fakeTokenPlaceholder"))
+ .withPlatformWorkloadIdentityProfile(new PlatformWorkloadIdentityProfile()
+ .withPlatformWorkloadIdentities(mapOf("", new PlatformWorkloadIdentity())))
.withNetworkProfile(new NetworkProfile().withPodCidr("10.128.0.0/14")
.withServiceCidr("172.30.0.0/16")
.withLoadBalancerProfile(
@@ -243,13 +93,13 @@ public final class OpenShiftClustersCreateOrUpdateSamples {
.withPreconfiguredNsg(PreconfiguredNsg.DISABLED))
.withMasterProfile(new MasterProfile().withVmSize("Standard_D8s_v3")
.withSubnetId(
- "/subscriptions/subscriptionId/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/master")
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/master")
.withEncryptionAtHost(EncryptionAtHost.ENABLED))
.withWorkerProfiles(Arrays.asList(new WorkerProfile().withName("worker")
.withVmSize("Standard_D2s_v3")
.withDiskSizeGB(128)
.withSubnetId(
- "/subscriptions/subscriptionId/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/worker")
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/worker")
.withCount(3)))
.withApiserverProfile(new ApiServerProfile().withVisibility(Visibility.PUBLIC))
.withIngressProfiles(
@@ -279,9 +129,7 @@ public final class OpenShiftClustersCreateOrUpdateSamples {
*/
public final class OpenShiftClustersDeleteSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_Delete.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_Delete.json
*/
/**
* Sample code: Deletes a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -303,9 +151,7 @@ public final class OpenShiftClustersDeleteSamples {
*/
public final class OpenShiftClustersGetByResourceGroupSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_Get.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_Get.json
*/
/**
* Sample code: Gets a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -328,9 +174,7 @@ public final class OpenShiftClustersGetByResourceGroupSamples {
*/
public final class OpenShiftClustersListSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_List.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_List.json
*/
/**
* Sample code: Lists OpenShift clusters in the specified subscription.
@@ -352,9 +196,7 @@ public final class OpenShiftClustersListSamples {
*/
public final class OpenShiftClustersListAdminCredentialsSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_ListAdminCredentials.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_ListAdminCredentials.json
*/
/**
* Sample code: Lists admin kubeconfig of an OpenShift cluster with the specified subscription, resource group and
@@ -378,9 +220,7 @@ public final class OpenShiftClustersListAdminCredentialsSamples {
*/
public final class OpenShiftClustersListByResourceGroupSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_ListByResourceGroup.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_ListByResourceGroup.json
*/
/**
* Sample code: Lists OpenShift clusters in the specified subscription and resource group.
@@ -402,9 +242,7 @@ public final class OpenShiftClustersListByResourceGroupSamples {
*/
public final class OpenShiftClustersListCredentialsSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_ListCredentials.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_ListCredentials.json
*/
/**
* Sample code: Lists credentials of an OpenShift cluster with the specified subscription, resource group and
@@ -431,11 +269,16 @@ import com.azure.resourcemanager.redhatopenshift.models.FipsValidatedModules;
import com.azure.resourcemanager.redhatopenshift.models.IngressProfile;
import com.azure.resourcemanager.redhatopenshift.models.LoadBalancerProfile;
import com.azure.resourcemanager.redhatopenshift.models.ManagedOutboundIPs;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentity;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentityType;
import com.azure.resourcemanager.redhatopenshift.models.MasterProfile;
import com.azure.resourcemanager.redhatopenshift.models.NetworkProfile;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftCluster;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentity;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityProfile;
import com.azure.resourcemanager.redhatopenshift.models.PreconfiguredNsg;
import com.azure.resourcemanager.redhatopenshift.models.ServicePrincipalProfile;
+import com.azure.resourcemanager.redhatopenshift.models.UserAssignedIdentity;
import com.azure.resourcemanager.redhatopenshift.models.Visibility;
import com.azure.resourcemanager.redhatopenshift.models.WorkerProfile;
import java.util.Arrays;
@@ -447,29 +290,33 @@ import java.util.Map;
*/
public final class OpenShiftClustersUpdateSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftClusters_Update.json
+ * x-ms-original-file: 2025-07-25/OpenShiftClusters_Update.json
*/
/**
- * Sample code: Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Sample code: Creates or updates a OpenShift cluster with the specified subscription, resource group and resource
+ * name.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void updatesAOpenShiftClusterWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
+ public static void createsOrUpdatesAOpenShiftClusterWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
OpenShiftCluster resource = manager.openShiftClusters()
.getByResourceGroupWithResponse("resourceGroup", "resourceName", com.azure.core.util.Context.NONE)
.getValue();
resource.update()
.withTags(mapOf("key", "fakeTokenPlaceholder"))
+ .withIdentity(new ManagedServiceIdentity().withType(ManagedServiceIdentityType.USER_ASSIGNED)
+ .withUserAssignedIdentities(mapOf("", new UserAssignedIdentity())))
.withClusterProfile(new ClusterProfile().withPullSecret("fakeTokenPlaceholder")
.withDomain("cluster.location.aroapp.io")
- .withResourceGroupId("/subscriptions/subscriptionId/resourceGroups/clusterResourceGroup")
+ .withResourceGroupId(
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/clusterResourceGroup")
.withFipsValidatedModules(FipsValidatedModules.ENABLED))
.withConsoleProfile(new ConsoleProfile())
.withServicePrincipalProfile(
new ServicePrincipalProfile().withClientId("clientId").withClientSecret("fakeTokenPlaceholder"))
+ .withPlatformWorkloadIdentityProfile(new PlatformWorkloadIdentityProfile()
+ .withPlatformWorkloadIdentities(mapOf("", new PlatformWorkloadIdentity())))
.withNetworkProfile(new NetworkProfile().withPodCidr("10.128.0.0/14")
.withServiceCidr("172.30.0.0/16")
.withLoadBalancerProfile(
@@ -477,13 +324,13 @@ public final class OpenShiftClustersUpdateSamples {
.withPreconfiguredNsg(PreconfiguredNsg.DISABLED))
.withMasterProfile(new MasterProfile().withVmSize("Standard_D8s_v3")
.withSubnetId(
- "/subscriptions/subscriptionId/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/master")
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/master")
.withEncryptionAtHost(EncryptionAtHost.ENABLED))
.withWorkerProfiles(Arrays.asList(new WorkerProfile().withName("worker")
.withVmSize("Standard_D2s_v3")
.withDiskSizeGB(128)
.withSubnetId(
- "/subscriptions/subscriptionId/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/worker")
+ "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/vnetResourceGroup/providers/Microsoft.Network/virtualNetworks/vnet/subnets/worker")
.withCount(3)))
.withApiserverProfile(new ApiServerProfile().withVisibility(Visibility.PUBLIC))
.withIngressProfiles(
@@ -505,451 +352,117 @@ public final class OpenShiftClustersUpdateSamples {
}
```
-### OpenShiftVersions_List
-
-```java
-/**
- * Samples for OpenShiftVersions List.
- */
-public final class OpenShiftVersionsListSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/OpenShiftVersions_List.json
- */
- /**
- * Sample code: Lists all OpenShift versions available to install in the specified location.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void listsAllOpenShiftVersionsAvailableToInstallInTheSpecifiedLocation(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.openShiftVersions().list("location", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### Operations_List
-
-```java
-/**
- * Samples for Operations List.
- */
-public final class OperationsListSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Operations_List.json
- */
- /**
- * Sample code: Lists all of the available RP operations.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void
- listsAllOfTheAvailableRPOperations(com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.operations().list(com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### Secrets_CreateOrUpdate
+### OpenShiftVersions_Get
```java
/**
- * Samples for Secrets CreateOrUpdate.
+ * Samples for OpenShiftVersions Get.
*/
-public final class SecretsCreateOrUpdateSamples {
+public final class OpenShiftVersionsGetSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Secrets_CreateOrUpdate.json
+ * x-ms-original-file: 2025-07-25/OpenShiftVersions_Get.json
*/
/**
- * Sample code: Creates or updates a Secret with the specified subscription, resource group and resource name.
+ * Sample code: Gets an available OpenShift version to install in the specified location.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void createsOrUpdatesASecretWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
+ public static void getsAnAvailableOpenShiftVersionToInstallInTheSpecifiedLocation(
com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.secrets()
- .define("childResourceName")
- .withExistingOpenshiftcluster("resourceGroup", "resourceName")
- .create();
+ manager.openShiftVersions().getWithResponse("location", "4.14.40", com.azure.core.util.Context.NONE);
}
}
```
-### Secrets_Delete
-
-```java
-/**
- * Samples for Secrets Delete.
- */
-public final class SecretsDeleteSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Secrets_Delete.json
- */
- /**
- * Sample code: Deletes a Secret with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void deletesASecretWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.secrets()
- .deleteWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### Secrets_Get
-
-```java
-/**
- * Samples for Secrets Get.
- */
-public final class SecretsGetSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Secrets_Get.json
- */
- /**
- * Sample code: Gets a Secret with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void getsASecretWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.secrets()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### Secrets_List
-
-```java
-/**
- * Samples for Secrets List.
- */
-public final class SecretsListSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Secrets_List.json
- */
- /**
- * Sample code: Lists Secrets that belong to that Azure Red Hat OpenShift Cluster.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void listsSecretsThatBelongToThatAzureRedHatOpenShiftCluster(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.secrets().list("resourceGroup", "resourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### Secrets_Update
-
-```java
-import com.azure.resourcemanager.redhatopenshift.models.Secret;
-
-/**
- * Samples for Secrets Update.
- */
-public final class SecretsUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/Secrets_Update.json
- */
- /**
- * Sample code: Updates a Secret with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void updatesASecretWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- Secret resource = manager.secrets()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE)
- .getValue();
- resource.update().apply();
- }
-}
-```
-
-### SyncIdentityProviders_CreateOrUpdate
-
-```java
-/**
- * Samples for SyncIdentityProviders CreateOrUpdate.
- */
-public final class SyncIdentityProvidersCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncIdentityProviders_CreateOrUpdate.json
- */
- /**
- * Sample code: Creates or updates a SyncIdentityProvider with the specified subscription, resource group and
- * resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void createsOrUpdatesASyncIdentityProviderWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncIdentityProviders()
- .define("childResourceName")
- .withExistingOpenshiftcluster("resourceGroup", "resourceName")
- .withResources(
- "ewogICAgImFwaVZlcnNpb24iOiAiaGl2ZS5vcGVuc2hpZnQuaW8vdjEiLAogICAgImtpbmQiOiAiU3luY0lkZW50aXR5UHJvdmlkZXIiLAogICAgIm1ldGFkYXRhIjogewogICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIsCiAgICAgICAgIm5hbWVzcGFjZSI6ICJhcm8tZjYwYWU4YTItYmNhMS00OTg3LTkwNTYtWFhYWFhYWFhYWFhYIgogICAgfSwKICAgICJzcGVjIjogewogICAgICAgICJjbHVzdGVyRGVwbG95bWVudFJlZnMiOiBbCiAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIKICAgICAgICAgICAgfQogICAgICAgIF0sCiAgICAgICAgImlkZW50aXR5UHJvdmlkZXJzIjogWwogICAgICAgICAgICB7CiAgICAgICAgICAgICAgICAiaHRwYXNzd2QiOiB7CiAgICAgICAgICAgICAgICAgICAgImZpbGVEYXRhIjogewogICAgICAgICAgICAgICAgICAgICAgICAibmFtZSI6ICJodHBhc3N3ZC1zZWNyZXQiCiAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgfSwKICAgICAgICAgICAgICAgICJtYXBwaW5nTWV0aG9kIjogImNsYWltIiwKICAgICAgICAgICAgICAgICJuYW1lIjogIkhUUGFzc3dkIiwKICAgICAgICAgICAgICAgICJ0eXBlIjogIkhUUGFzc3dkIgogICAgICAgICAgICB9CiAgICAgICAgXQogICAgfSwKICAgICJzdGF0dXMiOiB7fQp9Cg==")
- .create();
- }
-}
-```
-
-### SyncIdentityProviders_Delete
-
-```java
-/**
- * Samples for SyncIdentityProviders Delete.
- */
-public final class SyncIdentityProvidersDeleteSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncIdentityProviders_Delete.json
- */
- /**
- * Sample code: Deletes a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void deletesASyncIdentityProviderWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncIdentityProviders()
- .deleteWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SyncIdentityProviders_Get
-
-```java
-/**
- * Samples for SyncIdentityProviders Get.
- */
-public final class SyncIdentityProvidersGetSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncIdentityProviders_Get.json
- */
- /**
- * Sample code: Gets a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void getsASyncIdentityProviderWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncIdentityProviders()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SyncIdentityProviders_List
-
-```java
-/**
- * Samples for SyncIdentityProviders List.
- */
-public final class SyncIdentityProvidersListSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncIdentityProviders_List.json
- */
- /**
- * Sample code: Lists SyncIdentityProviders that belong to that Azure Red Hat OpenShift Cluster.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void listsSyncIdentityProvidersThatBelongToThatAzureRedHatOpenShiftCluster(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncIdentityProviders().list("resourceGroup", "resourceName", com.azure.core.util.Context.NONE);
- }
-}
-```
-
-### SyncIdentityProviders_Update
-
-```java
-import com.azure.resourcemanager.redhatopenshift.models.SyncIdentityProvider;
-
-/**
- * Samples for SyncIdentityProviders Update.
- */
-public final class SyncIdentityProvidersUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncIdentityProviders_Update.json
- */
- /**
- * Sample code: Updates a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void updatesASyncIdentityProviderWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- SyncIdentityProvider resource = manager.syncIdentityProviders()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE)
- .getValue();
- resource.update()
- .withResources(
- "ewogICAgImFwaVZlcnNpb24iOiAiaGl2ZS5vcGVuc2hpZnQuaW8vdjEiLAogICAgImtpbmQiOiAiU3luY0lkZW50aXR5UHJvdmlkZXIiLAogICAgIm1ldGFkYXRhIjogewogICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIsCiAgICAgICAgIm5hbWVzcGFjZSI6ICJhcm8tZjYwYWU4YTItYmNhMS00OTg3LTkwNTYtWFhYWFhYWFhYWFhYIgogICAgfSwKICAgICJzcGVjIjogewogICAgICAgICJjbHVzdGVyRGVwbG95bWVudFJlZnMiOiBbCiAgICAgICAgICAgIHsKICAgICAgICAgICAgICAgICJuYW1lIjogInRlc3QtY2x1c3RlciIKICAgICAgICAgICAgfQogICAgICAgIF0sCiAgICAgICAgImlkZW50aXR5UHJvdmlkZXJzIjogWwogICAgICAgICAgICB7CiAgICAgICAgICAgICAgICAiaHRwYXNzd2QiOiB7CiAgICAgICAgICAgICAgICAgICAgImZpbGVEYXRhIjogewogICAgICAgICAgICAgICAgICAgICAgICAibmFtZSI6ICJodHBhc3N3ZC1zZWNyZXQiCiAgICAgICAgICAgICAgICAgICAgfQogICAgICAgICAgICAgICAgfSwKICAgICAgICAgICAgICAgICJtYXBwaW5nTWV0aG9kIjogImNsYWltIiwKICAgICAgICAgICAgICAgICJuYW1lIjogIkhUUGFzc3dkIiwKICAgICAgICAgICAgICAgICJ0eXBlIjogIkhUUGFzc3dkIgogICAgICAgICAgICB9CiAgICAgICAgXQogICAgfSwKICAgICJzdGF0dXMiOiB7fQp9Cg==")
- .apply();
- }
-}
-```
-
-### SyncSets_CreateOrUpdate
-
-```java
-/**
- * Samples for SyncSets CreateOrUpdate.
- */
-public final class SyncSetsCreateOrUpdateSamples {
- /*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncSets_CreateOrUpdate.json
- */
- /**
- * Sample code: Creates or updates a SyncSet with the specified subscription, resource group and resource name.
- *
- * @param manager Entry point to RedHatOpenShiftManager.
- */
- public static void createsOrUpdatesASyncSetWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncSets()
- .define("childResourceName")
- .withExistingOpenshiftcluster("resourceGroup", "resourceName")
- .withResources(
- "eyAKICAiYXBpVmVyc2lvbiI6ICJoaXZlLm9wZW5zaGlmdC5pby92MSIsCiAgImtpbmQiOiAiU3luY1NldCIsCiAgIm1ldGFkYXRhIjogewogICAgIm5hbWUiOiAic2FtcGxlIiwKICAgICJuYW1lc3BhY2UiOiAiYXJvLWY2MGFlOGEyLWJjYTEtNDk4Ny05MDU2LWYyZjZhMTgzN2NhYSIKICB9LAogICJzcGVjIjogewogICAgImNsdXN0ZXJEZXBsb3ltZW50UmVmcyI6IFtdLAogICAgInJlc291cmNlcyI6IFsKICAgICAgewogICAgICAgICJhcGlWZXJzaW9uIjogInYxIiwKICAgICAgICAia2luZCI6ICJDb25maWdNYXAiLAogICAgICAgICJtZXRhZGF0YSI6IHsKICAgICAgICAgICJuYW1lIjogIm15Y29uZmlnbWFwIgogICAgICAgIH0KICAgICAgfQogICAgXQogIH0KfQo=")
- .create();
- }
-}
-```
-
-### SyncSets_Delete
+### OpenShiftVersions_List
```java
/**
- * Samples for SyncSets Delete.
+ * Samples for OpenShiftVersions List.
*/
-public final class SyncSetsDeleteSamples {
+public final class OpenShiftVersionsListSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncSets_Delete.json
+ * x-ms-original-file: 2025-07-25/OpenShiftVersions_List.json
*/
/**
- * Sample code: Deletes a SyncSet with the specified subscription, resource group and resource name.
+ * Sample code: Lists all OpenShift versions available to install in the specified location.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void deletesASyncSetWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
+ public static void listsAllOpenShiftVersionsAvailableToInstallInTheSpecifiedLocation(
com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncSets()
- .deleteWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
+ manager.openShiftVersions().list("location", com.azure.core.util.Context.NONE);
}
}
```
-### SyncSets_Get
+### Operations_List
```java
/**
- * Samples for SyncSets Get.
+ * Samples for Operations List.
*/
-public final class SyncSetsGetSamples {
+public final class OperationsListSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncSets_Get.json
+ * x-ms-original-file: 2025-07-25/Operations_List.json
*/
/**
- * Sample code: Gets a SyncSet with the specified subscription, resource group and resource name.
+ * Sample code: Lists all of the available RP operations.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void getsASyncSetWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncSets()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE);
+ public static void
+ listsAllOfTheAvailableRPOperations(com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
+ manager.operations().list(com.azure.core.util.Context.NONE);
}
}
```
-### SyncSets_List
+### PlatformWorkloadIdentityRoleSetOperation_Get
```java
/**
- * Samples for SyncSets List.
+ * Samples for PlatformWorkloadIdentityRoleSetOperation Get.
*/
-public final class SyncSetsListSamples {
+public final class PlatformWorkloadIdentityRoleSetOperationGetSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncSets_List.json
+ * x-ms-original-file: 2025-07-25/PlatformWorkloadIdentityRoleSet_Get.json
*/
/**
- * Sample code: Lists SyncSets that belong to that Azure Red Hat OpenShift Cluster.
+ * Sample code: Gets a mapping of an OpenShift version to identity requirements, which includes operatorName,
+ * roleDefinitionName, roleDefinitionId, and serviceAccounts.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void listsSyncSetsThatBelongToThatAzureRedHatOpenShiftCluster(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- manager.syncSets().list("resourceGroup", "resourceName", com.azure.core.util.Context.NONE);
+ public static void
+ getsAMappingOfAnOpenShiftVersionToIdentityRequirementsWhichIncludesOperatorNameRoleDefinitionNameRoleDefinitionIdAndServiceAccounts(
+ com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
+ manager.platformWorkloadIdentityRoleSetOperations()
+ .getWithResponse("location", "4.14", com.azure.core.util.Context.NONE);
}
}
```
-### SyncSets_Update
+### PlatformWorkloadIdentityRoleSets_List
```java
-import com.azure.resourcemanager.redhatopenshift.models.SyncSet;
-
/**
- * Samples for SyncSets Update.
+ * Samples for PlatformWorkloadIdentityRoleSets List.
*/
-public final class SyncSetsUpdateSamples {
+public final class PlatformWorkloadIdentityRoleSetsListSamples {
/*
- * x-ms-original-file:
- * specification/redhatopenshift/resource-manager/Microsoft.RedHatOpenShift/openshiftclusters/stable/2023-11-22/
- * examples/SyncSets_Update.json
+ * x-ms-original-file: 2025-07-25/PlatformWorkloadIdentityRoleSets_List.json
*/
/**
- * Sample code: Updates a SyncSet with the specified subscription, resource group and resource name.
+ * Sample code: Lists a mapping of OpenShift versions to identity requirements, which include operatorName,
+ * roleDefinitionName, roleDefinitionId, and serviceAccounts.
*
* @param manager Entry point to RedHatOpenShiftManager.
*/
- public static void updatesASyncSetWithTheSpecifiedSubscriptionResourceGroupAndResourceName(
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
- SyncSet resource = manager.syncSets()
- .getWithResponse("resourceGroup", "resourceName", "childResourceName", com.azure.core.util.Context.NONE)
- .getValue();
- resource.update()
- .withResources(
- "eyAKICAiYXBpVmVyc2lvbiI6ICJoaXZlLm9wZW5zaGlmdC5pby92MSIsCiAgImtpbmQiOiAiU3luY1NldCIsCiAgIm1ldGFkYXRhIjogewogICAgIm5hbWUiOiAic2FtcGxlIiwKICAgICJuYW1lc3BhY2UiOiAiYXJvLWY2MGFlOGEyLWJjYTEtNDk4Ny05MDU2LWYyZjZhMTgzN2NhYSIKICB9LAogICJzcGVjIjogewogICAgImNsdXN0ZXJEZXBsb3ltZW50UmVmcyI6IFtdLAogICAgInJlc291cmNlcyI6IFsKICAgICAgewogICAgICAgICJhcGlWZXJzaW9uIjogInYxIiwKICAgICAgICAia2luZCI6ICJDb25maWdNYXAiLAogICAgICAgICJtZXRhZGF0YSI6IHsKICAgICAgICAgICJuYW1lIjogIm15Y29uZmlnbWFwIgogICAgICAgIH0KICAgICAgfQogICAgXQogIH0KfQo=")
- .apply();
+ public static void
+ listsAMappingOfOpenShiftVersionsToIdentityRequirementsWhichIncludeOperatorNameRoleDefinitionNameRoleDefinitionIdAndServiceAccounts(
+ com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager) {
+ manager.platformWorkloadIdentityRoleSets().list("location", com.azure.core.util.Context.NONE);
}
}
```
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/pom.xml b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/pom.xml
index ae7139e05e8d..2efcfa715d7e 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/pom.xml
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/pom.xml
@@ -1,9 +1,9 @@
-
+
4.0.0
com.azure
@@ -14,11 +14,11 @@
com.azure.resourcemanager
azure-resourcemanager-redhatopenshift
- 1.0.0-beta.2
+ 1.0.0
jar
- Microsoft Azure SDK for Red Hat Open Shift Management
- This package contains Microsoft Azure SDK for Red Hat Open Shift Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Rest API for Azure Red Hat OpenShift 4. Package tag package-2023-11.
+ Microsoft Azure SDK for RedHatOpenShift Management
+ This package contains Microsoft Azure SDK for RedHatOpenShift Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Rest API for Azure Red Hat OpenShift 4. Package api-version 2025-07-25.
https://github.com/Azure/azure-sdk-for-java
@@ -45,14 +45,9 @@
UTF-8
0
0
- true
+ false
-
- com.azure
- azure-json
- 1.5.1
-
com.azure
azure-core
@@ -75,5 +70,10 @@
1.18.4
test
+
+ com.azure
+ azure-json
+ 1.5.1
+
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/RedHatOpenShiftManager.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/RedHatOpenShiftManager.java
index 0b157918c43c..fd6c5578e795 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/RedHatOpenShiftManager.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/RedHatOpenShiftManager.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift;
@@ -11,38 +11,36 @@
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.HttpLoggingPolicy;
+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;
import com.azure.core.http.policy.HttpPolicyProviders;
import com.azure.core.http.policy.RequestIdPolicy;
import com.azure.core.http.policy.RetryOptions;
import com.azure.core.http.policy.RetryPolicy;
import com.azure.core.http.policy.UserAgentPolicy;
-import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
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.redhatopenshift.fluent.AzureRedHatOpenShiftClient;
-import com.azure.resourcemanager.redhatopenshift.implementation.AzureRedHatOpenShiftClientBuilder;
-import com.azure.resourcemanager.redhatopenshift.implementation.MachinePoolsImpl;
+import com.azure.resourcemanager.redhatopenshift.fluent.RedHatOpenShiftManagementClient;
import com.azure.resourcemanager.redhatopenshift.implementation.OpenShiftClustersImpl;
import com.azure.resourcemanager.redhatopenshift.implementation.OpenShiftVersionsImpl;
import com.azure.resourcemanager.redhatopenshift.implementation.OperationsImpl;
-import com.azure.resourcemanager.redhatopenshift.implementation.SecretsImpl;
-import com.azure.resourcemanager.redhatopenshift.implementation.SyncIdentityProvidersImpl;
-import com.azure.resourcemanager.redhatopenshift.implementation.SyncSetsImpl;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePools;
+import com.azure.resourcemanager.redhatopenshift.implementation.PlatformWorkloadIdentityRoleSetOperationsImpl;
+import com.azure.resourcemanager.redhatopenshift.implementation.PlatformWorkloadIdentityRoleSetsImpl;
+import com.azure.resourcemanager.redhatopenshift.implementation.RedHatOpenShiftManagementClientBuilder;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusters;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftVersions;
import com.azure.resourcemanager.redhatopenshift.models.Operations;
-import com.azure.resourcemanager.redhatopenshift.models.Secrets;
-import com.azure.resourcemanager.redhatopenshift.models.SyncIdentityProviders;
-import com.azure.resourcemanager.redhatopenshift.models.SyncSets;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityRoleSetOperations;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityRoleSets;
import java.time.Duration;
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;
@@ -55,22 +53,18 @@ public final class RedHatOpenShiftManager {
private OpenShiftVersions openShiftVersions;
- private OpenShiftClusters openShiftClusters;
-
- private MachinePools machinePools;
+ private PlatformWorkloadIdentityRoleSets platformWorkloadIdentityRoleSets;
- private Secrets secrets;
-
- private SyncIdentityProviders syncIdentityProviders;
+ private OpenShiftClusters openShiftClusters;
- private SyncSets syncSets;
+ private PlatformWorkloadIdentityRoleSetOperations platformWorkloadIdentityRoleSetOperations;
- private final AzureRedHatOpenShiftClient clientObject;
+ private final RedHatOpenShiftManagementClient clientObject;
private RedHatOpenShiftManager(HttpPipeline httpPipeline, AzureProfile profile, Duration defaultPollInterval) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
Objects.requireNonNull(profile, "'profile' cannot be null.");
- this.clientObject = new AzureRedHatOpenShiftClientBuilder().pipeline(httpPipeline)
+ this.clientObject = new RedHatOpenShiftManagementClientBuilder().pipeline(httpPipeline)
.endpoint(profile.getEnvironment().getResourceManagerEndpoint())
.subscriptionId(profile.getSubscriptionId())
.defaultPollInterval(defaultPollInterval)
@@ -78,11 +72,11 @@ private RedHatOpenShiftManager(HttpPipeline httpPipeline, AzureProfile profile,
}
/**
- * Creates an instance of Red Hat Open Shift service API entry point.
+ * Creates an instance of RedHatOpenShift service API entry point.
*
* @param credential the credential to use.
* @param profile the Azure profile for client.
- * @return the Red Hat Open Shift service API instance.
+ * @return the RedHatOpenShift service API instance.
*/
public static RedHatOpenShiftManager authenticate(TokenCredential credential, AzureProfile profile) {
Objects.requireNonNull(credential, "'credential' cannot be null.");
@@ -91,11 +85,11 @@ public static RedHatOpenShiftManager authenticate(TokenCredential credential, Az
}
/**
- * Creates an instance of Red Hat Open Shift service API entry point.
+ * Creates an instance of RedHatOpenShift service API entry point.
*
* @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential.
* @param profile the Azure profile for client.
- * @return the Red Hat Open Shift service API instance.
+ * @return the RedHatOpenShift service API instance.
*/
public static RedHatOpenShiftManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) {
Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null.");
@@ -117,6 +111,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-redhatopenshift.properties");
private HttpClient httpClient;
private HttpLogOptions httpLogOptions;
@@ -214,22 +211,24 @@ public Configurable withDefaultPollInterval(Duration defaultPollInterval) {
}
/**
- * Creates an instance of Red Hat Open Shift service API entry point.
+ * Creates an instance of RedHatOpenShift service API entry point.
*
* @param credential the credential to use.
* @param profile the Azure profile for client.
- * @return the Red Hat Open Shift service API instance.
+ * @return the RedHatOpenShift service API instance.
*/
public RedHatOpenShiftManager authenticate(TokenCredential credential, AzureProfile profile) {
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.redhatopenshift")
.append("/")
- .append("1.0.0-beta.1");
+ .append(clientVersion);
if (!Configuration.getGlobalConfiguration().get("AZURE_TELEMETRY_DISABLED", false)) {
userAgentBuilder.append(" (")
.append(Configuration.getGlobalConfiguration().get("java.version"))
@@ -262,7 +261,7 @@ public RedHatOpenShiftManager 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()));
@@ -300,72 +299,50 @@ public OpenShiftVersions openShiftVersions() {
}
/**
- * Gets the resource collection API of OpenShiftClusters. It manages OpenShiftCluster.
+ * Gets the resource collection API of PlatformWorkloadIdentityRoleSets.
*
- * @return Resource collection API of OpenShiftClusters.
+ * @return Resource collection API of PlatformWorkloadIdentityRoleSets.
*/
- public OpenShiftClusters openShiftClusters() {
- if (this.openShiftClusters == null) {
- this.openShiftClusters = new OpenShiftClustersImpl(clientObject.getOpenShiftClusters(), this);
+ public PlatformWorkloadIdentityRoleSets platformWorkloadIdentityRoleSets() {
+ if (this.platformWorkloadIdentityRoleSets == null) {
+ this.platformWorkloadIdentityRoleSets
+ = new PlatformWorkloadIdentityRoleSetsImpl(clientObject.getPlatformWorkloadIdentityRoleSets(), this);
}
- return openShiftClusters;
+ return platformWorkloadIdentityRoleSets;
}
/**
- * Gets the resource collection API of MachinePools. It manages MachinePool.
- *
- * @return Resource collection API of MachinePools.
- */
- public MachinePools machinePools() {
- if (this.machinePools == null) {
- this.machinePools = new MachinePoolsImpl(clientObject.getMachinePools(), this);
- }
- return machinePools;
- }
-
- /**
- * Gets the resource collection API of Secrets. It manages Secret.
- *
- * @return Resource collection API of Secrets.
- */
- public Secrets secrets() {
- if (this.secrets == null) {
- this.secrets = new SecretsImpl(clientObject.getSecrets(), this);
- }
- return secrets;
- }
-
- /**
- * Gets the resource collection API of SyncIdentityProviders. It manages SyncIdentityProvider.
+ * Gets the resource collection API of OpenShiftClusters. It manages OpenShiftCluster.
*
- * @return Resource collection API of SyncIdentityProviders.
+ * @return Resource collection API of OpenShiftClusters.
*/
- public SyncIdentityProviders syncIdentityProviders() {
- if (this.syncIdentityProviders == null) {
- this.syncIdentityProviders = new SyncIdentityProvidersImpl(clientObject.getSyncIdentityProviders(), this);
+ public OpenShiftClusters openShiftClusters() {
+ if (this.openShiftClusters == null) {
+ this.openShiftClusters = new OpenShiftClustersImpl(clientObject.getOpenShiftClusters(), this);
}
- return syncIdentityProviders;
+ return openShiftClusters;
}
/**
- * Gets the resource collection API of SyncSets. It manages SyncSet.
+ * Gets the resource collection API of PlatformWorkloadIdentityRoleSetOperations.
*
- * @return Resource collection API of SyncSets.
+ * @return Resource collection API of PlatformWorkloadIdentityRoleSetOperations.
*/
- public SyncSets syncSets() {
- if (this.syncSets == null) {
- this.syncSets = new SyncSetsImpl(clientObject.getSyncSets(), this);
+ public PlatformWorkloadIdentityRoleSetOperations platformWorkloadIdentityRoleSetOperations() {
+ if (this.platformWorkloadIdentityRoleSetOperations == null) {
+ this.platformWorkloadIdentityRoleSetOperations = new PlatformWorkloadIdentityRoleSetOperationsImpl(
+ clientObject.getPlatformWorkloadIdentityRoleSetOperations(), this);
}
- return syncSets;
+ return platformWorkloadIdentityRoleSetOperations;
}
/**
- * Gets wrapped service client AzureRedHatOpenShiftClient providing direct access to the underlying auto-generated
- * API implementation, based on Azure REST API.
+ * Gets wrapped service client RedHatOpenShiftManagementClient providing direct access to the underlying
+ * auto-generated API implementation, based on Azure REST API.
*
- * @return Wrapped service client AzureRedHatOpenShiftClient.
+ * @return Wrapped service client RedHatOpenShiftManagementClient.
*/
- public AzureRedHatOpenShiftClient serviceClient() {
+ public RedHatOpenShiftManagementClient serviceClient() {
return this.clientObject;
}
}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/MachinePoolsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/MachinePoolsClient.java
deleted file mode 100644
index b3f1f048467d..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/MachinePoolsClient.java
+++ /dev/null
@@ -1,190 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.MachinePoolInner;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePoolUpdate;
-
-/**
- * An instance of this class provides access to all the operations defined in MachinePoolsClient.
- */
-public interface MachinePoolsClient {
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName);
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName, Context context);
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- MachinePoolInner get(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolInner parameters, Context context);
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- MachinePoolInner createOrUpdate(String resourceGroupName, String resourceName, String childResourceName,
- MachinePoolInner parameters);
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response updateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolUpdate parameters, Context context);
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- MachinePoolInner update(String resourceGroupName, String resourceName, String childResourceName,
- MachinePoolUpdate parameters);
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftClustersClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftClustersClient.java
index da859d7e1d9d..ad18b2e752ff 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftClustersClient.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftClustersClient.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent;
@@ -21,95 +21,110 @@
*/
public interface OpenShiftClustersClient {
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
+ *
+ * The operation returns properties of a OpenShift cluster along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list();
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getByResourceGroupWithResponse(String resourceGroupName, String resourceName,
+ Context context);
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
- * @param context The context to associate with this operation.
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
+ *
+ * The operation returns properties of a OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(Context context);
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ OpenShiftClusterInner getByResourceGroup(String resourceGroupName, String resourceName);
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByResourceGroup(String resourceGroupName);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterInner parameters);
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable listByResourceGroup(String resourceGroupName, Context context);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterInner parameters, Context context);
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
- * @param context The context to associate with this operation.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response getByResourceGroupWithResponse(String resourceGroupName, String resourceName,
- Context context);
+ OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters);
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
+ * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- OpenShiftClusterInner getByResourceGroup(String resourceGroupName, String resourceName);
+ OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters, Context context);
/**
* Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -125,8 +140,8 @@ Response getByResourceGroupWithResponse(String resourceGr
* @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterInner parameters);
+ SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterUpdate parameters);
/**
* Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -143,8 +158,8 @@ SyncPoller, OpenShiftClusterInner> beginCreate
* @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterInner parameters, Context context);
+ SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterUpdate parameters, Context context);
/**
* Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -160,8 +175,7 @@ SyncPoller, OpenShiftClusterInner> beginCreate
* @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters);
+ OpenShiftClusterInner update(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters);
/**
* Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -178,8 +192,8 @@ OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceNa
* @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters, Context context);
+ OpenShiftClusterInner update(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters,
+ Context context);
/**
* Deletes a OpenShift cluster with the specified subscription, resource group and resource name.
@@ -242,73 +256,63 @@ OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceNa
void delete(String resourceGroupName, String resourceName, Context context);
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterUpdate parameters);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName);
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterUpdate parameters, Context context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByResourceGroup(String resourceGroupName, Context context);
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
- * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- OpenShiftClusterInner update(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list();
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- OpenShiftClusterInner update(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters,
- Context context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(Context context);
/**
* Lists admin kubeconfig of an OpenShift cluster with the specified subscription, resource group and resource name.
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftVersionsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftVersionsClient.java
index 1ce7ebd3bfed..f8172a2ae6bb 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftVersionsClient.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OpenShiftVersionsClient.java
@@ -1,12 +1,13 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent;
import com.azure.core.annotation.ReturnType;
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
import com.azure.resourcemanager.redhatopenshift.fluent.models.OpenShiftVersionInner;
@@ -14,12 +15,47 @@
* An instance of this class provides access to all the operations defined in OpenShiftVersionsClient.
*/
public interface OpenShiftVersionsClient {
+ /**
+ * Gets an available OpenShift version to install in the specified location.
+ *
+ * This operation returns installable OpenShift version as a string.
+ *
+ * @param location The name of the Azure region.
+ * @param openShiftVersion The desired version value of the OpenShiftVersion resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an available OpenShift version to install in the specified location.
+ *
+ * This operation returns installable OpenShift version as a string along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String location, String openShiftVersion, Context context);
+
+ /**
+ * Gets an available OpenShift version to install in the specified location.
+ *
+ * This operation returns installable OpenShift version as a string.
+ *
+ * @param location The name of the Azure region.
+ * @param openShiftVersion The desired version value of the OpenShiftVersion resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return an available OpenShift version to install in the specified location.
+ *
+ * This operation returns installable OpenShift version as a string.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ OpenShiftVersionInner get(String location, String openShiftVersion);
+
/**
* Lists all OpenShift versions available to install in the specified location.
*
- * The operation returns the installable OpenShift versions as strings.
+ * The operation returns the installable OpenShift versions as a string.
*
- * @param location The name of Azure region.
+ * @param location The name of the Azure region.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
@@ -32,9 +68,9 @@ public interface OpenShiftVersionsClient {
/**
* Lists all OpenShift versions available to install in the specified location.
*
- * The operation returns the installable OpenShift versions as strings.
+ * The operation returns the installable OpenShift versions as a string.
*
- * @param location The name of Azure region.
+ * @param location The name of the Azure region.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OperationsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OperationsClient.java
index be0d943e28eb..bed963d5f602 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OperationsClient.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/OperationsClient.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent;
@@ -15,9 +15,7 @@
*/
public interface OperationsClient {
/**
- * Lists all of the available RP operations.
- *
- * The operation returns the RP operations.
+ * List the operations for the provider.
*
* @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,9 +25,7 @@ public interface OperationsClient {
PagedIterable list();
/**
- * Lists all of the available RP operations.
- *
- * The operation returns the RP operations.
+ * List the operations for the provider.
*
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetOperationsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetOperationsClient.java
new file mode 100644
index 000000000000..a17f061cb9ce
--- /dev/null
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetOperationsClient.java
@@ -0,0 +1,57 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
+
+package com.azure.resourcemanager.redhatopenshift.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.Response;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.redhatopenshift.fluent.models.PlatformWorkloadIdentityRoleSetInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in
+ * PlatformWorkloadIdentityRoleSetOperationsClient.
+ */
+public interface PlatformWorkloadIdentityRoleSetOperationsClient {
+ /**
+ * Gets a mapping of an OpenShift version to identity requirements, which includes operatorName, roleDefinitionName,
+ * roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns Platform Workload Identity Role Set as a string.
+ *
+ * @param location The name of the Azure region.
+ * @param openShiftMinorVersion The desired version value of the PlatformWorkloadIdentityRoleSet resource.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a mapping of an OpenShift version to identity requirements, which includes operatorName,
+ * roleDefinitionName, roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns Platform Workload Identity Role Set as a string along with {@link Response}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(String location, String openShiftMinorVersion,
+ Context context);
+
+ /**
+ * Gets a mapping of an OpenShift version to identity requirements, which includes operatorName, roleDefinitionName,
+ * roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns Platform Workload Identity Role Set as a string.
+ *
+ * @param location The name of the Azure region.
+ * @param openShiftMinorVersion The desired version value of the PlatformWorkloadIdentityRoleSet resource.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return a mapping of an OpenShift version to identity requirements, which includes operatorName,
+ * roleDefinitionName, roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns Platform Workload Identity Role Set as a string.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ PlatformWorkloadIdentityRoleSetInner get(String location, String openShiftMinorVersion);
+}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetsClient.java
new file mode 100644
index 000000000000..0cbf2ee0d23b
--- /dev/null
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/PlatformWorkloadIdentityRoleSetsClient.java
@@ -0,0 +1,49 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
+
+package com.azure.resourcemanager.redhatopenshift.fluent;
+
+import com.azure.core.annotation.ReturnType;
+import com.azure.core.annotation.ServiceMethod;
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.redhatopenshift.fluent.models.PlatformWorkloadIdentityRoleSetInner;
+
+/**
+ * An instance of this class provides access to all the operations defined in PlatformWorkloadIdentityRoleSetsClient.
+ */
+public interface PlatformWorkloadIdentityRoleSetsClient {
+ /**
+ * Lists a mapping of OpenShift versions to identity requirements, which include operatorName, roleDefinitionName,
+ * roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns a list of Platform Workload Identity Role Sets as a string.
+ *
+ * @param location The name of the Azure region.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return platformWorkloadIdentityRoleSetList represents a List of role sets as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String location);
+
+ /**
+ * Lists a mapping of OpenShift versions to identity requirements, which include operatorName, roleDefinitionName,
+ * roleDefinitionId, and serviceAccounts.
+ *
+ * This operation returns a list of Platform Workload Identity Role Sets as a string.
+ *
+ * @param location The name of the Azure region.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return platformWorkloadIdentityRoleSetList represents a List of role sets as paginated response with
+ * {@link PagedIterable}.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable list(String location, Context context);
+}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/AzureRedHatOpenShiftClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/RedHatOpenShiftManagementClient.java
similarity index 60%
rename from sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/AzureRedHatOpenShiftClient.java
rename to sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/RedHatOpenShiftManagementClient.java
index 52656f612456..285d2c80a002 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/AzureRedHatOpenShiftClient.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/RedHatOpenShiftManagementClient.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent;
@@ -8,30 +8,30 @@
import java.time.Duration;
/**
- * The interface for AzureRedHatOpenShiftClient class.
+ * The interface for RedHatOpenShiftManagementClient class.
*/
-public interface AzureRedHatOpenShiftClient {
+public interface RedHatOpenShiftManagementClient {
/**
- * Gets The ID of the target subscription.
- *
- * @return the subscriptionId value.
- */
- String getSubscriptionId();
-
- /**
- * Gets server parameter.
+ * Gets Service host.
*
* @return the endpoint value.
*/
String getEndpoint();
/**
- * Gets Api Version.
+ * Gets Version parameter.
*
* @return the apiVersion value.
*/
String getApiVersion();
+ /**
+ * Gets The ID of the target subscription. The value must be an UUID.
+ *
+ * @return the subscriptionId value.
+ */
+ String getSubscriptionId();
+
/**
* Gets The HTTP pipeline to send requests through.
*
@@ -61,37 +61,23 @@ public interface AzureRedHatOpenShiftClient {
OpenShiftVersionsClient getOpenShiftVersions();
/**
- * Gets the OpenShiftClustersClient object to access its operations.
- *
- * @return the OpenShiftClustersClient object.
- */
- OpenShiftClustersClient getOpenShiftClusters();
-
- /**
- * Gets the MachinePoolsClient object to access its operations.
+ * Gets the PlatformWorkloadIdentityRoleSetsClient object to access its operations.
*
- * @return the MachinePoolsClient object.
+ * @return the PlatformWorkloadIdentityRoleSetsClient object.
*/
- MachinePoolsClient getMachinePools();
+ PlatformWorkloadIdentityRoleSetsClient getPlatformWorkloadIdentityRoleSets();
/**
- * Gets the SecretsClient object to access its operations.
- *
- * @return the SecretsClient object.
- */
- SecretsClient getSecrets();
-
- /**
- * Gets the SyncIdentityProvidersClient object to access its operations.
+ * Gets the OpenShiftClustersClient object to access its operations.
*
- * @return the SyncIdentityProvidersClient object.
+ * @return the OpenShiftClustersClient object.
*/
- SyncIdentityProvidersClient getSyncIdentityProviders();
+ OpenShiftClustersClient getOpenShiftClusters();
/**
- * Gets the SyncSetsClient object to access its operations.
+ * Gets the PlatformWorkloadIdentityRoleSetOperationsClient object to access its operations.
*
- * @return the SyncSetsClient object.
+ * @return the PlatformWorkloadIdentityRoleSetOperationsClient object.
*/
- SyncSetsClient getSyncSets();
+ PlatformWorkloadIdentityRoleSetOperationsClient getPlatformWorkloadIdentityRoleSetOperations();
}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SecretsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SecretsClient.java
deleted file mode 100644
index a02faff85e30..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SecretsClient.java
+++ /dev/null
@@ -1,190 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.SecretInner;
-import com.azure.resourcemanager.redhatopenshift.models.SecretUpdate;
-
-/**
- * An instance of this class provides access to all the operations defined in SecretsClient.
- */
-public interface SecretsClient {
- /**
- * Lists Secrets that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 secretList represents a list of Secrets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName);
-
- /**
- * Lists Secrets that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 secretList represents a list of Secrets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName, Context context);
-
- /**
- * Gets a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @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 secret represents a secret along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Gets a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @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 secret represents a secret.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SecretInner get(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Creates or updates a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @param parameters The Secret resource.
- * @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 secret represents a secret along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, SecretInner parameters, Context context);
-
- /**
- * Creates or updates a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @param parameters The Secret resource.
- * @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 secret represents a secret.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SecretInner createOrUpdate(String resourceGroupName, String resourceName, String childResourceName,
- SecretInner parameters);
-
- /**
- * Deletes a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Deletes a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Updates a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @param parameters The Secret resource.
- * @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 secret represents a secret along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response updateWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- SecretUpdate parameters, Context context);
-
- /**
- * Updates a Secret with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a Secret.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the Secret resource.
- * @param parameters The Secret resource.
- * @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 secret represents a secret.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SecretInner update(String resourceGroupName, String resourceName, String childResourceName,
- SecretUpdate parameters);
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncIdentityProvidersClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncIdentityProvidersClient.java
deleted file mode 100644
index 22aa74c7bbc3..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncIdentityProvidersClient.java
+++ /dev/null
@@ -1,190 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.SyncIdentityProviderInner;
-import com.azure.resourcemanager.redhatopenshift.models.SyncIdentityProviderUpdate;
-
-/**
- * An instance of this class provides access to all the operations defined in SyncIdentityProvidersClient.
- */
-public interface SyncIdentityProvidersClient {
- /**
- * Lists SyncIdentityProviders that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 syncSetList represents a list of SyncSets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName);
-
- /**
- * Lists SyncIdentityProviders that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 syncSetList represents a list of SyncSets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName, Context context);
-
- /**
- * Gets a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, Context context);
-
- /**
- * Gets a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncIdentityProviderInner get(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Creates or updates a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @param parameters The SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, SyncIdentityProviderInner parameters, Context context);
-
- /**
- * Creates or updates a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @param parameters The SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncIdentityProviderInner createOrUpdate(String resourceGroupName, String resourceName, String childResourceName,
- SyncIdentityProviderInner parameters);
-
- /**
- * Deletes a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Deletes a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Updates a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @param parameters The SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response updateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, SyncIdentityProviderUpdate parameters, Context context);
-
- /**
- * Updates a SyncIdentityProvider with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncIdentityProvider.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncIdentityProvider resource.
- * @param parameters The SyncIdentityProvider resource.
- * @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 syncIdentityProvider represents a SyncIdentityProvider.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncIdentityProviderInner update(String resourceGroupName, String resourceName, String childResourceName,
- SyncIdentityProviderUpdate parameters);
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncSetsClient.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncSetsClient.java
deleted file mode 100644
index 5c41ea4125fd..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/SyncSetsClient.java
+++ /dev/null
@@ -1,190 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent;
-
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.SyncSetInner;
-import com.azure.resourcemanager.redhatopenshift.models.SyncSetUpdate;
-
-/**
- * An instance of this class provides access to all the operations defined in SyncSetsClient.
- */
-public interface SyncSetsClient {
- /**
- * Lists SyncSets that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 syncSetList represents a list of SyncSets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName);
-
- /**
- * Lists SyncSets that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 syncSetList represents a list of SyncSets as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- PagedIterable list(String resourceGroupName, String resourceName, Context context);
-
- /**
- * Gets a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response getWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Gets a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncSetInner get(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Creates or updates a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @param parameters The SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, SyncSetInner parameters, Context context);
-
- /**
- * Creates or updates a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @param parameters The SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncSetInner createOrUpdate(String resourceGroupName, String resourceName, String childResourceName,
- SyncSetInner parameters);
-
- /**
- * Deletes a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context);
-
- /**
- * Deletes a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- void delete(String resourceGroupName, String resourceName, String childResourceName);
-
- /**
- * Updates a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @param parameters The SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- Response updateWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- SyncSetUpdate parameters, Context context);
-
- /**
- * Updates a SyncSet with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a SyncSet.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the SyncSet resource.
- * @param parameters The SyncSet resource.
- * @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 syncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- SyncSetInner update(String resourceGroupName, String resourceName, String childResourceName,
- SyncSetUpdate parameters);
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolInner.java
deleted file mode 100644
index 9c091665e840..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolInner.java
+++ /dev/null
@@ -1,177 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import java.io.IOException;
-
-/**
- * MachinePool represents a MachinePool.
- */
-@Fluent
-public final class MachinePoolInner extends ProxyResource {
- /*
- * The MachinePool Properties
- */
- private MachinePoolProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- private SystemData systemData;
-
- /*
- * Fully qualified resource Id for the resource.
- */
- private String id;
-
- /*
- * The name of the resource.
- */
- private String name;
-
- /*
- * The type of the resource.
- */
- private String type;
-
- /**
- * Creates an instance of MachinePoolInner class.
- */
- public MachinePoolInner() {
- }
-
- /**
- * Get the innerProperties property: The MachinePool Properties.
- *
- * @return the innerProperties value.
- */
- private MachinePoolProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- @Override
- public String id() {
- return this.id;
- }
-
- /**
- * Get the name property: The name of the resource.
- *
- * @return the name value.
- */
- @Override
- public String name() {
- return this.name;
- }
-
- /**
- * Get the type property: The type of the resource.
- *
- * @return the type value.
- */
- @Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the resources property: The resources property.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.innerProperties() == null ? null : this.innerProperties().resources();
- }
-
- /**
- * Set the resources property: The resources property.
- *
- * @param resources the resources value to set.
- * @return the MachinePoolInner object itself.
- */
- public MachinePoolInner withResources(String resources) {
- if (this.innerProperties() == null) {
- this.innerProperties = new MachinePoolProperties();
- }
- this.innerProperties().withResources(resources);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeJsonField("properties", this.innerProperties);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of MachinePoolInner from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of MachinePoolInner if the JsonReader was pointing to an instance of it, or null if it was
- * pointing to JSON null.
- * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the MachinePoolInner.
- */
- public static MachinePoolInner fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- MachinePoolInner deserializedMachinePoolInner = new MachinePoolInner();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("id".equals(fieldName)) {
- deserializedMachinePoolInner.id = reader.getString();
- } else if ("name".equals(fieldName)) {
- deserializedMachinePoolInner.name = reader.getString();
- } else if ("type".equals(fieldName)) {
- deserializedMachinePoolInner.type = reader.getString();
- } else if ("properties".equals(fieldName)) {
- deserializedMachinePoolInner.innerProperties = MachinePoolProperties.fromJson(reader);
- } else if ("systemData".equals(fieldName)) {
- deserializedMachinePoolInner.systemData = SystemData.fromJson(reader);
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedMachinePoolInner;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolProperties.java
deleted file mode 100644
index 8ce031b9c1e0..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/MachinePoolProperties.java
+++ /dev/null
@@ -1,93 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.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;
-
-/**
- * MachinePoolProperties represents the properties of a MachinePool.
- */
-@Fluent
-public final class MachinePoolProperties implements JsonSerializable {
- /*
- * The resources property.
- */
- private String resources;
-
- /**
- * Creates an instance of MachinePoolProperties class.
- */
- public MachinePoolProperties() {
- }
-
- /**
- * Get the resources property: The resources property.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.resources;
- }
-
- /**
- * Set the resources property: The resources property.
- *
- * @param resources the resources value to set.
- * @return the MachinePoolProperties object itself.
- */
- public MachinePoolProperties withResources(String resources) {
- this.resources = resources;
- return this;
- }
-
- /**
- * 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();
- jsonWriter.writeStringField("resources", this.resources);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of MachinePoolProperties from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of MachinePoolProperties 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 MachinePoolProperties.
- */
- public static MachinePoolProperties fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- MachinePoolProperties deserializedMachinePoolProperties = new MachinePoolProperties();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("resources".equals(fieldName)) {
- deserializedMachinePoolProperties.resources = reader.getString();
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedMachinePoolProperties;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterAdminKubeconfigInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterAdminKubeconfigInner.java
index 9cf6c307f432..9848e0b6a16d 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterAdminKubeconfigInner.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterAdminKubeconfigInner.java
@@ -1,10 +1,10 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.json.JsonReader;
import com.azure.json.JsonSerializable;
import com.azure.json.JsonToken;
@@ -14,7 +14,7 @@
/**
* OpenShiftClusterAdminKubeconfig represents an OpenShift cluster's admin kubeconfig.
*/
-@Fluent
+@Immutable
public final class OpenShiftClusterAdminKubeconfigInner
implements JsonSerializable {
/*
@@ -25,7 +25,7 @@ public final class OpenShiftClusterAdminKubeconfigInner
/**
* Creates an instance of OpenShiftClusterAdminKubeconfigInner class.
*/
- public OpenShiftClusterAdminKubeconfigInner() {
+ private OpenShiftClusterAdminKubeconfigInner() {
}
/**
@@ -37,25 +37,6 @@ public String kubeconfig() {
return this.kubeconfig;
}
- /**
- * Set the kubeconfig property: The base64-encoded kubeconfig file.
- *
- * @param kubeconfig the kubeconfig value to set.
- * @return the OpenShiftClusterAdminKubeconfigInner object itself.
- */
- public OpenShiftClusterAdminKubeconfigInner withKubeconfig(String kubeconfig) {
- this.kubeconfig = kubeconfig;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-
/**
* {@inheritDoc}
*/
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterCredentialsInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterCredentialsInner.java
index 51bba368347c..b3b78cc721dd 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterCredentialsInner.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterCredentialsInner.java
@@ -1,10 +1,10 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.json.JsonReader;
import com.azure.json.JsonSerializable;
import com.azure.json.JsonToken;
@@ -14,7 +14,7 @@
/**
* OpenShiftClusterCredentials represents an OpenShift cluster's credentials.
*/
-@Fluent
+@Immutable
public final class OpenShiftClusterCredentialsInner implements JsonSerializable {
/*
* The username for the kubeadmin user.
@@ -29,7 +29,7 @@ public final class OpenShiftClusterCredentialsInner implements JsonSerializable<
/**
* Creates an instance of OpenShiftClusterCredentialsInner class.
*/
- public OpenShiftClusterCredentialsInner() {
+ private OpenShiftClusterCredentialsInner() {
}
/**
@@ -41,17 +41,6 @@ public String kubeadminUsername() {
return this.kubeadminUsername;
}
- /**
- * Set the kubeadminUsername property: The username for the kubeadmin user.
- *
- * @param kubeadminUsername the kubeadminUsername value to set.
- * @return the OpenShiftClusterCredentialsInner object itself.
- */
- public OpenShiftClusterCredentialsInner withKubeadminUsername(String kubeadminUsername) {
- this.kubeadminUsername = kubeadminUsername;
- return this;
- }
-
/**
* Get the kubeadminPassword property: The password for the kubeadmin user.
*
@@ -61,25 +50,6 @@ public String kubeadminPassword() {
return this.kubeadminPassword;
}
- /**
- * Set the kubeadminPassword property: The password for the kubeadmin user.
- *
- * @param kubeadminPassword the kubeadminPassword value to set.
- * @return the OpenShiftClusterCredentialsInner object itself.
- */
- public OpenShiftClusterCredentialsInner withKubeadminPassword(String kubeadminPassword) {
- this.kubeadminPassword = kubeadminPassword;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-
/**
* {@inheritDoc}
*/
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterInner.java
index c8806de9843b..2511cd9396d7 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterInner.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterInner.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
@@ -14,8 +14,10 @@
import com.azure.resourcemanager.redhatopenshift.models.ClusterProfile;
import com.azure.resourcemanager.redhatopenshift.models.ConsoleProfile;
import com.azure.resourcemanager.redhatopenshift.models.IngressProfile;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentity;
import com.azure.resourcemanager.redhatopenshift.models.MasterProfile;
import com.azure.resourcemanager.redhatopenshift.models.NetworkProfile;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityProfile;
import com.azure.resourcemanager.redhatopenshift.models.ProvisioningState;
import com.azure.resourcemanager.redhatopenshift.models.ServicePrincipalProfile;
import com.azure.resourcemanager.redhatopenshift.models.WorkerProfile;
@@ -33,15 +35,20 @@ public final class OpenShiftClusterInner extends Resource {
*/
private OpenShiftClusterProperties innerProperties;
+ /*
+ * The managed service identities assigned to this resource.
+ */
+ private ManagedServiceIdentity identity;
+
/*
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
*/
private SystemData systemData;
/*
- * Fully qualified resource Id for the resource.
+ * The type of the resource.
*/
- private String id;
+ private String type;
/*
* The name of the resource.
@@ -49,9 +56,9 @@ public final class OpenShiftClusterInner extends Resource {
private String name;
/*
- * The type of the resource.
+ * Fully qualified resource Id for the resource.
*/
- private String type;
+ private String id;
/**
* Creates an instance of OpenShiftClusterInner class.
@@ -68,6 +75,26 @@ private OpenShiftClusterProperties innerProperties() {
return this.innerProperties;
}
+ /**
+ * Get the identity property: The managed service identities assigned to this resource.
+ *
+ * @return the identity value.
+ */
+ public ManagedServiceIdentity identity() {
+ return this.identity;
+ }
+
+ /**
+ * Set the identity property: The managed service identities assigned to this resource.
+ *
+ * @param identity the identity value to set.
+ * @return the OpenShiftClusterInner object itself.
+ */
+ public OpenShiftClusterInner withIdentity(ManagedServiceIdentity identity) {
+ this.identity = identity;
+ return this;
+ }
+
/**
* Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
*
@@ -78,13 +105,13 @@ public SystemData systemData() {
}
/**
- * Get the id property: Fully qualified resource Id for the resource.
+ * Get the type property: The type of the resource.
*
- * @return the id value.
+ * @return the type value.
*/
@Override
- public String id() {
- return this.id;
+ public String type() {
+ return this.type;
}
/**
@@ -98,13 +125,13 @@ public String name() {
}
/**
- * Get the type property: The type of the resource.
+ * Get the id property: Fully qualified resource Id for the resource.
*
- * @return the type value.
+ * @return the id value.
*/
@Override
- public String type() {
- return this.type;
+ public String id() {
+ return this.id;
}
/**
@@ -217,6 +244,30 @@ public OpenShiftClusterInner withServicePrincipalProfile(ServicePrincipalProfile
return this;
}
+ /**
+ * Get the platformWorkloadIdentityProfile property: The workload identity profile.
+ *
+ * @return the platformWorkloadIdentityProfile value.
+ */
+ public PlatformWorkloadIdentityProfile platformWorkloadIdentityProfile() {
+ return this.innerProperties() == null ? null : this.innerProperties().platformWorkloadIdentityProfile();
+ }
+
+ /**
+ * Set the platformWorkloadIdentityProfile property: The workload identity profile.
+ *
+ * @param platformWorkloadIdentityProfile the platformWorkloadIdentityProfile value to set.
+ * @return the OpenShiftClusterInner object itself.
+ */
+ public OpenShiftClusterInner
+ withPlatformWorkloadIdentityProfile(PlatformWorkloadIdentityProfile platformWorkloadIdentityProfile) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new OpenShiftClusterProperties();
+ }
+ this.innerProperties().withPlatformWorkloadIdentityProfile(platformWorkloadIdentityProfile);
+ return this;
+ }
+
/**
* Get the networkProfile property: The cluster network profile.
*
@@ -341,17 +392,6 @@ public OpenShiftClusterInner withIngressProfiles(List ingressPro
return this;
}
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-
/**
* {@inheritDoc}
*/
@@ -361,6 +401,7 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
jsonWriter.writeStringField("location", location());
jsonWriter.writeMapField("tags", tags(), (writer, element) -> writer.writeString(element));
jsonWriter.writeJsonField("properties", this.innerProperties);
+ jsonWriter.writeJsonField("identity", this.identity);
return jsonWriter.writeEndObject();
}
@@ -393,6 +434,8 @@ public static OpenShiftClusterInner fromJson(JsonReader jsonReader) throws IOExc
deserializedOpenShiftClusterInner.withTags(tags);
} else if ("properties".equals(fieldName)) {
deserializedOpenShiftClusterInner.innerProperties = OpenShiftClusterProperties.fromJson(reader);
+ } else if ("identity".equals(fieldName)) {
+ deserializedOpenShiftClusterInner.identity = ManagedServiceIdentity.fromJson(reader);
} else if ("systemData".equals(fieldName)) {
deserializedOpenShiftClusterInner.systemData = SystemData.fromJson(reader);
} else {
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterProperties.java
index 788c641a4259..4ce0850c8f2d 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterProperties.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftClusterProperties.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
@@ -15,6 +15,7 @@
import com.azure.resourcemanager.redhatopenshift.models.IngressProfile;
import com.azure.resourcemanager.redhatopenshift.models.MasterProfile;
import com.azure.resourcemanager.redhatopenshift.models.NetworkProfile;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityProfile;
import com.azure.resourcemanager.redhatopenshift.models.ProvisioningState;
import com.azure.resourcemanager.redhatopenshift.models.ServicePrincipalProfile;
import com.azure.resourcemanager.redhatopenshift.models.WorkerProfile;
@@ -46,6 +47,11 @@ public final class OpenShiftClusterProperties implements JsonSerializable ingre
return this;
}
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (clusterProfile() != null) {
- clusterProfile().validate();
- }
- if (consoleProfile() != null) {
- consoleProfile().validate();
- }
- if (servicePrincipalProfile() != null) {
- servicePrincipalProfile().validate();
- }
- if (networkProfile() != null) {
- networkProfile().validate();
- }
- if (masterProfile() != null) {
- masterProfile().validate();
- }
- if (workerProfiles() != null) {
- workerProfiles().forEach(e -> e.validate());
- }
- if (workerProfilesStatus() != null) {
- workerProfilesStatus().forEach(e -> e.validate());
- }
- if (apiserverProfile() != null) {
- apiserverProfile().validate();
- }
- if (ingressProfiles() != null) {
- ingressProfiles().forEach(e -> e.validate());
- }
- }
-
/**
* {@inheritDoc}
*/
@@ -317,6 +309,7 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
jsonWriter.writeJsonField("clusterProfile", this.clusterProfile);
jsonWriter.writeJsonField("consoleProfile", this.consoleProfile);
jsonWriter.writeJsonField("servicePrincipalProfile", this.servicePrincipalProfile);
+ jsonWriter.writeJsonField("platformWorkloadIdentityProfile", this.platformWorkloadIdentityProfile);
jsonWriter.writeJsonField("networkProfile", this.networkProfile);
jsonWriter.writeJsonField("masterProfile", this.masterProfile);
jsonWriter.writeArrayField("workerProfiles", this.workerProfiles,
@@ -352,6 +345,9 @@ public static OpenShiftClusterProperties fromJson(JsonReader jsonReader) throws
} else if ("servicePrincipalProfile".equals(fieldName)) {
deserializedOpenShiftClusterProperties.servicePrincipalProfile
= ServicePrincipalProfile.fromJson(reader);
+ } else if ("platformWorkloadIdentityProfile".equals(fieldName)) {
+ deserializedOpenShiftClusterProperties.platformWorkloadIdentityProfile
+ = PlatformWorkloadIdentityProfile.fromJson(reader);
} else if ("networkProfile".equals(fieldName)) {
deserializedOpenShiftClusterProperties.networkProfile = NetworkProfile.fromJson(reader);
} else if ("masterProfile".equals(fieldName)) {
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionInner.java
index b72ec43067e9..ab2610a12475 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionInner.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionInner.java
@@ -1,10 +1,10 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.json.JsonReader;
@@ -15,7 +15,7 @@
/**
* OpenShiftVersion represents an OpenShift version that can be installed.
*/
-@Fluent
+@Immutable
public final class OpenShiftVersionInner extends ProxyResource {
/*
* The properties for the OpenShiftVersion resource.
@@ -28,9 +28,9 @@ public final class OpenShiftVersionInner extends ProxyResource {
private SystemData systemData;
/*
- * Fully qualified resource Id for the resource.
+ * The type of the resource.
*/
- private String id;
+ private String type;
/*
* The name of the resource.
@@ -38,14 +38,14 @@ public final class OpenShiftVersionInner extends ProxyResource {
private String name;
/*
- * The type of the resource.
+ * Fully qualified resource Id for the resource.
*/
- private String type;
+ private String id;
/**
* Creates an instance of OpenShiftVersionInner class.
*/
- public OpenShiftVersionInner() {
+ private OpenShiftVersionInner() {
}
/**
@@ -67,13 +67,13 @@ public SystemData systemData() {
}
/**
- * Get the id property: Fully qualified resource Id for the resource.
+ * Get the type property: The type of the resource.
*
- * @return the id value.
+ * @return the type value.
*/
@Override
- public String id() {
- return this.id;
+ public String type() {
+ return this.type;
}
/**
@@ -87,13 +87,13 @@ public String name() {
}
/**
- * Get the type property: The type of the resource.
+ * Get the id property: Fully qualified resource Id for the resource.
*
- * @return the type value.
+ * @return the id value.
*/
@Override
- public String type() {
- return this.type;
+ public String id() {
+ return this.id;
}
/**
@@ -105,31 +105,6 @@ public String version() {
return this.innerProperties() == null ? null : this.innerProperties().version();
}
- /**
- * Set the version property: Version represents the version to create the cluster at.
- *
- * @param version the version value to set.
- * @return the OpenShiftVersionInner object itself.
- */
- public OpenShiftVersionInner withVersion(String version) {
- if (this.innerProperties() == null) {
- this.innerProperties = new OpenShiftVersionProperties();
- }
- this.innerProperties().withVersion(version);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-
/**
* {@inheritDoc}
*/
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionProperties.java
index 5469cdd9fcc6..e5cf9fd019ca 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionProperties.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/OpenShiftVersionProperties.java
@@ -1,10 +1,10 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.json.JsonReader;
import com.azure.json.JsonSerializable;
import com.azure.json.JsonToken;
@@ -14,7 +14,7 @@
/**
* OpenShiftVersionProperties represents the properties of an OpenShiftVersion.
*/
-@Fluent
+@Immutable
public final class OpenShiftVersionProperties implements JsonSerializable {
/*
* Version represents the version to create the cluster at.
@@ -24,7 +24,7 @@ public final class OpenShiftVersionProperties implements JsonSerializable {
/*
* Operation name: {provider}/{resource}/{operation}.
@@ -35,7 +35,7 @@ public final class OperationInner implements JsonSerializable {
/**
* Creates an instance of OperationInner class.
*/
- public OperationInner() {
+ private OperationInner() {
}
/**
@@ -47,17 +47,6 @@ public String name() {
return this.name;
}
- /**
- * Set the name property: Operation name: {provider}/{resource}/{operation}.
- *
- * @param name the name value to set.
- * @return the OperationInner object itself.
- */
- public OperationInner withName(String name) {
- this.name = name;
- return this;
- }
-
/**
* Get the display property: The object that describes the operation.
*
@@ -67,17 +56,6 @@ public Display display() {
return this.display;
}
- /**
- * Set the display property: The object that describes the operation.
- *
- * @param display the display value to set.
- * @return the OperationInner object itself.
- */
- public OperationInner withDisplay(Display display) {
- this.display = display;
- return this;
- }
-
/**
* Get the origin property: Sources of requests to this operation. Comma separated list with valid values user or
* system, e.g. "user,system".
@@ -88,29 +66,6 @@ public String origin() {
return this.origin;
}
- /**
- * Set the origin property: Sources of requests to this operation. Comma separated list with valid values user or
- * system, e.g. "user,system".
- *
- * @param origin the origin value to set.
- * @return the OperationInner object itself.
- */
- public OperationInner withOrigin(String origin) {
- this.origin = origin;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (display() != null) {
- display().validate();
- }
- }
-
/**
* {@inheritDoc}
*/
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetInner.java
similarity index 51%
rename from sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderInner.java
rename to sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetInner.java
index 90f69af53116..71046beea460 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderInner.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetInner.java
@@ -1,26 +1,29 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.fluent.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.core.management.ProxyResource;
import com.azure.core.management.SystemData;
import com.azure.json.JsonReader;
import com.azure.json.JsonToken;
import com.azure.json.JsonWriter;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityRole;
import java.io.IOException;
+import java.util.List;
/**
- * SyncIdentityProvider represents a SyncIdentityProvider.
+ * PlatformWorkloadIdentityRoleSet represents a mapping from the names of OCP operators to the built-in roles that
+ * should be assigned to those operator's corresponding managed identities for a particular OCP version.
*/
-@Fluent
-public final class SyncIdentityProviderInner extends ProxyResource {
+@Immutable
+public final class PlatformWorkloadIdentityRoleSetInner extends ProxyResource {
/*
- * The SyncIdentityProvider Properties
+ * The properties for the PlatformWorkloadIdentityRoleSet resource.
*/
- private SyncIdentityProviderProperties innerProperties;
+ private PlatformWorkloadIdentityRoleSetProperties innerProperties;
/*
* Azure Resource Manager metadata containing createdBy and modifiedBy information.
@@ -28,9 +31,9 @@ public final class SyncIdentityProviderInner extends ProxyResource {
private SystemData systemData;
/*
- * Fully qualified resource Id for the resource.
+ * The type of the resource.
*/
- private String id;
+ private String type;
/*
* The name of the resource.
@@ -38,22 +41,22 @@ public final class SyncIdentityProviderInner extends ProxyResource {
private String name;
/*
- * The type of the resource.
+ * Fully qualified resource Id for the resource.
*/
- private String type;
+ private String id;
/**
- * Creates an instance of SyncIdentityProviderInner class.
+ * Creates an instance of PlatformWorkloadIdentityRoleSetInner class.
*/
- public SyncIdentityProviderInner() {
+ private PlatformWorkloadIdentityRoleSetInner() {
}
/**
- * Get the innerProperties property: The SyncIdentityProvider Properties.
+ * Get the innerProperties property: The properties for the PlatformWorkloadIdentityRoleSet resource.
*
* @return the innerProperties value.
*/
- private SyncIdentityProviderProperties innerProperties() {
+ private PlatformWorkloadIdentityRoleSetProperties innerProperties() {
return this.innerProperties;
}
@@ -67,13 +70,13 @@ public SystemData systemData() {
}
/**
- * Get the id property: Fully qualified resource Id for the resource.
+ * Get the type property: The type of the resource.
*
- * @return the id value.
+ * @return the type value.
*/
@Override
- public String id() {
- return this.id;
+ public String type() {
+ return this.type;
}
/**
@@ -87,47 +90,32 @@ public String name() {
}
/**
- * Get the type property: The type of the resource.
+ * Get the id property: Fully qualified resource Id for the resource.
*
- * @return the type value.
+ * @return the id value.
*/
@Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the resources property: The resources property.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.innerProperties() == null ? null : this.innerProperties().resources();
+ public String id() {
+ return this.id;
}
/**
- * Set the resources property: The resources property.
+ * Get the openShiftVersion property: OpenShiftVersion represents the version associated with this set of roles.
*
- * @param resources the resources value to set.
- * @return the SyncIdentityProviderInner object itself.
+ * @return the openShiftVersion value.
*/
- public SyncIdentityProviderInner withResources(String resources) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SyncIdentityProviderProperties();
- }
- this.innerProperties().withResources(resources);
- return this;
+ public String openShiftVersion() {
+ return this.innerProperties() == null ? null : this.innerProperties().openShiftVersion();
}
/**
- * Validates the instance.
+ * Get the platformWorkloadIdentityRoles property: PlatformWorkloadIdentityRoles represents the set of roles
+ * associated with this version.
*
- * @throws IllegalArgumentException thrown if the instance is not valid.
+ * @return the platformWorkloadIdentityRoles value.
*/
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
+ public List platformWorkloadIdentityRoles() {
+ return this.innerProperties() == null ? null : this.innerProperties().platformWorkloadIdentityRoles();
}
/**
@@ -141,38 +129,39 @@ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
}
/**
- * Reads an instance of SyncIdentityProviderInner from the JsonReader.
+ * Reads an instance of PlatformWorkloadIdentityRoleSetInner from the JsonReader.
*
* @param jsonReader The JsonReader being read.
- * @return An instance of SyncIdentityProviderInner if the JsonReader was pointing to an instance of it, or null if
- * it was pointing to JSON null.
+ * @return An instance of PlatformWorkloadIdentityRoleSetInner if the JsonReader was pointing to an instance of it,
+ * or null if it was pointing to JSON null.
* @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the SyncIdentityProviderInner.
+ * @throws IOException If an error occurs while reading the PlatformWorkloadIdentityRoleSetInner.
*/
- public static SyncIdentityProviderInner fromJson(JsonReader jsonReader) throws IOException {
+ public static PlatformWorkloadIdentityRoleSetInner fromJson(JsonReader jsonReader) throws IOException {
return jsonReader.readObject(reader -> {
- SyncIdentityProviderInner deserializedSyncIdentityProviderInner = new SyncIdentityProviderInner();
+ PlatformWorkloadIdentityRoleSetInner deserializedPlatformWorkloadIdentityRoleSetInner
+ = new PlatformWorkloadIdentityRoleSetInner();
while (reader.nextToken() != JsonToken.END_OBJECT) {
String fieldName = reader.getFieldName();
reader.nextToken();
if ("id".equals(fieldName)) {
- deserializedSyncIdentityProviderInner.id = reader.getString();
+ deserializedPlatformWorkloadIdentityRoleSetInner.id = reader.getString();
} else if ("name".equals(fieldName)) {
- deserializedSyncIdentityProviderInner.name = reader.getString();
+ deserializedPlatformWorkloadIdentityRoleSetInner.name = reader.getString();
} else if ("type".equals(fieldName)) {
- deserializedSyncIdentityProviderInner.type = reader.getString();
+ deserializedPlatformWorkloadIdentityRoleSetInner.type = reader.getString();
} else if ("properties".equals(fieldName)) {
- deserializedSyncIdentityProviderInner.innerProperties
- = SyncIdentityProviderProperties.fromJson(reader);
+ deserializedPlatformWorkloadIdentityRoleSetInner.innerProperties
+ = PlatformWorkloadIdentityRoleSetProperties.fromJson(reader);
} else if ("systemData".equals(fieldName)) {
- deserializedSyncIdentityProviderInner.systemData = SystemData.fromJson(reader);
+ deserializedPlatformWorkloadIdentityRoleSetInner.systemData = SystemData.fromJson(reader);
} else {
reader.skipChildren();
}
}
- return deserializedSyncIdentityProviderInner;
+ return deserializedPlatformWorkloadIdentityRoleSetInner;
});
}
}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetProperties.java
new file mode 100644
index 000000000000..477234d653a6
--- /dev/null
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/PlatformWorkloadIdentityRoleSetProperties.java
@@ -0,0 +1,100 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
+
+package com.azure.resourcemanager.redhatopenshift.fluent.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 com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityRole;
+import java.io.IOException;
+import java.util.List;
+
+/**
+ * PlatformWorkloadIdentityRoleSetProperties represents the properties of a PlatformWorkloadIdentityRoleSet resource.
+ */
+@Immutable
+public final class PlatformWorkloadIdentityRoleSetProperties
+ implements JsonSerializable {
+ /*
+ * OpenShiftVersion represents the version associated with this set of roles.
+ */
+ private String openShiftVersion;
+
+ /*
+ * PlatformWorkloadIdentityRoles represents the set of roles associated with this version.
+ */
+ private List platformWorkloadIdentityRoles;
+
+ /**
+ * Creates an instance of PlatformWorkloadIdentityRoleSetProperties class.
+ */
+ private PlatformWorkloadIdentityRoleSetProperties() {
+ }
+
+ /**
+ * Get the openShiftVersion property: OpenShiftVersion represents the version associated with this set of roles.
+ *
+ * @return the openShiftVersion value.
+ */
+ public String openShiftVersion() {
+ return this.openShiftVersion;
+ }
+
+ /**
+ * Get the platformWorkloadIdentityRoles property: PlatformWorkloadIdentityRoles represents the set of roles
+ * associated with this version.
+ *
+ * @return the platformWorkloadIdentityRoles value.
+ */
+ public List platformWorkloadIdentityRoles() {
+ return this.platformWorkloadIdentityRoles;
+ }
+
+ /**
+ * {@inheritDoc}
+ */
+ @Override
+ public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
+ jsonWriter.writeStartObject();
+ jsonWriter.writeStringField("openShiftVersion", this.openShiftVersion);
+ jsonWriter.writeArrayField("platformWorkloadIdentityRoles", this.platformWorkloadIdentityRoles,
+ (writer, element) -> writer.writeJson(element));
+ return jsonWriter.writeEndObject();
+ }
+
+ /**
+ * Reads an instance of PlatformWorkloadIdentityRoleSetProperties from the JsonReader.
+ *
+ * @param jsonReader The JsonReader being read.
+ * @return An instance of PlatformWorkloadIdentityRoleSetProperties 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 PlatformWorkloadIdentityRoleSetProperties.
+ */
+ public static PlatformWorkloadIdentityRoleSetProperties fromJson(JsonReader jsonReader) throws IOException {
+ return jsonReader.readObject(reader -> {
+ PlatformWorkloadIdentityRoleSetProperties deserializedPlatformWorkloadIdentityRoleSetProperties
+ = new PlatformWorkloadIdentityRoleSetProperties();
+ while (reader.nextToken() != JsonToken.END_OBJECT) {
+ String fieldName = reader.getFieldName();
+ reader.nextToken();
+
+ if ("openShiftVersion".equals(fieldName)) {
+ deserializedPlatformWorkloadIdentityRoleSetProperties.openShiftVersion = reader.getString();
+ } else if ("platformWorkloadIdentityRoles".equals(fieldName)) {
+ List platformWorkloadIdentityRoles
+ = reader.readArray(reader1 -> PlatformWorkloadIdentityRole.fromJson(reader1));
+ deserializedPlatformWorkloadIdentityRoleSetProperties.platformWorkloadIdentityRoles
+ = platformWorkloadIdentityRoles;
+ } else {
+ reader.skipChildren();
+ }
+ }
+
+ return deserializedPlatformWorkloadIdentityRoleSetProperties;
+ });
+ }
+}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretInner.java
deleted file mode 100644
index 734405bd0c41..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretInner.java
+++ /dev/null
@@ -1,177 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import java.io.IOException;
-
-/**
- * Secret represents a secret.
- */
-@Fluent
-public final class SecretInner extends ProxyResource {
- /*
- * The Secret Properties
- */
- private SecretProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- private SystemData systemData;
-
- /*
- * Fully qualified resource Id for the resource.
- */
- private String id;
-
- /*
- * The name of the resource.
- */
- private String name;
-
- /*
- * The type of the resource.
- */
- private String type;
-
- /**
- * Creates an instance of SecretInner class.
- */
- public SecretInner() {
- }
-
- /**
- * Get the innerProperties property: The Secret Properties.
- *
- * @return the innerProperties value.
- */
- private SecretProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- @Override
- public String id() {
- return this.id;
- }
-
- /**
- * Get the name property: The name of the resource.
- *
- * @return the name value.
- */
- @Override
- public String name() {
- return this.name;
- }
-
- /**
- * Get the type property: The type of the resource.
- *
- * @return the type value.
- */
- @Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the secretResources property: The Secrets Resources.
- *
- * @return the secretResources value.
- */
- public String secretResources() {
- return this.innerProperties() == null ? null : this.innerProperties().secretResources();
- }
-
- /**
- * Set the secretResources property: The Secrets Resources.
- *
- * @param secretResources the secretResources value to set.
- * @return the SecretInner object itself.
- */
- public SecretInner withSecretResources(String secretResources) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SecretProperties();
- }
- this.innerProperties().withSecretResources(secretResources);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeJsonField("properties", this.innerProperties);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SecretInner from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SecretInner if the JsonReader was pointing to an instance of it, or null if it was
- * pointing to JSON null.
- * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the SecretInner.
- */
- public static SecretInner fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SecretInner deserializedSecretInner = new SecretInner();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("id".equals(fieldName)) {
- deserializedSecretInner.id = reader.getString();
- } else if ("name".equals(fieldName)) {
- deserializedSecretInner.name = reader.getString();
- } else if ("type".equals(fieldName)) {
- deserializedSecretInner.type = reader.getString();
- } else if ("properties".equals(fieldName)) {
- deserializedSecretInner.innerProperties = SecretProperties.fromJson(reader);
- } else if ("systemData".equals(fieldName)) {
- deserializedSecretInner.systemData = SystemData.fromJson(reader);
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSecretInner;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretProperties.java
deleted file mode 100644
index d231f41aeadf..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SecretProperties.java
+++ /dev/null
@@ -1,93 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.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;
-
-/**
- * SecretProperties represents the properties of a Secret.
- */
-@Fluent
-public final class SecretProperties implements JsonSerializable {
- /*
- * The Secrets Resources.
- */
- private String secretResources;
-
- /**
- * Creates an instance of SecretProperties class.
- */
- public SecretProperties() {
- }
-
- /**
- * Get the secretResources property: The Secrets Resources.
- *
- * @return the secretResources value.
- */
- public String secretResources() {
- return this.secretResources;
- }
-
- /**
- * Set the secretResources property: The Secrets Resources.
- *
- * @param secretResources the secretResources value to set.
- * @return the SecretProperties object itself.
- */
- public SecretProperties withSecretResources(String secretResources) {
- this.secretResources = secretResources;
- return this;
- }
-
- /**
- * 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();
- jsonWriter.writeStringField("secretResources", this.secretResources);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SecretProperties from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SecretProperties 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 SecretProperties.
- */
- public static SecretProperties fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SecretProperties deserializedSecretProperties = new SecretProperties();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("secretResources".equals(fieldName)) {
- deserializedSecretProperties.secretResources = reader.getString();
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSecretProperties;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderProperties.java
deleted file mode 100644
index 3c5cb1346806..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncIdentityProviderProperties.java
+++ /dev/null
@@ -1,94 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.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;
-
-/**
- * SyncSetProperties represents the properties of a SyncSet.
- */
-@Fluent
-public final class SyncIdentityProviderProperties implements JsonSerializable {
- /*
- * The resources property.
- */
- private String resources;
-
- /**
- * Creates an instance of SyncIdentityProviderProperties class.
- */
- public SyncIdentityProviderProperties() {
- }
-
- /**
- * Get the resources property: The resources property.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.resources;
- }
-
- /**
- * Set the resources property: The resources property.
- *
- * @param resources the resources value to set.
- * @return the SyncIdentityProviderProperties object itself.
- */
- public SyncIdentityProviderProperties withResources(String resources) {
- this.resources = resources;
- return this;
- }
-
- /**
- * 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();
- jsonWriter.writeStringField("resources", this.resources);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SyncIdentityProviderProperties from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SyncIdentityProviderProperties 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 SyncIdentityProviderProperties.
- */
- public static SyncIdentityProviderProperties fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SyncIdentityProviderProperties deserializedSyncIdentityProviderProperties
- = new SyncIdentityProviderProperties();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("resources".equals(fieldName)) {
- deserializedSyncIdentityProviderProperties.resources = reader.getString();
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSyncIdentityProviderProperties;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetInner.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetInner.java
deleted file mode 100644
index 01677bcfae9b..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetInner.java
+++ /dev/null
@@ -1,177 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.management.ProxyResource;
-import com.azure.core.management.SystemData;
-import com.azure.json.JsonReader;
-import com.azure.json.JsonToken;
-import com.azure.json.JsonWriter;
-import java.io.IOException;
-
-/**
- * SyncSet represents a SyncSet for an Azure Red Hat OpenShift Cluster.
- */
-@Fluent
-public final class SyncSetInner extends ProxyResource {
- /*
- * The Syncsets properties
- */
- private SyncSetProperties innerProperties;
-
- /*
- * Azure Resource Manager metadata containing createdBy and modifiedBy information.
- */
- private SystemData systemData;
-
- /*
- * Fully qualified resource Id for the resource.
- */
- private String id;
-
- /*
- * The name of the resource.
- */
- private String name;
-
- /*
- * The type of the resource.
- */
- private String type;
-
- /**
- * Creates an instance of SyncSetInner class.
- */
- public SyncSetInner() {
- }
-
- /**
- * Get the innerProperties property: The Syncsets properties.
- *
- * @return the innerProperties value.
- */
- private SyncSetProperties innerProperties() {
- return this.innerProperties;
- }
-
- /**
- * Get the systemData property: Azure Resource Manager metadata containing createdBy and modifiedBy information.
- *
- * @return the systemData value.
- */
- public SystemData systemData() {
- return this.systemData;
- }
-
- /**
- * Get the id property: Fully qualified resource Id for the resource.
- *
- * @return the id value.
- */
- @Override
- public String id() {
- return this.id;
- }
-
- /**
- * Get the name property: The name of the resource.
- *
- * @return the name value.
- */
- @Override
- public String name() {
- return this.name;
- }
-
- /**
- * Get the type property: The type of the resource.
- *
- * @return the type value.
- */
- @Override
- public String type() {
- return this.type;
- }
-
- /**
- * Get the resources property: Resources represents the SyncSets configuration.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.innerProperties() == null ? null : this.innerProperties().resources();
- }
-
- /**
- * Set the resources property: Resources represents the SyncSets configuration.
- *
- * @param resources the resources value to set.
- * @return the SyncSetInner object itself.
- */
- public SyncSetInner withResources(String resources) {
- if (this.innerProperties() == null) {
- this.innerProperties = new SyncSetProperties();
- }
- this.innerProperties().withResources(resources);
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (innerProperties() != null) {
- innerProperties().validate();
- }
- }
-
- /**
- * {@inheritDoc}
- */
- @Override
- public JsonWriter toJson(JsonWriter jsonWriter) throws IOException {
- jsonWriter.writeStartObject();
- jsonWriter.writeJsonField("properties", this.innerProperties);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SyncSetInner from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SyncSetInner if the JsonReader was pointing to an instance of it, or null if it was
- * pointing to JSON null.
- * @throws IllegalStateException If the deserialized JSON object was missing any required properties.
- * @throws IOException If an error occurs while reading the SyncSetInner.
- */
- public static SyncSetInner fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SyncSetInner deserializedSyncSetInner = new SyncSetInner();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("id".equals(fieldName)) {
- deserializedSyncSetInner.id = reader.getString();
- } else if ("name".equals(fieldName)) {
- deserializedSyncSetInner.name = reader.getString();
- } else if ("type".equals(fieldName)) {
- deserializedSyncSetInner.type = reader.getString();
- } else if ("properties".equals(fieldName)) {
- deserializedSyncSetInner.innerProperties = SyncSetProperties.fromJson(reader);
- } else if ("systemData".equals(fieldName)) {
- deserializedSyncSetInner.systemData = SystemData.fromJson(reader);
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSyncSetInner;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetProperties.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetProperties.java
deleted file mode 100644
index eea844f8c996..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/SyncSetProperties.java
+++ /dev/null
@@ -1,93 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.fluent.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;
-
-/**
- * SyncSetProperties represents the properties of a SyncSet.
- */
-@Fluent
-public final class SyncSetProperties implements JsonSerializable {
- /*
- * Resources represents the SyncSets configuration.
- */
- private String resources;
-
- /**
- * Creates an instance of SyncSetProperties class.
- */
- public SyncSetProperties() {
- }
-
- /**
- * Get the resources property: Resources represents the SyncSets configuration.
- *
- * @return the resources value.
- */
- public String resources() {
- return this.resources;
- }
-
- /**
- * Set the resources property: Resources represents the SyncSets configuration.
- *
- * @param resources the resources value to set.
- * @return the SyncSetProperties object itself.
- */
- public SyncSetProperties withResources(String resources) {
- this.resources = resources;
- return this;
- }
-
- /**
- * 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();
- jsonWriter.writeStringField("resources", this.resources);
- return jsonWriter.writeEndObject();
- }
-
- /**
- * Reads an instance of SyncSetProperties from the JsonReader.
- *
- * @param jsonReader The JsonReader being read.
- * @return An instance of SyncSetProperties 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 SyncSetProperties.
- */
- public static SyncSetProperties fromJson(JsonReader jsonReader) throws IOException {
- return jsonReader.readObject(reader -> {
- SyncSetProperties deserializedSyncSetProperties = new SyncSetProperties();
- while (reader.nextToken() != JsonToken.END_OBJECT) {
- String fieldName = reader.getFieldName();
- reader.nextToken();
-
- if ("resources".equals(fieldName)) {
- deserializedSyncSetProperties.resources = reader.getString();
- } else {
- reader.skipChildren();
- }
- }
-
- return deserializedSyncSetProperties;
- });
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/package-info.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/package-info.java
index 49e8e4952273..8e2aa007459e 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/package-info.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/models/package-info.java
@@ -1,9 +1,9 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
/**
- * Package containing the inner data models for AzureRedHatOpenShiftClient.
+ * Package containing the inner data models for RedHatOpenShift.
* Rest API for Azure Red Hat OpenShift 4.
*/
package com.azure.resourcemanager.redhatopenshift.fluent.models;
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/package-info.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/package-info.java
index 6d8f04725466..db3dd99e1366 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/package-info.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/fluent/package-info.java
@@ -1,9 +1,9 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
/**
- * Package containing the service clients for AzureRedHatOpenShiftClient.
+ * Package containing the service clients for RedHatOpenShift.
* Rest API for Azure Red Hat OpenShift 4.
*/
package com.azure.resourcemanager.redhatopenshift.fluent;
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolImpl.java
deleted file mode 100644
index 96b6b3dc4bd7..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolImpl.java
+++ /dev/null
@@ -1,146 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.implementation;
-
-import com.azure.core.management.SystemData;
-import com.azure.core.util.Context;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.MachinePoolInner;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePool;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePoolUpdate;
-
-public final class MachinePoolImpl implements MachinePool, MachinePool.Definition, MachinePool.Update {
- private MachinePoolInner innerObject;
-
- private final com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager serviceManager;
-
- public String id() {
- return this.innerModel().id();
- }
-
- public String name() {
- return this.innerModel().name();
- }
-
- public String type() {
- return this.innerModel().type();
- }
-
- public SystemData systemData() {
- return this.innerModel().systemData();
- }
-
- public String resources() {
- return this.innerModel().resources();
- }
-
- public String resourceGroupName() {
- return resourceGroupName;
- }
-
- public MachinePoolInner innerModel() {
- return this.innerObject;
- }
-
- private com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager() {
- return this.serviceManager;
- }
-
- private String resourceGroupName;
-
- private String resourceName;
-
- private String childResourceName;
-
- private MachinePoolUpdate updateParameters;
-
- public MachinePoolImpl withExistingOpenshiftcluster(String resourceGroupName, String resourceName) {
- this.resourceGroupName = resourceGroupName;
- this.resourceName = resourceName;
- return this;
- }
-
- public MachinePool create() {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .createOrUpdateWithResponse(resourceGroupName, resourceName, childResourceName, this.innerModel(),
- Context.NONE)
- .getValue();
- return this;
- }
-
- public MachinePool create(Context context) {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .createOrUpdateWithResponse(resourceGroupName, resourceName, childResourceName, this.innerModel(), context)
- .getValue();
- return this;
- }
-
- MachinePoolImpl(String name, com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager serviceManager) {
- this.innerObject = new MachinePoolInner();
- this.serviceManager = serviceManager;
- this.childResourceName = name;
- }
-
- public MachinePoolImpl update() {
- this.updateParameters = new MachinePoolUpdate();
- return this;
- }
-
- public MachinePool apply() {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .updateWithResponse(resourceGroupName, resourceName, childResourceName, updateParameters, Context.NONE)
- .getValue();
- return this;
- }
-
- public MachinePool apply(Context context) {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .updateWithResponse(resourceGroupName, resourceName, childResourceName, updateParameters, context)
- .getValue();
- return this;
- }
-
- MachinePoolImpl(MachinePoolInner innerObject,
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager serviceManager) {
- this.innerObject = innerObject;
- this.serviceManager = serviceManager;
- this.resourceGroupName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "resourceGroups");
- this.resourceName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "openshiftclusters");
- this.childResourceName = ResourceManagerUtils.getValueFromIdByName(innerObject.id(), "machinePool");
- }
-
- public MachinePool refresh() {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .getWithResponse(resourceGroupName, resourceName, childResourceName, Context.NONE)
- .getValue();
- return this;
- }
-
- public MachinePool refresh(Context context) {
- this.innerObject = serviceManager.serviceClient()
- .getMachinePools()
- .getWithResponse(resourceGroupName, resourceName, childResourceName, context)
- .getValue();
- return this;
- }
-
- public MachinePoolImpl withResources(String resources) {
- if (isInCreateMode()) {
- this.innerModel().withResources(resources);
- return this;
- } else {
- this.updateParameters.withResources(resources);
- return this;
- }
- }
-
- private boolean isInCreateMode() {
- return this.innerModel().id() == null;
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsClientImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsClientImpl.java
deleted file mode 100644
index e29614d6e420..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsClientImpl.java
+++ /dev/null
@@ -1,942 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.implementation;
-
-import com.azure.core.annotation.BodyParam;
-import com.azure.core.annotation.Delete;
-import com.azure.core.annotation.ExpectedResponses;
-import com.azure.core.annotation.Get;
-import com.azure.core.annotation.HeaderParam;
-import com.azure.core.annotation.Headers;
-import com.azure.core.annotation.Host;
-import com.azure.core.annotation.HostParam;
-import com.azure.core.annotation.Patch;
-import com.azure.core.annotation.PathParam;
-import com.azure.core.annotation.Put;
-import com.azure.core.annotation.QueryParam;
-import com.azure.core.annotation.ReturnType;
-import com.azure.core.annotation.ServiceInterface;
-import com.azure.core.annotation.ServiceMethod;
-import com.azure.core.annotation.UnexpectedResponseExceptionType;
-import com.azure.core.http.rest.PagedFlux;
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.PagedResponse;
-import com.azure.core.http.rest.PagedResponseBase;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.RestProxy;
-import com.azure.core.management.exception.ManagementException;
-import com.azure.core.util.Context;
-import com.azure.core.util.FluxUtil;
-import com.azure.resourcemanager.redhatopenshift.fluent.MachinePoolsClient;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.MachinePoolInner;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePoolList;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePoolUpdate;
-import reactor.core.publisher.Mono;
-
-/**
- * An instance of this class provides access to all the operations defined in MachinePoolsClient.
- */
-public final class MachinePoolsClientImpl implements MachinePoolsClient {
- /**
- * The proxy service used to perform REST calls.
- */
- private final MachinePoolsService service;
-
- /**
- * The service client containing this operation class.
- */
- private final AzureRedHatOpenShiftClientImpl client;
-
- /**
- * Initializes an instance of MachinePoolsClientImpl.
- *
- * @param client the instance of the service client containing this operation class.
- */
- MachinePoolsClientImpl(AzureRedHatOpenShiftClientImpl client) {
- this.service
- = RestProxy.create(MachinePoolsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
- this.client = client;
- }
-
- /**
- * The interface defining all the services for AzureRedHatOpenShiftClientMachinePools to be used by the proxy
- * service to perform REST calls.
- */
- @Host("{$host}")
- @ServiceInterface(name = "AzureRedHatOpenShift")
- public interface MachinePoolsService {
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftCluster/{resourceName}/machinePools")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @HeaderParam("Accept") String accept, Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openshiftclusters/{resourceName}/machinePool/{childResourceName}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> get(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @PathParam("childResourceName") String childResourceName, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openshiftclusters/{resourceName}/machinePool/{childResourceName}")
- @ExpectedResponses({ 200, 201 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> createOrUpdate(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @PathParam("childResourceName") String childResourceName,
- @BodyParam("application/json") MachinePoolInner parameters, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openshiftclusters/{resourceName}/machinePool/{childResourceName}")
- @ExpectedResponses({ 200, 204 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> delete(@HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion,
- @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @PathParam("childResourceName") String childResourceName, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openshiftclusters/{resourceName}/machinePool/{childResourceName}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> update(@HostParam("$host") String endpoint,
- @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @PathParam("childResourceName") String childResourceName,
- @BodyParam("application/json") MachinePoolUpdate parameters, @HeaderParam("Accept") String accept,
- Context context);
-
- @Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
- @ExpectedResponses({ 200 })
- @UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listNext(@PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint, @HeaderParam("Accept") String accept, Context context);
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools along with {@link PagedResponse} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String resourceGroupName, String resourceName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.list(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(),
- res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools along with {@link PagedResponse} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(String resourceGroupName, String resourceName,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String resourceGroupName, String resourceName) {
- return new PagedFlux<>(() -> listSinglePageAsync(resourceGroupName, resourceName),
- nextLink -> listNextSinglePageAsync(nextLink));
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(String resourceGroupName, String resourceName, Context context) {
- return new PagedFlux<>(() -> listSinglePageAsync(resourceGroupName, resourceName, context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String resourceGroupName, String resourceName) {
- return new PagedIterable<>(listAsync(resourceGroupName, resourceName));
- }
-
- /**
- * Lists MachinePools that belong to that Azure Red Hat OpenShift Cluster.
- *
- * The operation returns properties of each MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 machinePoolList represents a list of MachinePools as paginated response with {@link PagedIterable}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(String resourceGroupName, String resourceName, Context context) {
- return new PagedIterable<>(listAsync(resourceGroupName, resourceName, context));
- }
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.get(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, childResourceName, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.get(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, childResourceName, accept, context);
- }
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getAsync(String resourceGroupName, String resourceName, String childResourceName) {
- return getWithResponseAsync(resourceGroupName, resourceName, childResourceName)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response getWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, Context context) {
- return getWithResponseAsync(resourceGroupName, resourceName, childResourceName, context).block();
- }
-
- /**
- * Gets a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public MachinePoolInner get(String resourceGroupName, String resourceName, String childResourceName) {
- return getWithResponse(resourceGroupName, resourceName, childResourceName, Context.NONE).getValue();
- }
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(String resourceGroupName,
- String resourceName, String childResourceName, MachinePoolInner parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, childResourceName, parameters, accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> createOrUpdateWithResponseAsync(String resourceGroupName,
- String resourceName, String childResourceName, MachinePoolInner parameters, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, childResourceName, parameters, accept,
- context);
- }
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolInner parameters) {
- return createOrUpdateWithResponseAsync(resourceGroupName, resourceName, childResourceName, parameters)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolInner parameters, Context context) {
- return createOrUpdateWithResponseAsync(resourceGroupName, resourceName, childResourceName, parameters, context)
- .block();
- }
-
- /**
- * Creates or updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public MachinePoolInner createOrUpdate(String resourceGroupName, String resourceName, String childResourceName,
- MachinePoolInner parameters) {
- return createOrUpdateWithResponse(resourceGroupName, resourceName, childResourceName, parameters, Context.NONE)
- .getValue();
- }
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.delete(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, childResourceName, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> deleteWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.delete(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, childResourceName, accept, context);
- }
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return A {@link Mono} that completes when a successful response is received.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String resourceName, String childResourceName) {
- return deleteWithResponseAsync(resourceGroupName, resourceName, childResourceName)
- .flatMap(ignored -> Mono.empty());
- }
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context) {
- return deleteWithResponseAsync(resourceGroupName, resourceName, childResourceName, context).block();
- }
-
- /**
- * Deletes a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns nothing.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
- * @throws ManagementException thrown if the request is rejected by server.
- * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String resourceName, String childResourceName) {
- deleteWithResponse(resourceGroupName, resourceName, childResourceName, Context.NONE);
- }
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> updateWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolUpdate parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.update(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, childResourceName, parameters, accept,
- context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response} on successful completion of
- * {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> updateWithResponseAsync(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolUpdate parameters, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (childResourceName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter childResourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.update(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, childResourceName, parameters, accept, context);
- }
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String resourceGroupName, String resourceName, String childResourceName,
- MachinePoolUpdate parameters) {
- return updateWithResponseAsync(resourceGroupName, resourceName, childResourceName, parameters)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
- }
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool along with {@link Response}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public Response updateWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, MachinePoolUpdate parameters, Context context) {
- return updateWithResponseAsync(resourceGroupName, resourceName, childResourceName, parameters, context).block();
- }
-
- /**
- * Updates a MachinePool with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a MachinePool.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param childResourceName The name of the MachinePool resource.
- * @param parameters The MachinePool resource.
- * @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 machinePool represents a MachinePool.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- public MachinePoolInner update(String resourceGroupName, String resourceName, String childResourceName,
- MachinePoolUpdate parameters) {
- return updateWithResponse(resourceGroupName, resourceName, childResourceName, parameters, Context.NONE)
- .getValue();
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @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 machinePoolList represents a list of MachinePools along with {@link PagedResponse} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil.withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(),
- res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
- }
-
- /**
- * Get the next page of items.
- *
- * @param nextLink The URL to get the next list of items.
- * @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 machinePoolList represents a list of MachinePools along with {@link PagedResponse} on successful
- * completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listNextSinglePageAsync(String nextLink, Context context) {
- if (nextLink == null) {
- return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null."));
- }
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.listNext(nextLink, this.client.getEndpoint(), accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsImpl.java
deleted file mode 100644
index d27d56e98965..000000000000
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/MachinePoolsImpl.java
+++ /dev/null
@@ -1,157 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
-
-package com.azure.resourcemanager.redhatopenshift.implementation;
-
-import com.azure.core.http.rest.PagedIterable;
-import com.azure.core.http.rest.Response;
-import com.azure.core.http.rest.SimpleResponse;
-import com.azure.core.util.Context;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.redhatopenshift.fluent.MachinePoolsClient;
-import com.azure.resourcemanager.redhatopenshift.fluent.models.MachinePoolInner;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePool;
-import com.azure.resourcemanager.redhatopenshift.models.MachinePools;
-
-public final class MachinePoolsImpl implements MachinePools {
- private static final ClientLogger LOGGER = new ClientLogger(MachinePoolsImpl.class);
-
- private final MachinePoolsClient innerClient;
-
- private final com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager serviceManager;
-
- public MachinePoolsImpl(MachinePoolsClient innerClient,
- com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager serviceManager) {
- this.innerClient = innerClient;
- this.serviceManager = serviceManager;
- }
-
- public PagedIterable list(String resourceGroupName, String resourceName) {
- PagedIterable inner = this.serviceClient().list(resourceGroupName, resourceName);
- return ResourceManagerUtils.mapPage(inner, inner1 -> new MachinePoolImpl(inner1, this.manager()));
- }
-
- public PagedIterable list(String resourceGroupName, String resourceName, Context context) {
- PagedIterable inner = this.serviceClient().list(resourceGroupName, resourceName, context);
- return ResourceManagerUtils.mapPage(inner, inner1 -> new MachinePoolImpl(inner1, this.manager()));
- }
-
- public Response getWithResponse(String resourceGroupName, String resourceName,
- String childResourceName, Context context) {
- Response inner
- = this.serviceClient().getWithResponse(resourceGroupName, resourceName, childResourceName, context);
- if (inner != null) {
- return new SimpleResponse<>(inner.getRequest(), inner.getStatusCode(), inner.getHeaders(),
- new MachinePoolImpl(inner.getValue(), this.manager()));
- } else {
- return null;
- }
- }
-
- public MachinePool get(String resourceGroupName, String resourceName, String childResourceName) {
- MachinePoolInner inner = this.serviceClient().get(resourceGroupName, resourceName, childResourceName);
- if (inner != null) {
- return new MachinePoolImpl(inner, this.manager());
- } else {
- return null;
- }
- }
-
- public Response deleteWithResponse(String resourceGroupName, String resourceName, String childResourceName,
- Context context) {
- return this.serviceClient().deleteWithResponse(resourceGroupName, resourceName, childResourceName, context);
- }
-
- public void delete(String resourceGroupName, String resourceName, String childResourceName) {
- this.serviceClient().delete(resourceGroupName, resourceName, childResourceName);
- }
-
- public MachinePool getById(String id) {
- String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String resourceName = ResourceManagerUtils.getValueFromIdByName(id, "openshiftclusters");
- if (resourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'openshiftclusters'.", id)));
- }
- String childResourceName = ResourceManagerUtils.getValueFromIdByName(id, "machinePool");
- if (childResourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'machinePool'.", id)));
- }
- return this.getWithResponse(resourceGroupName, resourceName, childResourceName, Context.NONE).getValue();
- }
-
- public Response getByIdWithResponse(String id, Context context) {
- String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String resourceName = ResourceManagerUtils.getValueFromIdByName(id, "openshiftclusters");
- if (resourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'openshiftclusters'.", id)));
- }
- String childResourceName = ResourceManagerUtils.getValueFromIdByName(id, "machinePool");
- if (childResourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'machinePool'.", id)));
- }
- return this.getWithResponse(resourceGroupName, resourceName, childResourceName, context);
- }
-
- public void deleteById(String id) {
- String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String resourceName = ResourceManagerUtils.getValueFromIdByName(id, "openshiftclusters");
- if (resourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'openshiftclusters'.", id)));
- }
- String childResourceName = ResourceManagerUtils.getValueFromIdByName(id, "machinePool");
- if (childResourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'machinePool'.", id)));
- }
- this.deleteWithResponse(resourceGroupName, resourceName, childResourceName, Context.NONE);
- }
-
- public Response deleteByIdWithResponse(String id, Context context) {
- String resourceGroupName = ResourceManagerUtils.getValueFromIdByName(id, "resourceGroups");
- if (resourceGroupName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'resourceGroups'.", id)));
- }
- String resourceName = ResourceManagerUtils.getValueFromIdByName(id, "openshiftclusters");
- if (resourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'openshiftclusters'.", id)));
- }
- String childResourceName = ResourceManagerUtils.getValueFromIdByName(id, "machinePool");
- if (childResourceName == null) {
- throw LOGGER.logExceptionAsError(new IllegalArgumentException(
- String.format("The resource ID '%s' is not valid. Missing path segment 'machinePool'.", id)));
- }
- return this.deleteWithResponse(resourceGroupName, resourceName, childResourceName, context);
- }
-
- private MachinePoolsClient serviceClient() {
- return this.innerClient;
- }
-
- private com.azure.resourcemanager.redhatopenshift.RedHatOpenShiftManager manager() {
- return this.serviceManager;
- }
-
- public MachinePoolImpl define(String name) {
- return new MachinePoolImpl(name, this.manager());
- }
-}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterAdminKubeconfigImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterAdminKubeconfigImpl.java
index 9ee1529b870f..6a1b07b4ceab 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterAdminKubeconfigImpl.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterAdminKubeconfigImpl.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.implementation;
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterCredentialsImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterCredentialsImpl.java
index 27b3ff48154f..de21cd62663e 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterCredentialsImpl.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterCredentialsImpl.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.implementation;
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterImpl.java
index 9ce59684e085..b30e511b8539 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterImpl.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClusterImpl.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.implementation;
@@ -13,12 +13,14 @@
import com.azure.resourcemanager.redhatopenshift.models.ClusterProfile;
import com.azure.resourcemanager.redhatopenshift.models.ConsoleProfile;
import com.azure.resourcemanager.redhatopenshift.models.IngressProfile;
+import com.azure.resourcemanager.redhatopenshift.models.ManagedServiceIdentity;
import com.azure.resourcemanager.redhatopenshift.models.MasterProfile;
import com.azure.resourcemanager.redhatopenshift.models.NetworkProfile;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftCluster;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusterAdminKubeconfig;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusterCredentials;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusterUpdate;
+import com.azure.resourcemanager.redhatopenshift.models.PlatformWorkloadIdentityProfile;
import com.azure.resourcemanager.redhatopenshift.models.ProvisioningState;
import com.azure.resourcemanager.redhatopenshift.models.ServicePrincipalProfile;
import com.azure.resourcemanager.redhatopenshift.models.WorkerProfile;
@@ -57,6 +59,10 @@ public Map tags() {
}
}
+ public ManagedServiceIdentity identity() {
+ return this.innerModel().identity();
+ }
+
public SystemData systemData() {
return this.innerModel().systemData();
}
@@ -77,6 +83,10 @@ public ServicePrincipalProfile servicePrincipalProfile() {
return this.innerModel().servicePrincipalProfile();
}
+ public PlatformWorkloadIdentityProfile platformWorkloadIdentityProfile() {
+ return this.innerModel().platformWorkloadIdentityProfile();
+ }
+
public NetworkProfile networkProfile() {
return this.innerModel().networkProfile();
}
@@ -247,6 +257,16 @@ public OpenShiftClusterImpl withTags(Map tags) {
}
}
+ public OpenShiftClusterImpl withIdentity(ManagedServiceIdentity identity) {
+ if (isInCreateMode()) {
+ this.innerModel().withIdentity(identity);
+ return this;
+ } else {
+ this.updateParameters.withIdentity(identity);
+ return this;
+ }
+ }
+
public OpenShiftClusterImpl withProvisioningState(ProvisioningState provisioningState) {
if (isInCreateMode()) {
this.innerModel().withProvisioningState(provisioningState);
@@ -287,6 +307,17 @@ public OpenShiftClusterImpl withServicePrincipalProfile(ServicePrincipalProfile
}
}
+ public OpenShiftClusterImpl
+ withPlatformWorkloadIdentityProfile(PlatformWorkloadIdentityProfile platformWorkloadIdentityProfile) {
+ if (isInCreateMode()) {
+ this.innerModel().withPlatformWorkloadIdentityProfile(platformWorkloadIdentityProfile);
+ return this;
+ } else {
+ this.updateParameters.withPlatformWorkloadIdentityProfile(platformWorkloadIdentityProfile);
+ return this;
+ }
+ }
+
public OpenShiftClusterImpl withNetworkProfile(NetworkProfile networkProfile) {
if (isInCreateMode()) {
this.innerModel().withNetworkProfile(networkProfile);
@@ -338,6 +369,6 @@ public OpenShiftClusterImpl withIngressProfiles(List ingressProf
}
private boolean isInCreateMode() {
- return this.innerModel().id() == null;
+ return this.innerModel() == null || this.innerModel().id() == null;
}
}
diff --git a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClustersClientImpl.java b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClustersClientImpl.java
index ea47e5bebc65..edd24c8e1cf1 100644
--- a/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClustersClientImpl.java
+++ b/sdk/redhatopenshift/azure-resourcemanager-redhatopenshift/src/main/java/com/azure/resourcemanager/redhatopenshift/implementation/OpenShiftClustersClientImpl.java
@@ -1,6 +1,6 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.
-// Code generated by Microsoft (R) AutoRest Code Generator.
+// Code generated by Microsoft (R) TypeSpec Code Generator.
package com.azure.resourcemanager.redhatopenshift.implementation;
@@ -29,6 +29,7 @@
import com.azure.core.http.rest.RestProxy;
import com.azure.core.management.exception.ManagementException;
import com.azure.core.management.polling.PollResult;
+import com.azure.core.util.BinaryData;
import com.azure.core.util.Context;
import com.azure.core.util.FluxUtil;
import com.azure.core.util.polling.PollerFlux;
@@ -37,7 +38,7 @@
import com.azure.resourcemanager.redhatopenshift.fluent.models.OpenShiftClusterAdminKubeconfigInner;
import com.azure.resourcemanager.redhatopenshift.fluent.models.OpenShiftClusterCredentialsInner;
import com.azure.resourcemanager.redhatopenshift.fluent.models.OpenShiftClusterInner;
-import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusterList;
+import com.azure.resourcemanager.redhatopenshift.implementation.models.OpenShiftClusterList;
import com.azure.resourcemanager.redhatopenshift.models.OpenShiftClusterUpdate;
import java.nio.ByteBuffer;
import reactor.core.publisher.Flux;
@@ -55,86 +56,147 @@ public final class OpenShiftClustersClientImpl implements OpenShiftClustersClien
/**
* The service client containing this operation class.
*/
- private final AzureRedHatOpenShiftClientImpl client;
+ private final RedHatOpenShiftManagementClientImpl client;
/**
* Initializes an instance of OpenShiftClustersClientImpl.
*
* @param client the instance of the service client containing this operation class.
*/
- OpenShiftClustersClientImpl(AzureRedHatOpenShiftClientImpl client) {
+ OpenShiftClustersClientImpl(RedHatOpenShiftManagementClientImpl client) {
this.service
= RestProxy.create(OpenShiftClustersService.class, client.getHttpPipeline(), client.getSerializerAdapter());
this.client = client;
}
/**
- * The interface defining all the services for AzureRedHatOpenShiftClientOpenShiftClusters to be used by the proxy
- * service to perform REST calls.
+ * The interface defining all the services for RedHatOpenShiftManagementClientOpenShiftClusters to be used by the
+ * proxy service to perform REST calls.
*/
- @Host("{$host}")
- @ServiceInterface(name = "AzureRedHatOpenShift")
+ @Host("{endpoint}")
+ @ServiceInterface(name = "RedHatOpenShiftManagementClientOpenShiftClusters")
public interface OpenShiftClustersService {
@Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(@HostParam("$host") String endpoint,
+ Mono> getByResourceGroup(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listByResourceGroup(@HostParam("$host") String endpoint,
+ Response getByResourceGroupSync(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
- @PathParam("resourceGroupName") String resourceGroupName, @HeaderParam("Accept") String accept,
- Context context);
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ @HeaderParam("Accept") String accept, Context context);
- @Headers({ "Content-Type: application/json" })
- @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
- @ExpectedResponses({ 200 })
+ @Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
+ @ExpectedResponses({ 200, 201 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> getByResourceGroup(@HostParam("$host") String endpoint,
+ Mono>> createOrUpdate(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @HeaderParam("Accept") String accept, Context context);
+ @HeaderParam("Content-Type") String contentType, @HeaderParam("Accept") String accept,
+ @BodyParam("application/json") OpenShiftClusterInner parameters, Context context);
- @Headers({ "Content-Type: application/json" })
@Put("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
@ExpectedResponses({ 200, 201 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> createOrUpdate(@HostParam("$host") String endpoint,
+ Response createOrUpdateSync(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ @HeaderParam("Content-Type") String contentType, @HeaderParam("Accept") String accept,
+ @BodyParam("application/json") OpenShiftClusterInner parameters, Context context);
+
+ @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
+ @ExpectedResponses({ 200, 201 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> update(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ @HeaderParam("Content-Type") String contentType, @HeaderParam("Accept") String accept,
+ @BodyParam("application/json") OpenShiftClusterUpdate parameters, Context context);
+
+ @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
+ @ExpectedResponses({ 200, 201 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response updateSync(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ @HeaderParam("Content-Type") String contentType, @HeaderParam("Accept") String accept,
+ @BodyParam("application/json") OpenShiftClusterUpdate parameters, Context context);
+
+ @Headers({ "Accept: application/json;q=0.9", "Content-Type: application/json" })
+ @Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
+ @ExpectedResponses({ 202, 204 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> delete(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @BodyParam("application/json") OpenShiftClusterInner parameters, @HeaderParam("Accept") String accept,
Context context);
- @Headers({ "Content-Type: application/json" })
+ @Headers({ "Accept: application/json;q=0.9", "Content-Type: application/json" })
@Delete("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
@ExpectedResponses({ 202, 204 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> delete(@HostParam("$host") String endpoint,
+ Response deleteSync(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByResourceGroup(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByResourceGroupSync(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> list(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
- @Patch("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}")
- @ExpectedResponses({ 200, 201 })
+ @Get("/subscriptions/{subscriptionId}/providers/Microsoft.RedHatOpenShift/openShiftClusters")
+ @ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono>> update(@HostParam("$host") String endpoint,
+ Response listSync(@HostParam("endpoint") 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.RedHatOpenShift/openShiftClusters/{resourceName}/listAdminCredentials")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listAdminCredentials(
+ @HostParam("endpoint") String endpoint, @QueryParam("api-version") String apiVersion,
+ @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
- @BodyParam("application/json") OpenShiftClusterUpdate parameters, @HeaderParam("Accept") String accept,
- Context context);
+ @HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
@Post("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}/listAdminCredentials")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listAdminCredentials(@HostParam("$host") String endpoint,
+ Response listAdminCredentialsSync(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
@HeaderParam("Accept") String accept, Context context);
@@ -143,424 +205,334 @@ Mono> listAdminCredentials(@HostP
@Post("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}/listCredentials")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listCredentials(@HostParam("$host") String endpoint,
+ Mono> listCredentials(@HostParam("endpoint") String endpoint,
@QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
@PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
@HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
- @Get("{nextLink}")
+ @Post("/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.RedHatOpenShift/openShiftClusters/{resourceName}/listCredentials")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> listNext(@PathParam(value = "nextLink", encoded = true) String nextLink,
- @HostParam("$host") String endpoint, @HeaderParam("Accept") String accept, Context context);
+ Response listCredentialsSync(@HostParam("endpoint") String endpoint,
+ @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName, @PathParam("resourceName") String resourceName,
+ @HeaderParam("Accept") String accept, Context context);
@Headers({ "Content-Type: application/json" })
@Get("{nextLink}")
@ExpectedResponses({ 200 })
@UnexpectedResponseExceptionType(ManagementException.class)
Mono> listByResourceGroupNext(
- @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint,
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("endpoint") String endpoint,
+ @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listByResourceGroupNextSync(
+ @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("endpoint") String endpoint,
@HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listNext(@PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, Context context);
+
+ @Headers({ "Content-Type: application/json" })
+ @Get("{nextLink}")
+ @ExpectedResponses({ 200 })
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Response listNextSync(@PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("endpoint") String endpoint, @HeaderParam("Accept") String accept, Context context);
}
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @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 openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
+ *
+ * The operation returns properties of a OpenShift cluster along with {@link Response} on successful completion of
+ * {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync() {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
+ private Mono> getByResourceGroupWithResponseAsync(String resourceGroupName,
+ String resourceName) {
final String accept = "application/json";
return FluxUtil
- .withContext(context -> service.list(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
+ .withContext(context -> service.getByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
- * @param context The context to associate with this operation.
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listSinglePageAsync(Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .list(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), accept,
- context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Lists OpenShift clusters in the specified subscription.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
- *
- * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedFlux}.
+ * The operation returns properties of a OpenShift cluster on successful completion of {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync() {
- return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getByResourceGroupAsync(String resourceGroupName, String resourceName) {
+ return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName)
+ .flatMap(res -> Mono.justOrEmpty(res.getValue()));
}
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listAsync(Context context) {
- return new PagedFlux<>(() -> listSinglePageAsync(context),
- nextLink -> listNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists OpenShift clusters in the specified subscription.
- *
- * The operation returns properties of each OpenShift cluster.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * The operation returns properties of a OpenShift cluster along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list() {
- return new PagedIterable<>(listAsync());
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getByResourceGroupWithResponse(String resourceGroupName, String resourceName,
+ Context context) {
+ final String accept = "application/json";
+ return service.getByResourceGroupSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context);
}
/**
- * Lists OpenShift clusters in the specified subscription.
+ * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
- * @param context The context to associate with this operation.
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return a OpenShift cluster with the specified subscription, resource group and resource name.
+ *
+ * The operation returns properties of a OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable list(Context context) {
- return new PagedIterable<>(listAsync(context));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public OpenShiftClusterInner getByResourceGroup(String resourceGroupName, String resourceName) {
+ return getByResourceGroupWithResponse(resourceGroupName, resourceName, Context.NONE).getValue();
}
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
+ * completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
+ private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName,
+ String resourceName, OpenShiftClusterInner parameters) {
+ final String contentType = "application/json";
final String accept = "application/json";
return FluxUtil
- .withContext(context -> service.listByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, accept, context))
- .>map(res -> new PagedResponseBase<>(res.getRequest(),
- res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
+ .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters,
+ context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param context The context to associate with this operation.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
- * successful completion of {@link Mono}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
+ private Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters) {
+ final String contentType = "application/json";
final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service
- .listByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, accept, context)
- .map(res -> new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(),
- res.getValue().value(), res.getValue().nextLink(), null));
- }
-
- /**
- * Lists OpenShift clusters in the specified subscription and resource group.
- *
- * The operation returns properties of each OpenShift cluster.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByResourceGroupAsync(String resourceGroupName) {
- return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName),
- nextLink -> listByResourceGroupNextSinglePageAsync(nextLink));
+ return service.createOrUpdateSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters,
+ Context.NONE);
}
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedFlux}.
- */
- @ServiceMethod(returns = ReturnType.COLLECTION)
- private PagedFlux listByResourceGroupAsync(String resourceGroupName, Context context) {
- return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName, context),
- nextLink -> listByResourceGroupNextSinglePageAsync(nextLink, context));
- }
-
- /**
- * Lists OpenShift clusters in the specified subscription and resource group.
- *
- * The operation returns properties of each OpenShift cluster.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByResourceGroup(String resourceGroupName) {
- return new PagedIterable<>(listByResourceGroupAsync(resourceGroupName));
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Response createOrUpdateWithResponse(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters, Context context) {
+ final String contentType = "application/json";
+ final String accept = "application/json";
+ return service.createOrUpdateSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters, context);
}
/**
- * Lists OpenShift clusters in the specified subscription and resource group.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
- * The operation returns properties of each OpenShift cluster.
+ * The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param context The context to associate with this operation.
+ * @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
- * {@link PagedIterable}.
+ * @return the {@link PollerFlux} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.COLLECTION)
- public PagedIterable listByResourceGroup(String resourceGroupName, Context context) {
- return new PagedIterable<>(listByResourceGroupAsync(resourceGroupName, context));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, OpenShiftClusterInner>
+ beginCreateOrUpdateAsync(String resourceGroupName, String resourceName, OpenShiftClusterInner parameters) {
+ Mono>> mono
+ = createOrUpdateWithResponseAsync(resourceGroupName, resourceName, parameters);
+ return this.client.getLroResult(mono,
+ this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class,
+ this.client.getContext());
}
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
- * completion of {@link Mono}.
+ * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getByResourceGroupWithResponseAsync(String resourceGroupName,
- String resourceName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.getByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, OpenShiftClusterInner>
+ beginCreateOrUpdate(String resourceGroupName, String resourceName, OpenShiftClusterInner parameters) {
+ Response response = createOrUpdateWithResponse(resourceGroupName, resourceName, parameters);
+ return this.client.getLroResult(response,
+ OpenShiftClusterInner.class, OpenShiftClusterInner.class, Context.NONE);
}
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
- * completion of {@link Mono}.
+ * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> getByResourceGroupWithResponseAsync(String resourceGroupName,
- String resourceName, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.getByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context);
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(
+ String resourceGroupName, String resourceName, OpenShiftClusterInner parameters, Context context) {
+ Response response
+ = createOrUpdateWithResponse(resourceGroupName, resourceName, parameters, context);
+ return this.client.getLroResult(response,
+ OpenShiftClusterInner.class, OpenShiftClusterInner.class, context);
}
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono getByResourceGroupAsync(String resourceGroupName, String resourceName) {
- return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName)
- .flatMap(res -> Mono.justOrEmpty(res.getValue()));
+ private Mono createOrUpdateAsync(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters) {
+ return beginCreateOrUpdateAsync(resourceGroupName, resourceName, parameters).last()
+ .flatMap(this.client::getLroFinalResultOrError);
}
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
- * @param context The context to associate with this operation.
+ * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response getByResourceGroupWithResponse(String resourceGroupName, String resourceName,
- Context context) {
- return getByResourceGroupWithResponseAsync(resourceGroupName, resourceName, context).block();
+ public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters) {
+ return beginCreateOrUpdate(resourceGroupName, resourceName, parameters).getFinalResult();
}
/**
- * Gets a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
*
* The operation returns properties of a OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param parameters The OpenShift cluster resource.
+ * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public OpenShiftClusterInner getByResourceGroup(String resourceGroupName, String resourceName) {
- return getByResourceGroupWithResponse(resourceGroupName, resourceName, Context.NONE).getValue();
+ public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
+ OpenShiftClusterInner parameters, Context context) {
+ return beginCreateOrUpdate(resourceGroupName, resourceName, parameters, context).getFinalResult();
}
/**
@@ -578,32 +550,12 @@ public OpenShiftClusterInner getByResourceGroup(String resourceGroupName, String
* completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName,
- String resourceName, OpenShiftClusterInner parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ private Mono>> updateWithResponseAsync(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters) {
+ final String contentType = "application/json";
final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, parameters, accept, context))
+ return FluxUtil.withContext(context -> service.update(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
@@ -615,40 +567,19 @@ private Mono>> createOrUpdateWithResponseAsync(String
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
* @param parameters The OpenShift cluster resource.
- * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
- * completion of {@link Mono}.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> createOrUpdateWithResponseAsync(String resourceGroupName,
- String resourceName, OpenShiftClusterInner parameters, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ private Response updateWithResponse(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters) {
+ final String contentType = "application/json";
final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.createOrUpdate(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, parameters, accept, context);
+ return service.updateSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters,
+ Context.NONE);
}
/**
@@ -659,19 +590,19 @@ private Mono>> createOrUpdateWithResponseAsync(String
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
* @param parameters The OpenShift cluster resource.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, OpenShiftClusterInner>
- beginCreateOrUpdateAsync(String resourceGroupName, String resourceName, OpenShiftClusterInner parameters) {
- Mono>> mono
- = createOrUpdateWithResponseAsync(resourceGroupName, resourceName, parameters);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class,
- this.client.getContext());
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Response updateWithResponse(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters, Context context) {
+ final String contentType = "application/json";
+ final String accept = "application/json";
+ return service.updateSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, contentType, accept, parameters, context);
}
/**
@@ -682,20 +613,18 @@ private Mono>> createOrUpdateWithResponseAsync(String
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
* @param parameters The OpenShift cluster resource.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the {@link PollerFlux} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, OpenShiftClusterInner> beginCreateOrUpdateAsync(
- String resourceGroupName, String resourceName, OpenShiftClusterInner parameters, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono
- = createOrUpdateWithResponseAsync(resourceGroupName, resourceName, parameters, context);
+ private PollerFlux, OpenShiftClusterInner>
+ beginUpdateAsync(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters) {
+ Mono>> mono = updateWithResponseAsync(resourceGroupName, resourceName, parameters);
return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class, context);
+ this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class,
+ this.client.getContext());
}
/**
@@ -712,9 +641,11 @@ private PollerFlux, OpenShiftClusterInner> beg
* @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, OpenShiftClusterInner>
- beginCreateOrUpdate(String resourceGroupName, String resourceName, OpenShiftClusterInner parameters) {
- return this.beginCreateOrUpdateAsync(resourceGroupName, resourceName, parameters).getSyncPoller();
+ public SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterUpdate parameters) {
+ Response response = updateWithResponse(resourceGroupName, resourceName, parameters);
+ return this.client.getLroResult(response,
+ OpenShiftClusterInner.class, OpenShiftClusterInner.class, Context.NONE);
}
/**
@@ -732,29 +663,11 @@ private PollerFlux, OpenShiftClusterInner> beg
* @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, OpenShiftClusterInner> beginCreateOrUpdate(
- String resourceGroupName, String resourceName, OpenShiftClusterInner parameters, Context context) {
- return this.beginCreateOrUpdateAsync(resourceGroupName, resourceName, parameters, context).getSyncPoller();
- }
-
- /**
- * Creates or updates a OpenShift cluster with the specified subscription, resource group and resource name.
- *
- * The operation returns properties of a OpenShift cluster.
- *
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
- * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster on successful completion of {@link Mono}.
- */
- @ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters) {
- return beginCreateOrUpdateAsync(resourceGroupName, resourceName, parameters).last()
- .flatMap(this.client::getLroFinalResultOrError);
+ public SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
+ String resourceName, OpenShiftClusterUpdate parameters, Context context) {
+ Response response = updateWithResponse(resourceGroupName, resourceName, parameters, context);
+ return this.client.getLroResult(response,
+ OpenShiftClusterInner.class, OpenShiftClusterInner.class, context);
}
/**
@@ -765,16 +678,15 @@ private Mono createOrUpdateAsync(String resourceGroupName
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
* @param parameters The OpenShift cluster resource.
- * @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 openShiftCluster represents an Azure Red Hat OpenShift cluster on successful completion of {@link Mono}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono createOrUpdateAsync(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters, Context context) {
- return beginCreateOrUpdateAsync(resourceGroupName, resourceName, parameters, context).last()
+ private Mono updateAsync(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters) {
+ return beginUpdateAsync(resourceGroupName, resourceName, parameters).last()
.flatMap(this.client::getLroFinalResultOrError);
}
@@ -792,9 +704,9 @@ private Mono createOrUpdateAsync(String resourceGroupName
* @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters) {
- return createOrUpdateAsync(resourceGroupName, resourceName, parameters).block();
+ public OpenShiftClusterInner update(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters) {
+ return beginUpdate(resourceGroupName, resourceName, parameters).getFinalResult();
}
/**
@@ -812,9 +724,9 @@ public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String res
* @return openShiftCluster represents an Azure Red Hat OpenShift cluster.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String resourceName,
- OpenShiftClusterInner parameters, Context context) {
- return createOrUpdateAsync(resourceGroupName, resourceName, parameters, context).block();
+ public OpenShiftClusterInner update(String resourceGroupName, String resourceName,
+ OpenShiftClusterUpdate parameters, Context context) {
+ return beginUpdate(resourceGroupName, resourceName, parameters, context).getFinalResult();
}
/**
@@ -831,25 +743,9 @@ public OpenShiftClusterInner createOrUpdate(String resourceGroupName, String res
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono>> deleteWithResponseAsync(String resourceGroupName, String resourceName) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
return FluxUtil
.withContext(context -> service.delete(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, accept, context))
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, context))
.contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
@@ -860,34 +756,15 @@ private Mono>> deleteWithResponseAsync(String resource
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link Response} on successful completion of {@link Mono}.
+ * @return the response body along with {@link Response}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> deleteWithResponseAsync(String resourceGroupName, String resourceName,
- Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.delete(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, accept, context);
+ private Response deleteWithResponse(String resourceGroupName, String resourceName) {
+ return service.deleteSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, Context.NONE);
}
/**
@@ -897,16 +774,16 @@ private Mono>> deleteWithResponseAsync(String resource
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of long-running operation.
+ * @return the response body along with {@link Response}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String resourceName) {
- Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName);
- return this.client.getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class,
- this.client.getContext());
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Response deleteWithResponse(String resourceGroupName, String resourceName, Context context) {
+ return service.deleteSync(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, resourceName, context);
}
/**
@@ -916,19 +793,16 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
* @return the {@link PollerFlux} for polling of long-running operation.
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String resourceName,
- Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName, context);
+ private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String resourceName) {
+ Mono>> mono = deleteWithResponseAsync(resourceGroupName, resourceName);
return this.client.getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class,
- context);
+ this.client.getContext());
}
/**
@@ -945,7 +819,8 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup
*/
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName) {
- return this.beginDeleteAsync(resourceGroupName, resourceName).getSyncPoller();
+ Response response = deleteWithResponse(resourceGroupName, resourceName);
+ return this.client.getLroResult(response, Void.class, Void.class, Context.NONE);
}
/**
@@ -964,7 +839,8 @@ public SyncPoller, Void> beginDelete(String resourceGroupName,
@ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
public SyncPoller, Void> beginDelete(String resourceGroupName, String resourceName,
Context context) {
- return this.beginDeleteAsync(resourceGroupName, resourceName, context).getSyncPoller();
+ Response response = deleteWithResponse(resourceGroupName, resourceName, context);
+ return this.client.getLroResult(response, Void.class, Void.class, context);
}
/**
@@ -991,16 +867,13 @@ private Mono deleteAsync(String resourceGroupName, String resourceName) {
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
- * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return A {@link Mono} that completes when a successful response is received.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono deleteAsync(String resourceGroupName, String resourceName, Context context) {
- return beginDeleteAsync(resourceGroupName, resourceName, context).last()
- .flatMap(this.client::getLroFinalResultOrError);
+ public void delete(String resourceGroupName, String resourceName) {
+ beginDelete(resourceGroupName, resourceName).getFinalResult();
}
/**
@@ -1010,283 +883,240 @@ private Mono deleteAsync(String resourceGroupName, String resourceName, Co
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
* @param resourceName The name of the OpenShift cluster resource.
+ * @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String resourceName) {
- deleteAsync(resourceGroupName, resourceName).block();
+ public void delete(String resourceGroupName, String resourceName, Context context) {
+ beginDelete(resourceGroupName, resourceName, context).getFinalResult();
+ }
+
+ /**
+ * Lists OpenShift clusters in the specified subscription and resource group.
+ *
+ * The operation returns properties of each OpenShift cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @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 openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
+ * successful completion of {@link Mono}.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByResourceGroupSinglePageAsync(String resourceGroupName) {
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.listByResourceGroup(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), resourceGroupName, accept, context))
+ .>map(res -> new PagedResponseBase<>(res.getRequest(),
+ res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Deletes a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns nothing.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @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 openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.SINGLE)
- public void delete(String resourceGroupName, String resourceName, Context context) {
- deleteAsync(resourceGroupName, resourceName, context).block();
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByResourceGroupAsync(String resourceGroupName) {
+ return new PagedFlux<>(() -> listByResourceGroupSinglePageAsync(resourceGroupName),
+ nextLink -> listByResourceGroupNextSinglePageAsync(nextLink));
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
- * completion of {@link Mono}.
+ * @return openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String resourceGroupName, String resourceName,
- OpenShiftClusterUpdate parameters) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ private PagedResponse listByResourceGroupSinglePage(String resourceGroupName) {
final String accept = "application/json";
- return FluxUtil
- .withContext(context -> service.update(this.client.getEndpoint(), this.client.getApiVersion(),
- this.client.getSubscriptionId(), resourceGroupName, resourceName, parameters, accept, context))
- .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ Response res = service.listByResourceGroupSync(this.client.getEndpoint(),
+ this.client.getApiVersion(), this.client.getSubscriptionId(), resourceGroupName, accept, Context.NONE);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster along with {@link Response} on successful
- * completion of {@link Mono}.
+ * @return openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse}.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono>> updateWithResponseAsync(String resourceGroupName, String resourceName,
- OpenShiftClusterUpdate parameters, Context context) {
- if (this.client.getEndpoint() == null) {
- return Mono.error(
- new IllegalArgumentException("Parameter this.client.getEndpoint() is required and cannot be null."));
- }
- if (this.client.getSubscriptionId() == null) {
- return Mono.error(new IllegalArgumentException(
- "Parameter this.client.getSubscriptionId() is required and cannot be null."));
- }
- if (resourceGroupName == null) {
- return Mono
- .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null."));
- }
- if (resourceName == null) {
- return Mono.error(new IllegalArgumentException("Parameter resourceName is required and cannot be null."));
- }
- if (parameters == null) {
- return Mono.error(new IllegalArgumentException("Parameter parameters is required and cannot be null."));
- } else {
- parameters.validate();
- }
+ private PagedResponse listByResourceGroupSinglePage(String resourceGroupName,
+ Context context) {
final String accept = "application/json";
- context = this.client.mergeContext(context);
- return service.update(this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(),
- resourceGroupName, resourceName, parameters, accept, context);
+ Response res = service.listByResourceGroupSync(this.client.getEndpoint(),
+ this.client.getApiVersion(), this.client.getSubscriptionId(), resourceGroupName, accept, context);
+ return new PagedResponseBase<>(res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(),
+ res.getValue().nextLink(), null);
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @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 openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, OpenShiftClusterInner>
- beginUpdateAsync(String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters) {
- Mono>> mono = updateWithResponseAsync(resourceGroupName, resourceName, parameters);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class,
- this.client.getContext());
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName) {
+ return new PagedIterable<>(() -> listByResourceGroupSinglePage(resourceGroupName),
+ nextLink -> listByResourceGroupNextSinglePage(nextLink));
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription and resource group.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
* @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
* @param context The context to associate with this operation.
* @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link PollerFlux} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedIterable}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- private PollerFlux, OpenShiftClusterInner> beginUpdateAsync(
- String resourceGroupName, String resourceName, OpenShiftClusterUpdate parameters, Context context) {
- context = this.client.mergeContext(context);
- Mono>> mono
- = updateWithResponseAsync(resourceGroupName, resourceName, parameters, context);
- return this.client.getLroResult(mono,
- this.client.getHttpPipeline(), OpenShiftClusterInner.class, OpenShiftClusterInner.class, context);
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByResourceGroup(String resourceGroupName, Context context) {
+ return new PagedIterable<>(() -> listByResourceGroupSinglePage(resourceGroupName, context),
+ nextLink -> listByResourceGroupNextSinglePage(nextLink, context));
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters along with {@link PagedResponse} on
+ * successful completion of {@link Mono}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterUpdate parameters) {
- return this.beginUpdateAsync(resourceGroupName, resourceName, parameters).getSyncPoller();
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listSinglePageAsync() {
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(context -> service.list(this.client.getEndpoint(), this.client.getApiVersion(),
+ this.client.getSubscriptionId(), accept, context))
+ .>map(res -> new PagedResponseBase<>(res.getRequest(),
+ res.getStatusCode(), res.getHeaders(), res.getValue().value(), res.getValue().nextLink(), null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
}
/**
- * Updates a OpenShift cluster with the specified subscription, resource group and resource name.
+ * Lists OpenShift clusters in the specified subscription.
*
- * The operation returns properties of a OpenShift cluster.
+ * The operation returns properties of each OpenShift cluster.
*
- * @param resourceGroupName The name of the resource group. The name is case insensitive.
- * @param resourceName The name of the OpenShift cluster resource.
- * @param parameters The OpenShift cluster resource.
- * @param context The context to associate with this operation.
- * @throws IllegalArgumentException thrown if parameters fail the validation.
* @throws ManagementException thrown if the request is rejected by server.
* @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
- * @return the {@link SyncPoller} for polling of openShiftCluster represents an Azure Red Hat OpenShift cluster.
+ * @return openShiftClusterList represents a list of OpenShift clusters as paginated response with
+ * {@link PagedFlux}.
*/
- @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
- public SyncPoller, OpenShiftClusterInner> beginUpdate(String resourceGroupName,
- String resourceName, OpenShiftClusterUpdate parameters, Context context) {
- return this.beginUpdateAsync(resourceGroupName, resourceName, parameters, context).getSyncPoller();
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux