diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/CHANGELOG.md b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/CHANGELOG.md
index 7c9638cae470..07eb7d7228dd 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/CHANGELOG.md
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/CHANGELOG.md
@@ -1,7 +1,8 @@
# Release History
-## 1.0.0-beta.2 (Unreleased)
+## 1.0.0-beta.1 (2021-11-25)
+- Azure Resource Manager AzureStackHci client library for Java. This package contains Microsoft Azure SDK for AzureStackHci Management SDK. Azure Stack HCI management service. Package tag package-2021-09. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt).
## 1.0.0-beta.1 (2021-04-12)
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/README.md b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/README.md
index 70d752936ae7..dd8ab26e0893 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/README.md
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/README.md
@@ -2,7 +2,7 @@
Azure Resource Manager AzureStackHci client library for Java.
-This package contains Microsoft Azure SDK for AzureStackHci Management SDK. Azure Stack HCI management service. Package tag package-2020-10. 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 AzureStackHci Management SDK. Azure Stack HCI management service. Package tag package-2021-09. 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-azurestackhci
- 1.0.0-beta.1
+ 1.0.0-beta.2
```
[//]: # ({x-version-update-end})
@@ -74,6 +74,9 @@ See [API design][design] for general introduction on design and key concepts on
## Examples
+[Code snippets and samples](https://github.com/Azure/azure-sdk-for-java/blob/main/sdk/azurestackhci/azure-resourcemanager-azurestackhci/SAMPLE.md)
+
+
## Troubleshooting
## Next steps
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/SAMPLE.md b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/SAMPLE.md
new file mode 100644
index 000000000000..38bc92db1422
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/SAMPLE.md
@@ -0,0 +1,415 @@
+# Code snippets and samples
+
+
+## ArcSettings
+
+- [Create](#arcsettings_create)
+- [Delete](#arcsettings_delete)
+- [Get](#arcsettings_get)
+- [ListByCluster](#arcsettings_listbycluster)
+
+## Clusters
+
+- [Create](#clusters_create)
+- [Delete](#clusters_delete)
+- [GetByResourceGroup](#clusters_getbyresourcegroup)
+- [List](#clusters_list)
+- [ListByResourceGroup](#clusters_listbyresourcegroup)
+- [Update](#clusters_update)
+
+## Extensions
+
+- [Create](#extensions_create)
+- [Delete](#extensions_delete)
+- [Get](#extensions_get)
+- [ListByArcSetting](#extensions_listbyarcsetting)
+- [Update](#extensions_update)
+### ArcSettings_Create
+
+```java
+/** Samples for ArcSettings Create. */
+public final class ArcSettingsCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PutArcSetting.json
+ */
+ /**
+ * Sample code: Create ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().define("default").withExistingCluster("test-rg", "myCluster").create();
+ }
+}
+```
+
+### ArcSettings_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings Delete. */
+public final class ArcSettingsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteArcSetting.json
+ */
+ /**
+ * Sample code: Delete ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().delete("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
+```
+
+### ArcSettings_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings Get. */
+public final class ArcSettingsGetSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetArcSetting.json
+ */
+ /**
+ * Sample code: Get ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().getWithResponse("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
+```
+
+### ArcSettings_ListByCluster
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings ListByCluster. */
+public final class ArcSettingsListByClusterSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListArcSettingsByCluster.json
+ */
+ /**
+ * Sample code: List ArcSetting resources by HCI Cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listArcSettingResourcesByHCICluster(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().listByCluster("test-rg", "myCluster", Context.NONE);
+ }
+}
+```
+
+### Clusters_Create
+
+```java
+/** Samples for Clusters Create. */
+public final class ClustersCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/CreateCluster.json
+ */
+ /**
+ * Sample code: Create cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager
+ .clusters()
+ .define("myCluster")
+ .withRegion("East US")
+ .withExistingResourceGroup("test-rg")
+ .withCloudManagementEndpoint("https://98294836-31be-4668-aeae-698667faf99b.waconazure.com")
+ .withAadClientId("24a6e53d-04e5-44d2-b7cc-1b732a847dfc")
+ .withAadTenantId("7e589cc1-a8b6-4dff-91bd-5ec0fa18db94")
+ .create();
+ }
+}
+```
+
+### Clusters_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Clusters Delete. */
+public final class ClustersDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteCluster.json
+ */
+ /**
+ * Sample code: Delete cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().deleteWithResponse("test-rg", "myCluster", Context.NONE);
+ }
+}
+```
+
+### Clusters_GetByResourceGroup
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Clusters GetByResourceGroup. */
+public final class ClustersGetByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetCluster.json
+ */
+ /**
+ * Sample code: Get cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().getByResourceGroupWithResponse("test-rg", "myCluster", Context.NONE);
+ }
+}
+```
+
+### Clusters_List
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Clusters List. */
+public final class ClustersListSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListClustersBySubscription.json
+ */
+ /**
+ * Sample code: List clusters in a given subscription.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listClustersInAGivenSubscription(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().list(Context.NONE);
+ }
+}
+```
+
+### Clusters_ListByResourceGroup
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Clusters ListByResourceGroup. */
+public final class ClustersListByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListClustersByResourceGroup.json
+ */
+ /**
+ * Sample code: List clusters in a given resource group.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listClustersInAGivenResourceGroup(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().listByResourceGroup("test-rg", Context.NONE);
+ }
+}
+```
+
+### Clusters_Update
+
+```java
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.models.Cluster;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
+import com.azure.resourcemanager.azurestackhci.models.DiagnosticLevel;
+import com.azure.resourcemanager.azurestackhci.models.WindowsServerSubscription;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for Clusters Update. */
+public final class ClustersUpdateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/UpdateCluster.json
+ */
+ /**
+ * Sample code: Update cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void updateCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ Cluster resource =
+ manager.clusters().getByResourceGroupWithResponse("test-rg", "myCluster", Context.NONE).getValue();
+ resource
+ .update()
+ .withTags(mapOf("tag1", "value1", "tag2", "value2"))
+ .withCloudManagementEndpoint("https://98294836-31be-4668-aeae-698667faf99b.waconazure.com")
+ .withDesiredProperties(
+ new ClusterDesiredProperties()
+ .withWindowsServerSubscription(WindowsServerSubscription.ENABLED)
+ .withDiagnosticLevel(DiagnosticLevel.BASIC))
+ .apply();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
+```
+
+### Extensions_Create
+
+```java
+import com.azure.core.management.serializer.SerializerFactory;
+import com.azure.core.util.serializer.SerializerEncoding;
+import java.io.IOException;
+
+/** Samples for Extensions Create. */
+public final class ExtensionsCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PutExtension.json
+ */
+ /**
+ * Sample code: Create Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager)
+ throws IOException {
+ manager
+ .extensions()
+ .define("MicrosoftMonitoringAgent")
+ .withExistingArcSetting("test-rg", "myCluster", "default")
+ .withPublisher("Microsoft.Compute")
+ .withTypePropertiesType("MicrosoftMonitoringAgent")
+ .withTypeHandlerVersion("1.10")
+ .withSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceId\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .withProtectedSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceKey\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .create();
+ }
+}
+```
+
+### Extensions_Delete
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Extensions Delete. */
+public final class ExtensionsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteExtension.json
+ */
+ /**
+ * Sample code: Delete Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.extensions().delete("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE);
+ }
+}
+```
+
+### Extensions_Get
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Extensions Get. */
+public final class ExtensionsGetSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetExtension.json
+ */
+ /**
+ * Sample code: Get ArcSettings Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getArcSettingsExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager
+ .extensions()
+ .getWithResponse("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE);
+ }
+}
+```
+
+### Extensions_ListByArcSetting
+
+```java
+import com.azure.core.util.Context;
+
+/** Samples for Extensions ListByArcSetting. */
+public final class ExtensionsListByArcSettingSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListExtensionsByArcSetting.json
+ */
+ /**
+ * Sample code: List Extensions under ArcSetting resource.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listExtensionsUnderArcSettingResource(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.extensions().listByArcSetting("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
+```
+
+### Extensions_Update
+
+```java
+import com.azure.core.management.serializer.SerializerFactory;
+import com.azure.core.util.Context;
+import com.azure.core.util.serializer.SerializerEncoding;
+import com.azure.resourcemanager.azurestackhci.models.Extension;
+import java.io.IOException;
+
+/** Samples for Extensions Update. */
+public final class ExtensionsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PatchExtension.json
+ */
+ /**
+ * Sample code: Update Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void updateArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager)
+ throws IOException {
+ Extension resource =
+ manager
+ .extensions()
+ .getWithResponse("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withPublisher("Microsoft.Compute")
+ .withTypePropertiesType("MicrosoftMonitoringAgent")
+ .withTypeHandlerVersion("1.10")
+ .withSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceId\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .apply();
+ }
+}
+```
+
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/pom.xml b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/pom.xml
index f45dd5b09dbe..e49e5dde5648 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/pom.xml
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/pom.xml
@@ -1,58 +1,81 @@
- 4.0.0
-
- com.azure
- azure-client-sdk-parent
- 1.7.0
- ../../parents/azure-client-sdk-parent
-
+ 4.0.0
+
+ com.azure
+ azure-client-sdk-parent
+ 1.7.0
+ ../../parents/azure-client-sdk-parent
+
- com.azure.resourcemanager
- azure-resourcemanager-azurestackhci
- 1.0.0-beta.2
- jar
+ com.azure.resourcemanager
+ azure-resourcemanager-azurestackhci
+ 1.0.0-beta.2
+ jar
- Microsoft Azure SDK for AzureStackHci Management
- This package contains Microsoft Azure SDK for AzureStackHci Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Azure Stack HCI management service. Package tag package-2020-10.
- https://github.com/Azure/azure-sdk-for-java
+ Microsoft Azure SDK for AzureStackHci Management
+ This package contains Microsoft Azure SDK for AzureStackHci Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. Azure Stack HCI management service. Package tag package-2021-09.
+ https://github.com/Azure/azure-sdk-for-java
-
-
- The MIT License (MIT)
- http://opensource.org/licenses/MIT
- repo
-
-
+
+
+ The MIT License (MIT)
+ http://opensource.org/licenses/MIT
+ repo
+
+
-
- https://github.com/Azure/azure-sdk-for-java
- scm:git:git@github.com:Azure/azure-sdk-for-java.git
- scm:git:git@github.com:Azure/azure-sdk-for-java.git
- HEAD
-
-
-
- microsoft
- Microsoft
-
-
-
- UTF-8
- true
+
+ https://github.com/Azure/azure-sdk-for-java
+ scm:git:git@github.com:Azure/azure-sdk-for-java.git
+ scm:git:git@github.com:Azure/azure-sdk-for-java.git
+ HEAD
+
+
+
+ microsoft
+ Microsoft
+
+
+
+ UTF-8
+ true
false
-
-
-
- com.azure
- azure-core
- 1.22.0
-
-
- com.azure
- azure-core-management
- 1.4.3
-
-
+
+
+
+ com.azure
+ azure-core
+ 1.22.0
+
+
+ com.azure
+ azure-core-management
+ 1.4.3
+
+
+
+
+
+ org.revapi
+ revapi-maven-plugin
+ 0.11.2
+
+
+
+ -
+
java.method.addedToInterface
+
+ -
+ true
+
.*
+ com\.azure\.resourcemanager(\.[^.]+)+\.fluent(\.[^.]+)*
+
+
+
+
+
+
+
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/AzureStackHciManager.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/AzureStackHciManager.java
index 3e48e353084b..b8a3a7728453 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/AzureStackHciManager.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/AzureStackHciManager.java
@@ -8,8 +8,8 @@
import com.azure.core.http.HttpClient;
import com.azure.core.http.HttpPipeline;
import com.azure.core.http.HttpPipelineBuilder;
+import com.azure.core.http.HttpPipelinePosition;
import com.azure.core.http.policy.AddDatePolicy;
-import com.azure.core.http.policy.BearerTokenAuthenticationPolicy;
import com.azure.core.http.policy.HttpLogOptions;
import com.azure.core.http.policy.HttpLoggingPolicy;
import com.azure.core.http.policy.HttpPipelinePolicy;
@@ -17,27 +17,37 @@
import com.azure.core.http.policy.RequestIdPolicy;
import com.azure.core.http.policy.RetryPolicy;
import com.azure.core.http.policy.UserAgentPolicy;
+import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy;
import com.azure.core.management.profile.AzureProfile;
import com.azure.core.util.Configuration;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.azurestackhci.fluent.AzureStackHciClient;
+import com.azure.resourcemanager.azurestackhci.implementation.ArcSettingsImpl;
import com.azure.resourcemanager.azurestackhci.implementation.AzureStackHciClientBuilder;
import com.azure.resourcemanager.azurestackhci.implementation.ClustersImpl;
+import com.azure.resourcemanager.azurestackhci.implementation.ExtensionsImpl;
import com.azure.resourcemanager.azurestackhci.implementation.OperationsImpl;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettings;
import com.azure.resourcemanager.azurestackhci.models.Clusters;
+import com.azure.resourcemanager.azurestackhci.models.Extensions;
import com.azure.resourcemanager.azurestackhci.models.Operations;
import java.time.Duration;
import java.time.temporal.ChronoUnit;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
+import java.util.stream.Collectors;
/** Entry point to AzureStackHciManager. Azure Stack HCI management service. */
public final class AzureStackHciManager {
- private Operations operations;
+ private ArcSettings arcSettings;
private Clusters clusters;
+ private Extensions extensions;
+
+ private Operations operations;
+
private final AzureStackHciClient clientObject;
private AzureStackHciManager(HttpPipeline httpPipeline, AzureProfile profile, Duration defaultPollInterval) {
@@ -81,6 +91,7 @@ public static final class Configurable {
private HttpClient httpClient;
private HttpLogOptions httpLogOptions;
private final List policies = new ArrayList<>();
+ private final List scopes = new ArrayList<>();
private RetryPolicy retryPolicy;
private Duration defaultPollInterval;
@@ -120,6 +131,17 @@ public Configurable withPolicy(HttpPipelinePolicy policy) {
return this;
}
+ /**
+ * Adds the scope to permission sets.
+ *
+ * @param scope the scope.
+ * @return the configurable object itself.
+ */
+ public Configurable withScope(String scope) {
+ this.scopes.add(Objects.requireNonNull(scope, "'scope' cannot be null."));
+ return this;
+ }
+
/**
* Sets the retry policy to the HTTP pipeline.
*
@@ -176,20 +198,33 @@ public AzureStackHciManager authenticate(TokenCredential credential, AzureProfil
userAgentBuilder.append(" (auto-generated)");
}
+ if (scopes.isEmpty()) {
+ scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default");
+ }
if (retryPolicy == null) {
retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS);
}
List policies = new ArrayList<>();
policies.add(new UserAgentPolicy(userAgentBuilder.toString()));
policies.add(new RequestIdPolicy());
+ policies
+ .addAll(
+ this
+ .policies
+ .stream()
+ .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_CALL)
+ .collect(Collectors.toList()));
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, profile.getEnvironment().getManagementEndpoint() + "/.default"));
- policies.addAll(this.policies);
+ .addAll(
+ this
+ .policies
+ .stream()
+ .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY)
+ .collect(Collectors.toList()));
HttpPolicyProviders.addAfterRetryPolicies(policies);
policies.add(new HttpLoggingPolicy(httpLogOptions));
HttpPipeline httpPipeline =
@@ -201,12 +236,12 @@ public AzureStackHciManager authenticate(TokenCredential credential, AzureProfil
}
}
- /** @return Resource collection API of Operations. */
- public Operations operations() {
- if (this.operations == null) {
- this.operations = new OperationsImpl(clientObject.getOperations(), this);
+ /** @return Resource collection API of ArcSettings. */
+ public ArcSettings arcSettings() {
+ if (this.arcSettings == null) {
+ this.arcSettings = new ArcSettingsImpl(clientObject.getArcSettings(), this);
}
- return operations;
+ return arcSettings;
}
/** @return Resource collection API of Clusters. */
@@ -217,6 +252,22 @@ public Clusters clusters() {
return clusters;
}
+ /** @return Resource collection API of Extensions. */
+ public Extensions extensions() {
+ if (this.extensions == null) {
+ this.extensions = new ExtensionsImpl(clientObject.getExtensions(), this);
+ }
+ return extensions;
+ }
+
+ /** @return Resource collection API of Operations. */
+ public Operations operations() {
+ if (this.operations == null) {
+ this.operations = new OperationsImpl(clientObject.getOperations(), this);
+ }
+ return operations;
+ }
+
/**
* @return Wrapped service client AzureStackHciClient providing direct access to the underlying auto-generated API
* implementation, based on Azure REST API.
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ArcSettingsClient.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ArcSettingsClient.java
new file mode 100644
index 000000000000..16eaeb582fcb
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ArcSettingsClient.java
@@ -0,0 +1,168 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+
+/** An instance of this class provides access to all the operations defined in ArcSettingsClient. */
+public interface ArcSettingsClient {
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByCluster(String resourceGroupName, String clusterName);
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByCluster(String resourceGroupName, String clusterName, Context context);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ArcSettingInner get(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ArcSettingInner create(
+ String resourceGroupName, String clusterName, String arcSettingName, ArcSettingInner arcSetting);
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response createWithResponse(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ ArcSettingInner arcSetting,
+ Context context);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 clusterName, String arcSettingName);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(String resourceGroupName, String clusterName, String arcSettingName, Context context);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/AzureStackHciClient.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/AzureStackHciClient.java
index 277e14ea65db..bb51fe0bea47 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/AzureStackHciClient.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/AzureStackHciClient.java
@@ -45,11 +45,11 @@ public interface AzureStackHciClient {
Duration getDefaultPollInterval();
/**
- * Gets the OperationsClient object to access its operations.
+ * Gets the ArcSettingsClient object to access its operations.
*
- * @return the OperationsClient object.
+ * @return the ArcSettingsClient object.
*/
- OperationsClient getOperations();
+ ArcSettingsClient getArcSettings();
/**
* Gets the ClustersClient object to access its operations.
@@ -57,4 +57,18 @@ public interface AzureStackHciClient {
* @return the ClustersClient object.
*/
ClustersClient getClusters();
+
+ /**
+ * Gets the ExtensionsClient object to access its operations.
+ *
+ * @return the ExtensionsClient object.
+ */
+ ExtensionsClient getExtensions();
+
+ /**
+ * Gets the OperationsClient object to access its operations.
+ *
+ * @return the OperationsClient object.
+ */
+ OperationsClient getOperations();
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ClustersClient.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ClustersClient.java
index b1023e2021f4..db9fcfea7ad4 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ClustersClient.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ClustersClient.java
@@ -10,7 +10,7 @@
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
import com.azure.resourcemanager.azurestackhci.fluent.models.ClusterInner;
-import com.azure.resourcemanager.azurestackhci.models.ClusterUpdate;
+import com.azure.resourcemanager.azurestackhci.models.ClusterPatch;
/** An instance of this class provides access to all the operations defined in ClustersClient. */
public interface ClustersClient {
@@ -131,7 +131,7 @@ Response createWithResponse(
* @return cluster details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- ClusterInner update(String resourceGroupName, String clusterName, ClusterUpdate cluster);
+ ClusterInner update(String resourceGroupName, String clusterName, ClusterPatch cluster);
/**
* Update an HCI cluster.
@@ -147,7 +147,7 @@ Response createWithResponse(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
Response updateWithResponse(
- String resourceGroupName, String clusterName, ClusterUpdate cluster, Context context);
+ String resourceGroupName, String clusterName, ClusterPatch cluster, Context context);
/**
* Delete an HCI cluster.
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ExtensionsClient.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ExtensionsClient.java
new file mode 100644
index 000000000000..ef53c4c1d3b3
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/ExtensionsClient.java
@@ -0,0 +1,318 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+
+/** An instance of this class provides access to all the operations defined in ExtensionsClient. */
+public interface ExtensionsClient {
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByArcSetting(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ExtensionInner get(String resourceGroupName, String clusterName, String arcSettingName, String extensionName);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context);
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ExtensionInner> beginCreate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension);
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ExtensionInner> beginCreate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context);
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ExtensionInner create(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension);
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ExtensionInner create(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context);
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ExtensionInner> beginUpdate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension);
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, ExtensionInner> beginUpdate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context);
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ExtensionInner update(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension);
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ ExtensionInner update(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 clusterName, String arcSettingName, String extensionName);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ void delete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/OperationsClient.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/OperationsClient.java
index 6a1af013a2fb..e53ec2798d9e 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/OperationsClient.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/OperationsClient.java
@@ -8,7 +8,7 @@
import com.azure.core.annotation.ServiceMethod;
import com.azure.core.http.rest.Response;
import com.azure.core.util.Context;
-import com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner;
+import com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner;
/** An instance of this class provides access to all the operations defined in OperationsClient. */
public interface OperationsClient {
@@ -17,10 +17,10 @@ public interface OperationsClient {
*
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- AvailableOperationsInner list();
+ OperationListResultInner list();
/**
* List all available Microsoft.AzureStackHCI provider operations.
@@ -29,8 +29,8 @@ public interface OperationsClient {
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- Response listWithResponse(Context context);
+ Response listWithResponse(Context context);
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingInner.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingInner.java
new file mode 100644
index 000000000000..31648d9d6d66
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingInner.java
@@ -0,0 +1,100 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettingAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** ArcSetting details. */
+@Fluent
+public final class ArcSettingInner extends ProxyResource {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ArcSettingInner.class);
+
+ /*
+ * System data of ArcSetting resource
+ */
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData innerSystemData;
+
+ /*
+ * ArcSetting properties.
+ */
+ @JsonProperty(value = "properties")
+ private ArcSettingProperties innerProperties;
+
+ /**
+ * Get the innerSystemData property: System data of ArcSetting resource.
+ *
+ * @return the innerSystemData value.
+ */
+ private SystemData innerSystemData() {
+ return this.innerSystemData;
+ }
+
+ /**
+ * Get the innerProperties property: ArcSetting properties.
+ *
+ * @return the innerProperties value.
+ */
+ private ArcSettingProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the ArcSetting proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ public ProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Get the arcInstanceResourceGroup property: The resource group that hosts the Arc agents, ie. Hybrid Compute
+ * Machine resources.
+ *
+ * @return the arcInstanceResourceGroup value.
+ */
+ public String arcInstanceResourceGroup() {
+ return this.innerProperties() == null ? null : this.innerProperties().arcInstanceResourceGroup();
+ }
+
+ /**
+ * Get the aggregateState property: Aggregate state of Arc agent across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ public ArcSettingAggregateState aggregateState() {
+ return this.innerProperties() == null ? null : this.innerProperties().aggregateState();
+ }
+
+ /**
+ * Get the perNodeDetails property: State of Arc agent in each of the nodes.
+ *
+ * @return the perNodeDetails value.
+ */
+ public List perNodeDetails() {
+ return this.innerProperties() == null ? null : this.innerProperties().perNodeDetails();
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingProperties.java
new file mode 100644
index 000000000000..d3c2ddfb7f9d
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ArcSettingProperties.java
@@ -0,0 +1,93 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettingAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** ArcSetting properties. */
+@Immutable
+public final class ArcSettingProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ArcSettingProperties.class);
+
+ /*
+ * Provisioning state of the ArcSetting proxy resource.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private ProvisioningState provisioningState;
+
+ /*
+ * The resource group that hosts the Arc agents, ie. Hybrid Compute Machine
+ * resources.
+ */
+ @JsonProperty(value = "arcInstanceResourceGroup", access = JsonProperty.Access.WRITE_ONLY)
+ private String arcInstanceResourceGroup;
+
+ /*
+ * Aggregate state of Arc agent across the nodes in this HCI cluster.
+ */
+ @JsonProperty(value = "aggregateState", access = JsonProperty.Access.WRITE_ONLY)
+ private ArcSettingAggregateState aggregateState;
+
+ /*
+ * State of Arc agent in each of the nodes.
+ */
+ @JsonProperty(value = "perNodeDetails", access = JsonProperty.Access.WRITE_ONLY)
+ private List perNodeDetails;
+
+ /**
+ * Get the provisioningState property: Provisioning state of the ArcSetting proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ public ProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the arcInstanceResourceGroup property: The resource group that hosts the Arc agents, ie. Hybrid Compute
+ * Machine resources.
+ *
+ * @return the arcInstanceResourceGroup value.
+ */
+ public String arcInstanceResourceGroup() {
+ return this.arcInstanceResourceGroup;
+ }
+
+ /**
+ * Get the aggregateState property: Aggregate state of Arc agent across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ public ArcSettingAggregateState aggregateState() {
+ return this.aggregateState;
+ }
+
+ /**
+ * Get the perNodeDetails property: State of Arc agent in each of the nodes.
+ *
+ * @return the perNodeDetails value.
+ */
+ public List perNodeDetails() {
+ return this.perNodeDetails;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (perNodeDetails() != null) {
+ perNodeDetails().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/AvailableOperationsInner.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/AvailableOperationsInner.java
deleted file mode 100644
index f3536ea73c01..000000000000
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/AvailableOperationsInner.java
+++ /dev/null
@@ -1,84 +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.azurestackhci.fluent.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
-import com.azure.resourcemanager.azurestackhci.models.OperationDetail;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.List;
-
-/** Available operations of the service. */
-@Fluent
-public final class AvailableOperationsInner {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(AvailableOperationsInner.class);
-
- /*
- * Collection of available operation details
- */
- @JsonProperty(value = "value")
- private List value;
-
- /*
- * URL client should use to fetch the next page (per server side paging).
- * It's null for now, added for future use.
- */
- @JsonProperty(value = "nextLink")
- private String nextLink;
-
- /**
- * Get the value property: Collection of available operation details.
- *
- * @return the value value.
- */
- public List value() {
- return this.value;
- }
-
- /**
- * Set the value property: Collection of available operation details.
- *
- * @param value the value value to set.
- * @return the AvailableOperationsInner object itself.
- */
- public AvailableOperationsInner withValue(List value) {
- this.value = value;
- return this;
- }
-
- /**
- * Get the nextLink property: URL client should use to fetch the next page (per server side paging). It's null for
- * now, added for future use.
- *
- * @return the nextLink value.
- */
- public String nextLink() {
- return this.nextLink;
- }
-
- /**
- * Set the nextLink property: URL client should use to fetch the next page (per server side paging). It's null for
- * now, added for future use.
- *
- * @param nextLink the nextLink value to set.
- * @return the AvailableOperationsInner object itself.
- */
- public AvailableOperationsInner withNextLink(String nextLink) {
- this.nextLink = nextLink;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (value() != null) {
- value().forEach(e -> e.validate());
- }
- }
-}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterInner.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterInner.java
index 30f5fcebff66..13c6a12ded5f 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterInner.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterInner.java
@@ -5,11 +5,11 @@
package com.azure.resourcemanager.azurestackhci.fluent.models;
import com.azure.core.annotation.Fluent;
-import com.azure.core.annotation.JsonFlatten;
import com.azure.core.management.Resource;
+import com.azure.core.management.SystemData;
import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
import com.azure.resourcemanager.azurestackhci.models.ClusterReportedProperties;
-import com.azure.resourcemanager.azurestackhci.models.CreatedByType;
import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
import com.azure.resourcemanager.azurestackhci.models.Status;
import com.fasterxml.jackson.annotation.JsonIgnore;
@@ -18,112 +18,53 @@
import java.util.Map;
/** Cluster details. */
-@JsonFlatten
@Fluent
-public class ClusterInner extends Resource {
+public final class ClusterInner extends Resource {
@JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterInner.class);
/*
- * Provisioning state.
+ * System data of Cluster resource
*/
- @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY)
- private ProvisioningState provisioningState;
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData innerSystemData;
/*
- * Status of the cluster agent.
+ * Cluster properties.
*/
- @JsonProperty(value = "properties.status", access = JsonProperty.Access.WRITE_ONLY)
- private Status status;
+ @JsonProperty(value = "properties")
+ private ClusterProperties innerProperties;
- /*
- * Unique, immutable resource id.
- */
- @JsonProperty(value = "properties.cloudId", access = JsonProperty.Access.WRITE_ONLY)
- private String cloudId;
-
- /*
- * App id of cluster AAD identity.
- */
- @JsonProperty(value = "properties.aadClientId")
- private String aadClientId;
-
- /*
- * Tenant id of cluster AAD identity.
- */
- @JsonProperty(value = "properties.aadTenantId")
- private String aadTenantId;
-
- /*
- * Properties reported by cluster agent.
- */
- @JsonProperty(value = "properties.reportedProperties")
- private ClusterReportedProperties reportedProperties;
-
- /*
- * Number of days remaining in the trial period.
- */
- @JsonProperty(value = "properties.trialDaysRemaining", access = JsonProperty.Access.WRITE_ONLY)
- private Float trialDaysRemaining;
-
- /*
- * Type of billing applied to the resource.
- */
- @JsonProperty(value = "properties.billingModel", access = JsonProperty.Access.WRITE_ONLY)
- private String billingModel;
-
- /*
- * First cluster sync timestamp.
- */
- @JsonProperty(value = "properties.registrationTimestamp", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime registrationTimestamp;
-
- /*
- * Most recent cluster sync timestamp.
- */
- @JsonProperty(value = "properties.lastSyncTimestamp", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastSyncTimestamp;
-
- /*
- * Most recent billing meter timestamp.
- */
- @JsonProperty(value = "properties.lastBillingTimestamp", access = JsonProperty.Access.WRITE_ONLY)
- private OffsetDateTime lastBillingTimestamp;
-
- /*
- * The identity that created the resource.
- */
- @JsonProperty(value = "systemData.createdBy")
- private String createdBy;
-
- /*
- * The type of identity that created the resource.
- */
- @JsonProperty(value = "systemData.createdByType")
- private CreatedByType createdByType;
-
- /*
- * The timestamp of resource creation (UTC).
+ /**
+ * Get the innerSystemData property: System data of Cluster resource.
+ *
+ * @return the innerSystemData value.
*/
- @JsonProperty(value = "systemData.createdAt")
- private OffsetDateTime createdAt;
+ private SystemData innerSystemData() {
+ return this.innerSystemData;
+ }
- /*
- * The identity that last modified the resource.
+ /**
+ * Get the innerProperties property: Cluster properties.
+ *
+ * @return the innerProperties value.
*/
- @JsonProperty(value = "systemData.lastModifiedBy")
- private String lastModifiedBy;
+ private ClusterProperties innerProperties() {
+ return this.innerProperties;
+ }
- /*
- * The type of identity that last modified the resource.
- */
- @JsonProperty(value = "systemData.lastModifiedByType")
- private CreatedByType lastModifiedByType;
+ /** {@inheritDoc} */
+ @Override
+ public ClusterInner withLocation(String location) {
+ super.withLocation(location);
+ return this;
+ }
- /*
- * The timestamp of resource last modification (UTC)
- */
- @JsonProperty(value = "systemData.lastModifiedAt")
- private OffsetDateTime lastModifiedAt;
+ /** {@inheritDoc} */
+ @Override
+ public ClusterInner withTags(Map tags) {
+ super.withTags(tags);
+ return this;
+ }
/**
* Get the provisioningState property: Provisioning state.
@@ -131,7 +72,7 @@ public class ClusterInner extends Resource {
* @return the provisioningState value.
*/
public ProvisioningState provisioningState() {
- return this.provisioningState;
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
}
/**
@@ -140,7 +81,7 @@ public ProvisioningState provisioningState() {
* @return the status value.
*/
public Status status() {
- return this.status;
+ return this.innerProperties() == null ? null : this.innerProperties().status();
}
/**
@@ -149,7 +90,30 @@ public Status status() {
* @return the cloudId value.
*/
public String cloudId() {
- return this.cloudId;
+ return this.innerProperties() == null ? null : this.innerProperties().cloudId();
+ }
+
+ /**
+ * Get the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @return the cloudManagementEndpoint value.
+ */
+ public String cloudManagementEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().cloudManagementEndpoint();
+ }
+
+ /**
+ * Set the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @param cloudManagementEndpoint the cloudManagementEndpoint value to set.
+ * @return the ClusterInner object itself.
+ */
+ public ClusterInner withCloudManagementEndpoint(String cloudManagementEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterProperties();
+ }
+ this.innerProperties().withCloudManagementEndpoint(cloudManagementEndpoint);
+ return this;
}
/**
@@ -158,7 +122,7 @@ public String cloudId() {
* @return the aadClientId value.
*/
public String aadClientId() {
- return this.aadClientId;
+ return this.innerProperties() == null ? null : this.innerProperties().aadClientId();
}
/**
@@ -168,7 +132,10 @@ public String aadClientId() {
* @return the ClusterInner object itself.
*/
public ClusterInner withAadClientId(String aadClientId) {
- this.aadClientId = aadClientId;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterProperties();
+ }
+ this.innerProperties().withAadClientId(aadClientId);
return this;
}
@@ -178,7 +145,7 @@ public ClusterInner withAadClientId(String aadClientId) {
* @return the aadTenantId value.
*/
public String aadTenantId() {
- return this.aadTenantId;
+ return this.innerProperties() == null ? null : this.innerProperties().aadTenantId();
}
/**
@@ -188,37 +155,52 @@ public String aadTenantId() {
* @return the ClusterInner object itself.
*/
public ClusterInner withAadTenantId(String aadTenantId) {
- this.aadTenantId = aadTenantId;
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterProperties();
+ }
+ this.innerProperties().withAadTenantId(aadTenantId);
return this;
}
/**
- * Get the reportedProperties property: Properties reported by cluster agent.
+ * Get the desiredProperties property: Desired properties of the cluster.
*
- * @return the reportedProperties value.
+ * @return the desiredProperties value.
*/
- public ClusterReportedProperties reportedProperties() {
- return this.reportedProperties;
+ public ClusterDesiredProperties desiredProperties() {
+ return this.innerProperties() == null ? null : this.innerProperties().desiredProperties();
}
/**
- * Set the reportedProperties property: Properties reported by cluster agent.
+ * Set the desiredProperties property: Desired properties of the cluster.
*
- * @param reportedProperties the reportedProperties value to set.
+ * @param desiredProperties the desiredProperties value to set.
* @return the ClusterInner object itself.
*/
- public ClusterInner withReportedProperties(ClusterReportedProperties reportedProperties) {
- this.reportedProperties = reportedProperties;
+ public ClusterInner withDesiredProperties(ClusterDesiredProperties desiredProperties) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterProperties();
+ }
+ this.innerProperties().withDesiredProperties(desiredProperties);
return this;
}
+ /**
+ * Get the reportedProperties property: Properties reported by cluster agent.
+ *
+ * @return the reportedProperties value.
+ */
+ public ClusterReportedProperties reportedProperties() {
+ return this.innerProperties() == null ? null : this.innerProperties().reportedProperties();
+ }
+
/**
* Get the trialDaysRemaining property: Number of days remaining in the trial period.
*
* @return the trialDaysRemaining value.
*/
public Float trialDaysRemaining() {
- return this.trialDaysRemaining;
+ return this.innerProperties() == null ? null : this.innerProperties().trialDaysRemaining();
}
/**
@@ -227,7 +209,7 @@ public Float trialDaysRemaining() {
* @return the billingModel value.
*/
public String billingModel() {
- return this.billingModel;
+ return this.innerProperties() == null ? null : this.innerProperties().billingModel();
}
/**
@@ -236,7 +218,7 @@ public String billingModel() {
* @return the registrationTimestamp value.
*/
public OffsetDateTime registrationTimestamp() {
- return this.registrationTimestamp;
+ return this.innerProperties() == null ? null : this.innerProperties().registrationTimestamp();
}
/**
@@ -245,7 +227,7 @@ public OffsetDateTime registrationTimestamp() {
* @return the lastSyncTimestamp value.
*/
public OffsetDateTime lastSyncTimestamp() {
- return this.lastSyncTimestamp;
+ return this.innerProperties() == null ? null : this.innerProperties().lastSyncTimestamp();
}
/**
@@ -254,141 +236,7 @@ public OffsetDateTime lastSyncTimestamp() {
* @return the lastBillingTimestamp value.
*/
public OffsetDateTime lastBillingTimestamp() {
- return this.lastBillingTimestamp;
- }
-
- /**
- * Get the createdBy property: The identity that created the resource.
- *
- * @return the createdBy value.
- */
- public String createdBy() {
- return this.createdBy;
- }
-
- /**
- * Set the createdBy property: The identity that created the resource.
- *
- * @param createdBy the createdBy value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withCreatedBy(String createdBy) {
- this.createdBy = createdBy;
- return this;
- }
-
- /**
- * Get the createdByType property: The type of identity that created the resource.
- *
- * @return the createdByType value.
- */
- public CreatedByType createdByType() {
- return this.createdByType;
- }
-
- /**
- * Set the createdByType property: The type of identity that created the resource.
- *
- * @param createdByType the createdByType value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withCreatedByType(CreatedByType createdByType) {
- this.createdByType = createdByType;
- return this;
- }
-
- /**
- * Get the createdAt property: The timestamp of resource creation (UTC).
- *
- * @return the createdAt value.
- */
- public OffsetDateTime createdAt() {
- return this.createdAt;
- }
-
- /**
- * Set the createdAt property: The timestamp of resource creation (UTC).
- *
- * @param createdAt the createdAt value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withCreatedAt(OffsetDateTime createdAt) {
- this.createdAt = createdAt;
- return this;
- }
-
- /**
- * Get the lastModifiedBy property: The identity that last modified the resource.
- *
- * @return the lastModifiedBy value.
- */
- public String lastModifiedBy() {
- return this.lastModifiedBy;
- }
-
- /**
- * Set the lastModifiedBy property: The identity that last modified the resource.
- *
- * @param lastModifiedBy the lastModifiedBy value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withLastModifiedBy(String lastModifiedBy) {
- this.lastModifiedBy = lastModifiedBy;
- return this;
- }
-
- /**
- * Get the lastModifiedByType property: The type of identity that last modified the resource.
- *
- * @return the lastModifiedByType value.
- */
- public CreatedByType lastModifiedByType() {
- return this.lastModifiedByType;
- }
-
- /**
- * Set the lastModifiedByType property: The type of identity that last modified the resource.
- *
- * @param lastModifiedByType the lastModifiedByType value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withLastModifiedByType(CreatedByType lastModifiedByType) {
- this.lastModifiedByType = lastModifiedByType;
- return this;
- }
-
- /**
- * Get the lastModifiedAt property: The timestamp of resource last modification (UTC).
- *
- * @return the lastModifiedAt value.
- */
- public OffsetDateTime lastModifiedAt() {
- return this.lastModifiedAt;
- }
-
- /**
- * Set the lastModifiedAt property: The timestamp of resource last modification (UTC).
- *
- * @param lastModifiedAt the lastModifiedAt value to set.
- * @return the ClusterInner object itself.
- */
- public ClusterInner withLastModifiedAt(OffsetDateTime lastModifiedAt) {
- this.lastModifiedAt = lastModifiedAt;
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public ClusterInner withLocation(String location) {
- super.withLocation(location);
- return this;
- }
-
- /** {@inheritDoc} */
- @Override
- public ClusterInner withTags(Map tags) {
- super.withTags(tags);
- return this;
+ return this.innerProperties() == null ? null : this.innerProperties().lastBillingTimestamp();
}
/**
@@ -397,8 +245,8 @@ public ClusterInner withTags(Map tags) {
* @throws IllegalArgumentException thrown if the instance is not valid.
*/
public void validate() {
- if (reportedProperties() != null) {
- reportedProperties().validate();
+ if (innerProperties() != null) {
+ innerProperties().validate();
}
}
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterPatchProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterPatchProperties.java
new file mode 100644
index 000000000000..efb50cfb4c28
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterPatchProperties.java
@@ -0,0 +1,132 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Cluster properties. */
+@Fluent
+public final class ClusterPatchProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterPatchProperties.class);
+
+ /*
+ * Endpoint configured for management from the Azure portal
+ */
+ @JsonProperty(value = "cloudManagementEndpoint")
+ private String cloudManagementEndpoint;
+
+ /*
+ * App id of cluster AAD identity.
+ */
+ @JsonProperty(value = "aadClientId")
+ private String aadClientId;
+
+ /*
+ * Tenant id of cluster AAD identity.
+ */
+ @JsonProperty(value = "aadTenantId")
+ private String aadTenantId;
+
+ /*
+ * Desired properties of the cluster.
+ */
+ @JsonProperty(value = "desiredProperties")
+ private ClusterDesiredProperties desiredProperties;
+
+ /**
+ * Get the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @return the cloudManagementEndpoint value.
+ */
+ public String cloudManagementEndpoint() {
+ return this.cloudManagementEndpoint;
+ }
+
+ /**
+ * Set the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @param cloudManagementEndpoint the cloudManagementEndpoint value to set.
+ * @return the ClusterPatchProperties object itself.
+ */
+ public ClusterPatchProperties withCloudManagementEndpoint(String cloudManagementEndpoint) {
+ this.cloudManagementEndpoint = cloudManagementEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the aadClientId property: App id of cluster AAD identity.
+ *
+ * @return the aadClientId value.
+ */
+ public String aadClientId() {
+ return this.aadClientId;
+ }
+
+ /**
+ * Set the aadClientId property: App id of cluster AAD identity.
+ *
+ * @param aadClientId the aadClientId value to set.
+ * @return the ClusterPatchProperties object itself.
+ */
+ public ClusterPatchProperties withAadClientId(String aadClientId) {
+ this.aadClientId = aadClientId;
+ return this;
+ }
+
+ /**
+ * Get the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @return the aadTenantId value.
+ */
+ public String aadTenantId() {
+ return this.aadTenantId;
+ }
+
+ /**
+ * Set the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @param aadTenantId the aadTenantId value to set.
+ * @return the ClusterPatchProperties object itself.
+ */
+ public ClusterPatchProperties withAadTenantId(String aadTenantId) {
+ this.aadTenantId = aadTenantId;
+ return this;
+ }
+
+ /**
+ * Get the desiredProperties property: Desired properties of the cluster.
+ *
+ * @return the desiredProperties value.
+ */
+ public ClusterDesiredProperties desiredProperties() {
+ return this.desiredProperties;
+ }
+
+ /**
+ * Set the desiredProperties property: Desired properties of the cluster.
+ *
+ * @param desiredProperties the desiredProperties value to set.
+ * @return the ClusterPatchProperties object itself.
+ */
+ public ClusterPatchProperties withDesiredProperties(ClusterDesiredProperties desiredProperties) {
+ this.desiredProperties = desiredProperties;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (desiredProperties() != null) {
+ desiredProperties().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterProperties.java
new file mode 100644
index 000000000000..8950f74c0e92
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ClusterProperties.java
@@ -0,0 +1,284 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
+import com.azure.resourcemanager.azurestackhci.models.ClusterReportedProperties;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import com.azure.resourcemanager.azurestackhci.models.Status;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.time.OffsetDateTime;
+
+/** Cluster properties. */
+@Fluent
+public final class ClusterProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterProperties.class);
+
+ /*
+ * Provisioning state.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private ProvisioningState provisioningState;
+
+ /*
+ * Status of the cluster agent.
+ */
+ @JsonProperty(value = "status", access = JsonProperty.Access.WRITE_ONLY)
+ private Status status;
+
+ /*
+ * Unique, immutable resource id.
+ */
+ @JsonProperty(value = "cloudId", access = JsonProperty.Access.WRITE_ONLY)
+ private String cloudId;
+
+ /*
+ * Endpoint configured for management from the Azure portal.
+ */
+ @JsonProperty(value = "cloudManagementEndpoint")
+ private String cloudManagementEndpoint;
+
+ /*
+ * App id of cluster AAD identity.
+ */
+ @JsonProperty(value = "aadClientId", required = true)
+ private String aadClientId;
+
+ /*
+ * Tenant id of cluster AAD identity.
+ */
+ @JsonProperty(value = "aadTenantId", required = true)
+ private String aadTenantId;
+
+ /*
+ * Desired properties of the cluster.
+ */
+ @JsonProperty(value = "desiredProperties")
+ private ClusterDesiredProperties desiredProperties;
+
+ /*
+ * Properties reported by cluster agent.
+ */
+ @JsonProperty(value = "reportedProperties", access = JsonProperty.Access.WRITE_ONLY)
+ private ClusterReportedProperties reportedProperties;
+
+ /*
+ * Number of days remaining in the trial period.
+ */
+ @JsonProperty(value = "trialDaysRemaining", access = JsonProperty.Access.WRITE_ONLY)
+ private Float trialDaysRemaining;
+
+ /*
+ * Type of billing applied to the resource.
+ */
+ @JsonProperty(value = "billingModel", access = JsonProperty.Access.WRITE_ONLY)
+ private String billingModel;
+
+ /*
+ * First cluster sync timestamp.
+ */
+ @JsonProperty(value = "registrationTimestamp", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime registrationTimestamp;
+
+ /*
+ * Most recent cluster sync timestamp.
+ */
+ @JsonProperty(value = "lastSyncTimestamp", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastSyncTimestamp;
+
+ /*
+ * Most recent billing meter timestamp.
+ */
+ @JsonProperty(value = "lastBillingTimestamp", access = JsonProperty.Access.WRITE_ONLY)
+ private OffsetDateTime lastBillingTimestamp;
+
+ /**
+ * Get the provisioningState property: Provisioning state.
+ *
+ * @return the provisioningState value.
+ */
+ public ProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the status property: Status of the cluster agent.
+ *
+ * @return the status value.
+ */
+ public Status status() {
+ return this.status;
+ }
+
+ /**
+ * Get the cloudId property: Unique, immutable resource id.
+ *
+ * @return the cloudId value.
+ */
+ public String cloudId() {
+ return this.cloudId;
+ }
+
+ /**
+ * Get the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @return the cloudManagementEndpoint value.
+ */
+ public String cloudManagementEndpoint() {
+ return this.cloudManagementEndpoint;
+ }
+
+ /**
+ * Set the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @param cloudManagementEndpoint the cloudManagementEndpoint value to set.
+ * @return the ClusterProperties object itself.
+ */
+ public ClusterProperties withCloudManagementEndpoint(String cloudManagementEndpoint) {
+ this.cloudManagementEndpoint = cloudManagementEndpoint;
+ return this;
+ }
+
+ /**
+ * Get the aadClientId property: App id of cluster AAD identity.
+ *
+ * @return the aadClientId value.
+ */
+ public String aadClientId() {
+ return this.aadClientId;
+ }
+
+ /**
+ * Set the aadClientId property: App id of cluster AAD identity.
+ *
+ * @param aadClientId the aadClientId value to set.
+ * @return the ClusterProperties object itself.
+ */
+ public ClusterProperties withAadClientId(String aadClientId) {
+ this.aadClientId = aadClientId;
+ return this;
+ }
+
+ /**
+ * Get the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @return the aadTenantId value.
+ */
+ public String aadTenantId() {
+ return this.aadTenantId;
+ }
+
+ /**
+ * Set the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @param aadTenantId the aadTenantId value to set.
+ * @return the ClusterProperties object itself.
+ */
+ public ClusterProperties withAadTenantId(String aadTenantId) {
+ this.aadTenantId = aadTenantId;
+ return this;
+ }
+
+ /**
+ * Get the desiredProperties property: Desired properties of the cluster.
+ *
+ * @return the desiredProperties value.
+ */
+ public ClusterDesiredProperties desiredProperties() {
+ return this.desiredProperties;
+ }
+
+ /**
+ * Set the desiredProperties property: Desired properties of the cluster.
+ *
+ * @param desiredProperties the desiredProperties value to set.
+ * @return the ClusterProperties object itself.
+ */
+ public ClusterProperties withDesiredProperties(ClusterDesiredProperties desiredProperties) {
+ this.desiredProperties = desiredProperties;
+ return this;
+ }
+
+ /**
+ * Get the reportedProperties property: Properties reported by cluster agent.
+ *
+ * @return the reportedProperties value.
+ */
+ public ClusterReportedProperties reportedProperties() {
+ return this.reportedProperties;
+ }
+
+ /**
+ * Get the trialDaysRemaining property: Number of days remaining in the trial period.
+ *
+ * @return the trialDaysRemaining value.
+ */
+ public Float trialDaysRemaining() {
+ return this.trialDaysRemaining;
+ }
+
+ /**
+ * Get the billingModel property: Type of billing applied to the resource.
+ *
+ * @return the billingModel value.
+ */
+ public String billingModel() {
+ return this.billingModel;
+ }
+
+ /**
+ * Get the registrationTimestamp property: First cluster sync timestamp.
+ *
+ * @return the registrationTimestamp value.
+ */
+ public OffsetDateTime registrationTimestamp() {
+ return this.registrationTimestamp;
+ }
+
+ /**
+ * Get the lastSyncTimestamp property: Most recent cluster sync timestamp.
+ *
+ * @return the lastSyncTimestamp value.
+ */
+ public OffsetDateTime lastSyncTimestamp() {
+ return this.lastSyncTimestamp;
+ }
+
+ /**
+ * Get the lastBillingTimestamp property: Most recent billing meter timestamp.
+ *
+ * @return the lastBillingTimestamp value.
+ */
+ public OffsetDateTime lastBillingTimestamp() {
+ return this.lastBillingTimestamp;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (aadClientId() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property aadClientId in model ClusterProperties"));
+ }
+ if (aadTenantId() == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException("Missing required property aadTenantId in model ClusterProperties"));
+ }
+ if (desiredProperties() != null) {
+ desiredProperties().validate();
+ }
+ if (reportedProperties() != null) {
+ reportedProperties().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionInner.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionInner.java
new file mode 100644
index 000000000000..e5d8a2de9c7c
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionInner.java
@@ -0,0 +1,257 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.management.ProxyResource;
+import com.azure.core.management.SystemData;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ExtensionAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeExtensionState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Details of a particular extension in HCI Cluster. */
+@Fluent
+public final class ExtensionInner extends ProxyResource {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ExtensionInner.class);
+
+ /*
+ * System data of Extension resource.
+ */
+ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY)
+ private SystemData innerSystemData;
+
+ /*
+ * Describes Machine Extension Properties.
+ */
+ @JsonProperty(value = "properties")
+ private ExtensionProperties innerProperties;
+
+ /**
+ * Get the innerSystemData property: System data of Extension resource.
+ *
+ * @return the innerSystemData value.
+ */
+ private SystemData innerSystemData() {
+ return this.innerSystemData;
+ }
+
+ /**
+ * Get the innerProperties property: Describes Machine Extension Properties.
+ *
+ * @return the innerProperties value.
+ */
+ private ExtensionProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the provisioningState property: Provisioning state of the Extension proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ public ProvisioningState provisioningState() {
+ return this.innerProperties() == null ? null : this.innerProperties().provisioningState();
+ }
+
+ /**
+ * Get the aggregateState property: Aggregate state of Arc Extensions across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ public ExtensionAggregateState aggregateState() {
+ return this.innerProperties() == null ? null : this.innerProperties().aggregateState();
+ }
+
+ /**
+ * Get the perNodeExtensionDetails property: State of Arc Extension in each of the nodes.
+ *
+ * @return the perNodeExtensionDetails value.
+ */
+ public List perNodeExtensionDetails() {
+ return this.innerProperties() == null ? null : this.innerProperties().perNodeExtensionDetails();
+ }
+
+ /**
+ * Get the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @return the forceUpdateTag value.
+ */
+ public String forceUpdateTag() {
+ return this.innerProperties() == null ? null : this.innerProperties().forceUpdateTag();
+ }
+
+ /**
+ * Set the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @param forceUpdateTag the forceUpdateTag value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withForceUpdateTag(String forceUpdateTag) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withForceUpdateTag(forceUpdateTag);
+ return this;
+ }
+
+ /**
+ * Get the publisher property: The name of the extension handler publisher.
+ *
+ * @return the publisher value.
+ */
+ public String publisher() {
+ return this.innerProperties() == null ? null : this.innerProperties().publisher();
+ }
+
+ /**
+ * Set the publisher property: The name of the extension handler publisher.
+ *
+ * @param publisher the publisher value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withPublisher(String publisher) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withPublisher(publisher);
+ return this;
+ }
+
+ /**
+ * Get the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @return the type value.
+ */
+ public String typePropertiesType() {
+ return this.innerProperties() == null ? null : this.innerProperties().type();
+ }
+
+ /**
+ * Set the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @param type the type value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withTypePropertiesType(String type) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withType(type);
+ return this;
+ }
+
+ /**
+ * Get the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @return the typeHandlerVersion value.
+ */
+ public String typeHandlerVersion() {
+ return this.innerProperties() == null ? null : this.innerProperties().typeHandlerVersion();
+ }
+
+ /**
+ * Set the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @param typeHandlerVersion the typeHandlerVersion value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withTypeHandlerVersion(String typeHandlerVersion) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withTypeHandlerVersion(typeHandlerVersion);
+ return this;
+ }
+
+ /**
+ * Get the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @return the autoUpgradeMinorVersion value.
+ */
+ public Boolean autoUpgradeMinorVersion() {
+ return this.innerProperties() == null ? null : this.innerProperties().autoUpgradeMinorVersion();
+ }
+
+ /**
+ * Set the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @param autoUpgradeMinorVersion the autoUpgradeMinorVersion value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withAutoUpgradeMinorVersion(autoUpgradeMinorVersion);
+ return this;
+ }
+
+ /**
+ * Get the settings property: Json formatted public settings for the extension.
+ *
+ * @return the settings value.
+ */
+ public Object settings() {
+ return this.innerProperties() == null ? null : this.innerProperties().settings();
+ }
+
+ /**
+ * Set the settings property: Json formatted public settings for the extension.
+ *
+ * @param settings the settings value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withSettings(Object settings) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withSettings(settings);
+ return this;
+ }
+
+ /**
+ * Get the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @return the protectedSettings value.
+ */
+ public Object protectedSettings() {
+ return this.innerProperties() == null ? null : this.innerProperties().protectedSettings();
+ }
+
+ /**
+ * Set the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @param protectedSettings the protectedSettings value to set.
+ * @return the ExtensionInner object itself.
+ */
+ public ExtensionInner withProtectedSettings(Object protectedSettings) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ExtensionProperties();
+ }
+ this.innerProperties().withProtectedSettings(protectedSettings);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionParameters.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionParameters.java
new file mode 100644
index 000000000000..6a8dd53e2e96
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionParameters.java
@@ -0,0 +1,217 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Describes the properties of a Machine Extension. This object mirrors the definition in HybridCompute. */
+@Fluent
+public final class ExtensionParameters {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ExtensionParameters.class);
+
+ /*
+ * How the extension handler should be forced to update even if the
+ * extension configuration has not changed.
+ */
+ @JsonProperty(value = "forceUpdateTag")
+ private String forceUpdateTag;
+
+ /*
+ * The name of the extension handler publisher.
+ */
+ @JsonProperty(value = "publisher")
+ private String publisher;
+
+ /*
+ * Specifies the type of the extension; an example is
+ * "CustomScriptExtension".
+ */
+ @JsonProperty(value = "type")
+ private String type;
+
+ /*
+ * Specifies the version of the script handler.
+ */
+ @JsonProperty(value = "typeHandlerVersion")
+ private String typeHandlerVersion;
+
+ /*
+ * Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension
+ * will not upgrade minor versions unless redeployed, even with this
+ * property set to true.
+ */
+ @JsonProperty(value = "autoUpgradeMinorVersion")
+ private Boolean autoUpgradeMinorVersion;
+
+ /*
+ * Json formatted public settings for the extension.
+ */
+ @JsonProperty(value = "settings")
+ private Object settings;
+
+ /*
+ * Protected settings (may contain secrets).
+ */
+ @JsonProperty(value = "protectedSettings")
+ private Object protectedSettings;
+
+ /**
+ * Get the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @return the forceUpdateTag value.
+ */
+ public String forceUpdateTag() {
+ return this.forceUpdateTag;
+ }
+
+ /**
+ * Set the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @param forceUpdateTag the forceUpdateTag value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withForceUpdateTag(String forceUpdateTag) {
+ this.forceUpdateTag = forceUpdateTag;
+ return this;
+ }
+
+ /**
+ * Get the publisher property: The name of the extension handler publisher.
+ *
+ * @return the publisher value.
+ */
+ public String publisher() {
+ return this.publisher;
+ }
+
+ /**
+ * Set the publisher property: The name of the extension handler publisher.
+ *
+ * @param publisher the publisher value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withPublisher(String publisher) {
+ this.publisher = publisher;
+ return this;
+ }
+
+ /**
+ * Get the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @return the type value.
+ */
+ public String type() {
+ return this.type;
+ }
+
+ /**
+ * Set the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @param type the type value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withType(String type) {
+ this.type = type;
+ return this;
+ }
+
+ /**
+ * Get the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @return the typeHandlerVersion value.
+ */
+ public String typeHandlerVersion() {
+ return this.typeHandlerVersion;
+ }
+
+ /**
+ * Set the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @param typeHandlerVersion the typeHandlerVersion value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withTypeHandlerVersion(String typeHandlerVersion) {
+ this.typeHandlerVersion = typeHandlerVersion;
+ return this;
+ }
+
+ /**
+ * Get the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @return the autoUpgradeMinorVersion value.
+ */
+ public Boolean autoUpgradeMinorVersion() {
+ return this.autoUpgradeMinorVersion;
+ }
+
+ /**
+ * Set the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @param autoUpgradeMinorVersion the autoUpgradeMinorVersion value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion) {
+ this.autoUpgradeMinorVersion = autoUpgradeMinorVersion;
+ return this;
+ }
+
+ /**
+ * Get the settings property: Json formatted public settings for the extension.
+ *
+ * @return the settings value.
+ */
+ public Object settings() {
+ return this.settings;
+ }
+
+ /**
+ * Set the settings property: Json formatted public settings for the extension.
+ *
+ * @param settings the settings value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withSettings(Object settings) {
+ this.settings = settings;
+ return this;
+ }
+
+ /**
+ * Get the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @return the protectedSettings value.
+ */
+ public Object protectedSettings() {
+ return this.protectedSettings;
+ }
+
+ /**
+ * Set the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @param protectedSettings the protectedSettings value to set.
+ * @return the ExtensionParameters object itself.
+ */
+ public ExtensionParameters withProtectedSettings(Object protectedSettings) {
+ this.protectedSettings = protectedSettings;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionProperties.java
new file mode 100644
index 000000000000..ae7f748fe360
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/ExtensionProperties.java
@@ -0,0 +1,263 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.ExtensionAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeExtensionState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** Status of Arc Extension for a particular node in HCI Cluster. */
+@Fluent
+public final class ExtensionProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ExtensionProperties.class);
+
+ /*
+ * Provisioning state of the Extension proxy resource.
+ */
+ @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY)
+ private ProvisioningState provisioningState;
+
+ /*
+ * Parameters specific to this extension type.
+ */
+ @JsonProperty(value = "extensionParameters")
+ private ExtensionParameters innerExtensionParameters;
+
+ /*
+ * Aggregate state of Arc Extensions across the nodes in this HCI cluster.
+ */
+ @JsonProperty(value = "aggregateState", access = JsonProperty.Access.WRITE_ONLY)
+ private ExtensionAggregateState aggregateState;
+
+ /*
+ * State of Arc Extension in each of the nodes.
+ */
+ @JsonProperty(value = "perNodeExtensionDetails", access = JsonProperty.Access.WRITE_ONLY)
+ private List perNodeExtensionDetails;
+
+ /**
+ * Get the provisioningState property: Provisioning state of the Extension proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ public ProvisioningState provisioningState() {
+ return this.provisioningState;
+ }
+
+ /**
+ * Get the innerExtensionParameters property: Parameters specific to this extension type.
+ *
+ * @return the innerExtensionParameters value.
+ */
+ private ExtensionParameters innerExtensionParameters() {
+ return this.innerExtensionParameters;
+ }
+
+ /**
+ * Get the aggregateState property: Aggregate state of Arc Extensions across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ public ExtensionAggregateState aggregateState() {
+ return this.aggregateState;
+ }
+
+ /**
+ * Get the perNodeExtensionDetails property: State of Arc Extension in each of the nodes.
+ *
+ * @return the perNodeExtensionDetails value.
+ */
+ public List perNodeExtensionDetails() {
+ return this.perNodeExtensionDetails;
+ }
+
+ /**
+ * Get the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @return the forceUpdateTag value.
+ */
+ public String forceUpdateTag() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().forceUpdateTag();
+ }
+
+ /**
+ * Set the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @param forceUpdateTag the forceUpdateTag value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withForceUpdateTag(String forceUpdateTag) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withForceUpdateTag(forceUpdateTag);
+ return this;
+ }
+
+ /**
+ * Get the publisher property: The name of the extension handler publisher.
+ *
+ * @return the publisher value.
+ */
+ public String publisher() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().publisher();
+ }
+
+ /**
+ * Set the publisher property: The name of the extension handler publisher.
+ *
+ * @param publisher the publisher value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withPublisher(String publisher) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withPublisher(publisher);
+ return this;
+ }
+
+ /**
+ * Get the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @return the type value.
+ */
+ public String type() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().type();
+ }
+
+ /**
+ * Set the type property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @param type the type value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withType(String type) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withType(type);
+ return this;
+ }
+
+ /**
+ * Get the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @return the typeHandlerVersion value.
+ */
+ public String typeHandlerVersion() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().typeHandlerVersion();
+ }
+
+ /**
+ * Set the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @param typeHandlerVersion the typeHandlerVersion value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withTypeHandlerVersion(String typeHandlerVersion) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withTypeHandlerVersion(typeHandlerVersion);
+ return this;
+ }
+
+ /**
+ * Get the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @return the autoUpgradeMinorVersion value.
+ */
+ public Boolean autoUpgradeMinorVersion() {
+ return this.innerExtensionParameters() == null
+ ? null
+ : this.innerExtensionParameters().autoUpgradeMinorVersion();
+ }
+
+ /**
+ * Set the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if one
+ * is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @param autoUpgradeMinorVersion the autoUpgradeMinorVersion value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withAutoUpgradeMinorVersion(autoUpgradeMinorVersion);
+ return this;
+ }
+
+ /**
+ * Get the settings property: Json formatted public settings for the extension.
+ *
+ * @return the settings value.
+ */
+ public Object settings() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().settings();
+ }
+
+ /**
+ * Set the settings property: Json formatted public settings for the extension.
+ *
+ * @param settings the settings value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withSettings(Object settings) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withSettings(settings);
+ return this;
+ }
+
+ /**
+ * Get the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @return the protectedSettings value.
+ */
+ public Object protectedSettings() {
+ return this.innerExtensionParameters() == null ? null : this.innerExtensionParameters().protectedSettings();
+ }
+
+ /**
+ * Set the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @param protectedSettings the protectedSettings value to set.
+ * @return the ExtensionProperties object itself.
+ */
+ public ExtensionProperties withProtectedSettings(Object protectedSettings) {
+ if (this.innerExtensionParameters() == null) {
+ this.innerExtensionParameters = new ExtensionParameters();
+ }
+ this.innerExtensionParameters().withProtectedSettings(protectedSettings);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerExtensionParameters() != null) {
+ innerExtensionParameters().validate();
+ }
+ if (perNodeExtensionDetails() != null) {
+ perNodeExtensionDetails().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/OperationListResultInner.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/OperationListResultInner.java
new file mode 100644
index 000000000000..7f3542a343df
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/fluent/models/OperationListResultInner.java
@@ -0,0 +1,62 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.fluent.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.models.Operation;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/**
+ * A list of REST API operations supported by an Azure Resource Provider. It contains an URL link to get the next set of
+ * results.
+ */
+@Immutable
+public final class OperationListResultInner {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationListResultInner.class);
+
+ /*
+ * List of operations supported by the resource provider
+ */
+ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY)
+ private List value;
+
+ /*
+ * URL to get the next set of operation list results (if there are any).
+ */
+ @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY)
+ private String nextLink;
+
+ /**
+ * Get the value property: List of operations supported by the resource provider.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Get the nextLink property: URL to get the next set of operation list results (if there are any).
+ *
+ * @return the nextLink value.
+ */
+ public String nextLink() {
+ return this.nextLink;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() != null) {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingImpl.java
new file mode 100644
index 000000000000..79e1594f7501
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingImpl.java
@@ -0,0 +1,125 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.implementation;
+
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+import com.azure.resourcemanager.azurestackhci.models.ArcSetting;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettingAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import java.util.Collections;
+import java.util.List;
+
+public final class ArcSettingImpl implements ArcSetting, ArcSetting.Definition {
+ private ArcSettingInner innerObject;
+
+ private final com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager;
+
+ ArcSettingImpl(
+ ArcSettingInner innerObject, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ }
+
+ public String id() {
+ return this.innerModel().id();
+ }
+
+ public String name() {
+ return this.innerModel().name();
+ }
+
+ public String type() {
+ return this.innerModel().type();
+ }
+
+ public ProvisioningState provisioningState() {
+ return this.innerModel().provisioningState();
+ }
+
+ public String arcInstanceResourceGroup() {
+ return this.innerModel().arcInstanceResourceGroup();
+ }
+
+ public ArcSettingAggregateState aggregateState() {
+ return this.innerModel().aggregateState();
+ }
+
+ public List perNodeDetails() {
+ List inner = this.innerModel().perNodeDetails();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public ArcSettingInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager() {
+ return this.serviceManager;
+ }
+
+ private String resourceGroupName;
+
+ private String clusterName;
+
+ private String arcSettingName;
+
+ public ArcSettingImpl withExistingCluster(String resourceGroupName, String clusterName) {
+ this.resourceGroupName = resourceGroupName;
+ this.clusterName = clusterName;
+ return this;
+ }
+
+ public ArcSetting create() {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getArcSettings()
+ .createWithResponse(resourceGroupName, clusterName, arcSettingName, this.innerModel(), Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public ArcSetting create(Context context) {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getArcSettings()
+ .createWithResponse(resourceGroupName, clusterName, arcSettingName, this.innerModel(), context)
+ .getValue();
+ return this;
+ }
+
+ ArcSettingImpl(String name, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerObject = new ArcSettingInner();
+ this.serviceManager = serviceManager;
+ this.arcSettingName = name;
+ }
+
+ public ArcSetting refresh() {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getArcSettings()
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public ArcSetting refresh(Context context) {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getArcSettings()
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, context)
+ .getValue();
+ return this;
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsClientImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsClientImpl.java
new file mode 100644
index 000000000000..824b5ab44192
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsClientImpl.java
@@ -0,0 +1,996 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.core.util.polling.PollerFlux;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.azurestackhci.fluent.ArcSettingsClient;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettingList;
+import java.nio.ByteBuffer;
+import reactor.core.publisher.Flux;
+import reactor.core.publisher.Mono;
+
+/** An instance of this class provides access to all the operations defined in ArcSettingsClient. */
+public final class ArcSettingsClientImpl implements ArcSettingsClient {
+ private final ClientLogger logger = new ClientLogger(ArcSettingsClientImpl.class);
+
+ /** The proxy service used to perform REST calls. */
+ private final ArcSettingsService service;
+
+ /** The service client containing this operation class. */
+ private final AzureStackHciClientImpl client;
+
+ /**
+ * Initializes an instance of ArcSettingsClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ ArcSettingsClientImpl(AzureStackHciClientImpl client) {
+ this.service =
+ RestProxy.create(ArcSettingsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for AzureStackHciClientArcSettings to be used by the proxy service to
+ * perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "AzureStackHciClientA")
+ private interface ArcSettingsService {
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByCluster(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> get(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Put(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> create(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") ArcSettingInner arcSetting,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Delete(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}")
+ @ExpectedResponses({200, 202, 204})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> delete(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("{nextLink}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByClusterNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept,
+ Context context);
+ }
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByClusterSinglePageAsync(
+ String resourceGroupName, String clusterName) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .listByCluster(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ this.client.getApiVersion(),
+ 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 ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByClusterSinglePageAsync(
+ String resourceGroupName, String clusterName, Context context) {
+ if (this.client.getEndpoint() == null) {
+ return Mono
+ .error(
+ new IllegalArgumentException(
+ "Parameter this.client.getEndpoint() is required and cannot be null."));
+ }
+ if (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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listByCluster(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ this.client.getApiVersion(),
+ accept,
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByClusterAsync(String resourceGroupName, String clusterName) {
+ return new PagedFlux<>(
+ () -> listByClusterSinglePageAsync(resourceGroupName, clusterName),
+ nextLink -> listByClusterNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByClusterAsync(
+ String resourceGroupName, String clusterName, Context context) {
+ return new PagedFlux<>(
+ () -> listByClusterSinglePageAsync(resourceGroupName, clusterName, context),
+ nextLink -> listByClusterNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByCluster(String resourceGroupName, String clusterName) {
+ return new PagedIterable<>(listByClusterAsync(resourceGroupName, clusterName));
+ }
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByCluster(String resourceGroupName, String clusterName, Context context) {
+ return new PagedIterable<>(listByClusterAsync(resourceGroupName, clusterName, context));
+ }
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .get(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .get(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(String resourceGroupName, String clusterName, String arcSettingName) {
+ return getWithResponseAsync(resourceGroupName, clusterName, arcSettingName)
+ .flatMap(
+ (Response res) -> {
+ if (res.getValue() != null) {
+ return Mono.just(res.getValue());
+ } else {
+ return Mono.empty();
+ }
+ });
+ }
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ArcSettingInner get(String resourceGroupName, String clusterName, String arcSettingName) {
+ return getAsync(resourceGroupName, clusterName, arcSettingName).block();
+ }
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ return getWithResponseAsync(resourceGroupName, clusterName, arcSettingName, context).block();
+ }
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> createWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, ArcSettingInner arcSetting) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (arcSetting == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSetting is required and cannot be null."));
+ } else {
+ arcSetting.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .create(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ arcSetting,
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> createWithResponseAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ ArcSettingInner arcSetting,
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (arcSetting == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSetting is required and cannot be null."));
+ } else {
+ arcSetting.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .create(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ arcSetting,
+ accept,
+ context);
+ }
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, ArcSettingInner arcSetting) {
+ return createWithResponseAsync(resourceGroupName, clusterName, arcSettingName, arcSetting)
+ .flatMap(
+ (Response res) -> {
+ if (res.getValue() != null) {
+ return Mono.just(res.getValue());
+ } else {
+ return Mono.empty();
+ }
+ });
+ }
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ArcSettingInner create(
+ String resourceGroupName, String clusterName, String arcSettingName, ArcSettingInner arcSetting) {
+ return createAsync(resourceGroupName, clusterName, arcSettingName, arcSetting).block();
+ }
+
+ /**
+ * Create ArcSetting for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param arcSetting Parameters supplied to the Create ArcSetting resource for this HCI cluster.
+ * @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 arcSetting details.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response createWithResponse(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ ArcSettingInner arcSetting,
+ Context context) {
+ return createWithResponseAsync(resourceGroupName, clusterName, arcSettingName, arcSetting, context).block();
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> deleteWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .delete(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> deleteWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .delete(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginDeleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ Mono>> mono = deleteWithResponseAsync(resourceGroupName, clusterName, arcSettingName);
+ return this
+ .client
+ .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE);
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginDeleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono =
+ deleteWithResponseAsync(resourceGroupName, clusterName, arcSettingName, context);
+ return this
+ .client
+ .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context);
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName).getSyncPoller();
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, context).getSyncPoller();
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(String resourceGroupName, String clusterName, String arcSettingName) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, context)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 clusterName, String arcSettingName) {
+ deleteAsync(resourceGroupName, clusterName, arcSettingName).block();
+ }
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 clusterName, String arcSettingName, Context context) {
+ deleteAsync(resourceGroupName, clusterName, arcSettingName, context).block();
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return list of ArcSetting proxy resources for the HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByClusterNextSinglePageAsync(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.listByClusterNext(nextLink, this.client.getEndpoint(), accept, context))
+ .>map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return list of ArcSetting proxy resources for the HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByClusterNextSinglePageAsync(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
+ .listByClusterNext(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/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsImpl.java
new file mode 100644
index 000000000000..b81afa990be0
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ArcSettingsImpl.java
@@ -0,0 +1,189 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.azurestackhci.fluent.ArcSettingsClient;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+import com.azure.resourcemanager.azurestackhci.models.ArcSetting;
+import com.azure.resourcemanager.azurestackhci.models.ArcSettings;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+
+public final class ArcSettingsImpl implements ArcSettings {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ArcSettingsImpl.class);
+
+ private final ArcSettingsClient innerClient;
+
+ private final com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager;
+
+ public ArcSettingsImpl(
+ ArcSettingsClient innerClient, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerClient = innerClient;
+ this.serviceManager = serviceManager;
+ }
+
+ public PagedIterable listByCluster(String resourceGroupName, String clusterName) {
+ PagedIterable inner = this.serviceClient().listByCluster(resourceGroupName, clusterName);
+ return Utils.mapPage(inner, inner1 -> new ArcSettingImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listByCluster(String resourceGroupName, String clusterName, Context context) {
+ PagedIterable inner =
+ this.serviceClient().listByCluster(resourceGroupName, clusterName, context);
+ return Utils.mapPage(inner, inner1 -> new ArcSettingImpl(inner1, this.manager()));
+ }
+
+ public ArcSetting get(String resourceGroupName, String clusterName, String arcSettingName) {
+ ArcSettingInner inner = this.serviceClient().get(resourceGroupName, clusterName, arcSettingName);
+ if (inner != null) {
+ return new ArcSettingImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ Response inner =
+ this.serviceClient().getWithResponse(resourceGroupName, clusterName, arcSettingName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(
+ inner.getRequest(),
+ inner.getStatusCode(),
+ inner.getHeaders(),
+ new ArcSettingImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public void delete(String resourceGroupName, String clusterName, String arcSettingName) {
+ this.serviceClient().delete(resourceGroupName, clusterName, arcSettingName);
+ }
+
+ public void delete(String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ this.serviceClient().delete(resourceGroupName, clusterName, arcSettingName, context);
+ }
+
+ public ArcSetting getById(String id) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ return this.getWithResponse(resourceGroupName, clusterName, arcSettingName, Context.NONE).getValue();
+ }
+
+ public Response getByIdWithResponse(String id, Context context) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ return this.getWithResponse(resourceGroupName, clusterName, arcSettingName, context);
+ }
+
+ public void deleteById(String id) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ this.delete(resourceGroupName, clusterName, arcSettingName, Context.NONE);
+ }
+
+ public void deleteByIdWithResponse(String id, Context context) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ this.delete(resourceGroupName, clusterName, arcSettingName, context);
+ }
+
+ private ArcSettingsClient serviceClient() {
+ return this.innerClient;
+ }
+
+ private com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager() {
+ return this.serviceManager;
+ }
+
+ public ArcSettingImpl define(String name) {
+ return new ArcSettingImpl(name, this.manager());
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AzureStackHciClientImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AzureStackHciClientImpl.java
index c6f8b7d73b93..b7ccee3ddcc6 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AzureStackHciClientImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AzureStackHciClientImpl.java
@@ -21,8 +21,10 @@
import com.azure.core.util.polling.PollerFlux;
import com.azure.core.util.serializer.SerializerAdapter;
import com.azure.core.util.serializer.SerializerEncoding;
+import com.azure.resourcemanager.azurestackhci.fluent.ArcSettingsClient;
import com.azure.resourcemanager.azurestackhci.fluent.AzureStackHciClient;
import com.azure.resourcemanager.azurestackhci.fluent.ClustersClient;
+import com.azure.resourcemanager.azurestackhci.fluent.ExtensionsClient;
import com.azure.resourcemanager.azurestackhci.fluent.OperationsClient;
import java.io.IOException;
import java.lang.reflect.Type;
@@ -111,16 +113,16 @@ public Duration getDefaultPollInterval() {
return this.defaultPollInterval;
}
- /** The OperationsClient object to access its operations. */
- private final OperationsClient operations;
+ /** The ArcSettingsClient object to access its operations. */
+ private final ArcSettingsClient arcSettings;
/**
- * Gets the OperationsClient object to access its operations.
+ * Gets the ArcSettingsClient object to access its operations.
*
- * @return the OperationsClient object.
+ * @return the ArcSettingsClient object.
*/
- public OperationsClient getOperations() {
- return this.operations;
+ public ArcSettingsClient getArcSettings() {
+ return this.arcSettings;
}
/** The ClustersClient object to access its operations. */
@@ -135,6 +137,30 @@ public ClustersClient getClusters() {
return this.clusters;
}
+ /** The ExtensionsClient object to access its operations. */
+ private final ExtensionsClient extensions;
+
+ /**
+ * Gets the ExtensionsClient object to access its operations.
+ *
+ * @return the ExtensionsClient object.
+ */
+ public ExtensionsClient getExtensions() {
+ return this.extensions;
+ }
+
+ /** The OperationsClient object to access its operations. */
+ private final OperationsClient operations;
+
+ /**
+ * Gets the OperationsClient object to access its operations.
+ *
+ * @return the OperationsClient object.
+ */
+ public OperationsClient getOperations() {
+ return this.operations;
+ }
+
/**
* Initializes an instance of AzureStackHciClient client.
*
@@ -157,9 +183,11 @@ public ClustersClient getClusters() {
this.defaultPollInterval = defaultPollInterval;
this.subscriptionId = subscriptionId;
this.endpoint = endpoint;
- this.apiVersion = "2020-10-01";
- this.operations = new OperationsClientImpl(this);
+ this.apiVersion = "2021-09-01";
+ this.arcSettings = new ArcSettingsClientImpl(this);
this.clusters = new ClustersClientImpl(this);
+ this.extensions = new ExtensionsClientImpl(this);
+ this.operations = new OperationsClientImpl(this);
}
/**
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClusterImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClusterImpl.java
index d42ade422ccf..f92bbec6a6c5 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClusterImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClusterImpl.java
@@ -8,9 +8,9 @@
import com.azure.core.util.Context;
import com.azure.resourcemanager.azurestackhci.fluent.models.ClusterInner;
import com.azure.resourcemanager.azurestackhci.models.Cluster;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
+import com.azure.resourcemanager.azurestackhci.models.ClusterPatch;
import com.azure.resourcemanager.azurestackhci.models.ClusterReportedProperties;
-import com.azure.resourcemanager.azurestackhci.models.ClusterUpdate;
-import com.azure.resourcemanager.azurestackhci.models.CreatedByType;
import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
import com.azure.resourcemanager.azurestackhci.models.Status;
import java.time.OffsetDateTime;
@@ -59,6 +59,10 @@ public String cloudId() {
return this.innerModel().cloudId();
}
+ public String cloudManagementEndpoint() {
+ return this.innerModel().cloudManagementEndpoint();
+ }
+
public String aadClientId() {
return this.innerModel().aadClientId();
}
@@ -67,6 +71,10 @@ public String aadTenantId() {
return this.innerModel().aadTenantId();
}
+ public ClusterDesiredProperties desiredProperties() {
+ return this.innerModel().desiredProperties();
+ }
+
public ClusterReportedProperties reportedProperties() {
return this.innerModel().reportedProperties();
}
@@ -91,30 +99,6 @@ public OffsetDateTime lastBillingTimestamp() {
return this.innerModel().lastBillingTimestamp();
}
- public String createdBy() {
- return this.innerModel().createdBy();
- }
-
- public CreatedByType createdByType() {
- return this.innerModel().createdByType();
- }
-
- public OffsetDateTime createdAt() {
- return this.innerModel().createdAt();
- }
-
- public String lastModifiedBy() {
- return this.innerModel().lastModifiedBy();
- }
-
- public CreatedByType lastModifiedByType() {
- return this.innerModel().lastModifiedByType();
- }
-
- public OffsetDateTime lastModifiedAt() {
- return this.innerModel().lastModifiedAt();
- }
-
public Region region() {
return Region.fromName(this.regionName());
}
@@ -135,7 +119,7 @@ private com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager() {
private String clusterName;
- private ClusterUpdate updateCluster;
+ private ClusterPatch updateCluster;
public ClusterImpl withExistingResourceGroup(String resourceGroupName) {
this.resourceGroupName = resourceGroupName;
@@ -169,7 +153,7 @@ public Cluster create(Context context) {
}
public ClusterImpl update() {
- this.updateCluster = new ClusterUpdate();
+ this.updateCluster = new ClusterPatch();
return this;
}
@@ -240,49 +224,44 @@ public ClusterImpl withTags(Map tags) {
}
}
- public ClusterImpl withAadClientId(String aadClientId) {
- this.innerModel().withAadClientId(aadClientId);
- return this;
- }
-
- public ClusterImpl withAadTenantId(String aadTenantId) {
- this.innerModel().withAadTenantId(aadTenantId);
- return this;
- }
-
- public ClusterImpl withReportedProperties(ClusterReportedProperties reportedProperties) {
- this.innerModel().withReportedProperties(reportedProperties);
- return this;
- }
-
- public ClusterImpl withCreatedBy(String createdBy) {
- this.innerModel().withCreatedBy(createdBy);
- return this;
- }
-
- public ClusterImpl withCreatedByType(CreatedByType createdByType) {
- this.innerModel().withCreatedByType(createdByType);
- return this;
- }
-
- public ClusterImpl withCreatedAt(OffsetDateTime createdAt) {
- this.innerModel().withCreatedAt(createdAt);
- return this;
+ public ClusterImpl withCloudManagementEndpoint(String cloudManagementEndpoint) {
+ if (isInCreateMode()) {
+ this.innerModel().withCloudManagementEndpoint(cloudManagementEndpoint);
+ return this;
+ } else {
+ this.updateCluster.withCloudManagementEndpoint(cloudManagementEndpoint);
+ return this;
+ }
}
- public ClusterImpl withLastModifiedBy(String lastModifiedBy) {
- this.innerModel().withLastModifiedBy(lastModifiedBy);
- return this;
+ public ClusterImpl withAadClientId(String aadClientId) {
+ if (isInCreateMode()) {
+ this.innerModel().withAadClientId(aadClientId);
+ return this;
+ } else {
+ this.updateCluster.withAadClientId(aadClientId);
+ return this;
+ }
}
- public ClusterImpl withLastModifiedByType(CreatedByType lastModifiedByType) {
- this.innerModel().withLastModifiedByType(lastModifiedByType);
- return this;
+ public ClusterImpl withAadTenantId(String aadTenantId) {
+ if (isInCreateMode()) {
+ this.innerModel().withAadTenantId(aadTenantId);
+ return this;
+ } else {
+ this.updateCluster.withAadTenantId(aadTenantId);
+ return this;
+ }
}
- public ClusterImpl withLastModifiedAt(OffsetDateTime lastModifiedAt) {
- this.innerModel().withLastModifiedAt(lastModifiedAt);
- return this;
+ public ClusterImpl withDesiredProperties(ClusterDesiredProperties desiredProperties) {
+ if (isInCreateMode()) {
+ this.innerModel().withDesiredProperties(desiredProperties);
+ return this;
+ } else {
+ this.updateCluster.withDesiredProperties(desiredProperties);
+ return this;
+ }
}
private boolean isInCreateMode() {
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersClientImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersClientImpl.java
index ce30daccae08..5b22b90ed16c 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersClientImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersClientImpl.java
@@ -33,7 +33,7 @@
import com.azure.resourcemanager.azurestackhci.fluent.ClustersClient;
import com.azure.resourcemanager.azurestackhci.fluent.models.ClusterInner;
import com.azure.resourcemanager.azurestackhci.models.ClusterList;
-import com.azure.resourcemanager.azurestackhci.models.ClusterUpdate;
+import com.azure.resourcemanager.azurestackhci.models.ClusterPatch;
import reactor.core.publisher.Mono;
/** An instance of this class provides access to all the operations defined in ClustersClient. */
@@ -131,7 +131,7 @@ Mono> update(
@PathParam("resourceGroupName") String resourceGroupName,
@PathParam("clusterName") String clusterName,
@QueryParam("api-version") String apiVersion,
- @BodyParam("application/json") ClusterUpdate cluster,
+ @BodyParam("application/json") ClusterPatch cluster,
@HeaderParam("Accept") String accept,
Context context);
@@ -803,7 +803,7 @@ public Response createWithResponse(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> updateWithResponseAsync(
- String resourceGroupName, String clusterName, ClusterUpdate cluster) {
+ String resourceGroupName, String clusterName, ClusterPatch cluster) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -859,7 +859,7 @@ private Mono> updateWithResponseAsync(
*/
@ServiceMethod(returns = ReturnType.SINGLE)
private Mono> updateWithResponseAsync(
- String resourceGroupName, String clusterName, ClusterUpdate cluster, Context context) {
+ String resourceGroupName, String clusterName, ClusterPatch cluster, Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -910,7 +910,7 @@ private Mono> updateWithResponseAsync(
* @return cluster details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono updateAsync(String resourceGroupName, String clusterName, ClusterUpdate cluster) {
+ private Mono updateAsync(String resourceGroupName, String clusterName, ClusterPatch cluster) {
return updateWithResponseAsync(resourceGroupName, clusterName, cluster)
.flatMap(
(Response res) -> {
@@ -934,7 +934,7 @@ private Mono updateAsync(String resourceGroupName, String clusterN
* @return cluster details.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public ClusterInner update(String resourceGroupName, String clusterName, ClusterUpdate cluster) {
+ public ClusterInner update(String resourceGroupName, String clusterName, ClusterPatch cluster) {
return updateAsync(resourceGroupName, clusterName, cluster).block();
}
@@ -952,7 +952,7 @@ public ClusterInner update(String resourceGroupName, String clusterName, Cluster
*/
@ServiceMethod(returns = ReturnType.SINGLE)
public Response updateWithResponse(
- String resourceGroupName, String clusterName, ClusterUpdate cluster, Context context) {
+ String resourceGroupName, String clusterName, ClusterPatch cluster, Context context) {
return updateWithResponseAsync(resourceGroupName, clusterName, cluster, context).block();
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersImpl.java
index ffdedeed7baa..3be6fdfc7fbb 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ClustersImpl.java
@@ -134,7 +134,7 @@ public void deleteById(String id) {
new IllegalArgumentException(
String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
}
- this.deleteWithResponse(resourceGroupName, clusterName, Context.NONE).getValue();
+ this.deleteWithResponse(resourceGroupName, clusterName, Context.NONE);
}
public Response deleteByIdWithResponse(String id, Context context) {
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionImpl.java
new file mode 100644
index 000000000000..de24dac070a6
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionImpl.java
@@ -0,0 +1,211 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.implementation;
+
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+import com.azure.resourcemanager.azurestackhci.models.Extension;
+import com.azure.resourcemanager.azurestackhci.models.ExtensionAggregateState;
+import com.azure.resourcemanager.azurestackhci.models.PerNodeExtensionState;
+import com.azure.resourcemanager.azurestackhci.models.ProvisioningState;
+import java.util.Collections;
+import java.util.List;
+
+public final class ExtensionImpl implements Extension, Extension.Definition, Extension.Update {
+ private ExtensionInner innerObject;
+
+ private final com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager;
+
+ public String id() {
+ return this.innerModel().id();
+ }
+
+ public String name() {
+ return this.innerModel().name();
+ }
+
+ public String type() {
+ return this.innerModel().type();
+ }
+
+ public ProvisioningState provisioningState() {
+ return this.innerModel().provisioningState();
+ }
+
+ public ExtensionAggregateState aggregateState() {
+ return this.innerModel().aggregateState();
+ }
+
+ public List perNodeExtensionDetails() {
+ List inner = this.innerModel().perNodeExtensionDetails();
+ if (inner != null) {
+ return Collections.unmodifiableList(inner);
+ } else {
+ return Collections.emptyList();
+ }
+ }
+
+ public String forceUpdateTag() {
+ return this.innerModel().forceUpdateTag();
+ }
+
+ public String publisher() {
+ return this.innerModel().publisher();
+ }
+
+ public String typePropertiesType() {
+ return this.innerModel().typePropertiesType();
+ }
+
+ public String typeHandlerVersion() {
+ return this.innerModel().typeHandlerVersion();
+ }
+
+ public Boolean autoUpgradeMinorVersion() {
+ return this.innerModel().autoUpgradeMinorVersion();
+ }
+
+ public Object settings() {
+ return this.innerModel().settings();
+ }
+
+ public Object protectedSettings() {
+ return this.innerModel().protectedSettings();
+ }
+
+ public ExtensionInner innerModel() {
+ return this.innerObject;
+ }
+
+ private com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager() {
+ return this.serviceManager;
+ }
+
+ private String resourceGroupName;
+
+ private String clusterName;
+
+ private String arcSettingName;
+
+ private String extensionName;
+
+ public ExtensionImpl withExistingArcSetting(String resourceGroupName, String clusterName, String arcSettingName) {
+ this.resourceGroupName = resourceGroupName;
+ this.clusterName = clusterName;
+ this.arcSettingName = arcSettingName;
+ return this;
+ }
+
+ public Extension create() {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .create(resourceGroupName, clusterName, arcSettingName, extensionName, this.innerModel(), Context.NONE);
+ return this;
+ }
+
+ public Extension create(Context context) {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .create(resourceGroupName, clusterName, arcSettingName, extensionName, this.innerModel(), context);
+ return this;
+ }
+
+ ExtensionImpl(String name, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerObject = new ExtensionInner();
+ this.serviceManager = serviceManager;
+ this.extensionName = name;
+ }
+
+ public ExtensionImpl update() {
+ return this;
+ }
+
+ public Extension apply() {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .update(resourceGroupName, clusterName, arcSettingName, extensionName, this.innerModel(), Context.NONE);
+ return this;
+ }
+
+ public Extension apply(Context context) {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .update(resourceGroupName, clusterName, arcSettingName, extensionName, this.innerModel(), context);
+ return this;
+ }
+
+ ExtensionImpl(
+ ExtensionInner innerObject, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerObject = innerObject;
+ this.serviceManager = serviceManager;
+ this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups");
+ this.clusterName = Utils.getValueFromIdByName(innerObject.id(), "clusters");
+ this.arcSettingName = Utils.getValueFromIdByName(innerObject.id(), "arcSettings");
+ this.extensionName = Utils.getValueFromIdByName(innerObject.id(), "extensions");
+ }
+
+ public Extension refresh() {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, extensionName, Context.NONE)
+ .getValue();
+ return this;
+ }
+
+ public Extension refresh(Context context) {
+ this.innerObject =
+ serviceManager
+ .serviceClient()
+ .getExtensions()
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, extensionName, context)
+ .getValue();
+ return this;
+ }
+
+ public ExtensionImpl withForceUpdateTag(String forceUpdateTag) {
+ this.innerModel().withForceUpdateTag(forceUpdateTag);
+ return this;
+ }
+
+ public ExtensionImpl withPublisher(String publisher) {
+ this.innerModel().withPublisher(publisher);
+ return this;
+ }
+
+ public ExtensionImpl withTypePropertiesType(String typePropertiesType) {
+ this.innerModel().withTypePropertiesType(typePropertiesType);
+ return this;
+ }
+
+ public ExtensionImpl withTypeHandlerVersion(String typeHandlerVersion) {
+ this.innerModel().withTypeHandlerVersion(typeHandlerVersion);
+ return this;
+ }
+
+ public ExtensionImpl withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion) {
+ this.innerModel().withAutoUpgradeMinorVersion(autoUpgradeMinorVersion);
+ return this;
+ }
+
+ public ExtensionImpl withSettings(Object settings) {
+ this.innerModel().withSettings(settings);
+ return this;
+ }
+
+ public ExtensionImpl withProtectedSettings(Object protectedSettings) {
+ this.innerModel().withProtectedSettings(protectedSettings);
+ return this;
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsClientImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsClientImpl.java
new file mode 100644
index 000000000000..ef0981895206
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsClientImpl.java
@@ -0,0 +1,1575 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.management.polling.PollResult;
+import com.azure.core.util.Context;
+import com.azure.core.util.FluxUtil;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.core.util.polling.PollerFlux;
+import com.azure.core.util.polling.SyncPoller;
+import com.azure.resourcemanager.azurestackhci.fluent.ExtensionsClient;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+import com.azure.resourcemanager.azurestackhci.models.ExtensionList;
+import java.nio.ByteBuffer;
+import reactor.core.publisher.Flux;
+import reactor.core.publisher.Mono;
+
+/** An instance of this class provides access to all the operations defined in ExtensionsClient. */
+public final class ExtensionsClientImpl implements ExtensionsClient {
+ private final ClientLogger logger = new ClientLogger(ExtensionsClientImpl.class);
+
+ /** The proxy service used to perform REST calls. */
+ private final ExtensionsService service;
+
+ /** The service client containing this operation class. */
+ private final AzureStackHciClientImpl client;
+
+ /**
+ * Initializes an instance of ExtensionsClientImpl.
+ *
+ * @param client the instance of the service client containing this operation class.
+ */
+ ExtensionsClientImpl(AzureStackHciClientImpl client) {
+ this.service =
+ RestProxy.create(ExtensionsService.class, client.getHttpPipeline(), client.getSerializerAdapter());
+ this.client = client;
+ }
+
+ /**
+ * The interface defining all the services for AzureStackHciClientExtensions to be used by the proxy service to
+ * perform REST calls.
+ */
+ @Host("{$host}")
+ @ServiceInterface(name = "AzureStackHciClientE")
+ private interface ExtensionsService {
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}/extensions")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByArcSetting(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}/extensions/{extensionName}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> get(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @PathParam("extensionName") String extensionName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Put(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}/extensions/{extensionName}")
+ @ExpectedResponses({200, 201})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> create(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @PathParam("extensionName") String extensionName,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") ExtensionInner extension,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Patch(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}/extensions/{extensionName}")
+ @ExpectedResponses({201})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> update(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @PathParam("extensionName") String extensionName,
+ @QueryParam("api-version") String apiVersion,
+ @BodyParam("application/json") ExtensionInner extension,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Delete(
+ "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.AzureStackHCI"
+ + "/clusters/{clusterName}/arcSettings/{arcSettingName}/extensions/{extensionName}")
+ @ExpectedResponses({200, 202, 204})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono>> delete(
+ @HostParam("$host") String endpoint,
+ @PathParam("subscriptionId") String subscriptionId,
+ @PathParam("resourceGroupName") String resourceGroupName,
+ @PathParam("clusterName") String clusterName,
+ @PathParam("arcSettingName") String arcSettingName,
+ @PathParam("extensionName") String extensionName,
+ @QueryParam("api-version") String apiVersion,
+ @HeaderParam("Accept") String accept,
+ Context context);
+
+ @Headers({"Content-Type: application/json"})
+ @Get("{nextLink}")
+ @ExpectedResponses({200})
+ @UnexpectedResponseExceptionType(ManagementException.class)
+ Mono> listByArcSettingNext(
+ @PathParam(value = "nextLink", encoded = true) String nextLink,
+ @HostParam("$host") String endpoint,
+ @HeaderParam("Accept") String accept,
+ Context context);
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByArcSettingSinglePageAsync(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .listByArcSetting(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ 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()));
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByArcSettingSinglePageAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .listByArcSetting(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ this.client.getApiVersion(),
+ accept,
+ context)
+ .map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null));
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByArcSettingAsync(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ return new PagedFlux<>(
+ () -> listByArcSettingSinglePageAsync(resourceGroupName, clusterName, arcSettingName),
+ nextLink -> listByArcSettingNextSinglePageAsync(nextLink));
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ private PagedFlux listByArcSettingAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ return new PagedFlux<>(
+ () -> listByArcSettingSinglePageAsync(resourceGroupName, clusterName, arcSettingName, context),
+ nextLink -> listByArcSettingNextSinglePageAsync(nextLink, context));
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ return new PagedIterable<>(listByArcSettingAsync(resourceGroupName, clusterName, arcSettingName));
+ }
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.COLLECTION)
+ public PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ return new PagedIterable<>(listByArcSettingAsync(resourceGroupName, clusterName, arcSettingName, context));
+ }
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .get(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> getWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .get(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono getAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ return getWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName)
+ .flatMap(
+ (Response res) -> {
+ if (res.getValue() != null) {
+ return Mono.just(res.getValue());
+ } else {
+ return Mono.empty();
+ }
+ });
+ }
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ExtensionInner get(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ return getAsync(resourceGroupName, clusterName, arcSettingName, extensionName).block();
+ }
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ return getWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, context).block();
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> createWithResponseAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ if (extension == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extension is required and cannot be null."));
+ } else {
+ extension.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .create(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ extension,
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> createWithResponseAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ if (extension == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extension is required and cannot be null."));
+ } else {
+ extension.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .create(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ extension,
+ accept,
+ context);
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ExtensionInner> beginCreateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ Mono>> mono =
+ createWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension);
+ return this
+ .client
+ .getLroResult(
+ mono, this.client.getHttpPipeline(), ExtensionInner.class, ExtensionInner.class, Context.NONE);
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ExtensionInner> beginCreateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono =
+ createWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context);
+ return this
+ .client
+ .getLroResult(
+ mono, this.client.getHttpPipeline(), ExtensionInner.class, ExtensionInner.class, context);
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ExtensionInner> beginCreate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return beginCreateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension)
+ .getSyncPoller();
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ExtensionInner> beginCreate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return beginCreateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context)
+ .getSyncPoller();
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return beginCreateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono createAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return beginCreateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ExtensionInner create(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return createAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension).block();
+ }
+
+ /**
+ * Create Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ExtensionInner create(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return createAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context).block();
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> updateWithResponseAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ if (extension == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extension is required and cannot be null."));
+ } else {
+ extension.validate();
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .update(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ extension,
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> updateWithResponseAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ if (extension == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extension is required and cannot be null."));
+ } else {
+ extension.validate();
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .update(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ extension,
+ accept,
+ context);
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ExtensionInner> beginUpdateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ Mono>> mono =
+ updateWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension);
+ return this
+ .client
+ .getLroResult(
+ mono, this.client.getHttpPipeline(), ExtensionInner.class, ExtensionInner.class, Context.NONE);
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, ExtensionInner> beginUpdateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono =
+ updateWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context);
+ return this
+ .client
+ .getLroResult(
+ mono, this.client.getHttpPipeline(), ExtensionInner.class, ExtensionInner.class, context);
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ExtensionInner> beginUpdate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return beginUpdateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension)
+ .getSyncPoller();
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, ExtensionInner> beginUpdate(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return beginUpdateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context)
+ .getSyncPoller();
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono updateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return beginUpdateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono updateAsync(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return beginUpdateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ExtensionInner update(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension) {
+ return updateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension).block();
+ }
+
+ /**
+ * Update Extension for HCI cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @param extension Details of the Machine Extension to be created.
+ * @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 details of a particular extension in HCI Cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ public ExtensionInner update(
+ String resourceGroupName,
+ String clusterName,
+ String arcSettingName,
+ String extensionName,
+ ExtensionInner extension,
+ Context context) {
+ return updateAsync(resourceGroupName, clusterName, arcSettingName, extensionName, extension, context).block();
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> deleteWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ return FluxUtil
+ .withContext(
+ context ->
+ service
+ .delete(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ accept,
+ context))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono>> deleteWithResponseAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, 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 (clusterName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter clusterName is required and cannot be null."));
+ }
+ if (arcSettingName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter arcSettingName is required and cannot be null."));
+ }
+ if (extensionName == null) {
+ return Mono.error(new IllegalArgumentException("Parameter extensionName is required and cannot be null."));
+ }
+ final String accept = "application/json";
+ context = this.client.mergeContext(context);
+ return service
+ .delete(
+ this.client.getEndpoint(),
+ this.client.getSubscriptionId(),
+ resourceGroupName,
+ clusterName,
+ arcSettingName,
+ extensionName,
+ this.client.getApiVersion(),
+ accept,
+ context);
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginDeleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ Mono>> mono =
+ deleteWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName);
+ return this
+ .client
+ .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE);
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ private PollerFlux, Void> beginDeleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ context = this.client.mergeContext(context);
+ Mono>> mono =
+ deleteWithResponseAsync(resourceGroupName, clusterName, arcSettingName, extensionName, context);
+ return this
+ .client
+ .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context);
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName).getSyncPoller();
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION)
+ public SyncPoller, Void> beginDelete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName, context).getSyncPoller();
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 completion.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono deleteAsync(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ return beginDeleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName, context)
+ .last()
+ .flatMap(this.client::getLroFinalResultOrError);
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 clusterName, String arcSettingName, String extensionName) {
+ deleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName).block();
+ }
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 clusterName, String arcSettingName, String extensionName, Context context) {
+ deleteAsync(resourceGroupName, clusterName, arcSettingName, extensionName, context).block();
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByArcSettingNextSinglePageAsync(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.listByArcSettingNext(nextLink, this.client.getEndpoint(), accept, context))
+ .>map(
+ res ->
+ new PagedResponseBase<>(
+ res.getRequest(),
+ res.getStatusCode(),
+ res.getHeaders(),
+ res.getValue().value(),
+ res.getValue().nextLink(),
+ null))
+ .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly()));
+ }
+
+ /**
+ * Get the next page of items.
+ *
+ * @param nextLink The nextLink parameter.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return list of Extensions in HCI cluster.
+ */
+ @ServiceMethod(returns = ReturnType.SINGLE)
+ private Mono> listByArcSettingNextSinglePageAsync(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
+ .listByArcSettingNext(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/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsImpl.java
new file mode 100644
index 000000000000..e9d6084e598c
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/ExtensionsImpl.java
@@ -0,0 +1,225 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.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.azurestackhci.fluent.ExtensionsClient;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+import com.azure.resourcemanager.azurestackhci.models.Extension;
+import com.azure.resourcemanager.azurestackhci.models.Extensions;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+
+public final class ExtensionsImpl implements Extensions {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ExtensionsImpl.class);
+
+ private final ExtensionsClient innerClient;
+
+ private final com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager;
+
+ public ExtensionsImpl(
+ ExtensionsClient innerClient, com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
+ this.innerClient = innerClient;
+ this.serviceManager = serviceManager;
+ }
+
+ public PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName) {
+ PagedIterable inner =
+ this.serviceClient().listByArcSetting(resourceGroupName, clusterName, arcSettingName);
+ return Utils.mapPage(inner, inner1 -> new ExtensionImpl(inner1, this.manager()));
+ }
+
+ public PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context) {
+ PagedIterable inner =
+ this.serviceClient().listByArcSetting(resourceGroupName, clusterName, arcSettingName, context);
+ return Utils.mapPage(inner, inner1 -> new ExtensionImpl(inner1, this.manager()));
+ }
+
+ public Extension get(String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ ExtensionInner inner = this.serviceClient().get(resourceGroupName, clusterName, arcSettingName, extensionName);
+ if (inner != null) {
+ return new ExtensionImpl(inner, this.manager());
+ } else {
+ return null;
+ }
+ }
+
+ public Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ Response inner =
+ this
+ .serviceClient()
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, extensionName, context);
+ if (inner != null) {
+ return new SimpleResponse<>(
+ inner.getRequest(),
+ inner.getStatusCode(),
+ inner.getHeaders(),
+ new ExtensionImpl(inner.getValue(), this.manager()));
+ } else {
+ return null;
+ }
+ }
+
+ public void delete(String resourceGroupName, String clusterName, String arcSettingName, String extensionName) {
+ this.serviceClient().delete(resourceGroupName, clusterName, arcSettingName, extensionName);
+ }
+
+ public void delete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context) {
+ this.serviceClient().delete(resourceGroupName, clusterName, arcSettingName, extensionName, context);
+ }
+
+ public Extension getById(String id) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ String extensionName = Utils.getValueFromIdByName(id, "extensions");
+ if (extensionName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'extensions'.", id)));
+ }
+ return this
+ .getWithResponse(resourceGroupName, clusterName, arcSettingName, extensionName, Context.NONE)
+ .getValue();
+ }
+
+ public Response getByIdWithResponse(String id, Context context) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ String extensionName = Utils.getValueFromIdByName(id, "extensions");
+ if (extensionName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'extensions'.", id)));
+ }
+ return this.getWithResponse(resourceGroupName, clusterName, arcSettingName, extensionName, context);
+ }
+
+ public void deleteById(String id) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ String extensionName = Utils.getValueFromIdByName(id, "extensions");
+ if (extensionName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'extensions'.", id)));
+ }
+ this.delete(resourceGroupName, clusterName, arcSettingName, extensionName, Context.NONE);
+ }
+
+ public void deleteByIdWithResponse(String id, Context context) {
+ String resourceGroupName = Utils.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 clusterName = Utils.getValueFromIdByName(id, "clusters");
+ if (clusterName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'clusters'.", id)));
+ }
+ String arcSettingName = Utils.getValueFromIdByName(id, "arcSettings");
+ if (arcSettingName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'arcSettings'.", id)));
+ }
+ String extensionName = Utils.getValueFromIdByName(id, "extensions");
+ if (extensionName == null) {
+ throw logger
+ .logExceptionAsError(
+ new IllegalArgumentException(
+ String.format("The resource ID '%s' is not valid. Missing path segment 'extensions'.", id)));
+ }
+ this.delete(resourceGroupName, clusterName, arcSettingName, extensionName, context);
+ }
+
+ private ExtensionsClient serviceClient() {
+ return this.innerClient;
+ }
+
+ private com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager() {
+ return this.serviceManager;
+ }
+
+ public ExtensionImpl define(String name) {
+ return new ExtensionImpl(name, this.manager());
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AvailableOperationsImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationListResultImpl.java
similarity index 62%
rename from sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AvailableOperationsImpl.java
rename to sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationListResultImpl.java
index 5b15c5c41e44..5d406ea17f05 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/AvailableOperationsImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationListResultImpl.java
@@ -4,26 +4,26 @@
package com.azure.resourcemanager.azurestackhci.implementation;
-import com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner;
-import com.azure.resourcemanager.azurestackhci.models.AvailableOperations;
-import com.azure.resourcemanager.azurestackhci.models.OperationDetail;
+import com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner;
+import com.azure.resourcemanager.azurestackhci.models.Operation;
+import com.azure.resourcemanager.azurestackhci.models.OperationListResult;
import java.util.Collections;
import java.util.List;
-public final class AvailableOperationsImpl implements AvailableOperations {
- private AvailableOperationsInner innerObject;
+public final class OperationListResultImpl implements OperationListResult {
+ private OperationListResultInner innerObject;
private final com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager;
- AvailableOperationsImpl(
- AvailableOperationsInner innerObject,
+ OperationListResultImpl(
+ OperationListResultInner innerObject,
com.azure.resourcemanager.azurestackhci.AzureStackHciManager serviceManager) {
this.innerObject = innerObject;
this.serviceManager = serviceManager;
}
- public List value() {
- List inner = this.innerModel().value();
+ public List value() {
+ List inner = this.innerModel().value();
if (inner != null) {
return Collections.unmodifiableList(inner);
} else {
@@ -35,7 +35,7 @@ public String nextLink() {
return this.innerModel().nextLink();
}
- public AvailableOperationsInner innerModel() {
+ public OperationListResultInner innerModel() {
return this.innerObject;
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsClientImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsClientImpl.java
index 96b74acc6656..614875c74daa 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsClientImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsClientImpl.java
@@ -22,7 +22,7 @@
import com.azure.core.util.FluxUtil;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.azurestackhci.fluent.OperationsClient;
-import com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner;
+import com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner;
import reactor.core.publisher.Mono;
/** An instance of this class provides access to all the operations defined in OperationsClient. */
@@ -57,7 +57,7 @@ private interface OperationsService {
@Get("/providers/Microsoft.AzureStackHCI/operations")
@ExpectedResponses({200})
@UnexpectedResponseExceptionType(ManagementException.class)
- Mono> list(
+ Mono> list(
@HostParam("$host") String endpoint,
@QueryParam("api-version") String apiVersion,
@HeaderParam("Accept") String accept,
@@ -69,10 +69,10 @@ Mono> list(
*
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listWithResponseAsync() {
+ private Mono> listWithResponseAsync() {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -93,10 +93,10 @@ private Mono> listWithResponseAsync() {
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono> listWithResponseAsync(Context context) {
+ private Mono> listWithResponseAsync(Context context) {
if (this.client.getEndpoint() == null) {
return Mono
.error(
@@ -113,13 +113,13 @@ private Mono> listWithResponseAsync(Context c
*
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- private Mono listAsync() {
+ private Mono listAsync() {
return listWithResponseAsync()
.flatMap(
- (Response res) -> {
+ (Response res) -> {
if (res.getValue() != null) {
return Mono.just(res.getValue());
} else {
@@ -133,10 +133,10 @@ private Mono listAsync() {
*
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public AvailableOperationsInner list() {
+ public OperationListResultInner list() {
return listAsync().block();
}
@@ -147,10 +147,10 @@ public AvailableOperationsInner list() {
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
@ServiceMethod(returns = ReturnType.SINGLE)
- public Response listWithResponse(Context context) {
+ public Response listWithResponse(Context context) {
return listWithResponseAsync(context).block();
}
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsImpl.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsImpl.java
index 25b04346c2d5..c6dfc852a06b 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsImpl.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/implementation/OperationsImpl.java
@@ -9,8 +9,8 @@
import com.azure.core.util.Context;
import com.azure.core.util.logging.ClientLogger;
import com.azure.resourcemanager.azurestackhci.fluent.OperationsClient;
-import com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner;
-import com.azure.resourcemanager.azurestackhci.models.AvailableOperations;
+import com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner;
+import com.azure.resourcemanager.azurestackhci.models.OperationListResult;
import com.azure.resourcemanager.azurestackhci.models.Operations;
import com.fasterxml.jackson.annotation.JsonIgnore;
@@ -27,23 +27,23 @@ public OperationsImpl(
this.serviceManager = serviceManager;
}
- public AvailableOperations list() {
- AvailableOperationsInner inner = this.serviceClient().list();
+ public OperationListResult list() {
+ OperationListResultInner inner = this.serviceClient().list();
if (inner != null) {
- return new AvailableOperationsImpl(inner, this.manager());
+ return new OperationListResultImpl(inner, this.manager());
} else {
return null;
}
}
- public Response listWithResponse(Context context) {
- Response inner = this.serviceClient().listWithResponse(context);
+ public Response listWithResponse(Context context) {
+ Response inner = this.serviceClient().listWithResponse(context);
if (inner != null) {
return new SimpleResponse<>(
inner.getRequest(),
inner.getStatusCode(),
inner.getHeaders(),
- new AvailableOperationsImpl(inner.getValue(), this.manager()));
+ new OperationListResultImpl(inner.getValue(), this.manager()));
} else {
return null;
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ActionType.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ActionType.java
new file mode 100644
index 000000000000..5affedfda787
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ActionType.java
@@ -0,0 +1,31 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for ActionType. */
+public final class ActionType extends ExpandableStringEnum {
+ /** Static value Internal for ActionType. */
+ public static final ActionType INTERNAL = fromString("Internal");
+
+ /**
+ * Creates or finds a ActionType from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding ActionType.
+ */
+ @JsonCreator
+ public static ActionType fromString(String name) {
+ return fromString(name, ActionType.class);
+ }
+
+ /** @return known ActionType values. */
+ public static Collection values() {
+ return values(ActionType.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSetting.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSetting.java
new file mode 100644
index 000000000000..1c9f5973f3fb
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSetting.java
@@ -0,0 +1,125 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+import java.util.List;
+
+/** An immutable client-side representation of ArcSetting. */
+public interface ArcSetting {
+ /**
+ * Gets the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ String id();
+
+ /**
+ * Gets the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ String name();
+
+ /**
+ * Gets the type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ String type();
+
+ /**
+ * Gets the provisioningState property: Provisioning state of the ArcSetting proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ ProvisioningState provisioningState();
+
+ /**
+ * Gets the arcInstanceResourceGroup property: The resource group that hosts the Arc agents, ie. Hybrid Compute
+ * Machine resources.
+ *
+ * @return the arcInstanceResourceGroup value.
+ */
+ String arcInstanceResourceGroup();
+
+ /**
+ * Gets the aggregateState property: Aggregate state of Arc agent across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ ArcSettingAggregateState aggregateState();
+
+ /**
+ * Gets the perNodeDetails property: State of Arc agent in each of the nodes.
+ *
+ * @return the perNodeDetails value.
+ */
+ List perNodeDetails();
+
+ /**
+ * Gets the inner com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner object.
+ *
+ * @return the inner object.
+ */
+ ArcSettingInner innerModel();
+
+ /** The entirety of the ArcSetting definition. */
+ interface Definition
+ extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
+ }
+ /** The ArcSetting definition stages. */
+ interface DefinitionStages {
+ /** The first stage of the ArcSetting definition. */
+ interface Blank extends WithParentResource {
+ }
+ /** The stage of the ArcSetting definition allowing to specify parent resource. */
+ interface WithParentResource {
+ /**
+ * Specifies resourceGroupName, clusterName.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @return the next definition stage.
+ */
+ WithCreate withExistingCluster(String resourceGroupName, String clusterName);
+ }
+ /**
+ * The stage of the ArcSetting definition which contains all the minimum required properties for the resource to
+ * be created, but also allows for any other optional properties to be specified.
+ */
+ interface WithCreate {
+ /**
+ * Executes the create request.
+ *
+ * @return the created resource.
+ */
+ ArcSetting create();
+
+ /**
+ * Executes the create request.
+ *
+ * @param context The context to associate with this operation.
+ * @return the created resource.
+ */
+ ArcSetting create(Context context);
+ }
+ }
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @return the refreshed resource.
+ */
+ ArcSetting refresh();
+
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @param context The context to associate with this operation.
+ * @return the refreshed resource.
+ */
+ ArcSetting refresh(Context context);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingAggregateState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingAggregateState.java
new file mode 100644
index 000000000000..938735eabf8a
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingAggregateState.java
@@ -0,0 +1,73 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for ArcSettingAggregateState. */
+public final class ArcSettingAggregateState extends ExpandableStringEnum {
+ /** Static value NotSpecified for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState NOT_SPECIFIED = fromString("NotSpecified");
+
+ /** Static value Error for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState ERROR = fromString("Error");
+
+ /** Static value Succeeded for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState SUCCEEDED = fromString("Succeeded");
+
+ /** Static value Canceled for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState CANCELED = fromString("Canceled");
+
+ /** Static value Failed for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState FAILED = fromString("Failed");
+
+ /** Static value Connected for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState CONNECTED = fromString("Connected");
+
+ /** Static value Disconnected for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState DISCONNECTED = fromString("Disconnected");
+
+ /** Static value Deleted for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState DELETED = fromString("Deleted");
+
+ /** Static value Creating for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState CREATING = fromString("Creating");
+
+ /** Static value Updating for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState UPDATING = fromString("Updating");
+
+ /** Static value Deleting for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState DELETING = fromString("Deleting");
+
+ /** Static value Moving for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState MOVING = fromString("Moving");
+
+ /** Static value PartiallySucceeded for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState PARTIALLY_SUCCEEDED = fromString("PartiallySucceeded");
+
+ /** Static value PartiallyConnected for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState PARTIALLY_CONNECTED = fromString("PartiallyConnected");
+
+ /** Static value InProgress for ArcSettingAggregateState. */
+ public static final ArcSettingAggregateState IN_PROGRESS = fromString("InProgress");
+
+ /**
+ * Creates or finds a ArcSettingAggregateState from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding ArcSettingAggregateState.
+ */
+ @JsonCreator
+ public static ArcSettingAggregateState fromString(String name) {
+ return fromString(name, ArcSettingAggregateState.class);
+ }
+
+ /** @return known ArcSettingAggregateState values. */
+ public static Collection values() {
+ return values(ArcSettingAggregateState.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingList.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingList.java
new file mode 100644
index 000000000000..76f3841c435a
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettingList.java
@@ -0,0 +1,59 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ArcSettingInner;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** List of ArcSetting proxy resources for the HCI cluster. */
+@Immutable
+public final class ArcSettingList {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ArcSettingList.class);
+
+ /*
+ * List of ArcSetting proxy resources.
+ */
+ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY)
+ private List value;
+
+ /*
+ * Link to the next set of results.
+ */
+ @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY)
+ private String nextLink;
+
+ /**
+ * Get the value property: List of ArcSetting proxy resources.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Get the nextLink property: Link to the next set of results.
+ *
+ * @return the nextLink value.
+ */
+ public String nextLink() {
+ return this.nextLink;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() != null) {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettings.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettings.java
new file mode 100644
index 000000000000..98e5042fa2d3
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ArcSettings.java
@@ -0,0 +1,142 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.http.rest.Response;
+import com.azure.core.util.Context;
+
+/** Resource collection API of ArcSettings. */
+public interface ArcSettings {
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @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 arcSetting resources of HCI Cluster.
+ */
+ PagedIterable listByCluster(String resourceGroupName, String clusterName);
+
+ /**
+ * Get ArcSetting resources of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return arcSetting resources of HCI Cluster.
+ */
+ PagedIterable listByCluster(String resourceGroupName, String clusterName, Context context);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ ArcSetting get(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 arcSetting resource details of HCI Cluster.
+ */
+ Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void delete(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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.
+ */
+ void delete(String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return arcSetting resource details of HCI Cluster.
+ */
+ ArcSetting getById(String id);
+
+ /**
+ * Get ArcSetting resource details of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return arcSetting resource details of HCI Cluster.
+ */
+ Response getByIdWithResponse(String id, Context context);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void deleteById(String id);
+
+ /**
+ * Delete ArcSetting resource details of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void deleteByIdWithResponse(String id, Context context);
+
+ /**
+ * Begins definition for a new ArcSetting resource.
+ *
+ * @param name resource name.
+ * @return the first stage of the new ArcSetting definition.
+ */
+ ArcSetting.DefinitionStages.Blank define(String name);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/AvailableOperations.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/AvailableOperations.java
deleted file mode 100644
index f34dac121ea0..000000000000
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/AvailableOperations.java
+++ /dev/null
@@ -1,33 +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.azurestackhci.models;
-
-import com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner;
-import java.util.List;
-
-/** An immutable client-side representation of AvailableOperations. */
-public interface AvailableOperations {
- /**
- * Gets the value property: Collection of available operation details.
- *
- * @return the value value.
- */
- List value();
-
- /**
- * Gets the nextLink property: URL client should use to fetch the next page (per server side paging). It's null for
- * now, added for future use.
- *
- * @return the nextLink value.
- */
- String nextLink();
-
- /**
- * Gets the inner com.azure.resourcemanager.azurestackhci.fluent.models.AvailableOperationsInner object.
- *
- * @return the inner object.
- */
- AvailableOperationsInner innerModel();
-}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Cluster.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Cluster.java
index 9465d92f2242..784250f8f9ff 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Cluster.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Cluster.java
@@ -68,6 +68,13 @@ public interface Cluster {
*/
String cloudId();
+ /**
+ * Gets the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @return the cloudManagementEndpoint value.
+ */
+ String cloudManagementEndpoint();
+
/**
* Gets the aadClientId property: App id of cluster AAD identity.
*
@@ -82,6 +89,13 @@ public interface Cluster {
*/
String aadTenantId();
+ /**
+ * Gets the desiredProperties property: Desired properties of the cluster.
+ *
+ * @return the desiredProperties value.
+ */
+ ClusterDesiredProperties desiredProperties();
+
/**
* Gets the reportedProperties property: Properties reported by cluster agent.
*
@@ -124,48 +138,6 @@ public interface Cluster {
*/
OffsetDateTime lastBillingTimestamp();
- /**
- * Gets the createdBy property: The identity that created the resource.
- *
- * @return the createdBy value.
- */
- String createdBy();
-
- /**
- * Gets the createdByType property: The type of identity that created the resource.
- *
- * @return the createdByType value.
- */
- CreatedByType createdByType();
-
- /**
- * Gets the createdAt property: The timestamp of resource creation (UTC).
- *
- * @return the createdAt value.
- */
- OffsetDateTime createdAt();
-
- /**
- * Gets the lastModifiedBy property: The identity that last modified the resource.
- *
- * @return the lastModifiedBy value.
- */
- String lastModifiedBy();
-
- /**
- * Gets the lastModifiedByType property: The type of identity that last modified the resource.
- *
- * @return the lastModifiedByType value.
- */
- CreatedByType lastModifiedByType();
-
- /**
- * Gets the lastModifiedAt property: The timestamp of resource last modification (UTC).
- *
- * @return the lastModifiedAt value.
- */
- OffsetDateTime lastModifiedAt();
-
/**
* Gets the region of the resource.
*
@@ -233,15 +205,10 @@ interface WithResourceGroup {
*/
interface WithCreate
extends DefinitionStages.WithTags,
+ DefinitionStages.WithCloudManagementEndpoint,
DefinitionStages.WithAadClientId,
DefinitionStages.WithAadTenantId,
- DefinitionStages.WithReportedProperties,
- DefinitionStages.WithCreatedBy,
- DefinitionStages.WithCreatedByType,
- DefinitionStages.WithCreatedAt,
- DefinitionStages.WithLastModifiedBy,
- DefinitionStages.WithLastModifiedByType,
- DefinitionStages.WithLastModifiedAt {
+ DefinitionStages.WithDesiredProperties {
/**
* Executes the create request.
*
@@ -267,6 +234,17 @@ interface WithTags {
*/
WithCreate withTags(Map tags);
}
+ /** The stage of the Cluster definition allowing to specify cloudManagementEndpoint. */
+ interface WithCloudManagementEndpoint {
+ /**
+ * Specifies the cloudManagementEndpoint property: Endpoint configured for management from the Azure
+ * portal..
+ *
+ * @param cloudManagementEndpoint Endpoint configured for management from the Azure portal.
+ * @return the next definition stage.
+ */
+ WithCreate withCloudManagementEndpoint(String cloudManagementEndpoint);
+ }
/** The stage of the Cluster definition allowing to specify aadClientId. */
interface WithAadClientId {
/**
@@ -287,75 +265,15 @@ interface WithAadTenantId {
*/
WithCreate withAadTenantId(String aadTenantId);
}
- /** The stage of the Cluster definition allowing to specify reportedProperties. */
- interface WithReportedProperties {
- /**
- * Specifies the reportedProperties property: Properties reported by cluster agent..
- *
- * @param reportedProperties Properties reported by cluster agent.
- * @return the next definition stage.
- */
- WithCreate withReportedProperties(ClusterReportedProperties reportedProperties);
- }
- /** The stage of the Cluster definition allowing to specify createdBy. */
- interface WithCreatedBy {
- /**
- * Specifies the createdBy property: The identity that created the resource..
- *
- * @param createdBy The identity that created the resource.
- * @return the next definition stage.
- */
- WithCreate withCreatedBy(String createdBy);
- }
- /** The stage of the Cluster definition allowing to specify createdByType. */
- interface WithCreatedByType {
+ /** The stage of the Cluster definition allowing to specify desiredProperties. */
+ interface WithDesiredProperties {
/**
- * Specifies the createdByType property: The type of identity that created the resource..
+ * Specifies the desiredProperties property: Desired properties of the cluster..
*
- * @param createdByType The type of identity that created the resource.
+ * @param desiredProperties Desired properties of the cluster.
* @return the next definition stage.
*/
- WithCreate withCreatedByType(CreatedByType createdByType);
- }
- /** The stage of the Cluster definition allowing to specify createdAt. */
- interface WithCreatedAt {
- /**
- * Specifies the createdAt property: The timestamp of resource creation (UTC)..
- *
- * @param createdAt The timestamp of resource creation (UTC).
- * @return the next definition stage.
- */
- WithCreate withCreatedAt(OffsetDateTime createdAt);
- }
- /** The stage of the Cluster definition allowing to specify lastModifiedBy. */
- interface WithLastModifiedBy {
- /**
- * Specifies the lastModifiedBy property: The identity that last modified the resource..
- *
- * @param lastModifiedBy The identity that last modified the resource.
- * @return the next definition stage.
- */
- WithCreate withLastModifiedBy(String lastModifiedBy);
- }
- /** The stage of the Cluster definition allowing to specify lastModifiedByType. */
- interface WithLastModifiedByType {
- /**
- * Specifies the lastModifiedByType property: The type of identity that last modified the resource..
- *
- * @param lastModifiedByType The type of identity that last modified the resource.
- * @return the next definition stage.
- */
- WithCreate withLastModifiedByType(CreatedByType lastModifiedByType);
- }
- /** The stage of the Cluster definition allowing to specify lastModifiedAt. */
- interface WithLastModifiedAt {
- /**
- * Specifies the lastModifiedAt property: The timestamp of resource last modification (UTC).
- *
- * @param lastModifiedAt The timestamp of resource last modification (UTC).
- * @return the next definition stage.
- */
- WithCreate withLastModifiedAt(OffsetDateTime lastModifiedAt);
+ WithCreate withDesiredProperties(ClusterDesiredProperties desiredProperties);
}
}
/**
@@ -366,7 +284,12 @@ interface WithLastModifiedAt {
Cluster.Update update();
/** The template for Cluster update. */
- interface Update extends UpdateStages.WithTags {
+ interface Update
+ extends UpdateStages.WithTags,
+ UpdateStages.WithCloudManagementEndpoint,
+ UpdateStages.WithAadClientId,
+ UpdateStages.WithAadTenantId,
+ UpdateStages.WithDesiredProperties {
/**
* Executes the update request.
*
@@ -394,6 +317,46 @@ interface WithTags {
*/
Update withTags(Map tags);
}
+ /** The stage of the Cluster update allowing to specify cloudManagementEndpoint. */
+ interface WithCloudManagementEndpoint {
+ /**
+ * Specifies the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @param cloudManagementEndpoint Endpoint configured for management from the Azure portal.
+ * @return the next definition stage.
+ */
+ Update withCloudManagementEndpoint(String cloudManagementEndpoint);
+ }
+ /** The stage of the Cluster update allowing to specify aadClientId. */
+ interface WithAadClientId {
+ /**
+ * Specifies the aadClientId property: App id of cluster AAD identity..
+ *
+ * @param aadClientId App id of cluster AAD identity.
+ * @return the next definition stage.
+ */
+ Update withAadClientId(String aadClientId);
+ }
+ /** The stage of the Cluster update allowing to specify aadTenantId. */
+ interface WithAadTenantId {
+ /**
+ * Specifies the aadTenantId property: Tenant id of cluster AAD identity..
+ *
+ * @param aadTenantId Tenant id of cluster AAD identity.
+ * @return the next definition stage.
+ */
+ Update withAadTenantId(String aadTenantId);
+ }
+ /** The stage of the Cluster update allowing to specify desiredProperties. */
+ interface WithDesiredProperties {
+ /**
+ * Specifies the desiredProperties property: Desired properties of the cluster..
+ *
+ * @param desiredProperties Desired properties of the cluster.
+ * @return the next definition stage.
+ */
+ Update withDesiredProperties(ClusterDesiredProperties desiredProperties);
+ }
}
/**
* Refreshes the resource to sync with Azure.
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterDesiredProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterDesiredProperties.java
new file mode 100644
index 000000000000..fbe4c0bb28cb
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterDesiredProperties.java
@@ -0,0 +1,76 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Desired properties of the cluster. */
+@Fluent
+public final class ClusterDesiredProperties {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterDesiredProperties.class);
+
+ /*
+ * Desired state of Windows Server Subscription.
+ */
+ @JsonProperty(value = "windowsServerSubscription")
+ private WindowsServerSubscription windowsServerSubscription;
+
+ /*
+ * Desired level of diagnostic data emitted by the cluster.
+ */
+ @JsonProperty(value = "diagnosticLevel")
+ private DiagnosticLevel diagnosticLevel;
+
+ /**
+ * Get the windowsServerSubscription property: Desired state of Windows Server Subscription.
+ *
+ * @return the windowsServerSubscription value.
+ */
+ public WindowsServerSubscription windowsServerSubscription() {
+ return this.windowsServerSubscription;
+ }
+
+ /**
+ * Set the windowsServerSubscription property: Desired state of Windows Server Subscription.
+ *
+ * @param windowsServerSubscription the windowsServerSubscription value to set.
+ * @return the ClusterDesiredProperties object itself.
+ */
+ public ClusterDesiredProperties withWindowsServerSubscription(WindowsServerSubscription windowsServerSubscription) {
+ this.windowsServerSubscription = windowsServerSubscription;
+ return this;
+ }
+
+ /**
+ * Get the diagnosticLevel property: Desired level of diagnostic data emitted by the cluster.
+ *
+ * @return the diagnosticLevel value.
+ */
+ public DiagnosticLevel diagnosticLevel() {
+ return this.diagnosticLevel;
+ }
+
+ /**
+ * Set the diagnosticLevel property: Desired level of diagnostic data emitted by the cluster.
+ *
+ * @param diagnosticLevel the diagnosticLevel value to set.
+ * @return the ClusterDesiredProperties object itself.
+ */
+ public ClusterDesiredProperties withDiagnosticLevel(DiagnosticLevel diagnosticLevel) {
+ this.diagnosticLevel = diagnosticLevel;
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterNode.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterNode.java
index c755566c5e9f..74098a48e7ba 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterNode.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterNode.java
@@ -26,6 +26,12 @@ public final class ClusterNode {
@JsonProperty(value = "id", access = JsonProperty.Access.WRITE_ONLY)
private Float id;
+ /*
+ * State of Windows Server Subscription.
+ */
+ @JsonProperty(value = "windowsServerSubscription", access = JsonProperty.Access.WRITE_ONLY)
+ private WindowsServerSubscription windowsServerSubscription;
+
/*
* Manufacturer of the cluster node hardware.
*/
@@ -86,6 +92,15 @@ public Float id() {
return this.id;
}
+ /**
+ * Get the windowsServerSubscription property: State of Windows Server Subscription.
+ *
+ * @return the windowsServerSubscription value.
+ */
+ public WindowsServerSubscription windowsServerSubscription() {
+ return this.windowsServerSubscription;
+ }
+
/**
* Get the manufacturer property: Manufacturer of the cluster node hardware.
*
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterPatch.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterPatch.java
new file mode 100644
index 000000000000..701994095747
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterPatch.java
@@ -0,0 +1,164 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ClusterPatchProperties;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonInclude;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.Map;
+
+/** Cluster details to update. */
+@Fluent
+public final class ClusterPatch {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterPatch.class);
+
+ /*
+ * Resource tags.
+ */
+ @JsonProperty(value = "tags")
+ @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS)
+ private Map tags;
+
+ /*
+ * Cluster properties.
+ */
+ @JsonProperty(value = "properties")
+ private ClusterPatchProperties innerProperties;
+
+ /**
+ * Get the tags property: Resource tags.
+ *
+ * @return the tags value.
+ */
+ public Map tags() {
+ return this.tags;
+ }
+
+ /**
+ * Set the tags property: Resource tags.
+ *
+ * @param tags the tags value to set.
+ * @return the ClusterPatch object itself.
+ */
+ public ClusterPatch withTags(Map tags) {
+ this.tags = tags;
+ return this;
+ }
+
+ /**
+ * Get the innerProperties property: Cluster properties.
+ *
+ * @return the innerProperties value.
+ */
+ private ClusterPatchProperties innerProperties() {
+ return this.innerProperties;
+ }
+
+ /**
+ * Get the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @return the cloudManagementEndpoint value.
+ */
+ public String cloudManagementEndpoint() {
+ return this.innerProperties() == null ? null : this.innerProperties().cloudManagementEndpoint();
+ }
+
+ /**
+ * Set the cloudManagementEndpoint property: Endpoint configured for management from the Azure portal.
+ *
+ * @param cloudManagementEndpoint the cloudManagementEndpoint value to set.
+ * @return the ClusterPatch object itself.
+ */
+ public ClusterPatch withCloudManagementEndpoint(String cloudManagementEndpoint) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterPatchProperties();
+ }
+ this.innerProperties().withCloudManagementEndpoint(cloudManagementEndpoint);
+ return this;
+ }
+
+ /**
+ * Get the aadClientId property: App id of cluster AAD identity.
+ *
+ * @return the aadClientId value.
+ */
+ public String aadClientId() {
+ return this.innerProperties() == null ? null : this.innerProperties().aadClientId();
+ }
+
+ /**
+ * Set the aadClientId property: App id of cluster AAD identity.
+ *
+ * @param aadClientId the aadClientId value to set.
+ * @return the ClusterPatch object itself.
+ */
+ public ClusterPatch withAadClientId(String aadClientId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterPatchProperties();
+ }
+ this.innerProperties().withAadClientId(aadClientId);
+ return this;
+ }
+
+ /**
+ * Get the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @return the aadTenantId value.
+ */
+ public String aadTenantId() {
+ return this.innerProperties() == null ? null : this.innerProperties().aadTenantId();
+ }
+
+ /**
+ * Set the aadTenantId property: Tenant id of cluster AAD identity.
+ *
+ * @param aadTenantId the aadTenantId value to set.
+ * @return the ClusterPatch object itself.
+ */
+ public ClusterPatch withAadTenantId(String aadTenantId) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterPatchProperties();
+ }
+ this.innerProperties().withAadTenantId(aadTenantId);
+ return this;
+ }
+
+ /**
+ * Get the desiredProperties property: Desired properties of the cluster.
+ *
+ * @return the desiredProperties value.
+ */
+ public ClusterDesiredProperties desiredProperties() {
+ return this.innerProperties() == null ? null : this.innerProperties().desiredProperties();
+ }
+
+ /**
+ * Set the desiredProperties property: Desired properties of the cluster.
+ *
+ * @param desiredProperties the desiredProperties value to set.
+ * @return the ClusterPatch object itself.
+ */
+ public ClusterPatch withDesiredProperties(ClusterDesiredProperties desiredProperties) {
+ if (this.innerProperties() == null) {
+ this.innerProperties = new ClusterPatchProperties();
+ }
+ this.innerProperties().withDesiredProperties(desiredProperties);
+ return this;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (innerProperties() != null) {
+ innerProperties().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterReportedProperties.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterReportedProperties.java
index 57e55b370e17..f9e9dc3ed77b 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterReportedProperties.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterReportedProperties.java
@@ -4,7 +4,7 @@
package com.azure.resourcemanager.azurestackhci.models;
-import com.azure.core.annotation.Immutable;
+import com.azure.core.annotation.Fluent;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
@@ -12,7 +12,7 @@
import java.util.List;
/** Properties reported by cluster agent. */
-@Immutable
+@Fluent
public final class ClusterReportedProperties {
@JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterReportedProperties.class);
@@ -46,6 +46,18 @@ public final class ClusterReportedProperties {
@JsonProperty(value = "lastUpdated", access = JsonProperty.Access.WRITE_ONLY)
private OffsetDateTime lastUpdated;
+ /*
+ * IMDS attestation status of the cluster.
+ */
+ @JsonProperty(value = "imdsAttestation", access = JsonProperty.Access.WRITE_ONLY)
+ private ImdsAttestation imdsAttestation;
+
+ /*
+ * Level of diagnostic data emitted by the cluster.
+ */
+ @JsonProperty(value = "diagnosticLevel")
+ private DiagnosticLevel diagnosticLevel;
+
/**
* Get the clusterName property: Name of the on-prem cluster connected to this resource.
*
@@ -91,6 +103,35 @@ public OffsetDateTime lastUpdated() {
return this.lastUpdated;
}
+ /**
+ * Get the imdsAttestation property: IMDS attestation status of the cluster.
+ *
+ * @return the imdsAttestation value.
+ */
+ public ImdsAttestation imdsAttestation() {
+ return this.imdsAttestation;
+ }
+
+ /**
+ * Get the diagnosticLevel property: Level of diagnostic data emitted by the cluster.
+ *
+ * @return the diagnosticLevel value.
+ */
+ public DiagnosticLevel diagnosticLevel() {
+ return this.diagnosticLevel;
+ }
+
+ /**
+ * Set the diagnosticLevel property: Level of diagnostic data emitted by the cluster.
+ *
+ * @param diagnosticLevel the diagnosticLevel value to set.
+ * @return the ClusterReportedProperties object itself.
+ */
+ public ClusterReportedProperties withDiagnosticLevel(DiagnosticLevel diagnosticLevel) {
+ this.diagnosticLevel = diagnosticLevel;
+ return this;
+ }
+
/**
* Validates the instance.
*
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterUpdate.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterUpdate.java
deleted file mode 100644
index 9f56919c75a2..000000000000
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ClusterUpdate.java
+++ /dev/null
@@ -1,51 +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.azurestackhci.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-import java.util.Map;
-
-/** Cluster details to update. */
-@Fluent
-public final class ClusterUpdate {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterUpdate.class);
-
- /*
- * Resource tags.
- */
- @JsonProperty(value = "tags")
- private Map tags;
-
- /**
- * Get the tags property: Resource tags.
- *
- * @return the tags value.
- */
- public Map tags() {
- return this.tags;
- }
-
- /**
- * Set the tags property: Resource tags.
- *
- * @param tags the tags value to set.
- * @return the ClusterUpdate object itself.
- */
- public ClusterUpdate withTags(Map tags) {
- this.tags = tags;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- }
-}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/CreatedByType.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/CreatedByType.java
deleted file mode 100644
index 71527757128d..000000000000
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/CreatedByType.java
+++ /dev/null
@@ -1,40 +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.azurestackhci.models;
-
-import com.azure.core.util.ExpandableStringEnum;
-import com.fasterxml.jackson.annotation.JsonCreator;
-import java.util.Collection;
-
-/** Defines values for CreatedByType. */
-public final class CreatedByType extends ExpandableStringEnum {
- /** Static value User for CreatedByType. */
- public static final CreatedByType USER = fromString("User");
-
- /** Static value Application for CreatedByType. */
- public static final CreatedByType APPLICATION = fromString("Application");
-
- /** Static value ManagedIdentity for CreatedByType. */
- public static final CreatedByType MANAGED_IDENTITY = fromString("ManagedIdentity");
-
- /** Static value Key for CreatedByType. */
- public static final CreatedByType KEY = fromString("Key");
-
- /**
- * Creates or finds a CreatedByType from its string representation.
- *
- * @param name a name to look for.
- * @return the corresponding CreatedByType.
- */
- @JsonCreator
- public static CreatedByType fromString(String name) {
- return fromString(name, CreatedByType.class);
- }
-
- /** @return known CreatedByType values. */
- public static Collection values() {
- return values(CreatedByType.class);
- }
-}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/DiagnosticLevel.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/DiagnosticLevel.java
new file mode 100644
index 000000000000..c7fe777fde3c
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/DiagnosticLevel.java
@@ -0,0 +1,37 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for DiagnosticLevel. */
+public final class DiagnosticLevel extends ExpandableStringEnum {
+ /** Static value Off for DiagnosticLevel. */
+ public static final DiagnosticLevel OFF = fromString("Off");
+
+ /** Static value Basic for DiagnosticLevel. */
+ public static final DiagnosticLevel BASIC = fromString("Basic");
+
+ /** Static value Enhanced for DiagnosticLevel. */
+ public static final DiagnosticLevel ENHANCED = fromString("Enhanced");
+
+ /**
+ * Creates or finds a DiagnosticLevel from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding DiagnosticLevel.
+ */
+ @JsonCreator
+ public static DiagnosticLevel fromString(String name) {
+ return fromString(name, DiagnosticLevel.class);
+ }
+
+ /** @return known DiagnosticLevel values. */
+ public static Collection values() {
+ return values(DiagnosticLevel.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extension.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extension.java
new file mode 100644
index 000000000000..9ff45b9f7688
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extension.java
@@ -0,0 +1,365 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+import java.util.List;
+
+/** An immutable client-side representation of Extension. */
+public interface Extension {
+ /**
+ * Gets the id property: Fully qualified resource Id for the resource.
+ *
+ * @return the id value.
+ */
+ String id();
+
+ /**
+ * Gets the name property: The name of the resource.
+ *
+ * @return the name value.
+ */
+ String name();
+
+ /**
+ * Gets the type property: The type of the resource.
+ *
+ * @return the type value.
+ */
+ String type();
+
+ /**
+ * Gets the provisioningState property: Provisioning state of the Extension proxy resource.
+ *
+ * @return the provisioningState value.
+ */
+ ProvisioningState provisioningState();
+
+ /**
+ * Gets the aggregateState property: Aggregate state of Arc Extensions across the nodes in this HCI cluster.
+ *
+ * @return the aggregateState value.
+ */
+ ExtensionAggregateState aggregateState();
+
+ /**
+ * Gets the perNodeExtensionDetails property: State of Arc Extension in each of the nodes.
+ *
+ * @return the perNodeExtensionDetails value.
+ */
+ List perNodeExtensionDetails();
+
+ /**
+ * Gets the forceUpdateTag property: How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ *
+ * @return the forceUpdateTag value.
+ */
+ String forceUpdateTag();
+
+ /**
+ * Gets the publisher property: The name of the extension handler publisher.
+ *
+ * @return the publisher value.
+ */
+ String publisher();
+
+ /**
+ * Gets the typePropertiesType property: Specifies the type of the extension; an example is "CustomScriptExtension".
+ *
+ * @return the typePropertiesType value.
+ */
+ String typePropertiesType();
+
+ /**
+ * Gets the typeHandlerVersion property: Specifies the version of the script handler.
+ *
+ * @return the typeHandlerVersion value.
+ */
+ String typeHandlerVersion();
+
+ /**
+ * Gets the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor version if
+ * one is available at deployment time. Once deployed, however, the extension will not upgrade minor versions unless
+ * redeployed, even with this property set to true.
+ *
+ * @return the autoUpgradeMinorVersion value.
+ */
+ Boolean autoUpgradeMinorVersion();
+
+ /**
+ * Gets the settings property: Json formatted public settings for the extension.
+ *
+ * @return the settings value.
+ */
+ Object settings();
+
+ /**
+ * Gets the protectedSettings property: Protected settings (may contain secrets).
+ *
+ * @return the protectedSettings value.
+ */
+ Object protectedSettings();
+
+ /**
+ * Gets the inner com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner object.
+ *
+ * @return the inner object.
+ */
+ ExtensionInner innerModel();
+
+ /** The entirety of the Extension definition. */
+ interface Definition
+ extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate {
+ }
+ /** The Extension definition stages. */
+ interface DefinitionStages {
+ /** The first stage of the Extension definition. */
+ interface Blank extends WithParentResource {
+ }
+ /** The stage of the Extension definition allowing to specify parent resource. */
+ interface WithParentResource {
+ /**
+ * Specifies resourceGroupName, clusterName, arcSettingName.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @return the next definition stage.
+ */
+ WithCreate withExistingArcSetting(String resourceGroupName, String clusterName, String arcSettingName);
+ }
+ /**
+ * The stage of the Extension definition which contains all the minimum required properties for the resource to
+ * be created, but also allows for any other optional properties to be specified.
+ */
+ interface WithCreate
+ extends DefinitionStages.WithForceUpdateTag,
+ DefinitionStages.WithPublisher,
+ DefinitionStages.WithTypePropertiesType,
+ DefinitionStages.WithTypeHandlerVersion,
+ DefinitionStages.WithAutoUpgradeMinorVersion,
+ DefinitionStages.WithSettings,
+ DefinitionStages.WithProtectedSettings {
+ /**
+ * Executes the create request.
+ *
+ * @return the created resource.
+ */
+ Extension create();
+
+ /**
+ * Executes the create request.
+ *
+ * @param context The context to associate with this operation.
+ * @return the created resource.
+ */
+ Extension create(Context context);
+ }
+ /** The stage of the Extension definition allowing to specify forceUpdateTag. */
+ interface WithForceUpdateTag {
+ /**
+ * Specifies the forceUpdateTag property: How the extension handler should be forced to update even if the
+ * extension configuration has not changed..
+ *
+ * @param forceUpdateTag How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ * @return the next definition stage.
+ */
+ WithCreate withForceUpdateTag(String forceUpdateTag);
+ }
+ /** The stage of the Extension definition allowing to specify publisher. */
+ interface WithPublisher {
+ /**
+ * Specifies the publisher property: The name of the extension handler publisher..
+ *
+ * @param publisher The name of the extension handler publisher.
+ * @return the next definition stage.
+ */
+ WithCreate withPublisher(String publisher);
+ }
+ /** The stage of the Extension definition allowing to specify typePropertiesType. */
+ interface WithTypePropertiesType {
+ /**
+ * Specifies the typePropertiesType property: Specifies the type of the extension; an example is
+ * "CustomScriptExtension"..
+ *
+ * @param typePropertiesType Specifies the type of the extension; an example is "CustomScriptExtension".
+ * @return the next definition stage.
+ */
+ WithCreate withTypePropertiesType(String typePropertiesType);
+ }
+ /** The stage of the Extension definition allowing to specify typeHandlerVersion. */
+ interface WithTypeHandlerVersion {
+ /**
+ * Specifies the typeHandlerVersion property: Specifies the version of the script handler..
+ *
+ * @param typeHandlerVersion Specifies the version of the script handler.
+ * @return the next definition stage.
+ */
+ WithCreate withTypeHandlerVersion(String typeHandlerVersion);
+ }
+ /** The stage of the Extension definition allowing to specify autoUpgradeMinorVersion. */
+ interface WithAutoUpgradeMinorVersion {
+ /**
+ * Specifies the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor
+ * version if one is available at deployment time. Once deployed, however, the extension will not upgrade
+ * minor versions unless redeployed, even with this property set to true..
+ *
+ * @param autoUpgradeMinorVersion Indicates whether the extension should use a newer minor version if one is
+ * available at deployment time. Once deployed, however, the extension will not upgrade minor versions
+ * unless redeployed, even with this property set to true.
+ * @return the next definition stage.
+ */
+ WithCreate withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion);
+ }
+ /** The stage of the Extension definition allowing to specify settings. */
+ interface WithSettings {
+ /**
+ * Specifies the settings property: Json formatted public settings for the extension..
+ *
+ * @param settings Json formatted public settings for the extension.
+ * @return the next definition stage.
+ */
+ WithCreate withSettings(Object settings);
+ }
+ /** The stage of the Extension definition allowing to specify protectedSettings. */
+ interface WithProtectedSettings {
+ /**
+ * Specifies the protectedSettings property: Protected settings (may contain secrets)..
+ *
+ * @param protectedSettings Protected settings (may contain secrets).
+ * @return the next definition stage.
+ */
+ WithCreate withProtectedSettings(Object protectedSettings);
+ }
+ }
+ /**
+ * Begins update for the Extension resource.
+ *
+ * @return the stage of resource update.
+ */
+ Extension.Update update();
+
+ /** The template for Extension update. */
+ interface Update
+ extends UpdateStages.WithForceUpdateTag,
+ UpdateStages.WithPublisher,
+ UpdateStages.WithTypePropertiesType,
+ UpdateStages.WithTypeHandlerVersion,
+ UpdateStages.WithAutoUpgradeMinorVersion,
+ UpdateStages.WithSettings,
+ UpdateStages.WithProtectedSettings {
+ /**
+ * Executes the update request.
+ *
+ * @return the updated resource.
+ */
+ Extension apply();
+
+ /**
+ * Executes the update request.
+ *
+ * @param context The context to associate with this operation.
+ * @return the updated resource.
+ */
+ Extension apply(Context context);
+ }
+ /** The Extension update stages. */
+ interface UpdateStages {
+ /** The stage of the Extension update allowing to specify forceUpdateTag. */
+ interface WithForceUpdateTag {
+ /**
+ * Specifies the forceUpdateTag property: How the extension handler should be forced to update even if the
+ * extension configuration has not changed..
+ *
+ * @param forceUpdateTag How the extension handler should be forced to update even if the extension
+ * configuration has not changed.
+ * @return the next definition stage.
+ */
+ Update withForceUpdateTag(String forceUpdateTag);
+ }
+ /** The stage of the Extension update allowing to specify publisher. */
+ interface WithPublisher {
+ /**
+ * Specifies the publisher property: The name of the extension handler publisher..
+ *
+ * @param publisher The name of the extension handler publisher.
+ * @return the next definition stage.
+ */
+ Update withPublisher(String publisher);
+ }
+ /** The stage of the Extension update allowing to specify typePropertiesType. */
+ interface WithTypePropertiesType {
+ /**
+ * Specifies the typePropertiesType property: Specifies the type of the extension; an example is
+ * "CustomScriptExtension"..
+ *
+ * @param typePropertiesType Specifies the type of the extension; an example is "CustomScriptExtension".
+ * @return the next definition stage.
+ */
+ Update withTypePropertiesType(String typePropertiesType);
+ }
+ /** The stage of the Extension update allowing to specify typeHandlerVersion. */
+ interface WithTypeHandlerVersion {
+ /**
+ * Specifies the typeHandlerVersion property: Specifies the version of the script handler..
+ *
+ * @param typeHandlerVersion Specifies the version of the script handler.
+ * @return the next definition stage.
+ */
+ Update withTypeHandlerVersion(String typeHandlerVersion);
+ }
+ /** The stage of the Extension update allowing to specify autoUpgradeMinorVersion. */
+ interface WithAutoUpgradeMinorVersion {
+ /**
+ * Specifies the autoUpgradeMinorVersion property: Indicates whether the extension should use a newer minor
+ * version if one is available at deployment time. Once deployed, however, the extension will not upgrade
+ * minor versions unless redeployed, even with this property set to true..
+ *
+ * @param autoUpgradeMinorVersion Indicates whether the extension should use a newer minor version if one is
+ * available at deployment time. Once deployed, however, the extension will not upgrade minor versions
+ * unless redeployed, even with this property set to true.
+ * @return the next definition stage.
+ */
+ Update withAutoUpgradeMinorVersion(Boolean autoUpgradeMinorVersion);
+ }
+ /** The stage of the Extension update allowing to specify settings. */
+ interface WithSettings {
+ /**
+ * Specifies the settings property: Json formatted public settings for the extension..
+ *
+ * @param settings Json formatted public settings for the extension.
+ * @return the next definition stage.
+ */
+ Update withSettings(Object settings);
+ }
+ /** The stage of the Extension update allowing to specify protectedSettings. */
+ interface WithProtectedSettings {
+ /**
+ * Specifies the protectedSettings property: Protected settings (may contain secrets)..
+ *
+ * @param protectedSettings Protected settings (may contain secrets).
+ * @return the next definition stage.
+ */
+ Update withProtectedSettings(Object protectedSettings);
+ }
+ }
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @return the refreshed resource.
+ */
+ Extension refresh();
+
+ /**
+ * Refreshes the resource to sync with Azure.
+ *
+ * @param context The context to associate with this operation.
+ * @return the refreshed resource.
+ */
+ Extension refresh(Context context);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionAggregateState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionAggregateState.java
new file mode 100644
index 000000000000..ee6bd61725ef
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionAggregateState.java
@@ -0,0 +1,73 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for ExtensionAggregateState. */
+public final class ExtensionAggregateState extends ExpandableStringEnum {
+ /** Static value NotSpecified for ExtensionAggregateState. */
+ public static final ExtensionAggregateState NOT_SPECIFIED = fromString("NotSpecified");
+
+ /** Static value Error for ExtensionAggregateState. */
+ public static final ExtensionAggregateState ERROR = fromString("Error");
+
+ /** Static value Succeeded for ExtensionAggregateState. */
+ public static final ExtensionAggregateState SUCCEEDED = fromString("Succeeded");
+
+ /** Static value Canceled for ExtensionAggregateState. */
+ public static final ExtensionAggregateState CANCELED = fromString("Canceled");
+
+ /** Static value Failed for ExtensionAggregateState. */
+ public static final ExtensionAggregateState FAILED = fromString("Failed");
+
+ /** Static value Connected for ExtensionAggregateState. */
+ public static final ExtensionAggregateState CONNECTED = fromString("Connected");
+
+ /** Static value Disconnected for ExtensionAggregateState. */
+ public static final ExtensionAggregateState DISCONNECTED = fromString("Disconnected");
+
+ /** Static value Deleted for ExtensionAggregateState. */
+ public static final ExtensionAggregateState DELETED = fromString("Deleted");
+
+ /** Static value Creating for ExtensionAggregateState. */
+ public static final ExtensionAggregateState CREATING = fromString("Creating");
+
+ /** Static value Updating for ExtensionAggregateState. */
+ public static final ExtensionAggregateState UPDATING = fromString("Updating");
+
+ /** Static value Deleting for ExtensionAggregateState. */
+ public static final ExtensionAggregateState DELETING = fromString("Deleting");
+
+ /** Static value Moving for ExtensionAggregateState. */
+ public static final ExtensionAggregateState MOVING = fromString("Moving");
+
+ /** Static value PartiallySucceeded for ExtensionAggregateState. */
+ public static final ExtensionAggregateState PARTIALLY_SUCCEEDED = fromString("PartiallySucceeded");
+
+ /** Static value PartiallyConnected for ExtensionAggregateState. */
+ public static final ExtensionAggregateState PARTIALLY_CONNECTED = fromString("PartiallyConnected");
+
+ /** Static value InProgress for ExtensionAggregateState. */
+ public static final ExtensionAggregateState IN_PROGRESS = fromString("InProgress");
+
+ /**
+ * Creates or finds a ExtensionAggregateState from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding ExtensionAggregateState.
+ */
+ @JsonCreator
+ public static ExtensionAggregateState fromString(String name) {
+ return fromString(name, ExtensionAggregateState.class);
+ }
+
+ /** @return known ExtensionAggregateState values. */
+ public static Collection values() {
+ return values(ExtensionAggregateState.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionList.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionList.java
new file mode 100644
index 000000000000..15ea79d0c8d4
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ExtensionList.java
@@ -0,0 +1,59 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.azure.resourcemanager.azurestackhci.fluent.models.ExtensionInner;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import java.util.List;
+
+/** List of Extensions in HCI cluster. */
+@Immutable
+public final class ExtensionList {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(ExtensionList.class);
+
+ /*
+ * List of Extensions in HCI cluster.
+ */
+ @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY)
+ private List value;
+
+ /*
+ * Link to the next set of results.
+ */
+ @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY)
+ private String nextLink;
+
+ /**
+ * Get the value property: List of Extensions in HCI cluster.
+ *
+ * @return the value value.
+ */
+ public List value() {
+ return this.value;
+ }
+
+ /**
+ * Get the nextLink property: Link to the next set of results.
+ *
+ * @return the nextLink value.
+ */
+ public String nextLink() {
+ return this.nextLink;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (value() != null) {
+ value().forEach(e -> e.validate());
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extensions.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extensions.java
new file mode 100644
index 000000000000..75451ca86082
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Extensions.java
@@ -0,0 +1,150 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.http.rest.PagedIterable;
+import com.azure.core.http.rest.Response;
+import com.azure.core.util.Context;
+
+/** Resource collection API of Extensions. */
+public interface Extensions {
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ PagedIterable listByArcSetting(String resourceGroupName, String clusterName, String arcSettingName);
+
+ /**
+ * List all Extensions under ArcSetting resource.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @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 list of Extensions in HCI cluster.
+ */
+ PagedIterable listByArcSetting(
+ String resourceGroupName, String clusterName, String arcSettingName, Context context);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ Extension get(String resourceGroupName, String clusterName, String arcSettingName, String extensionName);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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 particular Arc Extension of HCI Cluster.
+ */
+ Response getWithResponse(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void delete(String resourceGroupName, String clusterName, String arcSettingName, String extensionName);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param resourceGroupName The name of the resource group. The name is case insensitive.
+ * @param clusterName The name of the cluster.
+ * @param arcSettingName The name of the proxy resource holding details of HCI ArcSetting information.
+ * @param extensionName The name of the machine extension.
+ * @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.
+ */
+ void delete(
+ String resourceGroupName, String clusterName, String arcSettingName, String extensionName, Context context);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return particular Arc Extension of HCI Cluster.
+ */
+ Extension getById(String id);
+
+ /**
+ * Get particular Arc Extension of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ * @return particular Arc Extension of HCI Cluster.
+ */
+ Response getByIdWithResponse(String id, Context context);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void deleteById(String id);
+
+ /**
+ * Delete particular Arc Extension of HCI Cluster.
+ *
+ * @param id the resource ID.
+ * @param context The context to associate with this operation.
+ * @throws IllegalArgumentException thrown if parameters fail the validation.
+ * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server.
+ * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent.
+ */
+ void deleteByIdWithResponse(String id, Context context);
+
+ /**
+ * Begins definition for a new Extension resource.
+ *
+ * @param name resource name.
+ * @return the first stage of the new Extension definition.
+ */
+ Extension.DefinitionStages.Blank define(String name);
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ImdsAttestation.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ImdsAttestation.java
new file mode 100644
index 000000000000..cdc208bc6e7e
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/ImdsAttestation.java
@@ -0,0 +1,34 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for ImdsAttestation. */
+public final class ImdsAttestation extends ExpandableStringEnum {
+ /** Static value Disabled for ImdsAttestation. */
+ public static final ImdsAttestation DISABLED = fromString("Disabled");
+
+ /** Static value Enabled for ImdsAttestation. */
+ public static final ImdsAttestation ENABLED = fromString("Enabled");
+
+ /**
+ * Creates or finds a ImdsAttestation from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding ImdsAttestation.
+ */
+ @JsonCreator
+ public static ImdsAttestation fromString(String name) {
+ return fromString(name, ImdsAttestation.class);
+ }
+
+ /** @return known ImdsAttestation values. */
+ public static Collection values() {
+ return values(ImdsAttestation.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeArcState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeArcState.java
new file mode 100644
index 000000000000..354846019964
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeArcState.java
@@ -0,0 +1,64 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for NodeArcState. */
+public final class NodeArcState extends ExpandableStringEnum {
+ /** Static value NotSpecified for NodeArcState. */
+ public static final NodeArcState NOT_SPECIFIED = fromString("NotSpecified");
+
+ /** Static value Error for NodeArcState. */
+ public static final NodeArcState ERROR = fromString("Error");
+
+ /** Static value Succeeded for NodeArcState. */
+ public static final NodeArcState SUCCEEDED = fromString("Succeeded");
+
+ /** Static value Canceled for NodeArcState. */
+ public static final NodeArcState CANCELED = fromString("Canceled");
+
+ /** Static value Failed for NodeArcState. */
+ public static final NodeArcState FAILED = fromString("Failed");
+
+ /** Static value Connected for NodeArcState. */
+ public static final NodeArcState CONNECTED = fromString("Connected");
+
+ /** Static value Disconnected for NodeArcState. */
+ public static final NodeArcState DISCONNECTED = fromString("Disconnected");
+
+ /** Static value Deleted for NodeArcState. */
+ public static final NodeArcState DELETED = fromString("Deleted");
+
+ /** Static value Creating for NodeArcState. */
+ public static final NodeArcState CREATING = fromString("Creating");
+
+ /** Static value Updating for NodeArcState. */
+ public static final NodeArcState UPDATING = fromString("Updating");
+
+ /** Static value Deleting for NodeArcState. */
+ public static final NodeArcState DELETING = fromString("Deleting");
+
+ /** Static value Moving for NodeArcState. */
+ public static final NodeArcState MOVING = fromString("Moving");
+
+ /**
+ * Creates or finds a NodeArcState from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding NodeArcState.
+ */
+ @JsonCreator
+ public static NodeArcState fromString(String name) {
+ return fromString(name, NodeArcState.class);
+ }
+
+ /** @return known NodeArcState values. */
+ public static Collection values() {
+ return values(NodeArcState.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeExtensionState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeExtensionState.java
new file mode 100644
index 000000000000..ae9b97b6c547
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/NodeExtensionState.java
@@ -0,0 +1,64 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for NodeExtensionState. */
+public final class NodeExtensionState extends ExpandableStringEnum {
+ /** Static value NotSpecified for NodeExtensionState. */
+ public static final NodeExtensionState NOT_SPECIFIED = fromString("NotSpecified");
+
+ /** Static value Error for NodeExtensionState. */
+ public static final NodeExtensionState ERROR = fromString("Error");
+
+ /** Static value Succeeded for NodeExtensionState. */
+ public static final NodeExtensionState SUCCEEDED = fromString("Succeeded");
+
+ /** Static value Canceled for NodeExtensionState. */
+ public static final NodeExtensionState CANCELED = fromString("Canceled");
+
+ /** Static value Failed for NodeExtensionState. */
+ public static final NodeExtensionState FAILED = fromString("Failed");
+
+ /** Static value Connected for NodeExtensionState. */
+ public static final NodeExtensionState CONNECTED = fromString("Connected");
+
+ /** Static value Disconnected for NodeExtensionState. */
+ public static final NodeExtensionState DISCONNECTED = fromString("Disconnected");
+
+ /** Static value Deleted for NodeExtensionState. */
+ public static final NodeExtensionState DELETED = fromString("Deleted");
+
+ /** Static value Creating for NodeExtensionState. */
+ public static final NodeExtensionState CREATING = fromString("Creating");
+
+ /** Static value Updating for NodeExtensionState. */
+ public static final NodeExtensionState UPDATING = fromString("Updating");
+
+ /** Static value Deleting for NodeExtensionState. */
+ public static final NodeExtensionState DELETING = fromString("Deleting");
+
+ /** Static value Moving for NodeExtensionState. */
+ public static final NodeExtensionState MOVING = fromString("Moving");
+
+ /**
+ * Creates or finds a NodeExtensionState from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding NodeExtensionState.
+ */
+ @JsonCreator
+ public static NodeExtensionState fromString(String name) {
+ return fromString(name, NodeExtensionState.class);
+ }
+
+ /** @return known NodeExtensionState values. */
+ public static Collection values() {
+ return values(NodeExtensionState.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operation.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operation.java
new file mode 100644
index 000000000000..9c95864d20b4
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operation.java
@@ -0,0 +1,122 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Fluent;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** REST API Operation Details of a REST API operation, returned from the Resource Provider Operations API. */
+@Fluent
+public final class Operation {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(Operation.class);
+
+ /*
+ * The name of the operation, as per Resource-Based Access Control (RBAC).
+ * Examples: "Microsoft.Compute/virtualMachines/write",
+ * "Microsoft.Compute/virtualMachines/capture/action"
+ */
+ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
+ private String name;
+
+ /*
+ * Whether the operation applies to data-plane. This is "true" for
+ * data-plane operations and "false" for ARM/control-plane operations.
+ */
+ @JsonProperty(value = "isDataAction", access = JsonProperty.Access.WRITE_ONLY)
+ private Boolean isDataAction;
+
+ /*
+ * Localized display information for this particular operation.
+ */
+ @JsonProperty(value = "display")
+ private OperationDisplay display;
+
+ /*
+ * The intended executor of the operation; as in Resource Based Access
+ * Control (RBAC) and audit logs UX. Default value is "user,system"
+ */
+ @JsonProperty(value = "origin", access = JsonProperty.Access.WRITE_ONLY)
+ private Origin origin;
+
+ /*
+ * Enum. Indicates the action type. "Internal" refers to actions that are
+ * for internal only APIs.
+ */
+ @JsonProperty(value = "actionType", access = JsonProperty.Access.WRITE_ONLY)
+ private ActionType actionType;
+
+ /**
+ * Get the name property: The name of the operation, as per Resource-Based Access Control (RBAC). Examples:
+ * "Microsoft.Compute/virtualMachines/write", "Microsoft.Compute/virtualMachines/capture/action".
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the isDataAction property: Whether the operation applies to data-plane. This is "true" for data-plane
+ * operations and "false" for ARM/control-plane operations.
+ *
+ * @return the isDataAction value.
+ */
+ public Boolean isDataAction() {
+ return this.isDataAction;
+ }
+
+ /**
+ * Get the display property: Localized display information for this particular operation.
+ *
+ * @return the display value.
+ */
+ public OperationDisplay display() {
+ return this.display;
+ }
+
+ /**
+ * Set the display property: Localized display information for this particular operation.
+ *
+ * @param display the display value to set.
+ * @return the Operation object itself.
+ */
+ public Operation withDisplay(OperationDisplay display) {
+ this.display = display;
+ return this;
+ }
+
+ /**
+ * Get the origin property: The intended executor of the operation; as in Resource Based Access Control (RBAC) and
+ * audit logs UX. Default value is "user,system".
+ *
+ * @return the origin value.
+ */
+ public Origin origin() {
+ return this.origin;
+ }
+
+ /**
+ * Get the actionType property: Enum. Indicates the action type. "Internal" refers to actions that are for internal
+ * only APIs.
+ *
+ * @return the actionType value.
+ */
+ public ActionType actionType() {
+ return this.actionType;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ if (display() != null) {
+ display().validate();
+ }
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDetail.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDetail.java
deleted file mode 100644
index 78efe3438215..000000000000
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDetail.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.azurestackhci.models;
-
-import com.azure.core.annotation.Fluent;
-import com.azure.core.util.logging.ClientLogger;
-import com.fasterxml.jackson.annotation.JsonIgnore;
-import com.fasterxml.jackson.annotation.JsonProperty;
-
-/** Operation detail payload. */
-@Fluent
-public final class OperationDetail {
- @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationDetail.class);
-
- /*
- * Name of the operation
- */
- @JsonProperty(value = "name")
- private String name;
-
- /*
- * Indicates whether the operation is a data action
- */
- @JsonProperty(value = "isDataAction")
- private Boolean isDataAction;
-
- /*
- * Display of the operation
- */
- @JsonProperty(value = "display")
- private OperationDisplay display;
-
- /*
- * Origin of the operation
- */
- @JsonProperty(value = "origin")
- private String origin;
-
- /*
- * Properties of the operation
- */
- @JsonProperty(value = "properties")
- private Object properties;
-
- /**
- * Get the name property: Name of the operation.
- *
- * @return the name value.
- */
- public String name() {
- return this.name;
- }
-
- /**
- * Set the name property: Name of the operation.
- *
- * @param name the name value to set.
- * @return the OperationDetail object itself.
- */
- public OperationDetail withName(String name) {
- this.name = name;
- return this;
- }
-
- /**
- * Get the isDataAction property: Indicates whether the operation is a data action.
- *
- * @return the isDataAction value.
- */
- public Boolean isDataAction() {
- return this.isDataAction;
- }
-
- /**
- * Set the isDataAction property: Indicates whether the operation is a data action.
- *
- * @param isDataAction the isDataAction value to set.
- * @return the OperationDetail object itself.
- */
- public OperationDetail withIsDataAction(Boolean isDataAction) {
- this.isDataAction = isDataAction;
- return this;
- }
-
- /**
- * Get the display property: Display of the operation.
- *
- * @return the display value.
- */
- public OperationDisplay display() {
- return this.display;
- }
-
- /**
- * Set the display property: Display of the operation.
- *
- * @param display the display value to set.
- * @return the OperationDetail object itself.
- */
- public OperationDetail withDisplay(OperationDisplay display) {
- this.display = display;
- return this;
- }
-
- /**
- * Get the origin property: Origin of the operation.
- *
- * @return the origin value.
- */
- public String origin() {
- return this.origin;
- }
-
- /**
- * Set the origin property: Origin of the operation.
- *
- * @param origin the origin value to set.
- * @return the OperationDetail object itself.
- */
- public OperationDetail withOrigin(String origin) {
- this.origin = origin;
- return this;
- }
-
- /**
- * Get the properties property: Properties of the operation.
- *
- * @return the properties value.
- */
- public Object properties() {
- return this.properties;
- }
-
- /**
- * Set the properties property: Properties of the operation.
- *
- * @param properties the properties value to set.
- * @return the OperationDetail object itself.
- */
- public OperationDetail withProperties(Object properties) {
- this.properties = properties;
- return this;
- }
-
- /**
- * Validates the instance.
- *
- * @throws IllegalArgumentException thrown if the instance is not valid.
- */
- public void validate() {
- if (display() != null) {
- display().validate();
- }
- }
-}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDisplay.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDisplay.java
index b8580f63bfbb..215f839a289d 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDisplay.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationDisplay.java
@@ -4,42 +4,48 @@
package com.azure.resourcemanager.azurestackhci.models;
-import com.azure.core.annotation.Fluent;
+import com.azure.core.annotation.Immutable;
import com.azure.core.util.logging.ClientLogger;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonProperty;
-/** Operation display payload. */
-@Fluent
+/** Localized display information for this particular operation. */
+@Immutable
public final class OperationDisplay {
@JsonIgnore private final ClientLogger logger = new ClientLogger(OperationDisplay.class);
/*
- * Resource provider of the operation
+ * The localized friendly form of the resource provider name, e.g.
+ * "Microsoft Monitoring Insights" or "Microsoft Compute".
*/
- @JsonProperty(value = "provider")
+ @JsonProperty(value = "provider", access = JsonProperty.Access.WRITE_ONLY)
private String provider;
/*
- * Resource of the operation
+ * The localized friendly name of the resource type related to this
+ * operation. E.g. "Virtual Machines" or "Job Schedule Collections".
*/
- @JsonProperty(value = "resource")
+ @JsonProperty(value = "resource", access = JsonProperty.Access.WRITE_ONLY)
private String resource;
/*
- * Localized friendly name for the operation
+ * The concise, localized friendly name for the operation; suitable for
+ * dropdowns. E.g. "Create or Update Virtual Machine", "Restart Virtual
+ * Machine".
*/
- @JsonProperty(value = "operation")
+ @JsonProperty(value = "operation", access = JsonProperty.Access.WRITE_ONLY)
private String operation;
/*
- * Localized friendly description for the operation
+ * The short, localized friendly description of the operation; suitable for
+ * tool tips and detailed views.
*/
- @JsonProperty(value = "description")
+ @JsonProperty(value = "description", access = JsonProperty.Access.WRITE_ONLY)
private String description;
/**
- * Get the provider property: Resource provider of the operation.
+ * Get the provider property: The localized friendly form of the resource provider name, e.g. "Microsoft Monitoring
+ * Insights" or "Microsoft Compute".
*
* @return the provider value.
*/
@@ -48,18 +54,8 @@ public String provider() {
}
/**
- * Set the provider property: Resource provider of the operation.
- *
- * @param provider the provider value to set.
- * @return the OperationDisplay object itself.
- */
- public OperationDisplay withProvider(String provider) {
- this.provider = provider;
- return this;
- }
-
- /**
- * Get the resource property: Resource of the operation.
+ * Get the resource property: The localized friendly name of the resource type related to this operation. E.g.
+ * "Virtual Machines" or "Job Schedule Collections".
*
* @return the resource value.
*/
@@ -68,18 +64,8 @@ public String resource() {
}
/**
- * Set the resource property: Resource of the operation.
- *
- * @param resource the resource value to set.
- * @return the OperationDisplay object itself.
- */
- public OperationDisplay withResource(String resource) {
- this.resource = resource;
- return this;
- }
-
- /**
- * Get the operation property: Localized friendly name for the operation.
+ * Get the operation property: The concise, localized friendly name for the operation; suitable for dropdowns. E.g.
+ * "Create or Update Virtual Machine", "Restart Virtual Machine".
*
* @return the operation value.
*/
@@ -88,18 +74,8 @@ public String operation() {
}
/**
- * Set the operation property: Localized friendly name for the operation.
- *
- * @param operation the operation value to set.
- * @return the OperationDisplay object itself.
- */
- public OperationDisplay withOperation(String operation) {
- this.operation = operation;
- return this;
- }
-
- /**
- * Get the description property: Localized friendly description for the operation.
+ * Get the description property: The short, localized friendly description of the operation; suitable for tool tips
+ * and detailed views.
*
* @return the description value.
*/
@@ -107,17 +83,6 @@ public String description() {
return this.description;
}
- /**
- * Set the description property: Localized friendly description for the operation.
- *
- * @param description the description value to set.
- * @return the OperationDisplay object itself.
- */
- public OperationDisplay withDescription(String description) {
- this.description = description;
- return this;
- }
-
/**
* Validates the instance.
*
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationListResult.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationListResult.java
new file mode 100644
index 000000000000..6f6f0475efc8
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/OperationListResult.java
@@ -0,0 +1,32 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner;
+import java.util.List;
+
+/** An immutable client-side representation of OperationListResult. */
+public interface OperationListResult {
+ /**
+ * Gets the value property: List of operations supported by the resource provider.
+ *
+ * @return the value value.
+ */
+ List value();
+
+ /**
+ * Gets the nextLink property: URL to get the next set of operation list results (if there are any).
+ *
+ * @return the nextLink value.
+ */
+ String nextLink();
+
+ /**
+ * Gets the inner com.azure.resourcemanager.azurestackhci.fluent.models.OperationListResultInner object.
+ *
+ * @return the inner object.
+ */
+ OperationListResultInner innerModel();
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operations.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operations.java
index 9f0e894f6cdf..931250fb2834 100644
--- a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operations.java
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Operations.java
@@ -14,9 +14,9 @@ public interface Operations {
*
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
- AvailableOperations list();
+ OperationListResult list();
/**
* List all available Microsoft.AzureStackHCI provider operations.
@@ -25,7 +25,7 @@ public interface Operations {
* @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 available operations of the service.
+ * @return a list of REST API operations supported by an Azure Resource Provider.
*/
- Response listWithResponse(Context context);
+ Response listWithResponse(Context context);
}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Origin.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Origin.java
new file mode 100644
index 000000000000..9762cce2c379
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/Origin.java
@@ -0,0 +1,37 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for Origin. */
+public final class Origin extends ExpandableStringEnum {
+ /** Static value user for Origin. */
+ public static final Origin USER = fromString("user");
+
+ /** Static value system for Origin. */
+ public static final Origin SYSTEM = fromString("system");
+
+ /** Static value user,system for Origin. */
+ public static final Origin USER_SYSTEM = fromString("user,system");
+
+ /**
+ * Creates or finds a Origin from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding Origin.
+ */
+ @JsonCreator
+ public static Origin fromString(String name) {
+ return fromString(name, Origin.class);
+ }
+
+ /** @return known Origin values. */
+ public static Collection values() {
+ return values(Origin.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeExtensionState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeExtensionState.java
new file mode 100644
index 000000000000..f97514bebaab
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeExtensionState.java
@@ -0,0 +1,70 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Status of Arc Extension for a particular node in HCI Cluster. */
+@Immutable
+public final class PerNodeExtensionState {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(PerNodeExtensionState.class);
+
+ /*
+ * Name of the node in HCI Cluster.
+ */
+ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
+ private String name;
+
+ /*
+ * Fully qualified resource ID for the particular Arc Extension on this
+ * node.
+ */
+ @JsonProperty(value = "extension", access = JsonProperty.Access.WRITE_ONLY)
+ private String extension;
+
+ /*
+ * State of Arc Extension in this node.
+ */
+ @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
+ private NodeExtensionState state;
+
+ /**
+ * Get the name property: Name of the node in HCI Cluster.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the extension property: Fully qualified resource ID for the particular Arc Extension on this node.
+ *
+ * @return the extension value.
+ */
+ public String extension() {
+ return this.extension;
+ }
+
+ /**
+ * Get the state property: State of Arc Extension in this node.
+ *
+ * @return the state value.
+ */
+ public NodeExtensionState state() {
+ return this.state;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeState.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeState.java
new file mode 100644
index 000000000000..a463222b2705
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/PerNodeState.java
@@ -0,0 +1,69 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.annotation.Immutable;
+import com.azure.core.util.logging.ClientLogger;
+import com.fasterxml.jackson.annotation.JsonIgnore;
+import com.fasterxml.jackson.annotation.JsonProperty;
+
+/** Status of Arc agent for a particular node in HCI Cluster. */
+@Immutable
+public final class PerNodeState {
+ @JsonIgnore private final ClientLogger logger = new ClientLogger(PerNodeState.class);
+
+ /*
+ * Name of the Node in HCI Cluster
+ */
+ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY)
+ private String name;
+
+ /*
+ * Fully qualified resource ID for the Arc agent of this node.
+ */
+ @JsonProperty(value = "arcInstance", access = JsonProperty.Access.WRITE_ONLY)
+ private String arcInstance;
+
+ /*
+ * State of Arc agent in this node.
+ */
+ @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY)
+ private NodeArcState state;
+
+ /**
+ * Get the name property: Name of the Node in HCI Cluster.
+ *
+ * @return the name value.
+ */
+ public String name() {
+ return this.name;
+ }
+
+ /**
+ * Get the arcInstance property: Fully qualified resource ID for the Arc agent of this node.
+ *
+ * @return the arcInstance value.
+ */
+ public String arcInstance() {
+ return this.arcInstance;
+ }
+
+ /**
+ * Get the state property: State of Arc agent in this node.
+ *
+ * @return the state value.
+ */
+ public NodeArcState state() {
+ return this.state;
+ }
+
+ /**
+ * Validates the instance.
+ *
+ * @throws IllegalArgumentException thrown if the instance is not valid.
+ */
+ public void validate() {
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/WindowsServerSubscription.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/WindowsServerSubscription.java
new file mode 100644
index 000000000000..28701e4307f7
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/main/java/com/azure/resourcemanager/azurestackhci/models/WindowsServerSubscription.java
@@ -0,0 +1,34 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.models;
+
+import com.azure.core.util.ExpandableStringEnum;
+import com.fasterxml.jackson.annotation.JsonCreator;
+import java.util.Collection;
+
+/** Defines values for WindowsServerSubscription. */
+public final class WindowsServerSubscription extends ExpandableStringEnum {
+ /** Static value Disabled for WindowsServerSubscription. */
+ public static final WindowsServerSubscription DISABLED = fromString("Disabled");
+
+ /** Static value Enabled for WindowsServerSubscription. */
+ public static final WindowsServerSubscription ENABLED = fromString("Enabled");
+
+ /**
+ * Creates or finds a WindowsServerSubscription from its string representation.
+ *
+ * @param name a name to look for.
+ * @return the corresponding WindowsServerSubscription.
+ */
+ @JsonCreator
+ public static WindowsServerSubscription fromString(String name) {
+ return fromString(name, WindowsServerSubscription.class);
+ }
+
+ /** @return known WindowsServerSubscription values. */
+ public static Collection values() {
+ return values(WindowsServerSubscription.class);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsCreateSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsCreateSamples.java
new file mode 100644
index 000000000000..27a56355f0ac
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsCreateSamples.java
@@ -0,0 +1,20 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+/** Samples for ArcSettings Create. */
+public final class ArcSettingsCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PutArcSetting.json
+ */
+ /**
+ * Sample code: Create ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().define("default").withExistingCluster("test-rg", "myCluster").create();
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsDeleteSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsDeleteSamples.java
new file mode 100644
index 000000000000..491d392e5335
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsDeleteSamples.java
@@ -0,0 +1,22 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings Delete. */
+public final class ArcSettingsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteArcSetting.json
+ */
+ /**
+ * Sample code: Delete ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().delete("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsGetSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsGetSamples.java
new file mode 100644
index 000000000000..77bd4b691955
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsGetSamples.java
@@ -0,0 +1,22 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings Get. */
+public final class ArcSettingsGetSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetArcSetting.json
+ */
+ /**
+ * Sample code: Get ArcSetting.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getArcSetting(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().getWithResponse("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsListByClusterSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsListByClusterSamples.java
new file mode 100644
index 000000000000..0aed1d54b35f
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ArcSettingsListByClusterSamples.java
@@ -0,0 +1,23 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for ArcSettings ListByCluster. */
+public final class ArcSettingsListByClusterSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListArcSettingsByCluster.json
+ */
+ /**
+ * Sample code: List ArcSetting resources by HCI Cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listArcSettingResourcesByHCICluster(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.arcSettings().listByCluster("test-rg", "myCluster", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersCreateSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersCreateSamples.java
new file mode 100644
index 000000000000..d59e397a595f
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersCreateSamples.java
@@ -0,0 +1,28 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+/** Samples for Clusters Create. */
+public final class ClustersCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/CreateCluster.json
+ */
+ /**
+ * Sample code: Create cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager
+ .clusters()
+ .define("myCluster")
+ .withRegion("East US")
+ .withExistingResourceGroup("test-rg")
+ .withCloudManagementEndpoint("https://98294836-31be-4668-aeae-698667faf99b.waconazure.com")
+ .withAadClientId("24a6e53d-04e5-44d2-b7cc-1b732a847dfc")
+ .withAadTenantId("7e589cc1-a8b6-4dff-91bd-5ec0fa18db94")
+ .create();
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersDeleteSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersDeleteSamples.java
new file mode 100644
index 000000000000..1828509fecdd
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersDeleteSamples.java
@@ -0,0 +1,22 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Clusters Delete. */
+public final class ClustersDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteCluster.json
+ */
+ /**
+ * Sample code: Delete cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().deleteWithResponse("test-rg", "myCluster", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersGetByResourceGroupSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersGetByResourceGroupSamples.java
new file mode 100644
index 000000000000..c4481d8253fb
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersGetByResourceGroupSamples.java
@@ -0,0 +1,22 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Clusters GetByResourceGroup. */
+public final class ClustersGetByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetCluster.json
+ */
+ /**
+ * Sample code: Get cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().getByResourceGroupWithResponse("test-rg", "myCluster", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListByResourceGroupSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListByResourceGroupSamples.java
new file mode 100644
index 000000000000..ba7c78c1e4b2
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListByResourceGroupSamples.java
@@ -0,0 +1,23 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Clusters ListByResourceGroup. */
+public final class ClustersListByResourceGroupSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListClustersByResourceGroup.json
+ */
+ /**
+ * Sample code: List clusters in a given resource group.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listClustersInAGivenResourceGroup(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().listByResourceGroup("test-rg", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListSamples.java
new file mode 100644
index 000000000000..fd894cbf6e3a
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersListSamples.java
@@ -0,0 +1,23 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Clusters List. */
+public final class ClustersListSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListClustersBySubscription.json
+ */
+ /**
+ * Sample code: List clusters in a given subscription.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listClustersInAGivenSubscription(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.clusters().list(Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersUpdateSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersUpdateSamples.java
new file mode 100644
index 000000000000..867e0aaed76b
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ClustersUpdateSamples.java
@@ -0,0 +1,49 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+import com.azure.resourcemanager.azurestackhci.models.Cluster;
+import com.azure.resourcemanager.azurestackhci.models.ClusterDesiredProperties;
+import com.azure.resourcemanager.azurestackhci.models.DiagnosticLevel;
+import com.azure.resourcemanager.azurestackhci.models.WindowsServerSubscription;
+import java.util.HashMap;
+import java.util.Map;
+
+/** Samples for Clusters Update. */
+public final class ClustersUpdateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/UpdateCluster.json
+ */
+ /**
+ * Sample code: Update cluster.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void updateCluster(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ Cluster resource =
+ manager.clusters().getByResourceGroupWithResponse("test-rg", "myCluster", Context.NONE).getValue();
+ resource
+ .update()
+ .withTags(mapOf("tag1", "value1", "tag2", "value2"))
+ .withCloudManagementEndpoint("https://98294836-31be-4668-aeae-698667faf99b.waconazure.com")
+ .withDesiredProperties(
+ new ClusterDesiredProperties()
+ .withWindowsServerSubscription(WindowsServerSubscription.ENABLED)
+ .withDiagnosticLevel(DiagnosticLevel.BASIC))
+ .apply();
+ }
+
+ @SuppressWarnings("unchecked")
+ private static Map mapOf(Object... inputs) {
+ Map map = new HashMap<>();
+ for (int i = 0; i < inputs.length; i += 2) {
+ String key = (String) inputs[i];
+ T value = (T) inputs[i + 1];
+ map.put(key, value);
+ }
+ return map;
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsCreateSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsCreateSamples.java
new file mode 100644
index 000000000000..92b43979716d
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsCreateSamples.java
@@ -0,0 +1,40 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.management.serializer.SerializerFactory;
+import com.azure.core.util.serializer.SerializerEncoding;
+import java.io.IOException;
+
+/** Samples for Extensions Create. */
+public final class ExtensionsCreateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PutExtension.json
+ */
+ /**
+ * Sample code: Create Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void createArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager)
+ throws IOException {
+ manager
+ .extensions()
+ .define("MicrosoftMonitoringAgent")
+ .withExistingArcSetting("test-rg", "myCluster", "default")
+ .withPublisher("Microsoft.Compute")
+ .withTypePropertiesType("MicrosoftMonitoringAgent")
+ .withTypeHandlerVersion("1.10")
+ .withSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceId\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .withProtectedSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceKey\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .create();
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsDeleteSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsDeleteSamples.java
new file mode 100644
index 000000000000..4991b028751e
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsDeleteSamples.java
@@ -0,0 +1,22 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Extensions Delete. */
+public final class ExtensionsDeleteSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/DeleteExtension.json
+ */
+ /**
+ * Sample code: Delete Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void deleteArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.extensions().delete("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsGetSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsGetSamples.java
new file mode 100644
index 000000000000..401931990d30
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsGetSamples.java
@@ -0,0 +1,24 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Extensions Get. */
+public final class ExtensionsGetSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/GetExtension.json
+ */
+ /**
+ * Sample code: Get ArcSettings Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void getArcSettingsExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager
+ .extensions()
+ .getWithResponse("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsListByArcSettingSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsListByArcSettingSamples.java
new file mode 100644
index 000000000000..7d234dc3cfd0
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsListByArcSettingSamples.java
@@ -0,0 +1,23 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.util.Context;
+
+/** Samples for Extensions ListByArcSetting. */
+public final class ExtensionsListByArcSettingSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/ListExtensionsByArcSetting.json
+ */
+ /**
+ * Sample code: List Extensions under ArcSetting resource.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void listExtensionsUnderArcSettingResource(
+ com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager) {
+ manager.extensions().listByArcSetting("test-rg", "myCluster", "default", Context.NONE);
+ }
+}
diff --git a/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsUpdateSamples.java b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsUpdateSamples.java
new file mode 100644
index 000000000000..566a093f7f6e
--- /dev/null
+++ b/sdk/azurestackhci/azure-resourcemanager-azurestackhci/src/samples/java/com/azure/resourcemanager/azurestackhci/generated/ExtensionsUpdateSamples.java
@@ -0,0 +1,41 @@
+// Copyright (c) Microsoft Corporation. All rights reserved.
+// Licensed under the MIT License.
+// Code generated by Microsoft (R) AutoRest Code Generator.
+
+package com.azure.resourcemanager.azurestackhci.generated;
+
+import com.azure.core.management.serializer.SerializerFactory;
+import com.azure.core.util.Context;
+import com.azure.core.util.serializer.SerializerEncoding;
+import com.azure.resourcemanager.azurestackhci.models.Extension;
+import java.io.IOException;
+
+/** Samples for Extensions Update. */
+public final class ExtensionsUpdateSamples {
+ /*
+ * x-ms-original-file: specification/azurestackhci/resource-manager/Microsoft.AzureStackHCI/stable/2021-09-01/examples/PatchExtension.json
+ */
+ /**
+ * Sample code: Update Arc Extension.
+ *
+ * @param manager Entry point to AzureStackHciManager.
+ */
+ public static void updateArcExtension(com.azure.resourcemanager.azurestackhci.AzureStackHciManager manager)
+ throws IOException {
+ Extension resource =
+ manager
+ .extensions()
+ .getWithResponse("test-rg", "myCluster", "default", "MicrosoftMonitoringAgent", Context.NONE)
+ .getValue();
+ resource
+ .update()
+ .withPublisher("Microsoft.Compute")
+ .withTypePropertiesType("MicrosoftMonitoringAgent")
+ .withTypeHandlerVersion("1.10")
+ .withSettings(
+ SerializerFactory
+ .createDefaultManagementSerializerAdapter()
+ .deserialize("{\"workspaceId\":\"xx\"}", Object.class, SerializerEncoding.JSON))
+ .apply();
+ }
+}