diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md index 41c62a9ca98f6..8559d9382fb01 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md @@ -1,7 +1,8 @@ # Release History -## 1.0.0-beta.2 (Unreleased) +## 1.0.0-beta.1 (2022-05-09) +- Azure Resource Manager MachineLearningServices client library for Java. This package contains Microsoft Azure SDK for MachineLearningServices Management SDK. These APIs allow end users to operate on Azure Machine Learning Workspace resources. Package tag package-2021-07-01. 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-16) diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/README.md b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/README.md index fd63ec9be8f78..99b588a441da5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/README.md +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/README.md @@ -2,7 +2,7 @@ Azure Resource Manager MachineLearningServices client library for Java. -This package contains Microsoft Azure SDK for MachineLearningServices Management SDK. These APIs allow end users to operate on Azure Machine Learning Workspace resources. Package tag package-2021-04-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). +This package contains Microsoft Azure SDK for MachineLearningServices Management SDK. These APIs allow end users to operate on Azure Machine Learning Workspace resources. Package tag package-2021-07-01. For documentation on how to use this package, please see [Azure Management Libraries for Java](https://aka.ms/azsdk/java/mgmt). ## We'd love to hear your feedback @@ -32,7 +32,7 @@ Various documentation is available to help you get started com.azure.resourcemanager azure-resourcemanager-machinelearningservices - 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/machinelearningservices/azure-resourcemanager-machinelearningservices/SAMPLE.md) + + ## Troubleshooting ## Next steps diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/SAMPLE.md b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/SAMPLE.md new file mode 100644 index 0000000000000..e49bed02caa26 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/SAMPLE.md @@ -0,0 +1,1387 @@ +# Code snippets and samples + + +## Compute + +- [CreateOrUpdate](#compute_createorupdate) +- [Delete](#compute_delete) +- [Get](#compute_get) +- [List](#compute_list) +- [ListKeys](#compute_listkeys) +- [ListNodes](#compute_listnodes) +- [Restart](#compute_restart) +- [Start](#compute_start) +- [Stop](#compute_stop) +- [Update](#compute_update) + +## PrivateEndpointConnections + +- [CreateOrUpdate](#privateendpointconnections_createorupdate) +- [Delete](#privateendpointconnections_delete) +- [Get](#privateendpointconnections_get) +- [List](#privateendpointconnections_list) + +## PrivateLinkResources + +- [List](#privatelinkresources_list) + +## Quotas + +- [List](#quotas_list) +- [Update](#quotas_update) + +## Usages + +- [List](#usages_list) + +## VirtualMachineSizes + +- [List](#virtualmachinesizes_list) + +## WorkspaceConnections + +- [Create](#workspaceconnections_create) +- [Delete](#workspaceconnections_delete) +- [Get](#workspaceconnections_get) +- [List](#workspaceconnections_list) + +## WorkspaceFeatures + +- [List](#workspacefeatures_list) + +## WorkspaceSkus + +- [List](#workspaceskus_list) + +## Workspaces + +- [CreateOrUpdate](#workspaces_createorupdate) +- [Delete](#workspaces_delete) +- [Diagnose](#workspaces_diagnose) +- [GetByResourceGroup](#workspaces_getbyresourcegroup) +- [List](#workspaces_list) +- [ListByResourceGroup](#workspaces_listbyresourcegroup) +- [ListKeys](#workspaces_listkeys) +- [ListNotebookAccessToken](#workspaces_listnotebookaccesstoken) +- [ListNotebookKeys](#workspaces_listnotebookkeys) +- [ListOutboundNetworkDependenciesEndpoints](#workspaces_listoutboundnetworkdependenciesendpoints) +- [ListStorageAccountKeys](#workspaces_liststorageaccountkeys) +- [PrepareNotebook](#workspaces_preparenotebook) +- [ResyncKeys](#workspaces_resynckeys) +- [Update](#workspaces_update) +### Compute_CreateOrUpdate + +```java +import com.azure.resourcemanager.machinelearningservices.models.Aks; +import com.azure.resourcemanager.machinelearningservices.models.AksProperties; +import com.azure.resourcemanager.machinelearningservices.models.AmlCompute; +import com.azure.resourcemanager.machinelearningservices.models.AmlComputeProperties; +import com.azure.resourcemanager.machinelearningservices.models.ApplicationSharingPolicy; +import com.azure.resourcemanager.machinelearningservices.models.AssignedUser; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstance; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceAuthorizationType; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceProperties; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceSshSettings; +import com.azure.resourcemanager.machinelearningservices.models.DataFactory; +import com.azure.resourcemanager.machinelearningservices.models.InstanceTypeSchema; +import com.azure.resourcemanager.machinelearningservices.models.InstanceTypeSchemaResources; +import com.azure.resourcemanager.machinelearningservices.models.Kubernetes; +import com.azure.resourcemanager.machinelearningservices.models.KubernetesProperties; +import com.azure.resourcemanager.machinelearningservices.models.OsType; +import com.azure.resourcemanager.machinelearningservices.models.PersonalComputeInstanceSettings; +import com.azure.resourcemanager.machinelearningservices.models.RemoteLoginPortPublicAccess; +import com.azure.resourcemanager.machinelearningservices.models.ResourceId; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettings; +import com.azure.resourcemanager.machinelearningservices.models.SshPublicAccess; +import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineImage; +import com.azure.resourcemanager.machinelearningservices.models.VmPriority; +import java.time.Duration; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Compute CreateOrUpdate. */ +public final class ComputeCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicAKSCompute.json + */ + /** + * Sample code: Create an AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties(new Aks()) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/AKSCompute.json + */ + /** + * Sample code: Update an AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAnAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new Aks() + .withDescription("some compute") + .withResourceId( + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/testrg123/providers/Microsoft.ContainerService/managedClusters/compute123-56826-c9b00420020b2") + .withProperties(new AksProperties().withAgentCount(4))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/KubernetesCompute.json + */ + /** + * Sample code: Attach a Kubernetes Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void attachAKubernetesCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new Kubernetes() + .withDescription("some compute") + .withResourceId( + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/testrg123/providers/Microsoft.ContainerService/managedClusters/compute123-56826-c9b00420020b2") + .withProperties( + new KubernetesProperties() + .withNamespace("default") + .withDefaultInstanceType("defaultInstanceType") + .withInstanceTypes( + mapOf( + "defaultInstanceType", + new InstanceTypeSchema() + .withResources( + new InstanceTypeSchemaResources() + .withRequests( + mapOf("cpu", "1", "memory", "4Gi", "nvidia.com/gpu", null)) + .withLimits( + mapOf("cpu", "1", "memory", "4Gi", "nvidia.com/gpu", null))))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicAmlCompute.json + */ + /** + * Sample code: Create a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new AmlCompute() + .withProperties( + new AmlComputeProperties() + .withOsType(OsType.WINDOWS) + .withVmSize("STANDARD_NC6") + .withVmPriority(VmPriority.DEDICATED) + .withVirtualMachineImage( + new VirtualMachineImage() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Compute/galleries/myImageGallery/images/myImageDefinition/versions/0.0.1")) + .withIsolatedNetwork(false) + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(1) + .withMinNodeCount(0) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M"))) + .withRemoteLoginPortPublicAccess(RemoteLoginPortPublicAccess.NOT_SPECIFIED) + .withEnableNodePublicIp(true))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/ComputeInstance.json + */ + /** + * Sample code: Create an ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new ComputeInstance() + .withProperties( + new ComputeInstanceProperties() + .withVmSize("STANDARD_NC6") + .withSubnet(new ResourceId()) + .withApplicationSharingPolicy(ApplicationSharingPolicy.PERSONAL) + .withSshSettings( + new ComputeInstanceSshSettings().withSshPublicAccess(SshPublicAccess.DISABLED)) + .withComputeInstanceAuthorizationType(ComputeInstanceAuthorizationType.PERSONAL) + .withPersonalComputeInstanceSettings( + new PersonalComputeInstanceSettings() + .withAssignedUser( + new AssignedUser() + .withObjectId("00000000-0000-0000-0000-000000000000") + .withTenantId("00000000-0000-0000-0000-000000000000"))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/ComputeInstanceMinimal.json + */ + /** + * Sample code: Create an ComputeInstance Compute with minimal inputs. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnComputeInstanceComputeWithMinimalInputs( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new ComputeInstance().withProperties(new ComputeInstanceProperties().withVmSize("STANDARD_NC6"))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/AmlCompute.json + */ + /** + * Sample code: Update a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new AmlCompute() + .withDescription("some compute") + .withProperties( + new AmlComputeProperties() + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(4) + .withMinNodeCount(4) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M"))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicDataFactoryCompute.json + */ + /** + * Sample code: Create a DataFactory Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createADataFactoryCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties(new DataFactory()) + .create(); + } + + @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; + } +} +``` + +### Compute_Delete + +```java +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.UnderlyingResourceAction; + +/** Samples for Compute Delete. */ +public final class ComputeDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/delete.json + */ + /** + * Sample code: Delete Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .delete("testrg123", "workspaces123", "compute123", UnderlyingResourceAction.DELETE, Context.NONE); + } +} +``` + +### Compute_Get + +```java +import com.azure.core.util.Context; + +/** Samples for Compute Get. */ +public final class ComputeGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/AKSCompute.json + */ + /** + * Sample code: Get a AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/KubernetesCompute.json + */ + /** + * Sample code: Get a Kubernetes Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAKubernetesCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/ComputeInstance.json + */ + /** + * Sample code: Get an ComputeInstance. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAnComputeInstance( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/AmlCompute.json + */ + /** + * Sample code: Get a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_List + +```java +import com.azure.core.util.Context; + +/** Samples for Compute List. */ +public final class ComputeListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/list.json + */ + /** + * Sample code: Get Computes. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getComputes( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().list("testrg123", "workspaces123", null, Context.NONE); + } +} +``` + +### Compute_ListKeys + +```java +import com.azure.core.util.Context; + +/** Samples for Compute ListKeys. */ +public final class ComputeListKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/listKeys.json + */ + /** + * Sample code: List AKS Compute Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listAKSComputeKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().listKeysWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_ListNodes + +```java +import com.azure.core.util.Context; + +/** Samples for Compute ListNodes. */ +public final class ComputeListNodesSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/listNodes.json + */ + /** + * Sample code: Get compute nodes information for a compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getComputeNodesInformationForACompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().listNodes("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_Restart + +```java +import com.azure.core.util.Context; + +/** Samples for Compute Restart. */ +public final class ComputeRestartSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/restart.json + */ + /** + * Sample code: Restart ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void restartComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().restart("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_Start + +```java +import com.azure.core.util.Context; + +/** Samples for Compute Start. */ +public final class ComputeStartSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/start.json + */ + /** + * Sample code: Start ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void startComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().start("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_Stop + +```java +import com.azure.core.util.Context; + +/** Samples for Compute Stop. */ +public final class ComputeStopSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/stop.json + */ + /** + * Sample code: Stop ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void stopComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().stop("testrg123", "workspaces123", "compute123", Context.NONE); + } +} +``` + +### Compute_Update + +```java +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.ComputeResource; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettings; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettingsInformation; +import java.time.Duration; + +/** Samples for Compute Update. */ +public final class ComputeUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/patch.json + */ + /** + * Sample code: Update a AmlCompute Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAAmlComputeCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + ComputeResource resource = + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE).getValue(); + resource + .update() + .withProperties( + new ScaleSettingsInformation() + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(4) + .withMinNodeCount(4) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M")))) + .apply(); + } +} +``` + +### PrivateEndpointConnections_CreateOrUpdate + +```java +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkServiceConnectionState; + +/** Samples for PrivateEndpointConnections CreateOrUpdate. */ +public final class PrivateEndpointConnectionsCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/createOrUpdate.json + */ + /** + * Sample code: WorkspacePutPrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspacePutPrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .define("{privateEndpointConnectionName}") + .withExistingWorkspace("rg-1234", "testworkspace") + .withPrivateLinkServiceConnectionState( + new PrivateLinkServiceConnectionState() + .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) + .withDescription("Auto-Approved")) + .create(); + } +} +``` + +### PrivateEndpointConnections_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections Delete. */ +public final class PrivateEndpointConnectionsDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/delete.json + */ + /** + * Sample code: WorkspaceDeletePrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceDeletePrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .deleteWithResponse("rg-1234", "testworkspace", "{privateEndpointConnectionName}", Context.NONE); + } +} +``` + +### PrivateEndpointConnections_Get + +```java +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections Get. */ +public final class PrivateEndpointConnectionsGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/get.json + */ + /** + * Sample code: WorkspaceGetPrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceGetPrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .getWithResponse("rg-1234", "testworkspace", "{privateEndpointConnectionName}", Context.NONE); + } +} +``` + +### PrivateEndpointConnections_List + +```java +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections List. */ +public final class PrivateEndpointConnectionsListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/list.json + */ + /** + * Sample code: StorageAccountListPrivateEndpointConnections. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void storageAccountListPrivateEndpointConnections( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.privateEndpointConnections().list("rg-1234", "testworkspace", Context.NONE); + } +} +``` + +### PrivateLinkResources_List + +```java +import com.azure.core.util.Context; + +/** Samples for PrivateLinkResources List. */ +public final class PrivateLinkResourcesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateLinkResource/list.json + */ + /** + * Sample code: WorkspaceListPrivateLinkResources. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceListPrivateLinkResources( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.privateLinkResources().listWithResponse("rg-1234", "testworkspace", Context.NONE); + } +} +``` + +### Quotas_List + +```java +import com.azure.core.util.Context; + +/** Samples for Quotas List. */ +public final class QuotasListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Quota/list.json + */ + /** + * Sample code: List workspace quotas by VMFamily. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceQuotasByVMFamily( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.quotas().list("eastus", Context.NONE); + } +} +``` + +### Quotas_Update + +```java +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.QuotaBaseProperties; +import com.azure.resourcemanager.machinelearningservices.models.QuotaUnit; +import com.azure.resourcemanager.machinelearningservices.models.QuotaUpdateParameters; +import java.util.Arrays; + +/** Samples for Quotas Update. */ +public final class QuotasUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Quota/update.json + */ + /** + * Sample code: update quotas. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateQuotas( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .quotas() + .updateWithResponse( + "eastus", + new QuotaUpdateParameters() + .withValue( + Arrays + .asList( + new QuotaBaseProperties() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace1/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs") + .withType("Microsoft.MachineLearningServices/workspaces/quotas") + .withLimit(100L) + .withUnit(QuotaUnit.COUNT), + new QuotaBaseProperties() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace2/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs") + .withType("Microsoft.MachineLearningServices/workspaces/quotas") + .withLimit(200L) + .withUnit(QuotaUnit.COUNT))), + Context.NONE); + } +} +``` + +### Usages_List + +```java +import com.azure.core.util.Context; + +/** Samples for Usages List. */ +public final class UsagesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Usage/list.json + */ + /** + * Sample code: List Usages. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listUsages( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.usages().list("eastus", Context.NONE); + } +} +``` + +### VirtualMachineSizes_List + +```java +import com.azure.core.util.Context; + +/** Samples for VirtualMachineSizes List. */ +public final class VirtualMachineSizesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/VirtualMachineSize/list.json + */ + /** + * Sample code: List VM Sizes. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listVMSizes( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.virtualMachineSizes().listWithResponse("eastus", Context.NONE); + } +} +``` + +### WorkspaceConnections_Create + +```java +/** Samples for WorkspaceConnections Create. */ +public final class WorkspaceConnectionsCreateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/create.json + */ + /** + * Sample code: CreateWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaceConnections() + .define("connection-1") + .withExistingWorkspace("resourceGroup-1", "workspace-1") + .withCategory("ACR") + .withTarget("www.facebook.com") + .withAuthType("PAT") + .withValue("secrets") + .create(); + } +} +``` + +### WorkspaceConnections_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections Delete. */ +public final class WorkspaceConnectionsDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/delete.json + */ + /** + * Sample code: DeleteWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaceConnections() + .deleteWithResponse("resourceGroup-1", "workspace-1", "connection-1", Context.NONE); + } +} +``` + +### WorkspaceConnections_Get + +```java +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections Get. */ +public final class WorkspaceConnectionsGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/get.json + */ + /** + * Sample code: GetWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceConnections().getWithResponse("resourceGroup-1", "workspace-1", "connection-1", Context.NONE); + } +} +``` + +### WorkspaceConnections_List + +```java +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections List. */ +public final class WorkspaceConnectionsListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/list.json + */ + /** + * Sample code: ListWorkspaceConnections. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceConnections( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceConnections().list("resourceGroup-1", "workspace-1", "www.facebook.com", "ACR", Context.NONE); + } +} +``` + +### WorkspaceFeatures_List + +```java +import com.azure.core.util.Context; + +/** Samples for WorkspaceFeatures List. */ +public final class WorkspaceFeaturesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceFeature/list.json + */ + /** + * Sample code: List Workspace features. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceFeatures( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceFeatures().list("myResourceGroup", "testworkspace", Context.NONE); + } +} +``` + +### WorkspaceSkus_List + +```java +import com.azure.core.util.Context; + +/** Samples for WorkspaceSkus List. */ +public final class WorkspaceSkusListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceSku/list.json + */ + /** + * Sample code: List Skus. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listSkus( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceSkus().list(Context.NONE); + } +} +``` + +### Workspaces_CreateOrUpdate + +```java +import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; +import com.azure.resourcemanager.machinelearningservices.models.EncryptionStatus; +import com.azure.resourcemanager.machinelearningservices.models.Identity; +import com.azure.resourcemanager.machinelearningservices.models.IdentityForCmk; +import com.azure.resourcemanager.machinelearningservices.models.KeyVaultProperties; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.azure.resourcemanager.machinelearningservices.models.ResourceIdentityType; +import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; +import com.azure.resourcemanager.machinelearningservices.models.UserAssignedIdentity; +import java.util.Arrays; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Workspaces CreateOrUpdate. */ +public final class WorkspacesCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/create.json + */ + /** + * Sample code: Create Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .define("testworkspace") + .withExistingResourceGroup("workspace-1234") + .withRegion("eastus2euap") + .withIdentity( + new Identity() + .withType(ResourceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED) + .withUserAssignedIdentities( + mapOf( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai", + new UserAssignedIdentity()))) + .withDescription("test description") + .withFriendlyName("HelloName") + .withKeyVault( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv") + .withApplicationInsights( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/microsoft.insights/components/testinsights") + .withContainerRegistry( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ContainerRegistry/registries/testRegistry") + .withStorageAccount( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/accountcrud-1234/providers/Microsoft.Storage/storageAccounts/testStorageAccount") + .withEncryption( + new EncryptionProperty() + .withStatus(EncryptionStatus.ENABLED) + .withIdentity( + new IdentityForCmk() + .withUserAssignedIdentity( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai")) + .withKeyVaultProperties( + new KeyVaultProperties() + .withKeyVaultArmId( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv") + .withKeyIdentifier( + "https://testkv.vault.azure.net/keys/testkey/aabbccddee112233445566778899aabb") + .withIdentityClientId(""))) + .withHbiWorkspace(false) + .withSharedPrivateLinkResources( + Arrays + .asList( + new SharedPrivateLinkResource() + .withName("testdbresource") + .withPrivateLinkResourceId( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.DocumentDB/databaseAccounts/testdbresource/privateLinkResources/Sql") + .withGroupId("Sql") + .withRequestMessage("Please approve") + .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED))) + .create(); + } + + @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; + } +} +``` + +### Workspaces_Delete + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces Delete. */ +public final class WorkspacesDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/delete.json + */ + /** + * Sample code: Delete Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().delete("workspace-1234", "testworkspace", Context.NONE); + } +} +``` + +### Workspaces_Diagnose + +```java +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseRequestProperties; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Workspaces Diagnose. */ +public final class WorkspacesDiagnoseSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/diagnose.json + */ + /** + * Sample code: Diagnose Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void diagnoseWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .diagnose( + "workspace-1234", + "testworkspace", + new DiagnoseWorkspaceParameters() + .withValue( + new DiagnoseRequestProperties() + .withUdr(mapOf()) + .withNsg(mapOf()) + .withResourceLock(mapOf()) + .withDnsResolution(mapOf()) + .withStorageAccount(mapOf()) + .withKeyVault(mapOf()) + .withContainerRegistry(mapOf()) + .withApplicationInsights(mapOf()) + .withOthers(mapOf())), + Context.NONE); + } + + @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; + } +} +``` + +### Workspaces_GetByResourceGroup + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces GetByResourceGroup. */ +public final class WorkspacesGetByResourceGroupSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/get.json + */ + /** + * Sample code: Get Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().getByResourceGroupWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} +``` + +### Workspaces_List + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces List. */ +public final class WorkspacesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listBySubscription.json + */ + /** + * Sample code: Get Workspaces by subscription. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspacesBySubscription( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().list(null, Context.NONE); + } +} +``` + +### Workspaces_ListByResourceGroup + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListByResourceGroup. */ +public final class WorkspacesListByResourceGroupSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listByResourceGroup.json + */ + /** + * Sample code: Get Workspaces by Resource Group. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspacesByResourceGroup( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listByResourceGroup("workspace-1234", null, Context.NONE); + } +} +``` + +### Workspaces_ListKeys + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListKeys. */ +public final class WorkspacesListKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} +``` + +### Workspaces_ListNotebookAccessToken + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListNotebookAccessToken. */ +public final class WorkspacesListNotebookAccessTokenSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listNotebookAccessToken.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listNotebookAccessTokenWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} +``` + +### Workspaces_ListNotebookKeys + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListNotebookKeys. */ +public final class WorkspacesListNotebookKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Notebook/listKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listNotebookKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} +``` + +### Workspaces_ListOutboundNetworkDependenciesEndpoints + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListOutboundNetworkDependenciesEndpoints. */ +public final class WorkspacesListOutboundNetworkDependenciesEndpointsSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/ExternalFQDN/get.json + */ + /** + * Sample code: ListOutboundNetworkDependenciesEndpoints. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listOutboundNetworkDependenciesEndpoints( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .listOutboundNetworkDependenciesEndpointsWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} +``` + +### Workspaces_ListStorageAccountKeys + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ListStorageAccountKeys. */ +public final class WorkspacesListStorageAccountKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listStorageAccountKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listStorageAccountKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} +``` + +### Workspaces_PrepareNotebook + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces PrepareNotebook. */ +public final class WorkspacesPrepareNotebookSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Notebook/prepare.json + */ + /** + * Sample code: Prepare Notebook. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void prepareNotebook( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().prepareNotebook("testrg123", "workspaces123", Context.NONE); + } +} +``` + +### Workspaces_ResyncKeys + +```java +import com.azure.core.util.Context; + +/** Samples for Workspaces ResyncKeys. */ +public final class WorkspacesResyncKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/resyncKeys.json + */ + /** + * Sample code: Resync Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void resyncWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().resyncKeys("testrg123", "workspaces123", Context.NONE); + } +} +``` + +### Workspaces_Update + +```java +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.Workspace; + +/** Samples for Workspaces Update. */ +public final class WorkspacesUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/update.json + */ + /** + * Sample code: Update Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + Workspace resource = + manager + .workspaces() + .getByResourceGroupWithResponse("workspace-1234", "testworkspace", Context.NONE) + .getValue(); + resource + .update() + .withDescription("new description") + .withFriendlyName("New friendly name") + .withPublicNetworkAccess(PublicNetworkAccess.DISABLED) + .apply(); + } +} +``` + diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml index 51b2776f0ff81..1c8ef279eaa98 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml @@ -1,55 +1,55 @@ - 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-machinelearningservices - 1.0.0-beta.2 - jar + com.azure.resourcemanager + azure-resourcemanager-machinelearningservices + 1.0.0-beta.2 + jar - Microsoft Azure SDK for MachineLearningServices Management - This package contains Microsoft Azure SDK for MachineLearningServices Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. These APIs allow end users to operate on Azure Machine Learning Workspace resources. Package tag package-2021-04-01. - https://github.com/Azure/azure-sdk-for-java + Microsoft Azure SDK for MachineLearningServices Management + This package contains Microsoft Azure SDK for MachineLearningServices Management SDK. For documentation on how to use this package, please see https://aka.ms/azsdk/java/mgmt. These APIs allow end users to operate on Azure Machine Learning Workspace resources. Package tag package-2021-07-01. + 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 - - - - com.azure - azure-core - 1.28.0 - - - com.azure - azure-core-management - 1.6.0 - - + + 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 + + + + com.azure + azure-core + 1.28.0 + + + com.azure + azure-core-management + 1.6.0 + + diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/MachineLearningServicesManager.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/MachineLearningServicesManager.java index 1c9aaf51e0be9..12fa341b3d235 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/MachineLearningServicesManager.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/MachineLearningServicesManager.java @@ -8,53 +8,51 @@ 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.AddHeadersFromContextPolicy; import com.azure.core.http.policy.HttpLogOptions; import com.azure.core.http.policy.HttpLoggingPolicy; import com.azure.core.http.policy.HttpPipelinePolicy; import com.azure.core.http.policy.HttpPolicyProviders; import com.azure.core.http.policy.RequestIdPolicy; +import com.azure.core.http.policy.RetryOptions; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; +import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy; import com.azure.core.management.profile.AzureProfile; import com.azure.core.util.Configuration; import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.AzureMachineLearningWorkspaces; import com.azure.resourcemanager.machinelearningservices.implementation.AzureMachineLearningWorkspacesBuilder; -import com.azure.resourcemanager.machinelearningservices.implementation.MachineLearningComputesImpl; -import com.azure.resourcemanager.machinelearningservices.implementation.MachineLearningServicesImpl; -import com.azure.resourcemanager.machinelearningservices.implementation.NotebooksImpl; +import com.azure.resourcemanager.machinelearningservices.implementation.ComputesImpl; import com.azure.resourcemanager.machinelearningservices.implementation.OperationsImpl; import com.azure.resourcemanager.machinelearningservices.implementation.PrivateEndpointConnectionsImpl; import com.azure.resourcemanager.machinelearningservices.implementation.PrivateLinkResourcesImpl; import com.azure.resourcemanager.machinelearningservices.implementation.QuotasImpl; -import com.azure.resourcemanager.machinelearningservices.implementation.StorageAccountsImpl; import com.azure.resourcemanager.machinelearningservices.implementation.UsagesImpl; import com.azure.resourcemanager.machinelearningservices.implementation.VirtualMachineSizesImpl; import com.azure.resourcemanager.machinelearningservices.implementation.WorkspaceConnectionsImpl; import com.azure.resourcemanager.machinelearningservices.implementation.WorkspaceFeaturesImpl; -import com.azure.resourcemanager.machinelearningservices.implementation.WorkspaceOperationsImpl; +import com.azure.resourcemanager.machinelearningservices.implementation.WorkspaceSkusImpl; import com.azure.resourcemanager.machinelearningservices.implementation.WorkspacesImpl; -import com.azure.resourcemanager.machinelearningservices.models.MachineLearningComputes; -import com.azure.resourcemanager.machinelearningservices.models.MachineLearningServices; -import com.azure.resourcemanager.machinelearningservices.models.Notebooks; +import com.azure.resourcemanager.machinelearningservices.models.Computes; import com.azure.resourcemanager.machinelearningservices.models.Operations; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnections; import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkResources; import com.azure.resourcemanager.machinelearningservices.models.Quotas; -import com.azure.resourcemanager.machinelearningservices.models.StorageAccounts; import com.azure.resourcemanager.machinelearningservices.models.Usages; import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineSizes; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnections; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceFeatures; -import com.azure.resourcemanager.machinelearningservices.models.WorkspaceOperations; +import com.azure.resourcemanager.machinelearningservices.models.WorkspaceSkus; import com.azure.resourcemanager.machinelearningservices.models.Workspaces; 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 MachineLearningServicesManager. These APIs allow end users to operate on Azure Machine Learning @@ -65,29 +63,23 @@ public final class MachineLearningServicesManager { private Workspaces workspaces; - private WorkspaceFeatures workspaceFeatures; - private Usages usages; private VirtualMachineSizes virtualMachineSizes; private Quotas quotas; - private MachineLearningComputes machineLearningComputes; - - private WorkspaceOperations workspaceOperations; + private Computes computes; private PrivateEndpointConnections privateEndpointConnections; private PrivateLinkResources privateLinkResources; - private MachineLearningServices machineLearningServices; - - private Notebooks notebooks; + private WorkspaceConnections workspaceConnections; - private StorageAccounts storageAccounts; + private WorkspaceFeatures workspaceFeatures; - private WorkspaceConnections workspaceConnections; + private WorkspaceSkus workspaceSkus; private final AzureMachineLearningWorkspaces clientObject; @@ -117,6 +109,19 @@ public static MachineLearningServicesManager authenticate(TokenCredential creden return configure().authenticate(credential, profile); } + /** + * Creates an instance of MachineLearningServices service API entry point. + * + * @param httpPipeline the {@link HttpPipeline} configured with Azure authentication credential. + * @param profile the Azure profile for client. + * @return the MachineLearningServices service API instance. + */ + public static MachineLearningServicesManager authenticate(HttpPipeline httpPipeline, AzureProfile profile) { + Objects.requireNonNull(httpPipeline, "'httpPipeline' cannot be null."); + Objects.requireNonNull(profile, "'profile' cannot be null."); + return new MachineLearningServicesManager(httpPipeline, profile, null); + } + /** * Gets a Configurable instance that can be used to create MachineLearningServicesManager with optional * configuration. @@ -129,12 +134,14 @@ public static Configurable configure() { /** The Configurable allowing configurations to be set. */ public static final class Configurable { - private final ClientLogger logger = new ClientLogger(Configurable.class); + private static final ClientLogger LOGGER = new ClientLogger(Configurable.class); private HttpClient httpClient; private HttpLogOptions httpLogOptions; private final List policies = new ArrayList<>(); + private final List scopes = new ArrayList<>(); private RetryPolicy retryPolicy; + private RetryOptions retryOptions; private Duration defaultPollInterval; private Configurable() { @@ -173,6 +180,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. * @@ -184,6 +202,19 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) { return this; } + /** + * Sets the retry options for the HTTP pipeline retry policy. + * + *

This setting has no effect, if retry policy is set via {@link #withRetryPolicy(RetryPolicy)}. + * + * @param retryOptions the retry options for the HTTP pipeline retry policy. + * @return the configurable object itself. + */ + public Configurable withRetryOptions(RetryOptions retryOptions) { + this.retryOptions = Objects.requireNonNull(retryOptions, "'retryOptions' cannot be null."); + return this; + } + /** * Sets the default poll interval, used when service does not provide "Retry-After" header. * @@ -191,9 +222,11 @@ public Configurable withRetryPolicy(RetryPolicy retryPolicy) { * @return the configurable object itself. */ public Configurable withDefaultPollInterval(Duration defaultPollInterval) { - this.defaultPollInterval = Objects.requireNonNull(defaultPollInterval, "'retryPolicy' cannot be null."); + this.defaultPollInterval = + Objects.requireNonNull(defaultPollInterval, "'defaultPollInterval' cannot be null."); if (this.defaultPollInterval.isNegative()) { - throw logger.logExceptionAsError(new IllegalArgumentException("'httpPipeline' cannot be negative")); + throw LOGGER + .logExceptionAsError(new IllegalArgumentException("'defaultPollInterval' cannot be negative")); } return this; } @@ -229,20 +262,38 @@ public MachineLearningServicesManager authenticate(TokenCredential credential, A userAgentBuilder.append(" (auto-generated)"); } + if (scopes.isEmpty()) { + scopes.add(profile.getEnvironment().getManagementEndpoint() + "/.default"); + } if (retryPolicy == null) { - retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + if (retryOptions != null) { + retryPolicy = new RetryPolicy(retryOptions); + } else { + retryPolicy = new RetryPolicy("Retry-After", ChronoUnit.SECONDS); + } } List policies = new ArrayList<>(); policies.add(new UserAgentPolicy(userAgentBuilder.toString())); + policies.add(new AddHeadersFromContextPolicy()); policies.add(new RequestIdPolicy()); + policies + .addAll( + 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 = @@ -254,7 +305,11 @@ public MachineLearningServicesManager authenticate(TokenCredential credential, A } } - /** @return Resource collection API of Operations. */ + /** + * Gets the resource collection API of Operations. + * + * @return Resource collection API of Operations. + */ public Operations operations() { if (this.operations == null) { this.operations = new OperationsImpl(clientObject.getOperations(), this); @@ -262,7 +317,11 @@ public Operations operations() { return operations; } - /** @return Resource collection API of Workspaces. */ + /** + * Gets the resource collection API of Workspaces. + * + * @return Resource collection API of Workspaces. + */ public Workspaces workspaces() { if (this.workspaces == null) { this.workspaces = new WorkspacesImpl(clientObject.getWorkspaces(), this); @@ -270,15 +329,11 @@ public Workspaces workspaces() { return workspaces; } - /** @return Resource collection API of WorkspaceFeatures. */ - public WorkspaceFeatures workspaceFeatures() { - if (this.workspaceFeatures == null) { - this.workspaceFeatures = new WorkspaceFeaturesImpl(clientObject.getWorkspaceFeatures(), this); - } - return workspaceFeatures; - } - - /** @return Resource collection API of Usages. */ + /** + * Gets the resource collection API of Usages. + * + * @return Resource collection API of Usages. + */ public Usages usages() { if (this.usages == null) { this.usages = new UsagesImpl(clientObject.getUsages(), this); @@ -286,7 +341,11 @@ public Usages usages() { return usages; } - /** @return Resource collection API of VirtualMachineSizes. */ + /** + * Gets the resource collection API of VirtualMachineSizes. + * + * @return Resource collection API of VirtualMachineSizes. + */ public VirtualMachineSizes virtualMachineSizes() { if (this.virtualMachineSizes == null) { this.virtualMachineSizes = new VirtualMachineSizesImpl(clientObject.getVirtualMachineSizes(), this); @@ -294,7 +353,11 @@ public VirtualMachineSizes virtualMachineSizes() { return virtualMachineSizes; } - /** @return Resource collection API of Quotas. */ + /** + * Gets the resource collection API of Quotas. + * + * @return Resource collection API of Quotas. + */ public Quotas quotas() { if (this.quotas == null) { this.quotas = new QuotasImpl(clientObject.getQuotas(), this); @@ -302,24 +365,23 @@ public Quotas quotas() { return quotas; } - /** @return Resource collection API of MachineLearningComputes. */ - public MachineLearningComputes machineLearningComputes() { - if (this.machineLearningComputes == null) { - this.machineLearningComputes = - new MachineLearningComputesImpl(clientObject.getMachineLearningComputes(), this); - } - return machineLearningComputes; - } - - /** @return Resource collection API of WorkspaceOperations. */ - public WorkspaceOperations workspaceOperations() { - if (this.workspaceOperations == null) { - this.workspaceOperations = new WorkspaceOperationsImpl(clientObject.getWorkspaceOperations(), this); + /** + * Gets the resource collection API of Computes. + * + * @return Resource collection API of Computes. + */ + public Computes computes() { + if (this.computes == null) { + this.computes = new ComputesImpl(clientObject.getComputes(), this); } - return workspaceOperations; + return computes; } - /** @return Resource collection API of PrivateEndpointConnections. */ + /** + * Gets the resource collection API of PrivateEndpointConnections. + * + * @return Resource collection API of PrivateEndpointConnections. + */ public PrivateEndpointConnections privateEndpointConnections() { if (this.privateEndpointConnections == null) { this.privateEndpointConnections = @@ -328,7 +390,11 @@ public PrivateEndpointConnections privateEndpointConnections() { return privateEndpointConnections; } - /** @return Resource collection API of PrivateLinkResources. */ + /** + * Gets the resource collection API of PrivateLinkResources. + * + * @return Resource collection API of PrivateLinkResources. + */ public PrivateLinkResources privateLinkResources() { if (this.privateLinkResources == null) { this.privateLinkResources = new PrivateLinkResourcesImpl(clientObject.getPrivateLinkResources(), this); @@ -336,37 +402,40 @@ public PrivateLinkResources privateLinkResources() { return privateLinkResources; } - /** @return Resource collection API of MachineLearningServices. */ - public MachineLearningServices machineLearningServices() { - if (this.machineLearningServices == null) { - this.machineLearningServices = - new MachineLearningServicesImpl(clientObject.getMachineLearningServices(), this); - } - return machineLearningServices; - } - - /** @return Resource collection API of Notebooks. */ - public Notebooks notebooks() { - if (this.notebooks == null) { - this.notebooks = new NotebooksImpl(clientObject.getNotebooks(), this); + /** + * Gets the resource collection API of WorkspaceConnections. + * + * @return Resource collection API of WorkspaceConnections. + */ + public WorkspaceConnections workspaceConnections() { + if (this.workspaceConnections == null) { + this.workspaceConnections = new WorkspaceConnectionsImpl(clientObject.getWorkspaceConnections(), this); } - return notebooks; + return workspaceConnections; } - /** @return Resource collection API of StorageAccounts. */ - public StorageAccounts storageAccounts() { - if (this.storageAccounts == null) { - this.storageAccounts = new StorageAccountsImpl(clientObject.getStorageAccounts(), this); + /** + * Gets the resource collection API of WorkspaceFeatures. + * + * @return Resource collection API of WorkspaceFeatures. + */ + public WorkspaceFeatures workspaceFeatures() { + if (this.workspaceFeatures == null) { + this.workspaceFeatures = new WorkspaceFeaturesImpl(clientObject.getWorkspaceFeatures(), this); } - return storageAccounts; + return workspaceFeatures; } - /** @return Resource collection API of WorkspaceConnections. */ - public WorkspaceConnections workspaceConnections() { - if (this.workspaceConnections == null) { - this.workspaceConnections = new WorkspaceConnectionsImpl(clientObject.getWorkspaceConnections(), this); + /** + * Gets the resource collection API of WorkspaceSkus. + * + * @return Resource collection API of WorkspaceSkus. + */ + public WorkspaceSkus workspaceSkus() { + if (this.workspaceSkus == null) { + this.workspaceSkus = new WorkspaceSkusImpl(clientObject.getWorkspaceSkus(), this); } - return workspaceConnections; + return workspaceSkus; } /** diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/AzureMachineLearningWorkspaces.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/AzureMachineLearningWorkspaces.java index af14f5759361b..c2ab163750abc 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/AzureMachineLearningWorkspaces.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/AzureMachineLearningWorkspaces.java @@ -10,7 +10,7 @@ /** The interface for AzureMachineLearningWorkspaces class. */ public interface AzureMachineLearningWorkspaces { /** - * Gets Azure subscription identifier. + * Gets The ID of the target subscription. * * @return the subscriptionId value. */ @@ -58,13 +58,6 @@ public interface AzureMachineLearningWorkspaces { */ WorkspacesClient getWorkspaces(); - /** - * Gets the WorkspaceFeaturesClient object to access its operations. - * - * @return the WorkspaceFeaturesClient object. - */ - WorkspaceFeaturesClient getWorkspaceFeatures(); - /** * Gets the UsagesClient object to access its operations. * @@ -87,18 +80,11 @@ public interface AzureMachineLearningWorkspaces { QuotasClient getQuotas(); /** - * Gets the MachineLearningComputesClient object to access its operations. - * - * @return the MachineLearningComputesClient object. - */ - MachineLearningComputesClient getMachineLearningComputes(); - - /** - * Gets the WorkspaceOperationsClient object to access its operations. + * Gets the ComputesClient object to access its operations. * - * @return the WorkspaceOperationsClient object. + * @return the ComputesClient object. */ - WorkspaceOperationsClient getWorkspaceOperations(); + ComputesClient getComputes(); /** * Gets the PrivateEndpointConnectionsClient object to access its operations. @@ -115,30 +101,23 @@ public interface AzureMachineLearningWorkspaces { PrivateLinkResourcesClient getPrivateLinkResources(); /** - * Gets the MachineLearningServicesClient object to access its operations. - * - * @return the MachineLearningServicesClient object. - */ - MachineLearningServicesClient getMachineLearningServices(); - - /** - * Gets the NotebooksClient object to access its operations. + * Gets the WorkspaceConnectionsClient object to access its operations. * - * @return the NotebooksClient object. + * @return the WorkspaceConnectionsClient object. */ - NotebooksClient getNotebooks(); + WorkspaceConnectionsClient getWorkspaceConnections(); /** - * Gets the StorageAccountsClient object to access its operations. + * Gets the WorkspaceFeaturesClient object to access its operations. * - * @return the StorageAccountsClient object. + * @return the WorkspaceFeaturesClient object. */ - StorageAccountsClient getStorageAccounts(); + WorkspaceFeaturesClient getWorkspaceFeatures(); /** - * Gets the WorkspaceConnectionsClient object to access its operations. + * Gets the WorkspaceSkusClient object to access its operations. * - * @return the WorkspaceConnectionsClient object. + * @return the WorkspaceSkusClient object. */ - WorkspaceConnectionsClient getWorkspaceConnections(); + WorkspaceSkusClient getWorkspaceSkus(); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningComputesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/ComputesClient.java similarity index 78% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningComputesClient.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/ComputesClient.java index b07cc7e45a959..e7875660d0c8a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningComputesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/ComputesClient.java @@ -17,42 +17,42 @@ import com.azure.resourcemanager.machinelearningservices.models.ClusterUpdateParameters; import com.azure.resourcemanager.machinelearningservices.models.UnderlyingResourceAction; -/** An instance of this class provides access to all the operations defined in MachineLearningComputesClient. */ -public interface MachineLearningComputesClient { +/** An instance of this class provides access to all the operations defined in ComputesClient. */ +public interface ComputesClient { /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listByWorkspace(String resourceGroupName, String workspaceName); + PagedIterable list(String resourceGroupName, String workspaceName); /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listByWorkspace( + PagedIterable list( String resourceGroupName, String workspaceName, String skip, Context context); /** * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -67,14 +67,14 @@ PagedIterable listByWorkspace( * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getWithResponse( @@ -84,16 +84,16 @@ Response getWithResponse( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, ComputeResourceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, String computeName, ComputeResourceInner parameters); @@ -101,7 +101,7 @@ SyncPoller, ComputeResourceInner> beginCreateOr * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -109,9 +109,9 @@ SyncPoller, ComputeResourceInner> beginCreateOr * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, ComputeResourceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, @@ -123,7 +123,7 @@ SyncPoller, ComputeResourceInner> beginCreateOr * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -140,7 +140,7 @@ ComputeResourceInner createOrUpdate( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -162,16 +162,16 @@ ComputeResourceInner createOrUpdate( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, ComputeResourceInner> beginUpdate( String resourceGroupName, String workspaceName, String computeName, ClusterUpdateParameters parameters); @@ -179,7 +179,7 @@ SyncPoller, ComputeResourceInner> beginUpdate( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -187,9 +187,9 @@ SyncPoller, ComputeResourceInner> beginUpdate( * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, ComputeResourceInner> beginUpdate( String resourceGroupName, String workspaceName, @@ -201,7 +201,7 @@ SyncPoller, ComputeResourceInner> beginUpdate( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -218,7 +218,7 @@ ComputeResourceInner update( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -239,7 +239,7 @@ ComputeResourceInner update( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -247,9 +247,9 @@ ComputeResourceInner update( * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -259,7 +259,7 @@ SyncPoller, Void> beginDelete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -268,9 +268,9 @@ SyncPoller, Void> beginDelete( * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -281,7 +281,7 @@ SyncPoller, Void> beginDelete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -300,7 +300,7 @@ void delete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -321,13 +321,14 @@ void delete( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listNodes( @@ -336,14 +337,15 @@ PagedIterable listNodes( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listNodes( @@ -352,7 +354,7 @@ PagedIterable listNodes( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -366,14 +368,15 @@ PagedIterable listNodes( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listKeysWithResponse( @@ -382,37 +385,37 @@ Response listKeysWithResponse( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStart(String resourceGroupName, String workspaceName, String computeName); /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStart( String resourceGroupName, String workspaceName, String computeName, Context context); /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -425,7 +428,7 @@ SyncPoller, Void> beginStart( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -439,37 +442,37 @@ SyncPoller, Void> beginStart( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStop(String resourceGroupName, String workspaceName, String computeName); /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginStop( String resourceGroupName, String workspaceName, String computeName, Context context); /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -482,7 +485,7 @@ SyncPoller, Void> beginStop( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -496,7 +499,37 @@ SyncPoller, Void> beginStop( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, Void> beginRestart(String resourceGroupName, String workspaceName, String computeName); + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, Void> beginRestart( + String resourceGroupName, String workspaceName, String computeName, Context context); + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -509,16 +542,14 @@ SyncPoller, Void> beginStop( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response restartWithResponse( - String resourceGroupName, String workspaceName, String computeName, Context context); + void restart(String resourceGroupName, String workspaceName, String computeName, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningServicesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningServicesClient.java deleted file mode 100644 index ae52246e89b26..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningServicesClient.java +++ /dev/null @@ -1,207 +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.machinelearningservices.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.machinelearningservices.fluent.models.ServiceResourceInner; -import com.azure.resourcemanager.machinelearningservices.models.CreateServiceRequest; -import com.azure.resourcemanager.machinelearningservices.models.OrderString; - -/** An instance of this class provides access to all the operations defined in MachineLearningServicesClient. */ -public interface MachineLearningServicesClient { - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listByWorkspace(String resourceGroupName, String workspaceName); - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listByWorkspace( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - Context context); - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ServiceResourceInner get(String resourceGroupName, String workspaceName, String serviceName); - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - Response getWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand, Context context); - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @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 workspaceName, String serviceName); - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - Response deleteWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Context context); - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - SyncPoller, ServiceResourceInner> beginCreateOrUpdate( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties); - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - SyncPoller, ServiceResourceInner> beginCreateOrUpdate( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context); - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ServiceResourceInner createOrUpdate( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties); - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ServiceResourceInner createOrUpdate( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/NotebooksClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/NotebooksClient.java deleted file mode 100644 index 2e926970ec64f..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/NotebooksClient.java +++ /dev/null @@ -1,89 +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.machinelearningservices.fluent; - -import com.azure.core.annotation.ReturnType; -import com.azure.core.annotation.ServiceMethod; -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.machinelearningservices.fluent.models.ListNotebookKeysResultInner; -import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; - -/** An instance of this class provides access to all the operations defined in NotebooksClient. */ -public interface NotebooksClient { - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - SyncPoller, NotebookResourceInfoInner> beginPrepare( - String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - SyncPoller, NotebookResourceInfoInner> beginPrepare( - String resourceGroupName, String workspaceName, Context context); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - NotebookResourceInfoInner prepare(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - NotebookResourceInfoInner prepare(String resourceGroupName, String workspaceName, Context context); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ListNotebookKeysResultInner listKeys(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/OperationsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/OperationsClient.java index e6a69f11283d7..2c5539b063908 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/OperationsClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/OperationsClient.java @@ -17,7 +17,8 @@ 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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(); @@ -29,7 +30,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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateEndpointConnectionsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateEndpointConnectionsClient.java index 28c1ae7879899..1242791f92cf7 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateEndpointConnectionsClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateEndpointConnectionsClient.java @@ -6,16 +6,46 @@ import com.azure.core.annotation.ReturnType; import com.azure.core.annotation.ServiceMethod; +import com.azure.core.http.rest.PagedIterable; import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; /** An instance of this class provides access to all the operations defined in PrivateEndpointConnectionsClient. */ public interface PrivateEndpointConnectionsClient { + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String workspaceName); + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + PagedIterable list(String resourceGroupName, String workspaceName, Context context); + /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -30,14 +60,14 @@ PrivateEndpointConnectionInner get( /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getWithResponse( @@ -46,7 +76,7 @@ Response getWithResponse( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. @@ -56,7 +86,7 @@ Response getWithResponse( * @return the Private Endpoint Connection resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - PrivateEndpointConnectionInner put( + PrivateEndpointConnectionInner createOrUpdate( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -65,7 +95,7 @@ PrivateEndpointConnectionInner put( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. @@ -73,10 +103,10 @@ PrivateEndpointConnectionInner put( * @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 Private Endpoint Connection resource. + * @return the Private Endpoint Connection resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response putWithResponse( + Response createOrUpdateWithResponse( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -86,7 +116,7 @@ Response putWithResponse( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -99,14 +129,14 @@ Response putWithResponse( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response deleteWithResponse( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateLinkResourcesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateLinkResourcesClient.java index 8ab1afdbdaeb9..9d84579f3bf54 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateLinkResourcesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateLinkResourcesClient.java @@ -15,7 +15,7 @@ public interface PrivateLinkResourcesClient { /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -23,20 +23,20 @@ public interface PrivateLinkResourcesClient { * @return the private link resources that need to be created for a workspace. */ @ServiceMethod(returns = ReturnType.SINGLE) - PrivateLinkResourceListResultInner listByWorkspace(String resourceGroupName, String workspaceName); + PrivateLinkResourceListResultInner list(String resourceGroupName, String workspaceName); /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response listByWorkspaceWithResponse( + Response listWithResponse( String resourceGroupName, String workspaceName, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/QuotasClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/QuotasClient.java index f551dd9813747..1e3026ff19b5c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/QuotasClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/QuotasClient.java @@ -37,7 +37,7 @@ public interface QuotasClient { * @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 result of update workspace quota. + * @return the result of update workspace quota along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response updateWithResponse( @@ -50,7 +50,8 @@ Response updateWithResponse( * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location); @@ -63,7 +64,8 @@ Response updateWithResponse( * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/StorageAccountsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/StorageAccountsClient.java deleted file mode 100644 index 95a577f1d77d0..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/StorageAccountsClient.java +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.fluent; - -import com.azure.core.annotation.ReturnType; -import com.azure.core.annotation.ServiceMethod; -import com.azure.core.http.rest.Response; -import com.azure.core.util.Context; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; - -/** An instance of this class provides access to all the operations defined in StorageAccountsClient. */ -public interface StorageAccountsClient { - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - ListStorageAccountKeysResultInner listKeys(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/UsagesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/UsagesClient.java index e76f4c9e04f8f..5af9b3a358e79 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/UsagesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/UsagesClient.java @@ -19,7 +19,8 @@ public interface UsagesClient { * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location); @@ -32,7 +33,8 @@ public interface UsagesClient { * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String location, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/VirtualMachineSizesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/VirtualMachineSizesClient.java index dc92a4a70f897..7b9e18ffac4c4 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/VirtualMachineSizesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/VirtualMachineSizesClient.java @@ -32,7 +32,7 @@ public interface VirtualMachineSizesClient { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listWithResponse(String location, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceConnectionsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceConnectionsClient.java index e595d0c2001b1..45137eddeccb6 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceConnectionsClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceConnectionsClient.java @@ -10,19 +10,18 @@ import com.azure.core.http.rest.Response; import com.azure.core.util.Context; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceConnectionInner; -import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnectionDto; /** An instance of this class provides access to all the operations defined in WorkspaceConnectionsClient. */ public interface WorkspaceConnectionsClient { /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String workspaceName); @@ -30,7 +29,7 @@ public interface WorkspaceConnectionsClient { /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -38,7 +37,7 @@ public interface WorkspaceConnectionsClient { * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list( @@ -47,7 +46,7 @@ PagedIterable list( /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. @@ -58,12 +57,12 @@ PagedIterable list( */ @ServiceMethod(returns = ReturnType.SINGLE) WorkspaceConnectionInner create( - String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionDto parameters); + String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionInner parameters); /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. @@ -71,20 +70,20 @@ WorkspaceConnectionInner create( * @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 workspace connection. + * @return workspace connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response createWithResponse( String resourceGroupName, String workspaceName, String connectionName, - WorkspaceConnectionDto parameters, + WorkspaceConnectionInner parameters, Context context); /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -98,14 +97,14 @@ Response createWithResponse( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @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 detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getWithResponse( @@ -114,7 +113,7 @@ Response getWithResponse( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -127,14 +126,14 @@ Response getWithResponse( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response deleteWithResponse( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceFeaturesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceFeaturesClient.java index f6451157bc19f..fd2c279b8dc0a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceFeaturesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceFeaturesClient.java @@ -15,12 +15,12 @@ public interface WorkspaceFeaturesClient { /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String workspaceName); @@ -28,13 +28,13 @@ public interface WorkspaceFeaturesClient { /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String resourceGroupName, String workspaceName, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceOperationsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceSkusClient.java similarity index 79% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceOperationsClient.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceSkusClient.java index 6cc8f4f463450..46269218ed93c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceOperationsClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceSkusClient.java @@ -10,17 +10,17 @@ import com.azure.core.util.Context; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceSkuInner; -/** An instance of this class provides access to all the operations defined in WorkspaceOperationsClient. */ -public interface WorkspaceOperationsClient { +/** An instance of this class provides access to all the operations defined in WorkspaceSkusClient. */ +public interface WorkspaceSkusClient { /** * Lists all skus with associated features. * * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listSkus(); + PagedIterable list(); /** * Lists all skus with associated features. @@ -29,8 +29,8 @@ public interface WorkspaceOperationsClient { * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listSkus(Context context); + PagedIterable list(Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspacesClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspacesClient.java index f412c73fd058b..521380e3de751 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspacesClient.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspacesClient.java @@ -11,9 +11,15 @@ import com.azure.core.management.polling.PollResult; import com.azure.core.util.Context; import com.azure.core.util.polling.SyncPoller; +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListNotebookKeysResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.ListWorkspaceKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookAccessTokenResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceInner; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceUpdateParameters; /** An instance of this class provides access to all the operations defined in WorkspacesClient. */ @@ -21,7 +27,7 @@ public interface WorkspacesClient { /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -34,13 +40,13 @@ public interface WorkspacesClient { /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response getByResourceGroupWithResponse( @@ -49,38 +55,38 @@ Response getByResourceGroupWithResponse( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link SyncPoller} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, WorkspaceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, WorkspaceInner parameters); /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link SyncPoller} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, WorkspaceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, WorkspaceInner parameters, Context context); /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -94,7 +100,7 @@ SyncPoller, WorkspaceInner> beginCreateOrUpdate( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. @@ -110,34 +116,34 @@ WorkspaceInner createOrUpdate( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete(String resourceGroupName, String workspaceName); /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginDelete(String resourceGroupName, String workspaceName, Context context); /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -149,7 +155,7 @@ WorkspaceInner createOrUpdate( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -162,7 +168,7 @@ WorkspaceInner createOrUpdate( /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -176,14 +182,14 @@ WorkspaceInner createOrUpdate( /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response updateWithResponse( @@ -192,11 +198,12 @@ Response updateWithResponse( /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByResourceGroup(String resourceGroupName); @@ -204,22 +211,98 @@ Response updateWithResponse( /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listByResourceGroup(String resourceGroupName, String skip, Context context); + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, DiagnoseResponseResultInner> beginDiagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, DiagnoseResponseResultInner> beginDiagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + DiagnoseResponseResultInner diagnose(String resourceGroupName, String workspaceName); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context); + /** * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -233,13 +316,13 @@ Response updateWithResponse( * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listKeysWithResponse( @@ -249,36 +332,36 @@ Response listKeysWithResponse( * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginResyncKeys(String resourceGroupName, String workspaceName); /** * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) SyncPoller, Void> beginResyncKeys(String resourceGroupName, String workspaceName, Context context); /** * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -291,7 +374,7 @@ Response listKeysWithResponse( * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -306,7 +389,8 @@ Response listKeysWithResponse( * * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(); @@ -319,7 +403,8 @@ Response listKeysWithResponse( * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable list(String skip, Context context); @@ -327,7 +412,7 @@ Response listKeysWithResponse( /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -340,15 +425,155 @@ Response listKeysWithResponse( /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) Response listNotebookAccessTokenWithResponse( String resourceGroupName, String workspaceName, Context context); + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, NotebookResourceInfoInner> beginPrepareNotebook( + String resourceGroupName, String workspaceName); + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + SyncPoller, NotebookResourceInfoInner> beginPrepareNotebook( + String resourceGroupName, String workspaceName, Context context); + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + NotebookResourceInfoInner prepareNotebook(String resourceGroupName, String workspaceName); + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + NotebookResourceInfoInner prepareNotebook(String resourceGroupName, String workspaceName, Context context); + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + ListStorageAccountKeysResultInner listStorageAccountKeys(String resourceGroupName, String workspaceName); + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response listStorageAccountKeysWithResponse( + String resourceGroupName, String workspaceName, Context context); + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + ListNotebookKeysResultInner listNotebookKeys(String resourceGroupName, String workspaceName); + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response listNotebookKeysWithResponse( + String resourceGroupName, String workspaceName, Context context); + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + ExternalFqdnResponseInner listOutboundNetworkDependenciesEndpoints(String resourceGroupName, String workspaceName); + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + Response listOutboundNetworkDependenciesEndpointsWithResponse( + String resourceGroupName, String workspaceName, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/AmlUserFeatureInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/AmlUserFeatureInner.java index 0c10295210b25..338b584931bb2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/AmlUserFeatureInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/AmlUserFeatureInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Features enabled for a workspace. */ @Fluent public final class AmlUserFeatureInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlUserFeatureInner.class); - /* * Specifies the feature ID */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ClusterUpdateProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ClusterUpdateProperties.java new file mode 100644 index 0000000000000..8a2ccba92361a --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ClusterUpdateProperties.java @@ -0,0 +1,50 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettingsInformation; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The properties of a amlCompute that need to be updated. */ +@Fluent +public final class ClusterUpdateProperties { + /* + * Properties of ClusterUpdate + */ + @JsonProperty(value = "properties") + private ScaleSettingsInformation properties; + + /** + * Get the properties property: Properties of ClusterUpdate. + * + * @return the properties value. + */ + public ScaleSettingsInformation properties() { + return this.properties; + } + + /** + * Set the properties property: Properties of ClusterUpdate. + * + * @param properties the properties value to set. + * @return the ClusterUpdateProperties object itself. + */ + public ClusterUpdateProperties withProperties(ScaleSettingsInformation properties) { + this.properties = properties; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (properties() != null) { + properties().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeResourceInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeResourceInner.java index 30285709c7152..d810d08c43fe8 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeResourceInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeResourceInner.java @@ -5,32 +5,36 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.management.Resource; +import com.azure.core.management.ProxyResource; import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.Compute; import com.azure.resourcemanager.machinelearningservices.models.Identity; import com.azure.resourcemanager.machinelearningservices.models.Sku; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; /** Machine Learning compute object wrapped into ARM resource envelope. */ @Fluent -public final class ComputeResourceInner extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeResourceInner.class); +public final class ComputeResourceInner extends ProxyResource { + /* + * The identity of the resource. + */ + @JsonProperty(value = "identity") + private Identity identity; /* - * Compute properties + * Specifies the location of the resource. */ - @JsonProperty(value = "properties") - private Compute properties; + @JsonProperty(value = "location") + private String location; /* - * The identity of the resource. + * Contains resource tags defined as key/value pairs. */ - @JsonProperty(value = "identity") - private Identity identity; + @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map tags; /* * The sku of the workspace. @@ -39,48 +43,74 @@ public final class ComputeResourceInner extends Resource { private Sku sku; /* - * Read only system data + * System data */ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) private SystemData systemData; + /* + * Compute properties + */ + @JsonProperty(value = "properties") + private Compute properties; + /** - * Get the properties property: Compute properties. + * Get the identity property: The identity of the resource. * - * @return the properties value. + * @return the identity value. */ - public Compute properties() { - return this.properties; + public Identity identity() { + return this.identity; } /** - * Set the properties property: Compute properties. + * Set the identity property: The identity of the resource. * - * @param properties the properties value to set. + * @param identity the identity value to set. * @return the ComputeResourceInner object itself. */ - public ComputeResourceInner withProperties(Compute properties) { - this.properties = properties; + public ComputeResourceInner withIdentity(Identity identity) { + this.identity = identity; return this; } /** - * Get the identity property: The identity of the resource. + * Get the location property: Specifies the location of the resource. * - * @return the identity value. + * @return the location value. */ - public Identity identity() { - return this.identity; + public String location() { + return this.location; } /** - * Set the identity property: The identity of the resource. + * Set the location property: Specifies the location of the resource. * - * @param identity the identity value to set. + * @param location the location value to set. * @return the ComputeResourceInner object itself. */ - public ComputeResourceInner withIdentity(Identity identity) { - this.identity = identity; + public ComputeResourceInner withLocation(String location) { + this.location = location; + return this; + } + + /** + * Get the tags property: Contains resource tags defined as key/value pairs. + * + * @return the tags value. + */ + public Map tags() { + return this.tags; + } + + /** + * Set the tags property: Contains resource tags defined as key/value pairs. + * + * @param tags the tags value to set. + * @return the ComputeResourceInner object itself. + */ + public ComputeResourceInner withTags(Map tags) { + this.tags = tags; return this; } @@ -105,7 +135,7 @@ public ComputeResourceInner withSku(Sku sku) { } /** - * Get the systemData property: Read only system data. + * Get the systemData property: System data. * * @return the systemData value. */ @@ -113,17 +143,23 @@ public SystemData systemData() { return this.systemData; } - /** {@inheritDoc} */ - @Override - public ComputeResourceInner withLocation(String location) { - super.withLocation(location); - return this; + /** + * Get the properties property: Compute properties. + * + * @return the properties value. + */ + public Compute properties() { + return this.properties; } - /** {@inheritDoc} */ - @Override - public ComputeResourceInner withTags(Map tags) { - super.withTags(tags); + /** + * Set the properties property: Compute properties. + * + * @param properties the properties value to set. + * @return the ComputeResourceInner object itself. + */ + public ComputeResourceInner withProperties(Compute properties) { + this.properties = properties; return this; } @@ -133,14 +169,14 @@ public ComputeResourceInner withTags(Map tags) { * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (properties() != null) { - properties().validate(); - } if (identity() != null) { identity().validate(); } if (sku() != null) { sku().validate(); } + if (properties() != null) { + properties().validate(); + } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeSecretsInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeSecretsInner.java index b789485a28a3d..dc65d739a4dd2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeSecretsInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ComputeSecretsInner.java @@ -5,11 +5,9 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.AksComputeSecrets; import com.azure.resourcemanager.machinelearningservices.models.DatabricksComputeSecrets; import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineSecrets; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -28,8 +26,6 @@ }) @Immutable public class ComputeSecretsInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeSecretsInner.class); - /** * Validates the instance. * diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/DiagnoseResponseResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/DiagnoseResponseResultInner.java new file mode 100644 index 0000000000000..57ac8a4343b1a --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/DiagnoseResponseResultInner.java @@ -0,0 +1,50 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResultValue; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The DiagnoseResponseResult model. */ +@Fluent +public final class DiagnoseResponseResultInner { + /* + * The value property. + */ + @JsonProperty(value = "value") + private DiagnoseResponseResultValue value; + + /** + * Get the value property: The value property. + * + * @return the value value. + */ + public DiagnoseResponseResultValue value() { + return this.value; + } + + /** + * Set the value property: The value property. + * + * @param value the value value to set. + * @return the DiagnoseResponseResultInner object itself. + */ + public DiagnoseResponseResultInner withValue(DiagnoseResponseResultValue value) { + this.value = value; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (value() != null) { + value().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ExternalFqdnResponseInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ExternalFqdnResponseInner.java new file mode 100644 index 0000000000000..7078960a2e01f --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ExternalFqdnResponseInner.java @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.FqdnEndpoints; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The ExternalFqdnResponse model. */ +@Fluent +public final class ExternalFqdnResponseInner { + /* + * The value property. + */ + @JsonProperty(value = "value") + private List value; + + /** + * Get the value property: The value property. + * + * @return the value value. + */ + public List value() { + return this.value; + } + + /** + * Set the value property: The value property. + * + * @param value the value value to set. + * @return the ExternalFqdnResponseInner object itself. + */ + public ExternalFqdnResponseInner withValue(List value) { + this.value = value; + 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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListNotebookKeysResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListNotebookKeysResultInner.java index 08a36edd74025..12cd43f32f503 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListNotebookKeysResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListNotebookKeysResultInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The ListNotebookKeysResult model. */ @Immutable public final class ListNotebookKeysResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListNotebookKeysResultInner.class); - /* * The primaryAccessKey property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListStorageAccountKeysResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListStorageAccountKeysResultInner.java index 1566c723c8806..43d9ffdbc7b3d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListStorageAccountKeysResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListStorageAccountKeysResultInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The ListStorageAccountKeysResult model. */ @Immutable public final class ListStorageAccountKeysResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListStorageAccountKeysResultInner.class); - /* * The userStorageKey property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListWorkspaceKeysResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListWorkspaceKeysResultInner.java index 4302d6c695bb7..d9b82c5c20266 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListWorkspaceKeysResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ListWorkspaceKeysResultInner.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.RegistryListCredentialsResult; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The ListWorkspaceKeysResult model. */ @Immutable public final class ListWorkspaceKeysResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListWorkspaceKeysResultInner.class); - /* * The userStorageKey property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookAccessTokenResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookAccessTokenResultInner.java index 9d42615915f6e..1f31e9a9712dd 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookAccessTokenResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookAccessTokenResultInner.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The NotebookAccessTokenResult model. */ @Immutable public final class NotebookAccessTokenResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NotebookAccessTokenResultInner.class); - /* * The notebookResourceId property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookResourceInfoInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookResourceInfoInner.java index 540740e101ab6..a14e6ebd2ba35 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookResourceInfoInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/NotebookResourceInfoInner.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.NotebookPreparationError; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The NotebookResourceInfo model. */ @Fluent public final class NotebookResourceInfoInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NotebookResourceInfoInner.class); - /* * The fqdn property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/OperationInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/OperationInner.java index 44ee8df486ac2..62b37ef4e6bb3 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/OperationInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/OperationInner.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.OperationDisplay; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Azure Machine Learning workspace REST API operation. */ @Fluent public final class OperationInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationInner.class); - /* * Operation name: {provider}/{resource}/{operation} */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionInner.java index 3334cc9a86e15..5bdb8ee0684c2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionInner.java @@ -5,49 +5,44 @@ package com.azure.resourcemanager.machinelearningservices.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.ProxyResource; import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.Identity; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpoint; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnectionProvisioningState; import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkServiceConnectionState; import com.azure.resourcemanager.machinelearningservices.models.Sku; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; /** The Private Endpoint Connection resource. */ -@JsonFlatten @Fluent -public class PrivateEndpointConnectionInner extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionInner.class); - +public final class PrivateEndpointConnectionInner extends ProxyResource { /* - * The resource of private end point. + * Resource properties. */ - @JsonProperty(value = "properties.privateEndpoint") - private PrivateEndpoint privateEndpoint; + @JsonProperty(value = "properties") + private PrivateEndpointConnectionProperties innerProperties; /* - * A collection of information about the state of the connection between - * service consumer and provider. + * The identity of the resource. */ - @JsonProperty(value = "properties.privateLinkServiceConnectionState") - private PrivateLinkServiceConnectionState privateLinkServiceConnectionState; + @JsonProperty(value = "identity") + private Identity identity; /* - * The provisioning state of the private endpoint connection resource. + * Specifies the location of the resource. */ - @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY) - private PrivateEndpointConnectionProvisioningState provisioningState; + @JsonProperty(value = "location") + private String location; /* - * The identity of the resource. + * Contains resource tags defined as key/value pairs. */ - @JsonProperty(value = "identity") - private Identity identity; + @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map tags; /* * The sku of the workspace. @@ -56,80 +51,77 @@ public class PrivateEndpointConnectionInner extends Resource { private Sku sku; /* - * Read only system data + * System data */ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) private SystemData systemData; /** - * Get the privateEndpoint property: The resource of private end point. + * Get the innerProperties property: Resource properties. * - * @return the privateEndpoint value. + * @return the innerProperties value. */ - public PrivateEndpoint privateEndpoint() { - return this.privateEndpoint; + private PrivateEndpointConnectionProperties innerProperties() { + return this.innerProperties; } /** - * Set the privateEndpoint property: The resource of private end point. + * Get the identity property: The identity of the resource. * - * @param privateEndpoint the privateEndpoint value to set. - * @return the PrivateEndpointConnectionInner object itself. + * @return the identity value. */ - public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privateEndpoint) { - this.privateEndpoint = privateEndpoint; - return this; + public Identity identity() { + return this.identity; } /** - * Get the privateLinkServiceConnectionState property: A collection of information about the state of the connection - * between service consumer and provider. + * Set the identity property: The identity of the resource. * - * @return the privateLinkServiceConnectionState value. + * @param identity the identity value to set. + * @return the PrivateEndpointConnectionInner object itself. */ - public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { - return this.privateLinkServiceConnectionState; + public PrivateEndpointConnectionInner withIdentity(Identity identity) { + this.identity = identity; + return this; } /** - * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection - * between service consumer and provider. + * Get the location property: Specifies the location of the resource. * - * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set. - * @return the PrivateEndpointConnectionInner object itself. + * @return the location value. */ - public PrivateEndpointConnectionInner withPrivateLinkServiceConnectionState( - PrivateLinkServiceConnectionState privateLinkServiceConnectionState) { - this.privateLinkServiceConnectionState = privateLinkServiceConnectionState; - return this; + public String location() { + return this.location; } /** - * Get the provisioningState property: The provisioning state of the private endpoint connection resource. + * Set the location property: Specifies the location of the resource. * - * @return the provisioningState value. + * @param location the location value to set. + * @return the PrivateEndpointConnectionInner object itself. */ - public PrivateEndpointConnectionProvisioningState provisioningState() { - return this.provisioningState; + public PrivateEndpointConnectionInner withLocation(String location) { + this.location = location; + return this; } /** - * Get the identity property: The identity of the resource. + * Get the tags property: Contains resource tags defined as key/value pairs. * - * @return the identity value. + * @return the tags value. */ - public Identity identity() { - return this.identity; + public Map tags() { + return this.tags; } /** - * Set the identity property: The identity of the resource. + * Set the tags property: Contains resource tags defined as key/value pairs. * - * @param identity the identity value to set. + * @param tags the tags value to set. * @return the PrivateEndpointConnectionInner object itself. */ - public PrivateEndpointConnectionInner withIdentity(Identity identity) { - this.identity = identity; + public PrivateEndpointConnectionInner withTags(Map tags) { + this.tags = tags; return this; } @@ -154,7 +146,7 @@ public PrivateEndpointConnectionInner withSku(Sku sku) { } /** - * Get the systemData property: Read only system data. + * Get the systemData property: System data. * * @return the systemData value. */ @@ -162,31 +154,72 @@ public SystemData systemData() { return this.systemData; } - /** {@inheritDoc} */ - @Override - public PrivateEndpointConnectionInner withLocation(String location) { - super.withLocation(location); + /** + * Get the privateEndpoint property: The resource of private end point. + * + * @return the privateEndpoint value. + */ + public PrivateEndpoint privateEndpoint() { + return this.innerProperties() == null ? null : this.innerProperties().privateEndpoint(); + } + + /** + * Set the privateEndpoint property: The resource of private end point. + * + * @param privateEndpoint the privateEndpoint value to set. + * @return the PrivateEndpointConnectionInner object itself. + */ + public PrivateEndpointConnectionInner withPrivateEndpoint(PrivateEndpoint privateEndpoint) { + if (this.innerProperties() == null) { + this.innerProperties = new PrivateEndpointConnectionProperties(); + } + this.innerProperties().withPrivateEndpoint(privateEndpoint); return this; } - /** {@inheritDoc} */ - @Override - public PrivateEndpointConnectionInner withTags(Map tags) { - super.withTags(tags); + /** + * Get the privateLinkServiceConnectionState property: A collection of information about the state of the connection + * between service consumer and provider. + * + * @return the privateLinkServiceConnectionState value. + */ + public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { + return this.innerProperties() == null ? null : this.innerProperties().privateLinkServiceConnectionState(); + } + + /** + * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection + * between service consumer and provider. + * + * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set. + * @return the PrivateEndpointConnectionInner object itself. + */ + public PrivateEndpointConnectionInner withPrivateLinkServiceConnectionState( + PrivateLinkServiceConnectionState privateLinkServiceConnectionState) { + if (this.innerProperties() == null) { + this.innerProperties = new PrivateEndpointConnectionProperties(); + } + this.innerProperties().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState); return this; } + /** + * Get the provisioningState property: The provisioning state of the private endpoint connection resource. + * + * @return the provisioningState value. + */ + public PrivateEndpointConnectionProvisioningState provisioningState() { + return this.innerProperties() == null ? null : this.innerProperties().provisioningState(); + } + /** * Validates the instance. * * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (privateEndpoint() != null) { - privateEndpoint().validate(); - } - if (privateLinkServiceConnectionState() != null) { - privateLinkServiceConnectionState().validate(); + if (innerProperties() != null) { + innerProperties().validate(); } if (identity() != null) { identity().validate(); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionProperties.java new file mode 100644 index 0000000000000..e2bc1259471e0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionProperties.java @@ -0,0 +1,109 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpoint; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnectionProvisioningState; +import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkServiceConnectionState; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of the PrivateEndpointConnectProperties. */ +@Fluent +public final class PrivateEndpointConnectionProperties { + /* + * The resource of private end point. + */ + @JsonProperty(value = "privateEndpoint") + private PrivateEndpoint privateEndpoint; + + /* + * A collection of information about the state of the connection between + * service consumer and provider. + */ + @JsonProperty(value = "privateLinkServiceConnectionState", required = true) + private PrivateLinkServiceConnectionState privateLinkServiceConnectionState; + + /* + * The provisioning state of the private endpoint connection resource. + */ + @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private PrivateEndpointConnectionProvisioningState provisioningState; + + /** + * Get the privateEndpoint property: The resource of private end point. + * + * @return the privateEndpoint value. + */ + public PrivateEndpoint privateEndpoint() { + return this.privateEndpoint; + } + + /** + * Set the privateEndpoint property: The resource of private end point. + * + * @param privateEndpoint the privateEndpoint value to set. + * @return the PrivateEndpointConnectionProperties object itself. + */ + public PrivateEndpointConnectionProperties withPrivateEndpoint(PrivateEndpoint privateEndpoint) { + this.privateEndpoint = privateEndpoint; + return this; + } + + /** + * Get the privateLinkServiceConnectionState property: A collection of information about the state of the connection + * between service consumer and provider. + * + * @return the privateLinkServiceConnectionState value. + */ + public PrivateLinkServiceConnectionState privateLinkServiceConnectionState() { + return this.privateLinkServiceConnectionState; + } + + /** + * Set the privateLinkServiceConnectionState property: A collection of information about the state of the connection + * between service consumer and provider. + * + * @param privateLinkServiceConnectionState the privateLinkServiceConnectionState value to set. + * @return the PrivateEndpointConnectionProperties object itself. + */ + public PrivateEndpointConnectionProperties withPrivateLinkServiceConnectionState( + PrivateLinkServiceConnectionState privateLinkServiceConnectionState) { + this.privateLinkServiceConnectionState = privateLinkServiceConnectionState; + return this; + } + + /** + * Get the provisioningState property: The provisioning state of the private endpoint connection resource. + * + * @return the provisioningState value. + */ + public PrivateEndpointConnectionProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (privateEndpoint() != null) { + privateEndpoint().validate(); + } + if (privateLinkServiceConnectionState() == null) { + throw LOGGER + .logExceptionAsError( + new IllegalArgumentException( + "Missing required property privateLinkServiceConnectionState in model" + + " PrivateEndpointConnectionProperties")); + } else { + privateLinkServiceConnectionState().validate(); + } + } + + private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionProperties.class); +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceListResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceListResultInner.java index 8a8d6e7db587f..f73ad916266b0 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceListResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceListResultInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkResource; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** A list of private link resources. */ @Fluent public final class PrivateLinkResourceListResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceListResultInner.class); - /* * Array of private link resources */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceProperties.java new file mode 100644 index 0000000000000..6acef1fa0c269 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceProperties.java @@ -0,0 +1,77 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** Properties of a private link resource. */ +@Fluent +public final class PrivateLinkResourceProperties { + /* + * The private link resource group id. + */ + @JsonProperty(value = "groupId", access = JsonProperty.Access.WRITE_ONLY) + private String groupId; + + /* + * The private link resource required member names. + */ + @JsonProperty(value = "requiredMembers", access = JsonProperty.Access.WRITE_ONLY) + private List requiredMembers; + + /* + * The private link resource Private link DNS zone name. + */ + @JsonProperty(value = "requiredZoneNames") + private List requiredZoneNames; + + /** + * Get the groupId property: The private link resource group id. + * + * @return the groupId value. + */ + public String groupId() { + return this.groupId; + } + + /** + * Get the requiredMembers property: The private link resource required member names. + * + * @return the requiredMembers value. + */ + public List requiredMembers() { + return this.requiredMembers; + } + + /** + * Get the requiredZoneNames property: The private link resource Private link DNS zone name. + * + * @return the requiredZoneNames value. + */ + public List requiredZoneNames() { + return this.requiredZoneNames; + } + + /** + * Set the requiredZoneNames property: The private link resource Private link DNS zone name. + * + * @param requiredZoneNames the requiredZoneNames value to set. + * @return the PrivateLinkResourceProperties object itself. + */ + public PrivateLinkResourceProperties withRequiredZoneNames(List requiredZoneNames) { + this.requiredZoneNames = requiredZoneNames; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ResourceQuotaInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ResourceQuotaInner.java index 9df00d984560e..7b5c83c40bfd1 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ResourceQuotaInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ResourceQuotaInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.QuotaUnit; import com.azure.resourcemanager.machinelearningservices.models.ResourceName; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The quota assigned to a resource. */ @Immutable public final class ResourceQuotaInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceQuotaInner.class); - /* * Specifies the resource ID. */ @@ -41,7 +37,7 @@ public final class ResourceQuotaInner { private ResourceName name; /* - * The maximum permitted quota of the resource. + * Limit. The maximum permitted quota of the resource. */ @JsonProperty(value = "limit", access = JsonProperty.Access.WRITE_ONLY) private Long limit; @@ -89,7 +85,7 @@ public ResourceName name() { } /** - * Get the limit property: The maximum permitted quota of the resource. + * Get the limit property: Limit. The maximum permitted quota of the resource. * * @return the limit value. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ServiceResourceInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ServiceResourceInner.java deleted file mode 100644 index 7153f64ec175d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ServiceResourceInner.java +++ /dev/null @@ -1,146 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.fluent.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.management.Resource; -import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.models.Identity; -import com.azure.resourcemanager.machinelearningservices.models.ServiceResponseBase; -import com.azure.resourcemanager.machinelearningservices.models.Sku; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; -import java.util.Map; - -/** Machine Learning service object wrapped into ARM resource envelope. */ -@Fluent -public final class ServiceResourceInner extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServiceResourceInner.class); - - /* - * Service properties - */ - @JsonProperty(value = "properties") - private ServiceResponseBase properties; - - /* - * The identity of the resource. - */ - @JsonProperty(value = "identity") - private Identity identity; - - /* - * The sku of the workspace. - */ - @JsonProperty(value = "sku") - private Sku sku; - - /* - * Read only system data - */ - @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) - private SystemData systemData; - - /** - * Get the properties property: Service properties. - * - * @return the properties value. - */ - public ServiceResponseBase properties() { - return this.properties; - } - - /** - * Set the properties property: Service properties. - * - * @param properties the properties value to set. - * @return the ServiceResourceInner object itself. - */ - public ServiceResourceInner withProperties(ServiceResponseBase properties) { - this.properties = properties; - return this; - } - - /** - * Get the identity property: The identity of the resource. - * - * @return the identity value. - */ - public Identity identity() { - return this.identity; - } - - /** - * Set the identity property: The identity of the resource. - * - * @param identity the identity value to set. - * @return the ServiceResourceInner object itself. - */ - public ServiceResourceInner withIdentity(Identity identity) { - this.identity = identity; - return this; - } - - /** - * Get the sku property: The sku of the workspace. - * - * @return the sku value. - */ - public Sku sku() { - return this.sku; - } - - /** - * Set the sku property: The sku of the workspace. - * - * @param sku the sku value to set. - * @return the ServiceResourceInner object itself. - */ - public ServiceResourceInner withSku(Sku sku) { - this.sku = sku; - return this; - } - - /** - * Get the systemData property: Read only system data. - * - * @return the systemData value. - */ - public SystemData systemData() { - return this.systemData; - } - - /** {@inheritDoc} */ - @Override - public ServiceResourceInner withLocation(String location) { - super.withLocation(location); - return this; - } - - /** {@inheritDoc} */ - @Override - public ServiceResourceInner withTags(Map tags) { - super.withTags(tags); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (properties() != null) { - properties().validate(); - } - if (identity() != null) { - identity().validate(); - } - if (sku() != null) { - sku().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/SharedPrivateLinkResourceProperty.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/SharedPrivateLinkResourceProperty.java new file mode 100644 index 0000000000000..9f0145021453b --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/SharedPrivateLinkResourceProperty.java @@ -0,0 +1,128 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of a shared private link resource. */ +@Fluent +public final class SharedPrivateLinkResourceProperty { + /* + * The resource id that private link links to. + */ + @JsonProperty(value = "privateLinkResourceId") + private String privateLinkResourceId; + + /* + * The private link resource group id. + */ + @JsonProperty(value = "groupId") + private String groupId; + + /* + * Request message. + */ + @JsonProperty(value = "requestMessage") + private String requestMessage; + + /* + * Indicates whether the connection has been Approved/Rejected/Removed by + * the owner of the service. + */ + @JsonProperty(value = "status") + private PrivateEndpointServiceConnectionStatus status; + + /** + * Get the privateLinkResourceId property: The resource id that private link links to. + * + * @return the privateLinkResourceId value. + */ + public String privateLinkResourceId() { + return this.privateLinkResourceId; + } + + /** + * Set the privateLinkResourceId property: The resource id that private link links to. + * + * @param privateLinkResourceId the privateLinkResourceId value to set. + * @return the SharedPrivateLinkResourceProperty object itself. + */ + public SharedPrivateLinkResourceProperty withPrivateLinkResourceId(String privateLinkResourceId) { + this.privateLinkResourceId = privateLinkResourceId; + return this; + } + + /** + * Get the groupId property: The private link resource group id. + * + * @return the groupId value. + */ + public String groupId() { + return this.groupId; + } + + /** + * Set the groupId property: The private link resource group id. + * + * @param groupId the groupId value to set. + * @return the SharedPrivateLinkResourceProperty object itself. + */ + public SharedPrivateLinkResourceProperty withGroupId(String groupId) { + this.groupId = groupId; + return this; + } + + /** + * Get the requestMessage property: Request message. + * + * @return the requestMessage value. + */ + public String requestMessage() { + return this.requestMessage; + } + + /** + * Set the requestMessage property: Request message. + * + * @param requestMessage the requestMessage value to set. + * @return the SharedPrivateLinkResourceProperty object itself. + */ + public SharedPrivateLinkResourceProperty withRequestMessage(String requestMessage) { + this.requestMessage = requestMessage; + return this; + } + + /** + * Get the status property: Indicates whether the connection has been Approved/Rejected/Removed by the owner of the + * service. + * + * @return the status value. + */ + public PrivateEndpointServiceConnectionStatus status() { + return this.status; + } + + /** + * Set the status property: Indicates whether the connection has been Approved/Rejected/Removed by the owner of the + * service. + * + * @param status the status value to set. + * @return the SharedPrivateLinkResourceProperty object itself. + */ + public SharedPrivateLinkResourceProperty withStatus(PrivateEndpointServiceConnectionStatus status) { + this.status = status; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UpdateWorkspaceQuotasResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UpdateWorkspaceQuotasResultInner.java index bc0791401d53d..c4ee9fd12831b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UpdateWorkspaceQuotasResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UpdateWorkspaceQuotasResultInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.UpdateWorkspaceQuotas; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The result of update workspace quota. */ @Immutable public final class UpdateWorkspaceQuotasResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UpdateWorkspaceQuotasResultInner.class); - /* * The list of workspace quota update result. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UsageInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UsageInner.java index 06adbfe134511..2849f5fd83d77 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UsageInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/UsageInner.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.UsageName; import com.azure.resourcemanager.machinelearningservices.models.UsageUnit; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Describes AML Resource Usage. */ @Immutable public final class UsageInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UsageInner.class); - /* * Specifies the resource ID. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/VirtualMachineSizeListResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/VirtualMachineSizeListResultInner.java index d7b7bc81d032e..0f1c7ecfa6acc 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/VirtualMachineSizeListResultInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/VirtualMachineSizeListResultInner.java @@ -5,40 +5,36 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineSize; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The List Virtual Machine size operation response. */ @Fluent public final class VirtualMachineSizeListResultInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineSizeListResultInner.class); - /* * The list of virtual machine sizes supported by AmlCompute. */ - @JsonProperty(value = "amlCompute") - private List amlCompute; + @JsonProperty(value = "value") + private List value; /** - * Get the amlCompute property: The list of virtual machine sizes supported by AmlCompute. + * Get the value property: The list of virtual machine sizes supported by AmlCompute. * - * @return the amlCompute value. + * @return the value value. */ - public List amlCompute() { - return this.amlCompute; + public List value() { + return this.value; } /** - * Set the amlCompute property: The list of virtual machine sizes supported by AmlCompute. + * Set the value property: The list of virtual machine sizes supported by AmlCompute. * - * @param amlCompute the amlCompute value to set. + * @param value the value value to set. * @return the VirtualMachineSizeListResultInner object itself. */ - public VirtualMachineSizeListResultInner withAmlCompute(List amlCompute) { - this.amlCompute = amlCompute; + public VirtualMachineSizeListResultInner withValue(List value) { + this.value = value; return this; } @@ -48,8 +44,8 @@ public VirtualMachineSizeListResultInner withAmlCompute(List * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (amlCompute() != null) { - amlCompute().forEach(e -> e.validate()); + if (value() != null) { + value().forEach(e -> e.validate()); } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionInner.java index faddd431765e3..4af65f73ac21b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionInner.java @@ -5,48 +5,27 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; import com.azure.core.management.ProxyResource; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.ValueFormat; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Workspace connection. */ -@JsonFlatten @Fluent -public class WorkspaceConnectionInner extends ProxyResource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceConnectionInner.class); - - /* - * Category of the workspace connection. - */ - @JsonProperty(value = "properties.category") - private String category; - - /* - * Target of the workspace connection. - */ - @JsonProperty(value = "properties.target") - private String target; - +public final class WorkspaceConnectionInner extends ProxyResource { /* - * Authorization type of the workspace connection. + * Properties of workspace connection. */ - @JsonProperty(value = "properties.authType") - private String authType; + @JsonProperty(value = "properties") + private WorkspaceConnectionProps innerProperties; - /* - * Value details of the workspace connection. - */ - @JsonProperty(value = "properties.value") - private String value; - - /* - * format for the workspace connection value + /** + * Get the innerProperties property: Properties of workspace connection. + * + * @return the innerProperties value. */ - @JsonProperty(value = "properties.valueFormat") - private ValueFormat valueFormat; + private WorkspaceConnectionProps innerProperties() { + return this.innerProperties; + } /** * Get the category property: Category of the workspace connection. @@ -54,7 +33,7 @@ public class WorkspaceConnectionInner extends ProxyResource { * @return the category value. */ public String category() { - return this.category; + return this.innerProperties() == null ? null : this.innerProperties().category(); } /** @@ -64,7 +43,10 @@ public String category() { * @return the WorkspaceConnectionInner object itself. */ public WorkspaceConnectionInner withCategory(String category) { - this.category = category; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspaceConnectionProps(); + } + this.innerProperties().withCategory(category); return this; } @@ -74,7 +56,7 @@ public WorkspaceConnectionInner withCategory(String category) { * @return the target value. */ public String target() { - return this.target; + return this.innerProperties() == null ? null : this.innerProperties().target(); } /** @@ -84,7 +66,10 @@ public String target() { * @return the WorkspaceConnectionInner object itself. */ public WorkspaceConnectionInner withTarget(String target) { - this.target = target; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspaceConnectionProps(); + } + this.innerProperties().withTarget(target); return this; } @@ -94,7 +79,7 @@ public WorkspaceConnectionInner withTarget(String target) { * @return the authType value. */ public String authType() { - return this.authType; + return this.innerProperties() == null ? null : this.innerProperties().authType(); } /** @@ -104,7 +89,10 @@ public String authType() { * @return the WorkspaceConnectionInner object itself. */ public WorkspaceConnectionInner withAuthType(String authType) { - this.authType = authType; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspaceConnectionProps(); + } + this.innerProperties().withAuthType(authType); return this; } @@ -114,7 +102,7 @@ public WorkspaceConnectionInner withAuthType(String authType) { * @return the value value. */ public String value() { - return this.value; + return this.innerProperties() == null ? null : this.innerProperties().value(); } /** @@ -124,7 +112,10 @@ public String value() { * @return the WorkspaceConnectionInner object itself. */ public WorkspaceConnectionInner withValue(String value) { - this.value = value; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspaceConnectionProps(); + } + this.innerProperties().withValue(value); return this; } @@ -134,7 +125,7 @@ public WorkspaceConnectionInner withValue(String value) { * @return the valueFormat value. */ public ValueFormat valueFormat() { - return this.valueFormat; + return this.innerProperties() == null ? null : this.innerProperties().valueFormat(); } /** @@ -144,7 +135,10 @@ public ValueFormat valueFormat() { * @return the WorkspaceConnectionInner object itself. */ public WorkspaceConnectionInner withValueFormat(ValueFormat valueFormat) { - this.valueFormat = valueFormat; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspaceConnectionProps(); + } + this.innerProperties().withValueFormat(valueFormat); return this; } @@ -154,5 +148,8 @@ public WorkspaceConnectionInner withValueFormat(ValueFormat valueFormat) { * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { + if (innerProperties() != null) { + innerProperties().validate(); + } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnectionDto.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionProps.java similarity index 60% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnectionDto.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionProps.java index 74476aaea3568..7b59efbeca811 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnectionDto.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceConnectionProps.java @@ -2,76 +2,45 @@ // Licensed under the MIT License. // Code generated by Microsoft (R) AutoRest Code Generator. -package com.azure.resourcemanager.machinelearningservices.models; +package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.models.ValueFormat; import com.fasterxml.jackson.annotation.JsonProperty; -/** object used for creating workspace connection. */ -@JsonFlatten +/** Workspace Connection specific properties. */ @Fluent -public class WorkspaceConnectionDto { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceConnectionDto.class); - - /* - * Friendly name of the workspace connection - */ - @JsonProperty(value = "name") - private String name; - +public final class WorkspaceConnectionProps { /* * Category of the workspace connection. */ - @JsonProperty(value = "properties.category") + @JsonProperty(value = "category") private String category; /* * Target of the workspace connection. */ - @JsonProperty(value = "properties.target") + @JsonProperty(value = "target") private String target; /* * Authorization type of the workspace connection. */ - @JsonProperty(value = "properties.authType") + @JsonProperty(value = "authType") private String authType; /* * Value details of the workspace connection. */ - @JsonProperty(value = "properties.value") + @JsonProperty(value = "value") private String value; /* * format for the workspace connection value */ - @JsonProperty(value = "properties.valueFormat") + @JsonProperty(value = "valueFormat") private ValueFormat valueFormat; - /** - * Get the name property: Friendly name of the workspace connection. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: Friendly name of the workspace connection. - * - * @param name the name value to set. - * @return the WorkspaceConnectionDto object itself. - */ - public WorkspaceConnectionDto withName(String name) { - this.name = name; - return this; - } - /** * Get the category property: Category of the workspace connection. * @@ -85,9 +54,9 @@ public String category() { * Set the category property: Category of the workspace connection. * * @param category the category value to set. - * @return the WorkspaceConnectionDto object itself. + * @return the WorkspaceConnectionProps object itself. */ - public WorkspaceConnectionDto withCategory(String category) { + public WorkspaceConnectionProps withCategory(String category) { this.category = category; return this; } @@ -105,9 +74,9 @@ public String target() { * Set the target property: Target of the workspace connection. * * @param target the target value to set. - * @return the WorkspaceConnectionDto object itself. + * @return the WorkspaceConnectionProps object itself. */ - public WorkspaceConnectionDto withTarget(String target) { + public WorkspaceConnectionProps withTarget(String target) { this.target = target; return this; } @@ -125,9 +94,9 @@ public String authType() { * Set the authType property: Authorization type of the workspace connection. * * @param authType the authType value to set. - * @return the WorkspaceConnectionDto object itself. + * @return the WorkspaceConnectionProps object itself. */ - public WorkspaceConnectionDto withAuthType(String authType) { + public WorkspaceConnectionProps withAuthType(String authType) { this.authType = authType; return this; } @@ -145,9 +114,9 @@ public String value() { * Set the value property: Value details of the workspace connection. * * @param value the value value to set. - * @return the WorkspaceConnectionDto object itself. + * @return the WorkspaceConnectionProps object itself. */ - public WorkspaceConnectionDto withValue(String value) { + public WorkspaceConnectionProps withValue(String value) { this.value = value; return this; } @@ -165,9 +134,9 @@ public ValueFormat valueFormat() { * Set the valueFormat property: format for the workspace connection value. * * @param valueFormat the valueFormat value to set. - * @return the WorkspaceConnectionDto object itself. + * @return the WorkspaceConnectionProps object itself. */ - public WorkspaceConnectionDto withValueFormat(ValueFormat valueFormat) { + public WorkspaceConnectionProps withValueFormat(ValueFormat valueFormat) { this.valueFormat = valueFormat; return this; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceInner.java index a8815c7b7bbda..83e5b696b3457 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceInner.java @@ -5,179 +5,157 @@ package com.azure.resourcemanager.machinelearningservices.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.ProxyResource; import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; import com.azure.resourcemanager.machinelearningservices.models.Identity; import com.azure.resourcemanager.machinelearningservices.models.ProvisioningState; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; import com.azure.resourcemanager.machinelearningservices.models.Sku; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; import java.util.Map; /** An object that represents a machine learning workspace. */ -@JsonFlatten @Fluent -public class WorkspaceInner extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceInner.class); - - /* - * The immutable id associated with this workspace. - */ - @JsonProperty(value = "properties.workspaceId", access = JsonProperty.Access.WRITE_ONLY) - private String workspaceId; - - /* - * The description of this workspace. - */ - @JsonProperty(value = "properties.description") - private String description; - - /* - * The friendly name for this workspace. This name in mutable - */ - @JsonProperty(value = "properties.friendlyName") - private String friendlyName; - - /* - * ARM id of the key vault associated with this workspace. This cannot be - * changed once the workspace has been created - */ - @JsonProperty(value = "properties.keyVault") - private String keyVault; - - /* - * ARM id of the application insights associated with this workspace. This - * cannot be changed once the workspace has been created - */ - @JsonProperty(value = "properties.applicationInsights") - private String applicationInsights; - - /* - * ARM id of the container registry associated with this workspace. This - * cannot be changed once the workspace has been created - */ - @JsonProperty(value = "properties.containerRegistry") - private String containerRegistry; - - /* - * ARM id of the storage account associated with this workspace. This - * cannot be changed once the workspace has been created - */ - @JsonProperty(value = "properties.storageAccount") - private String storageAccount; - +public final class WorkspaceInner extends ProxyResource { /* - * Url for the discovery service to identify regional endpoints for machine - * learning experimentation services + * The properties of the machine learning workspace. */ - @JsonProperty(value = "properties.discoveryUrl") - private String discoveryUrl; + @JsonProperty(value = "properties") + private WorkspacePropertiesInner innerProperties; /* - * The current deployment state of workspace resource. The - * provisioningState is to indicate states for resource provisioning. - */ - @JsonProperty(value = "properties.provisioningState", access = JsonProperty.Access.WRITE_ONLY) - private ProvisioningState provisioningState; - - /* - * The encryption settings of Azure ML workspace. + * The identity of the resource. */ - @JsonProperty(value = "properties.encryption") - private EncryptionProperty encryption; + @JsonProperty(value = "identity") + private Identity identity; /* - * The flag to signal HBI data in the workspace and reduce diagnostic data - * collected by the service + * Specifies the location of the resource. */ - @JsonProperty(value = "properties.hbiWorkspace") - private Boolean hbiWorkspace; + @JsonProperty(value = "location") + private String location; /* - * The name of the managed resource group created by workspace RP in - * customer subscription if the workspace is CMK workspace + * Contains resource tags defined as key/value pairs. */ - @JsonProperty(value = "properties.serviceProvisionedResourceGroup", access = JsonProperty.Access.WRITE_ONLY) - private String serviceProvisionedResourceGroup; + @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map tags; /* - * Count of private connections in the workspace + * The sku of the workspace. */ - @JsonProperty(value = "properties.privateLinkCount", access = JsonProperty.Access.WRITE_ONLY) - private Integer privateLinkCount; + @JsonProperty(value = "sku") + private Sku sku; /* - * The compute name for image build + * System data */ - @JsonProperty(value = "properties.imageBuildCompute") - private String imageBuildCompute; + @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) + private SystemData systemData; - /* - * The flag to indicate whether to allow public access when behind VNet. + /** + * Get the innerProperties property: The properties of the machine learning workspace. + * + * @return the innerProperties value. */ - @JsonProperty(value = "properties.allowPublicAccessWhenBehindVnet") - private Boolean allowPublicAccessWhenBehindVnet; + private WorkspacePropertiesInner innerProperties() { + return this.innerProperties; + } - /* - * The list of private endpoint connections in the workspace. + /** + * Get the identity property: The identity of the resource. + * + * @return the identity value. */ - @JsonProperty(value = "properties.privateEndpointConnections", access = JsonProperty.Access.WRITE_ONLY) - private List privateEndpointConnections; + public Identity identity() { + return this.identity; + } - /* - * The list of shared private link resources in this workspace. + /** + * Set the identity property: The identity of the resource. + * + * @param identity the identity value to set. + * @return the WorkspaceInner object itself. */ - @JsonProperty(value = "properties.sharedPrivateLinkResources") - private List sharedPrivateLinkResources; + public WorkspaceInner withIdentity(Identity identity) { + this.identity = identity; + return this; + } - /* - * The notebook info of Azure ML workspace. + /** + * Get the location property: Specifies the location of the resource. + * + * @return the location value. */ - @JsonProperty(value = "properties.notebookInfo", access = JsonProperty.Access.WRITE_ONLY) - private NotebookResourceInfoInner notebookInfo; + public String location() { + return this.location; + } - /* - * The service managed resource settings. + /** + * Set the location property: Specifies the location of the resource. + * + * @param location the location value to set. + * @return the WorkspaceInner object itself. */ - @JsonProperty(value = "properties.serviceManagedResourcesSettings") - private ServiceManagedResourcesSettings serviceManagedResourcesSettings; + public WorkspaceInner withLocation(String location) { + this.location = location; + return this; + } - /* - * The user assigned identity resource id that represents the workspace - * identity. + /** + * Get the tags property: Contains resource tags defined as key/value pairs. + * + * @return the tags value. */ - @JsonProperty(value = "properties.primaryUserAssignedIdentity") - private String primaryUserAssignedIdentity; + public Map tags() { + return this.tags; + } - /* - * The tenant id associated with this workspace. + /** + * Set the tags property: Contains resource tags defined as key/value pairs. + * + * @param tags the tags value to set. + * @return the WorkspaceInner object itself. */ - @JsonProperty(value = "properties.tenantId", access = JsonProperty.Access.WRITE_ONLY) - private String tenantId; + public WorkspaceInner withTags(Map tags) { + this.tags = tags; + return this; + } - /* - * The identity of the resource. + /** + * Get the sku property: The sku of the workspace. + * + * @return the sku value. */ - @JsonProperty(value = "identity") - private Identity identity; + public Sku sku() { + return this.sku; + } - /* - * The sku of the workspace. + /** + * Set the sku property: The sku of the workspace. + * + * @param sku the sku value to set. + * @return the WorkspaceInner object itself. */ - @JsonProperty(value = "sku") - private Sku sku; + public WorkspaceInner withSku(Sku sku) { + this.sku = sku; + return this; + } - /* - * Read only system data + /** + * Get the systemData property: System data. + * + * @return the systemData value. */ - @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) - private SystemData systemData; + public SystemData systemData() { + return this.systemData; + } /** * Get the workspaceId property: The immutable id associated with this workspace. @@ -185,7 +163,7 @@ public class WorkspaceInner extends Resource { * @return the workspaceId value. */ public String workspaceId() { - return this.workspaceId; + return this.innerProperties() == null ? null : this.innerProperties().workspaceId(); } /** @@ -194,7 +172,7 @@ public String workspaceId() { * @return the description value. */ public String description() { - return this.description; + return this.innerProperties() == null ? null : this.innerProperties().description(); } /** @@ -204,7 +182,10 @@ public String description() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withDescription(String description) { - this.description = description; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withDescription(description); return this; } @@ -214,7 +195,7 @@ public WorkspaceInner withDescription(String description) { * @return the friendlyName value. */ public String friendlyName() { - return this.friendlyName; + return this.innerProperties() == null ? null : this.innerProperties().friendlyName(); } /** @@ -224,7 +205,10 @@ public String friendlyName() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withFriendlyName(String friendlyName) { - this.friendlyName = friendlyName; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withFriendlyName(friendlyName); return this; } @@ -235,7 +219,7 @@ public WorkspaceInner withFriendlyName(String friendlyName) { * @return the keyVault value. */ public String keyVault() { - return this.keyVault; + return this.innerProperties() == null ? null : this.innerProperties().keyVault(); } /** @@ -246,7 +230,10 @@ public String keyVault() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withKeyVault(String keyVault) { - this.keyVault = keyVault; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withKeyVault(keyVault); return this; } @@ -257,7 +244,7 @@ public WorkspaceInner withKeyVault(String keyVault) { * @return the applicationInsights value. */ public String applicationInsights() { - return this.applicationInsights; + return this.innerProperties() == null ? null : this.innerProperties().applicationInsights(); } /** @@ -268,7 +255,10 @@ public String applicationInsights() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withApplicationInsights(String applicationInsights) { - this.applicationInsights = applicationInsights; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withApplicationInsights(applicationInsights); return this; } @@ -279,7 +269,7 @@ public WorkspaceInner withApplicationInsights(String applicationInsights) { * @return the containerRegistry value. */ public String containerRegistry() { - return this.containerRegistry; + return this.innerProperties() == null ? null : this.innerProperties().containerRegistry(); } /** @@ -290,7 +280,10 @@ public String containerRegistry() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withContainerRegistry(String containerRegistry) { - this.containerRegistry = containerRegistry; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withContainerRegistry(containerRegistry); return this; } @@ -301,7 +294,7 @@ public WorkspaceInner withContainerRegistry(String containerRegistry) { * @return the storageAccount value. */ public String storageAccount() { - return this.storageAccount; + return this.innerProperties() == null ? null : this.innerProperties().storageAccount(); } /** @@ -312,7 +305,10 @@ public String storageAccount() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withStorageAccount(String storageAccount) { - this.storageAccount = storageAccount; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withStorageAccount(storageAccount); return this; } @@ -323,7 +319,7 @@ public WorkspaceInner withStorageAccount(String storageAccount) { * @return the discoveryUrl value. */ public String discoveryUrl() { - return this.discoveryUrl; + return this.innerProperties() == null ? null : this.innerProperties().discoveryUrl(); } /** @@ -334,7 +330,10 @@ public String discoveryUrl() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withDiscoveryUrl(String discoveryUrl) { - this.discoveryUrl = discoveryUrl; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withDiscoveryUrl(discoveryUrl); return this; } @@ -345,7 +344,7 @@ public WorkspaceInner withDiscoveryUrl(String discoveryUrl) { * @return the provisioningState value. */ public ProvisioningState provisioningState() { - return this.provisioningState; + return this.innerProperties() == null ? null : this.innerProperties().provisioningState(); } /** @@ -354,7 +353,7 @@ public ProvisioningState provisioningState() { * @return the encryption value. */ public EncryptionProperty encryption() { - return this.encryption; + return this.innerProperties() == null ? null : this.innerProperties().encryption(); } /** @@ -364,7 +363,10 @@ public EncryptionProperty encryption() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withEncryption(EncryptionProperty encryption) { - this.encryption = encryption; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withEncryption(encryption); return this; } @@ -375,7 +377,7 @@ public WorkspaceInner withEncryption(EncryptionProperty encryption) { * @return the hbiWorkspace value. */ public Boolean hbiWorkspace() { - return this.hbiWorkspace; + return this.innerProperties() == null ? null : this.innerProperties().hbiWorkspace(); } /** @@ -386,7 +388,10 @@ public Boolean hbiWorkspace() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withHbiWorkspace(Boolean hbiWorkspace) { - this.hbiWorkspace = hbiWorkspace; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withHbiWorkspace(hbiWorkspace); return this; } @@ -397,7 +402,7 @@ public WorkspaceInner withHbiWorkspace(Boolean hbiWorkspace) { * @return the serviceProvisionedResourceGroup value. */ public String serviceProvisionedResourceGroup() { - return this.serviceProvisionedResourceGroup; + return this.innerProperties() == null ? null : this.innerProperties().serviceProvisionedResourceGroup(); } /** @@ -406,7 +411,7 @@ public String serviceProvisionedResourceGroup() { * @return the privateLinkCount value. */ public Integer privateLinkCount() { - return this.privateLinkCount; + return this.innerProperties() == null ? null : this.innerProperties().privateLinkCount(); } /** @@ -415,7 +420,7 @@ public Integer privateLinkCount() { * @return the imageBuildCompute value. */ public String imageBuildCompute() { - return this.imageBuildCompute; + return this.innerProperties() == null ? null : this.innerProperties().imageBuildCompute(); } /** @@ -425,7 +430,10 @@ public String imageBuildCompute() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withImageBuildCompute(String imageBuildCompute) { - this.imageBuildCompute = imageBuildCompute; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withImageBuildCompute(imageBuildCompute); return this; } @@ -436,7 +444,7 @@ public WorkspaceInner withImageBuildCompute(String imageBuildCompute) { * @return the allowPublicAccessWhenBehindVnet value. */ public Boolean allowPublicAccessWhenBehindVnet() { - return this.allowPublicAccessWhenBehindVnet; + return this.innerProperties() == null ? null : this.innerProperties().allowPublicAccessWhenBehindVnet(); } /** @@ -447,7 +455,33 @@ public Boolean allowPublicAccessWhenBehindVnet() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withAllowPublicAccessWhenBehindVnet(Boolean allowPublicAccessWhenBehindVnet) { - this.allowPublicAccessWhenBehindVnet = allowPublicAccessWhenBehindVnet; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withAllowPublicAccessWhenBehindVnet(allowPublicAccessWhenBehindVnet); + return this; + } + + /** + * Get the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccess publicNetworkAccess() { + return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess(); + } + + /** + * Set the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the WorkspaceInner object itself. + */ + public WorkspaceInner withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) { + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withPublicNetworkAccess(publicNetworkAccess); return this; } @@ -457,7 +491,7 @@ public WorkspaceInner withAllowPublicAccessWhenBehindVnet(Boolean allowPublicAcc * @return the privateEndpointConnections value. */ public List privateEndpointConnections() { - return this.privateEndpointConnections; + return this.innerProperties() == null ? null : this.innerProperties().privateEndpointConnections(); } /** @@ -466,7 +500,7 @@ public List privateEndpointConnections() { * @return the sharedPrivateLinkResources value. */ public List sharedPrivateLinkResources() { - return this.sharedPrivateLinkResources; + return this.innerProperties() == null ? null : this.innerProperties().sharedPrivateLinkResources(); } /** @@ -476,7 +510,10 @@ public List sharedPrivateLinkResources() { * @return the WorkspaceInner object itself. */ public WorkspaceInner withSharedPrivateLinkResources(List sharedPrivateLinkResources) { - this.sharedPrivateLinkResources = sharedPrivateLinkResources; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesInner(); + } + this.innerProperties().withSharedPrivateLinkResources(sharedPrivateLinkResources); return this; } @@ -486,7 +523,7 @@ public WorkspaceInner withSharedPrivateLinkResources(List tags) { - super.withTags(tags); - return this; + public String mlFlowTrackingUri() { + return this.innerProperties() == null ? null : this.innerProperties().mlFlowTrackingUri(); } /** @@ -610,20 +610,8 @@ public WorkspaceInner withTags(Map tags) { * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (encryption() != null) { - encryption().validate(); - } - if (privateEndpointConnections() != null) { - privateEndpointConnections().forEach(e -> e.validate()); - } - if (sharedPrivateLinkResources() != null) { - sharedPrivateLinkResources().forEach(e -> e.validate()); - } - if (notebookInfo() != null) { - notebookInfo().validate(); - } - if (serviceManagedResourcesSettings() != null) { - serviceManagedResourcesSettings().validate(); + if (innerProperties() != null) { + innerProperties().validate(); } if (identity() != null) { identity().validate(); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesInner.java new file mode 100644 index 0000000000000..a67b84a675c7e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesInner.java @@ -0,0 +1,599 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; +import com.azure.resourcemanager.machinelearningservices.models.ProvisioningState; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; +import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The properties of a machine learning workspace. */ +@Fluent +public final class WorkspacePropertiesInner { + /* + * The immutable id associated with this workspace. + */ + @JsonProperty(value = "workspaceId", access = JsonProperty.Access.WRITE_ONLY) + private String workspaceId; + + /* + * The description of this workspace. + */ + @JsonProperty(value = "description") + private String description; + + /* + * The friendly name for this workspace. This name in mutable + */ + @JsonProperty(value = "friendlyName") + private String friendlyName; + + /* + * ARM id of the key vault associated with this workspace. This cannot be + * changed once the workspace has been created + */ + @JsonProperty(value = "keyVault") + private String keyVault; + + /* + * ARM id of the application insights associated with this workspace. This + * cannot be changed once the workspace has been created + */ + @JsonProperty(value = "applicationInsights") + private String applicationInsights; + + /* + * ARM id of the container registry associated with this workspace. This + * cannot be changed once the workspace has been created + */ + @JsonProperty(value = "containerRegistry") + private String containerRegistry; + + /* + * ARM id of the storage account associated with this workspace. This + * cannot be changed once the workspace has been created + */ + @JsonProperty(value = "storageAccount") + private String storageAccount; + + /* + * Url for the discovery service to identify regional endpoints for machine + * learning experimentation services + */ + @JsonProperty(value = "discoveryUrl") + private String discoveryUrl; + + /* + * The current deployment state of workspace resource. The + * provisioningState is to indicate states for resource provisioning. + */ + @JsonProperty(value = "provisioningState", access = JsonProperty.Access.WRITE_ONLY) + private ProvisioningState provisioningState; + + /* + * The encryption settings of Azure ML workspace. + */ + @JsonProperty(value = "encryption") + private EncryptionProperty encryption; + + /* + * The flag to signal HBI data in the workspace and reduce diagnostic data + * collected by the service + */ + @JsonProperty(value = "hbiWorkspace") + private Boolean hbiWorkspace; + + /* + * The name of the managed resource group created by workspace RP in + * customer subscription if the workspace is CMK workspace + */ + @JsonProperty(value = "serviceProvisionedResourceGroup", access = JsonProperty.Access.WRITE_ONLY) + private String serviceProvisionedResourceGroup; + + /* + * Count of private connections in the workspace + */ + @JsonProperty(value = "privateLinkCount", access = JsonProperty.Access.WRITE_ONLY) + private Integer privateLinkCount; + + /* + * The compute name for image build + */ + @JsonProperty(value = "imageBuildCompute") + private String imageBuildCompute; + + /* + * The flag to indicate whether to allow public access when behind VNet. + */ + @JsonProperty(value = "allowPublicAccessWhenBehindVnet") + private Boolean allowPublicAccessWhenBehindVnet; + + /* + * Whether requests from Public Network are allowed. + */ + @JsonProperty(value = "publicNetworkAccess") + private PublicNetworkAccess publicNetworkAccess; + + /* + * The list of private endpoint connections in the workspace. + */ + @JsonProperty(value = "privateEndpointConnections", access = JsonProperty.Access.WRITE_ONLY) + private List privateEndpointConnections; + + /* + * The list of shared private link resources in this workspace. + */ + @JsonProperty(value = "sharedPrivateLinkResources") + private List sharedPrivateLinkResources; + + /* + * The notebook info of Azure ML workspace. + */ + @JsonProperty(value = "notebookInfo", access = JsonProperty.Access.WRITE_ONLY) + private NotebookResourceInfoInner notebookInfo; + + /* + * The service managed resource settings. + */ + @JsonProperty(value = "serviceManagedResourcesSettings") + private ServiceManagedResourcesSettings serviceManagedResourcesSettings; + + /* + * The user assigned identity resource id that represents the workspace + * identity. + */ + @JsonProperty(value = "primaryUserAssignedIdentity") + private String primaryUserAssignedIdentity; + + /* + * The tenant id associated with this workspace. + */ + @JsonProperty(value = "tenantId", access = JsonProperty.Access.WRITE_ONLY) + private String tenantId; + + /* + * If the storage associated with the workspace has hierarchical + * namespace(HNS) enabled. + */ + @JsonProperty(value = "storageHnsEnabled", access = JsonProperty.Access.WRITE_ONLY) + private Boolean storageHnsEnabled; + + /* + * The URI associated with this workspace that machine learning flow must + * point at to set up tracking. + */ + @JsonProperty(value = "mlFlowTrackingUri", access = JsonProperty.Access.WRITE_ONLY) + private String mlFlowTrackingUri; + + /** + * Get the workspaceId property: The immutable id associated with this workspace. + * + * @return the workspaceId value. + */ + public String workspaceId() { + return this.workspaceId; + } + + /** + * Get the description property: The description of this workspace. + * + * @return the description value. + */ + public String description() { + return this.description; + } + + /** + * Set the description property: The description of this workspace. + * + * @param description the description value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the friendlyName property: The friendly name for this workspace. This name in mutable. + * + * @return the friendlyName value. + */ + public String friendlyName() { + return this.friendlyName; + } + + /** + * Set the friendlyName property: The friendly name for this workspace. This name in mutable. + * + * @param friendlyName the friendlyName value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withFriendlyName(String friendlyName) { + this.friendlyName = friendlyName; + return this; + } + + /** + * Get the keyVault property: ARM id of the key vault associated with this workspace. This cannot be changed once + * the workspace has been created. + * + * @return the keyVault value. + */ + public String keyVault() { + return this.keyVault; + } + + /** + * Set the keyVault property: ARM id of the key vault associated with this workspace. This cannot be changed once + * the workspace has been created. + * + * @param keyVault the keyVault value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withKeyVault(String keyVault) { + this.keyVault = keyVault; + return this; + } + + /** + * Get the applicationInsights property: ARM id of the application insights associated with this workspace. This + * cannot be changed once the workspace has been created. + * + * @return the applicationInsights value. + */ + public String applicationInsights() { + return this.applicationInsights; + } + + /** + * Set the applicationInsights property: ARM id of the application insights associated with this workspace. This + * cannot be changed once the workspace has been created. + * + * @param applicationInsights the applicationInsights value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withApplicationInsights(String applicationInsights) { + this.applicationInsights = applicationInsights; + return this; + } + + /** + * Get the containerRegistry property: ARM id of the container registry associated with this workspace. This cannot + * be changed once the workspace has been created. + * + * @return the containerRegistry value. + */ + public String containerRegistry() { + return this.containerRegistry; + } + + /** + * Set the containerRegistry property: ARM id of the container registry associated with this workspace. This cannot + * be changed once the workspace has been created. + * + * @param containerRegistry the containerRegistry value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withContainerRegistry(String containerRegistry) { + this.containerRegistry = containerRegistry; + return this; + } + + /** + * Get the storageAccount property: ARM id of the storage account associated with this workspace. This cannot be + * changed once the workspace has been created. + * + * @return the storageAccount value. + */ + public String storageAccount() { + return this.storageAccount; + } + + /** + * Set the storageAccount property: ARM id of the storage account associated with this workspace. This cannot be + * changed once the workspace has been created. + * + * @param storageAccount the storageAccount value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withStorageAccount(String storageAccount) { + this.storageAccount = storageAccount; + return this; + } + + /** + * Get the discoveryUrl property: Url for the discovery service to identify regional endpoints for machine learning + * experimentation services. + * + * @return the discoveryUrl value. + */ + public String discoveryUrl() { + return this.discoveryUrl; + } + + /** + * Set the discoveryUrl property: Url for the discovery service to identify regional endpoints for machine learning + * experimentation services. + * + * @param discoveryUrl the discoveryUrl value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withDiscoveryUrl(String discoveryUrl) { + this.discoveryUrl = discoveryUrl; + return this; + } + + /** + * Get the provisioningState property: The current deployment state of workspace resource. The provisioningState is + * to indicate states for resource provisioning. + * + * @return the provisioningState value. + */ + public ProvisioningState provisioningState() { + return this.provisioningState; + } + + /** + * Get the encryption property: The encryption settings of Azure ML workspace. + * + * @return the encryption value. + */ + public EncryptionProperty encryption() { + return this.encryption; + } + + /** + * Set the encryption property: The encryption settings of Azure ML workspace. + * + * @param encryption the encryption value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withEncryption(EncryptionProperty encryption) { + this.encryption = encryption; + return this; + } + + /** + * Get the hbiWorkspace property: The flag to signal HBI data in the workspace and reduce diagnostic data collected + * by the service. + * + * @return the hbiWorkspace value. + */ + public Boolean hbiWorkspace() { + return this.hbiWorkspace; + } + + /** + * Set the hbiWorkspace property: The flag to signal HBI data in the workspace and reduce diagnostic data collected + * by the service. + * + * @param hbiWorkspace the hbiWorkspace value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withHbiWorkspace(Boolean hbiWorkspace) { + this.hbiWorkspace = hbiWorkspace; + return this; + } + + /** + * Get the serviceProvisionedResourceGroup property: The name of the managed resource group created by workspace RP + * in customer subscription if the workspace is CMK workspace. + * + * @return the serviceProvisionedResourceGroup value. + */ + public String serviceProvisionedResourceGroup() { + return this.serviceProvisionedResourceGroup; + } + + /** + * Get the privateLinkCount property: Count of private connections in the workspace. + * + * @return the privateLinkCount value. + */ + public Integer privateLinkCount() { + return this.privateLinkCount; + } + + /** + * Get the imageBuildCompute property: The compute name for image build. + * + * @return the imageBuildCompute value. + */ + public String imageBuildCompute() { + return this.imageBuildCompute; + } + + /** + * Set the imageBuildCompute property: The compute name for image build. + * + * @param imageBuildCompute the imageBuildCompute value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withImageBuildCompute(String imageBuildCompute) { + this.imageBuildCompute = imageBuildCompute; + return this; + } + + /** + * Get the allowPublicAccessWhenBehindVnet property: The flag to indicate whether to allow public access when behind + * VNet. + * + * @return the allowPublicAccessWhenBehindVnet value. + */ + public Boolean allowPublicAccessWhenBehindVnet() { + return this.allowPublicAccessWhenBehindVnet; + } + + /** + * Set the allowPublicAccessWhenBehindVnet property: The flag to indicate whether to allow public access when behind + * VNet. + * + * @param allowPublicAccessWhenBehindVnet the allowPublicAccessWhenBehindVnet value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withAllowPublicAccessWhenBehindVnet(Boolean allowPublicAccessWhenBehindVnet) { + this.allowPublicAccessWhenBehindVnet = allowPublicAccessWhenBehindVnet; + return this; + } + + /** + * Get the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccess publicNetworkAccess() { + return this.publicNetworkAccess; + } + + /** + * Set the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) { + this.publicNetworkAccess = publicNetworkAccess; + return this; + } + + /** + * Get the privateEndpointConnections property: The list of private endpoint connections in the workspace. + * + * @return the privateEndpointConnections value. + */ + public List privateEndpointConnections() { + return this.privateEndpointConnections; + } + + /** + * Get the sharedPrivateLinkResources property: The list of shared private link resources in this workspace. + * + * @return the sharedPrivateLinkResources value. + */ + public List sharedPrivateLinkResources() { + return this.sharedPrivateLinkResources; + } + + /** + * Set the sharedPrivateLinkResources property: The list of shared private link resources in this workspace. + * + * @param sharedPrivateLinkResources the sharedPrivateLinkResources value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withSharedPrivateLinkResources( + List sharedPrivateLinkResources) { + this.sharedPrivateLinkResources = sharedPrivateLinkResources; + return this; + } + + /** + * Get the notebookInfo property: The notebook info of Azure ML workspace. + * + * @return the notebookInfo value. + */ + public NotebookResourceInfoInner notebookInfo() { + return this.notebookInfo; + } + + /** + * Get the serviceManagedResourcesSettings property: The service managed resource settings. + * + * @return the serviceManagedResourcesSettings value. + */ + public ServiceManagedResourcesSettings serviceManagedResourcesSettings() { + return this.serviceManagedResourcesSettings; + } + + /** + * Set the serviceManagedResourcesSettings property: The service managed resource settings. + * + * @param serviceManagedResourcesSettings the serviceManagedResourcesSettings value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withServiceManagedResourcesSettings( + ServiceManagedResourcesSettings serviceManagedResourcesSettings) { + this.serviceManagedResourcesSettings = serviceManagedResourcesSettings; + return this; + } + + /** + * Get the primaryUserAssignedIdentity property: The user assigned identity resource id that represents the + * workspace identity. + * + * @return the primaryUserAssignedIdentity value. + */ + public String primaryUserAssignedIdentity() { + return this.primaryUserAssignedIdentity; + } + + /** + * Set the primaryUserAssignedIdentity property: The user assigned identity resource id that represents the + * workspace identity. + * + * @param primaryUserAssignedIdentity the primaryUserAssignedIdentity value to set. + * @return the WorkspacePropertiesInner object itself. + */ + public WorkspacePropertiesInner withPrimaryUserAssignedIdentity(String primaryUserAssignedIdentity) { + this.primaryUserAssignedIdentity = primaryUserAssignedIdentity; + return this; + } + + /** + * Get the tenantId property: The tenant id associated with this workspace. + * + * @return the tenantId value. + */ + public String tenantId() { + return this.tenantId; + } + + /** + * Get the storageHnsEnabled property: If the storage associated with the workspace has hierarchical namespace(HNS) + * enabled. + * + * @return the storageHnsEnabled value. + */ + public Boolean storageHnsEnabled() { + return this.storageHnsEnabled; + } + + /** + * Get the mlFlowTrackingUri property: The URI associated with this workspace that machine learning flow must point + * at to set up tracking. + * + * @return the mlFlowTrackingUri value. + */ + public String mlFlowTrackingUri() { + return this.mlFlowTrackingUri; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (encryption() != null) { + encryption().validate(); + } + if (privateEndpointConnections() != null) { + privateEndpointConnections().forEach(e -> e.validate()); + } + if (sharedPrivateLinkResources() != null) { + sharedPrivateLinkResources().forEach(e -> e.validate()); + } + if (notebookInfo() != null) { + notebookInfo().validate(); + } + if (serviceManagedResourcesSettings() != null) { + serviceManagedResourcesSettings().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesUpdateParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesUpdateParameters.java new file mode 100644 index 0000000000000..95d92446fe6c0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesUpdateParameters.java @@ -0,0 +1,185 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The parameters for updating the properties of a machine learning workspace. */ +@Fluent +public final class WorkspacePropertiesUpdateParameters { + /* + * The description of this workspace. + */ + @JsonProperty(value = "description") + private String description; + + /* + * The friendly name for this workspace. + */ + @JsonProperty(value = "friendlyName") + private String friendlyName; + + /* + * The compute name for image build + */ + @JsonProperty(value = "imageBuildCompute") + private String imageBuildCompute; + + /* + * The service managed resource settings. + */ + @JsonProperty(value = "serviceManagedResourcesSettings") + private ServiceManagedResourcesSettings serviceManagedResourcesSettings; + + /* + * The user assigned identity resource id that represents the workspace + * identity. + */ + @JsonProperty(value = "primaryUserAssignedIdentity") + private String primaryUserAssignedIdentity; + + /* + * Whether requests from Public Network are allowed. + */ + @JsonProperty(value = "publicNetworkAccess") + private PublicNetworkAccess publicNetworkAccess; + + /** + * Get the description property: The description of this workspace. + * + * @return the description value. + */ + public String description() { + return this.description; + } + + /** + * Set the description property: The description of this workspace. + * + * @param description the description value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withDescription(String description) { + this.description = description; + return this; + } + + /** + * Get the friendlyName property: The friendly name for this workspace. + * + * @return the friendlyName value. + */ + public String friendlyName() { + return this.friendlyName; + } + + /** + * Set the friendlyName property: The friendly name for this workspace. + * + * @param friendlyName the friendlyName value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withFriendlyName(String friendlyName) { + this.friendlyName = friendlyName; + return this; + } + + /** + * Get the imageBuildCompute property: The compute name for image build. + * + * @return the imageBuildCompute value. + */ + public String imageBuildCompute() { + return this.imageBuildCompute; + } + + /** + * Set the imageBuildCompute property: The compute name for image build. + * + * @param imageBuildCompute the imageBuildCompute value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withImageBuildCompute(String imageBuildCompute) { + this.imageBuildCompute = imageBuildCompute; + return this; + } + + /** + * Get the serviceManagedResourcesSettings property: The service managed resource settings. + * + * @return the serviceManagedResourcesSettings value. + */ + public ServiceManagedResourcesSettings serviceManagedResourcesSettings() { + return this.serviceManagedResourcesSettings; + } + + /** + * Set the serviceManagedResourcesSettings property: The service managed resource settings. + * + * @param serviceManagedResourcesSettings the serviceManagedResourcesSettings value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withServiceManagedResourcesSettings( + ServiceManagedResourcesSettings serviceManagedResourcesSettings) { + this.serviceManagedResourcesSettings = serviceManagedResourcesSettings; + return this; + } + + /** + * Get the primaryUserAssignedIdentity property: The user assigned identity resource id that represents the + * workspace identity. + * + * @return the primaryUserAssignedIdentity value. + */ + public String primaryUserAssignedIdentity() { + return this.primaryUserAssignedIdentity; + } + + /** + * Set the primaryUserAssignedIdentity property: The user assigned identity resource id that represents the + * workspace identity. + * + * @param primaryUserAssignedIdentity the primaryUserAssignedIdentity value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withPrimaryUserAssignedIdentity(String primaryUserAssignedIdentity) { + this.primaryUserAssignedIdentity = primaryUserAssignedIdentity; + return this; + } + + /** + * Get the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccess publicNetworkAccess() { + return this.publicNetworkAccess; + } + + /** + * Set the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the WorkspacePropertiesUpdateParameters object itself. + */ + public WorkspacePropertiesUpdateParameters withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) { + this.publicNetworkAccess = publicNetworkAccess; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (serviceManagedResourcesSettings() != null) { + serviceManagedResourcesSettings().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceSkuInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceSkuInner.java index b62edc97d6831..73615cb6795ca 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceSkuInner.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspaceSkuInner.java @@ -5,19 +5,15 @@ package com.azure.resourcemanager.machinelearningservices.fluent.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.models.ResourceSkuLocationInfo; import com.azure.resourcemanager.machinelearningservices.models.Restriction; import com.azure.resourcemanager.machinelearningservices.models.SkuCapability; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Describes Workspace Sku details and features. */ @Fluent public final class WorkspaceSkuInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceSkuInner.class); - /* * The set of locations that the SKU is available. This will be supported * and registered Azure Geo Regions (e.g. West US, East US, Southeast Asia, diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesBuilder.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesBuilder.java index eea90921315f0..fa83654cc236f 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesBuilder.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesBuilder.java @@ -7,7 +7,6 @@ import com.azure.core.annotation.ServiceClientBuilder; import com.azure.core.http.HttpPipeline; import com.azure.core.http.HttpPipelineBuilder; -import com.azure.core.http.policy.CookiePolicy; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; import com.azure.core.management.AzureEnvironment; @@ -19,12 +18,12 @@ @ServiceClientBuilder(serviceClients = {AzureMachineLearningWorkspacesImpl.class}) public final class AzureMachineLearningWorkspacesBuilder { /* - * Azure subscription identifier. + * The ID of the target subscription. */ private String subscriptionId; /** - * Sets Azure subscription identifier. + * Sets The ID of the target subscription. * * @param subscriptionId the subscriptionId value. * @return the AzureMachineLearningWorkspacesBuilder. @@ -67,34 +66,34 @@ public AzureMachineLearningWorkspacesBuilder environment(AzureEnvironment enviro } /* - * The default poll interval for long-running operation + * The HTTP pipeline to send requests through */ - private Duration defaultPollInterval; + private HttpPipeline pipeline; /** - * Sets The default poll interval for long-running operation. + * Sets The HTTP pipeline to send requests through. * - * @param defaultPollInterval the defaultPollInterval value. + * @param pipeline the pipeline value. * @return the AzureMachineLearningWorkspacesBuilder. */ - public AzureMachineLearningWorkspacesBuilder defaultPollInterval(Duration defaultPollInterval) { - this.defaultPollInterval = defaultPollInterval; + public AzureMachineLearningWorkspacesBuilder pipeline(HttpPipeline pipeline) { + this.pipeline = pipeline; return this; } /* - * The HTTP pipeline to send requests through + * The default poll interval for long-running operation */ - private HttpPipeline pipeline; + private Duration defaultPollInterval; /** - * Sets The HTTP pipeline to send requests through. + * Sets The default poll interval for long-running operation. * - * @param pipeline the pipeline value. + * @param defaultPollInterval the defaultPollInterval value. * @return the AzureMachineLearningWorkspacesBuilder. */ - public AzureMachineLearningWorkspacesBuilder pipeline(HttpPipeline pipeline) { - this.pipeline = pipeline; + public AzureMachineLearningWorkspacesBuilder defaultPollInterval(Duration defaultPollInterval) { + this.defaultPollInterval = defaultPollInterval; return this; } @@ -126,15 +125,12 @@ public AzureMachineLearningWorkspacesImpl buildClient() { if (environment == null) { this.environment = AzureEnvironment.AZURE; } + if (pipeline == null) { + this.pipeline = new HttpPipelineBuilder().policies(new UserAgentPolicy(), new RetryPolicy()).build(); + } if (defaultPollInterval == null) { this.defaultPollInterval = Duration.ofSeconds(30); } - if (pipeline == null) { - this.pipeline = - new HttpPipelineBuilder() - .policies(new UserAgentPolicy(), new RetryPolicy(), new CookiePolicy()) - .build(); - } if (serializerAdapter == null) { this.serializerAdapter = SerializerFactory.createDefaultManagementSerializerAdapter(); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesImpl.java index 031355d5ac861..e7ecc52f1bb42 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesImpl.java @@ -22,19 +22,16 @@ import com.azure.core.util.serializer.SerializerAdapter; import com.azure.core.util.serializer.SerializerEncoding; import com.azure.resourcemanager.machinelearningservices.fluent.AzureMachineLearningWorkspaces; -import com.azure.resourcemanager.machinelearningservices.fluent.MachineLearningComputesClient; -import com.azure.resourcemanager.machinelearningservices.fluent.MachineLearningServicesClient; -import com.azure.resourcemanager.machinelearningservices.fluent.NotebooksClient; +import com.azure.resourcemanager.machinelearningservices.fluent.ComputesClient; import com.azure.resourcemanager.machinelearningservices.fluent.OperationsClient; import com.azure.resourcemanager.machinelearningservices.fluent.PrivateEndpointConnectionsClient; import com.azure.resourcemanager.machinelearningservices.fluent.PrivateLinkResourcesClient; import com.azure.resourcemanager.machinelearningservices.fluent.QuotasClient; -import com.azure.resourcemanager.machinelearningservices.fluent.StorageAccountsClient; import com.azure.resourcemanager.machinelearningservices.fluent.UsagesClient; import com.azure.resourcemanager.machinelearningservices.fluent.VirtualMachineSizesClient; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceConnectionsClient; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceFeaturesClient; -import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceOperationsClient; +import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceSkusClient; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspacesClient; import java.io.IOException; import java.lang.reflect.Type; @@ -49,13 +46,11 @@ /** Initializes a new instance of the AzureMachineLearningWorkspacesImpl type. */ @ServiceClient(builder = AzureMachineLearningWorkspacesBuilder.class) public final class AzureMachineLearningWorkspacesImpl implements AzureMachineLearningWorkspaces { - private final ClientLogger logger = new ClientLogger(AzureMachineLearningWorkspacesImpl.class); - - /** Azure subscription identifier. */ + /** The ID of the target subscription. */ private final String subscriptionId; /** - * Gets Azure subscription identifier. + * Gets The ID of the target subscription. * * @return the subscriptionId value. */ @@ -147,18 +142,6 @@ public WorkspacesClient getWorkspaces() { return this.workspaces; } - /** The WorkspaceFeaturesClient object to access its operations. */ - private final WorkspaceFeaturesClient workspaceFeatures; - - /** - * Gets the WorkspaceFeaturesClient object to access its operations. - * - * @return the WorkspaceFeaturesClient object. - */ - public WorkspaceFeaturesClient getWorkspaceFeatures() { - return this.workspaceFeatures; - } - /** The UsagesClient object to access its operations. */ private final UsagesClient usages; @@ -195,28 +178,16 @@ public QuotasClient getQuotas() { return this.quotas; } - /** The MachineLearningComputesClient object to access its operations. */ - private final MachineLearningComputesClient machineLearningComputes; + /** The ComputesClient object to access its operations. */ + private final ComputesClient computes; /** - * Gets the MachineLearningComputesClient object to access its operations. + * Gets the ComputesClient object to access its operations. * - * @return the MachineLearningComputesClient object. + * @return the ComputesClient object. */ - public MachineLearningComputesClient getMachineLearningComputes() { - return this.machineLearningComputes; - } - - /** The WorkspaceOperationsClient object to access its operations. */ - private final WorkspaceOperationsClient workspaceOperations; - - /** - * Gets the WorkspaceOperationsClient object to access its operations. - * - * @return the WorkspaceOperationsClient object. - */ - public WorkspaceOperationsClient getWorkspaceOperations() { - return this.workspaceOperations; + public ComputesClient getComputes() { + return this.computes; } /** The PrivateEndpointConnectionsClient object to access its operations. */ @@ -243,52 +214,40 @@ public PrivateLinkResourcesClient getPrivateLinkResources() { return this.privateLinkResources; } - /** The MachineLearningServicesClient object to access its operations. */ - private final MachineLearningServicesClient machineLearningServices; - - /** - * Gets the MachineLearningServicesClient object to access its operations. - * - * @return the MachineLearningServicesClient object. - */ - public MachineLearningServicesClient getMachineLearningServices() { - return this.machineLearningServices; - } - - /** The NotebooksClient object to access its operations. */ - private final NotebooksClient notebooks; + /** The WorkspaceConnectionsClient object to access its operations. */ + private final WorkspaceConnectionsClient workspaceConnections; /** - * Gets the NotebooksClient object to access its operations. + * Gets the WorkspaceConnectionsClient object to access its operations. * - * @return the NotebooksClient object. + * @return the WorkspaceConnectionsClient object. */ - public NotebooksClient getNotebooks() { - return this.notebooks; + public WorkspaceConnectionsClient getWorkspaceConnections() { + return this.workspaceConnections; } - /** The StorageAccountsClient object to access its operations. */ - private final StorageAccountsClient storageAccounts; + /** The WorkspaceFeaturesClient object to access its operations. */ + private final WorkspaceFeaturesClient workspaceFeatures; /** - * Gets the StorageAccountsClient object to access its operations. + * Gets the WorkspaceFeaturesClient object to access its operations. * - * @return the StorageAccountsClient object. + * @return the WorkspaceFeaturesClient object. */ - public StorageAccountsClient getStorageAccounts() { - return this.storageAccounts; + public WorkspaceFeaturesClient getWorkspaceFeatures() { + return this.workspaceFeatures; } - /** The WorkspaceConnectionsClient object to access its operations. */ - private final WorkspaceConnectionsClient workspaceConnections; + /** The WorkspaceSkusClient object to access its operations. */ + private final WorkspaceSkusClient workspaceSkus; /** - * Gets the WorkspaceConnectionsClient object to access its operations. + * Gets the WorkspaceSkusClient object to access its operations. * - * @return the WorkspaceConnectionsClient object. + * @return the WorkspaceSkusClient object. */ - public WorkspaceConnectionsClient getWorkspaceConnections() { - return this.workspaceConnections; + public WorkspaceSkusClient getWorkspaceSkus() { + return this.workspaceSkus; } /** @@ -298,7 +257,7 @@ public WorkspaceConnectionsClient getWorkspaceConnections() { * @param serializerAdapter The serializer to serialize an object into a string. * @param defaultPollInterval The default poll interval for long-running operation. * @param environment The Azure environment. - * @param subscriptionId Azure subscription identifier. + * @param subscriptionId The ID of the target subscription. * @param endpoint server parameter. */ AzureMachineLearningWorkspacesImpl( @@ -313,21 +272,18 @@ public WorkspaceConnectionsClient getWorkspaceConnections() { this.defaultPollInterval = defaultPollInterval; this.subscriptionId = subscriptionId; this.endpoint = endpoint; - this.apiVersion = "2021-04-01"; + this.apiVersion = "2021-07-01"; this.operations = new OperationsClientImpl(this); this.workspaces = new WorkspacesClientImpl(this); - this.workspaceFeatures = new WorkspaceFeaturesClientImpl(this); this.usages = new UsagesClientImpl(this); this.virtualMachineSizes = new VirtualMachineSizesClientImpl(this); this.quotas = new QuotasClientImpl(this); - this.machineLearningComputes = new MachineLearningComputesClientImpl(this); - this.workspaceOperations = new WorkspaceOperationsClientImpl(this); + this.computes = new ComputesClientImpl(this); this.privateEndpointConnections = new PrivateEndpointConnectionsClientImpl(this); this.privateLinkResources = new PrivateLinkResourcesClientImpl(this); - this.machineLearningServices = new MachineLearningServicesClientImpl(this); - this.notebooks = new NotebooksClientImpl(this); - this.storageAccounts = new StorageAccountsClientImpl(this); this.workspaceConnections = new WorkspaceConnectionsClientImpl(this); + this.workspaceFeatures = new WorkspaceFeaturesClientImpl(this); + this.workspaceSkus = new WorkspaceSkusClientImpl(this); } /** @@ -413,7 +369,7 @@ public Mono getLroFinalResultOrError(AsyncPollResponse, managementError = null; } } catch (IOException | RuntimeException ioe) { - logger.logThrowableAsWarning(ioe); + LOGGER.logThrowableAsWarning(ioe); } } } else { @@ -472,4 +428,6 @@ public Mono getBodyAsString(Charset charset) { return Mono.just(new String(responseBody, charset)); } } + + private static final ClientLogger LOGGER = new ClientLogger(AzureMachineLearningWorkspacesImpl.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputeResourceImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputeResourceImpl.java index 340f21513bf74..7d0a295ca8201 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputeResourceImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputeResourceImpl.java @@ -16,7 +16,7 @@ import com.azure.resourcemanager.machinelearningservices.models.ComputeResource; import com.azure.resourcemanager.machinelearningservices.models.ComputeSecrets; import com.azure.resourcemanager.machinelearningservices.models.Identity; -import com.azure.resourcemanager.machinelearningservices.models.ScaleSettings; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettingsInformation; import com.azure.resourcemanager.machinelearningservices.models.Sku; import java.util.Collections; import java.util.Map; @@ -38,6 +38,10 @@ public String type() { return this.innerModel().type(); } + public Identity identity() { + return this.innerModel().identity(); + } + public String location() { return this.innerModel().location(); } @@ -51,14 +55,6 @@ public Map tags() { } } - public Compute properties() { - return this.innerModel().properties(); - } - - public Identity identity() { - return this.innerModel().identity(); - } - public Sku sku() { return this.innerModel().sku(); } @@ -67,6 +63,10 @@ public SystemData systemData() { return this.innerModel().systemData(); } + public Compute properties() { + return this.innerModel().properties(); + } + public Region region() { return Region.fromName(this.regionName()); } @@ -101,7 +101,7 @@ public ComputeResource create() { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .createOrUpdate(resourceGroupName, workspaceName, computeName, this.innerModel(), Context.NONE); return this; } @@ -110,7 +110,7 @@ public ComputeResource create(Context context) { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .createOrUpdate(resourceGroupName, workspaceName, computeName, this.innerModel(), context); return this; } @@ -131,7 +131,7 @@ public ComputeResource apply() { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .update(resourceGroupName, workspaceName, computeName, updateParameters, Context.NONE); return this; } @@ -140,7 +140,7 @@ public ComputeResource apply(Context context) { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .update(resourceGroupName, workspaceName, computeName, updateParameters, context); return this; } @@ -159,7 +159,7 @@ public ComputeResource refresh() { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .getWithResponse(resourceGroupName, workspaceName, computeName, Context.NONE) .getValue(); return this; @@ -169,56 +169,50 @@ public ComputeResource refresh(Context context) { this.innerObject = serviceManager .serviceClient() - .getMachineLearningComputes() + .getComputes() .getWithResponse(resourceGroupName, workspaceName, computeName, context) .getValue(); return this; } public PagedIterable listNodes() { - return serviceManager.machineLearningComputes().listNodes(resourceGroupName, workspaceName, computeName); + return serviceManager.computes().listNodes(resourceGroupName, workspaceName, computeName); } public PagedIterable listNodes(Context context) { - return serviceManager - .machineLearningComputes() - .listNodes(resourceGroupName, workspaceName, computeName, context); + return serviceManager.computes().listNodes(resourceGroupName, workspaceName, computeName, context); } public ComputeSecrets listKeys() { - return serviceManager.machineLearningComputes().listKeys(resourceGroupName, workspaceName, computeName); + return serviceManager.computes().listKeys(resourceGroupName, workspaceName, computeName); } public Response listKeysWithResponse(Context context) { - return serviceManager - .machineLearningComputes() - .listKeysWithResponse(resourceGroupName, workspaceName, computeName, context); + return serviceManager.computes().listKeysWithResponse(resourceGroupName, workspaceName, computeName, context); } public void start() { - serviceManager.machineLearningComputes().start(resourceGroupName, workspaceName, computeName); + serviceManager.computes().start(resourceGroupName, workspaceName, computeName); } public void start(Context context) { - serviceManager.machineLearningComputes().start(resourceGroupName, workspaceName, computeName, context); + serviceManager.computes().start(resourceGroupName, workspaceName, computeName, context); } public void stop() { - serviceManager.machineLearningComputes().stop(resourceGroupName, workspaceName, computeName); + serviceManager.computes().stop(resourceGroupName, workspaceName, computeName); } public void stop(Context context) { - serviceManager.machineLearningComputes().stop(resourceGroupName, workspaceName, computeName, context); + serviceManager.computes().stop(resourceGroupName, workspaceName, computeName, context); } public void restart() { - serviceManager.machineLearningComputes().restart(resourceGroupName, workspaceName, computeName); + serviceManager.computes().restart(resourceGroupName, workspaceName, computeName); } - public Response restartWithResponse(Context context) { - return serviceManager - .machineLearningComputes() - .restartWithResponse(resourceGroupName, workspaceName, computeName, context); + public void restart(Context context) { + serviceManager.computes().restart(resourceGroupName, workspaceName, computeName, context); } public ComputeResourceImpl withRegion(Region location) { @@ -236,11 +230,6 @@ public ComputeResourceImpl withTags(Map tags) { return this; } - public ComputeResourceImpl withProperties(Compute properties) { - this.innerModel().withProperties(properties); - return this; - } - public ComputeResourceImpl withIdentity(Identity identity) { this.innerModel().withIdentity(identity); return this; @@ -251,8 +240,13 @@ public ComputeResourceImpl withSku(Sku sku) { return this; } - public ComputeResourceImpl withScaleSettings(ScaleSettings scaleSettings) { - this.updateParameters.withScaleSettings(scaleSettings); + public ComputeResourceImpl withProperties(Compute properties) { + this.innerModel().withProperties(properties); + return this; + } + + public ComputeResourceImpl withProperties(ScaleSettingsInformation properties) { + this.updateParameters.withProperties(properties); return this; } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesClientImpl.java similarity index 83% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesClientImpl.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesClientImpl.java index 486c37c45ef22..5f3f7380da491 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesClientImpl.java @@ -31,10 +31,9 @@ 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.machinelearningservices.fluent.MachineLearningComputesClient; +import com.azure.resourcemanager.machinelearningservices.fluent.ComputesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeResourceInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeSecretsInner; import com.azure.resourcemanager.machinelearningservices.models.AmlComputeNodeInformation; @@ -46,42 +45,38 @@ import reactor.core.publisher.Flux; import reactor.core.publisher.Mono; -/** An instance of this class provides access to all the operations defined in MachineLearningComputesClient. */ -public final class MachineLearningComputesClientImpl implements MachineLearningComputesClient { - private final ClientLogger logger = new ClientLogger(MachineLearningComputesClientImpl.class); - +/** An instance of this class provides access to all the operations defined in ComputesClient. */ +public final class ComputesClientImpl implements ComputesClient { /** The proxy service used to perform REST calls. */ - private final MachineLearningComputesService service; + private final ComputesService service; /** The service client containing this operation class. */ private final AzureMachineLearningWorkspacesImpl client; /** - * Initializes an instance of MachineLearningComputesClientImpl. + * Initializes an instance of ComputesClientImpl. * * @param client the instance of the service client containing this operation class. */ - MachineLearningComputesClientImpl(AzureMachineLearningWorkspacesImpl client) { - this.service = - RestProxy - .create(MachineLearningComputesService.class, client.getHttpPipeline(), client.getSerializerAdapter()); + ComputesClientImpl(AzureMachineLearningWorkspacesImpl client) { + this.service = RestProxy.create(ComputesService.class, client.getHttpPipeline(), client.getSerializerAdapter()); this.client = client; } /** - * The interface defining all the services for AzureMachineLearningWorkspacesMachineLearningComputes to be used by - * the proxy service to perform REST calls. + * The interface defining all the services for AzureMachineLearningWorkspacesComputes to be used by the proxy + * service to perform REST calls. */ @Host("{$host}") @ServiceInterface(name = "AzureMachineLearning") - private interface MachineLearningComputesService { + private interface ComputesService { @Headers({"Content-Type: application/json"}) @Get( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/computes") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listByWorkspace( + Mono> list( @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId, @PathParam("resourceGroupName") String resourceGroupName, @@ -226,9 +221,9 @@ Mono>> stop( @Post( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/computes/{computeName}/restart") - @ExpectedResponses({200}) + @ExpectedResponses({202}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> restart( + Mono>> restart( @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId, @PathParam("resourceGroupName") String resourceGroupName, @@ -242,7 +237,7 @@ Mono> restart( @Get("{nextLink}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listByWorkspaceNext( + Mono> listNext( @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint, @HeaderParam("Accept") String accept, @@ -262,16 +257,17 @@ Mono> listNodesNext( /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 computes in specified workspace. + * @return computes in specified workspace along with {@link PagedResponse} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceSinglePageAsync( + private Mono> listSinglePageAsync( String resourceGroupName, String workspaceName, String skip) { if (this.client.getEndpoint() == null) { return Mono @@ -297,7 +293,7 @@ private Mono> listByWorkspaceSinglePageAsync .withContext( context -> service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -321,17 +317,18 @@ private Mono> listByWorkspaceSinglePageAsync /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @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 computes in specified workspace. + * @return computes in specified workspace along with {@link PagedResponse} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceSinglePageAsync( + private Mono> listSinglePageAsync( String resourceGroupName, String workspaceName, String skip, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -355,7 +352,7 @@ private Mono> listByWorkspaceSinglePageAsync final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -378,105 +375,104 @@ private Mono> listByWorkspaceSinglePageAsync /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync( - String resourceGroupName, String workspaceName, String skip) { + private PagedFlux listAsync(String resourceGroupName, String workspaceName, String skip) { return new PagedFlux<>( - () -> listByWorkspaceSinglePageAsync(resourceGroupName, workspaceName, skip), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink)); + () -> listSinglePageAsync(resourceGroupName, workspaceName, skip), + nextLink -> listNextSinglePageAsync(nextLink)); } /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync(String resourceGroupName, String workspaceName) { + private PagedFlux listAsync(String resourceGroupName, String workspaceName) { final String skip = null; return new PagedFlux<>( - () -> listByWorkspaceSinglePageAsync(resourceGroupName, workspaceName, skip), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink)); + () -> listSinglePageAsync(resourceGroupName, workspaceName, skip), + nextLink -> listNextSinglePageAsync(nextLink)); } /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync( + private PagedFlux listAsync( String resourceGroupName, String workspaceName, String skip, Context context) { return new PagedFlux<>( - () -> listByWorkspaceSinglePageAsync(resourceGroupName, workspaceName, skip, context), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink, context)); + () -> listSinglePageAsync(resourceGroupName, workspaceName, skip, context), + nextLink -> listNextSinglePageAsync(nextLink, context)); } /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listByWorkspace(String resourceGroupName, String workspaceName) { + public PagedIterable list(String resourceGroupName, String workspaceName) { final String skip = null; - return new PagedIterable<>(listByWorkspaceAsync(resourceGroupName, workspaceName, skip)); + return new PagedIterable<>(listAsync(resourceGroupName, workspaceName, skip)); } /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listByWorkspace( + public PagedIterable list( String resourceGroupName, String workspaceName, String skip, Context context) { - return new PagedIterable<>(listByWorkspaceAsync(resourceGroupName, workspaceName, skip, context)); + return new PagedIterable<>(listAsync(resourceGroupName, workspaceName, skip, context)); } /** * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -524,14 +520,14 @@ private Mono> getWithResponseAsync( * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -576,13 +572,13 @@ private Mono> getWithResponseAsync( * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 compute definition by its name. + * @return compute definition by its name on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync(String resourceGroupName, String workspaceName, String computeName) { @@ -601,7 +597,7 @@ private Mono getAsync(String resourceGroupName, String wor * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -618,14 +614,14 @@ public ComputeResourceInner get(String resourceGroupName, String workspaceName, * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getWithResponse( @@ -637,14 +633,15 @@ public Response getWithResponse( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -698,7 +695,7 @@ private Mono>> createOrUpdateWithResponseAsync( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -706,7 +703,8 @@ private Mono>> createOrUpdateWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -761,16 +759,16 @@ private Mono>> createOrUpdateWithResponseAsync( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link PollerFlux} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, ComputeResourceInner> beginCreateOrUpdateAsync( String resourceGroupName, String workspaceName, String computeName, ComputeResourceInner parameters) { Mono>> mono = @@ -782,14 +780,14 @@ private PollerFlux, ComputeResourceInner> begin this.client.getHttpPipeline(), ComputeResourceInner.class, ComputeResourceInner.class, - Context.NONE); + this.client.getContext()); } /** * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -797,9 +795,9 @@ private PollerFlux, ComputeResourceInner> begin * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link PollerFlux} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, ComputeResourceInner> beginCreateOrUpdateAsync( String resourceGroupName, String workspaceName, @@ -819,16 +817,16 @@ private PollerFlux, ComputeResourceInner> begin * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, ComputeResourceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, String computeName, ComputeResourceInner parameters) { return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, computeName, parameters).getSyncPoller(); @@ -838,7 +836,7 @@ public SyncPoller, ComputeResourceInner> beginC * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -846,9 +844,9 @@ public SyncPoller, ComputeResourceInner> beginC * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, ComputeResourceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, @@ -863,14 +861,15 @@ public SyncPoller, ComputeResourceInner> beginC * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -884,7 +883,7 @@ private Mono createOrUpdateAsync( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -892,7 +891,8 @@ private Mono createOrUpdateAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -910,7 +910,7 @@ private Mono createOrUpdateAsync( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -929,7 +929,7 @@ public ComputeResourceInner createOrUpdate( * Creates or updates compute. This call will overwrite a compute if it exists. This is a nonrecoverable operation. * If your intent is to create a new compute, do a GET first to verify that it does not exist yet. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Payload with Machine Learning compute definition. @@ -953,14 +953,15 @@ public ComputeResourceInner createOrUpdate( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> updateWithResponseAsync( @@ -1014,7 +1015,7 @@ private Mono>> updateWithResponseAsync( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1022,7 +1023,8 @@ private Mono>> updateWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> updateWithResponseAsync( @@ -1077,16 +1079,16 @@ private Mono>> updateWithResponseAsync( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link PollerFlux} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, ComputeResourceInner> beginUpdateAsync( String resourceGroupName, String workspaceName, String computeName, ClusterUpdateParameters parameters) { Mono>> mono = @@ -1098,14 +1100,14 @@ private PollerFlux, ComputeResourceInner> begin this.client.getHttpPipeline(), ComputeResourceInner.class, ComputeResourceInner.class, - Context.NONE); + this.client.getContext()); } /** * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1113,9 +1115,9 @@ private PollerFlux, ComputeResourceInner> begin * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link PollerFlux} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, ComputeResourceInner> beginUpdateAsync( String resourceGroupName, String workspaceName, @@ -1135,16 +1137,16 @@ private PollerFlux, ComputeResourceInner> begin * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, ComputeResourceInner> beginUpdate( String resourceGroupName, String workspaceName, String computeName, ClusterUpdateParameters parameters) { return beginUpdateAsync(resourceGroupName, workspaceName, computeName, parameters).getSyncPoller(); @@ -1154,7 +1156,7 @@ public SyncPoller, ComputeResourceInner> beginU * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1162,9 +1164,9 @@ public SyncPoller, ComputeResourceInner> beginU * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return the {@link SyncPoller} for polling of machine Learning compute object wrapped into ARM resource envelope. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, ComputeResourceInner> beginUpdate( String resourceGroupName, String workspaceName, @@ -1178,14 +1180,15 @@ public SyncPoller, ComputeResourceInner> beginU * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -1199,7 +1202,7 @@ private Mono updateAsync( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1207,7 +1210,8 @@ private Mono updateAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 machine Learning compute object wrapped into ARM resource envelope. + * @return machine Learning compute object wrapped into ARM resource envelope on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -1225,7 +1229,7 @@ private Mono updateAsync( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1244,7 +1248,7 @@ public ComputeResourceInner update( * Updates properties of a compute. This call will overwrite a compute if it exists. This is a nonrecoverable * operation. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param parameters Additional parameters for cluster update. @@ -1267,7 +1271,7 @@ public ComputeResourceInner update( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1275,7 +1279,7 @@ public ComputeResourceInner update( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -1331,7 +1335,7 @@ private Mono>> deleteWithResponseAsync( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1340,7 +1344,7 @@ private Mono>> deleteWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -1394,7 +1398,7 @@ private Mono>> deleteWithResponseAsync( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1402,9 +1406,9 @@ private Mono>> deleteWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String workspaceName, @@ -1414,13 +1418,14 @@ private PollerFlux, Void> beginDeleteAsync( deleteWithResponseAsync(resourceGroupName, workspaceName, computeName, underlyingResourceAction); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1429,9 +1434,9 @@ private PollerFlux, Void> beginDeleteAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String workspaceName, @@ -1449,7 +1454,7 @@ private PollerFlux, Void> beginDeleteAsync( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1457,9 +1462,9 @@ private PollerFlux, Void> beginDeleteAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -1472,7 +1477,7 @@ public SyncPoller, Void> beginDelete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1481,9 +1486,9 @@ public SyncPoller, Void> beginDelete( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -1497,7 +1502,7 @@ public SyncPoller, Void> beginDelete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1505,7 +1510,7 @@ public SyncPoller, Void> beginDelete( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -1521,7 +1526,7 @@ private Mono deleteAsync( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1530,7 +1535,7 @@ private Mono deleteAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -1547,7 +1552,7 @@ private Mono deleteAsync( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1568,7 +1573,7 @@ public void delete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -1591,13 +1596,14 @@ public void delete( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesSinglePageAsync( @@ -1653,14 +1659,15 @@ private Mono> listNodesSinglePageAsync( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesSinglePageAsync( @@ -1713,13 +1720,14 @@ private Mono> listNodesSinglePageAsync( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listNodesAsync( @@ -1732,14 +1740,15 @@ private PagedFlux listNodesAsync( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listNodesAsync( @@ -1752,13 +1761,14 @@ private PagedFlux listNodesAsync( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listNodes( @@ -1769,14 +1779,15 @@ public PagedIterable listNodes( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listNodes( @@ -1787,13 +1798,14 @@ public PagedIterable listNodes( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listKeysWithResponseAsync( @@ -1840,14 +1852,15 @@ private Mono> listKeysWithResponseAsync( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listKeysWithResponseAsync( @@ -1891,13 +1904,14 @@ private Mono> listKeysWithResponseAsync( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono listKeysAsync( @@ -1916,7 +1930,7 @@ private Mono listKeysAsync( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1932,14 +1946,15 @@ public ComputeSecretsInner listKeys(String resourceGroupName, String workspaceNa /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response listKeysWithResponse( @@ -1950,13 +1965,13 @@ public Response listKeysWithResponse( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> startWithResponseAsync( @@ -2003,14 +2018,14 @@ private Mono>> startWithResponseAsync( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> startWithResponseAsync( @@ -2054,36 +2069,37 @@ private Mono>> startWithResponseAsync( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginStartAsync( String resourceGroupName, String workspaceName, String computeName) { Mono>> mono = startWithResponseAsync(resourceGroupName, workspaceName, computeName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginStartAsync( String resourceGroupName, String workspaceName, String computeName, Context context) { context = this.client.mergeContext(context); @@ -2097,15 +2113,15 @@ private PollerFlux, Void> beginStartAsync( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginStart( String resourceGroupName, String workspaceName, String computeName) { return beginStartAsync(resourceGroupName, workspaceName, computeName).getSyncPoller(); @@ -2114,16 +2130,16 @@ public SyncPoller, Void> beginStart( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginStart( String resourceGroupName, String workspaceName, String computeName, Context context) { return beginStartAsync(resourceGroupName, workspaceName, computeName, context).getSyncPoller(); @@ -2132,13 +2148,13 @@ public SyncPoller, Void> beginStart( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono startAsync(String resourceGroupName, String workspaceName, String computeName) { @@ -2150,14 +2166,14 @@ private Mono startAsync(String resourceGroupName, String workspaceName, St /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono startAsync(String resourceGroupName, String workspaceName, String computeName, Context context) { @@ -2169,7 +2185,7 @@ private Mono startAsync(String resourceGroupName, String workspaceName, St /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2184,7 +2200,7 @@ public void start(String resourceGroupName, String workspaceName, String compute /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -2200,13 +2216,13 @@ public void start(String resourceGroupName, String workspaceName, String compute /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> stopWithResponseAsync( @@ -2253,14 +2269,14 @@ private Mono>> stopWithResponseAsync( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> stopWithResponseAsync( @@ -2304,36 +2320,37 @@ private Mono>> stopWithResponseAsync( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginStopAsync( String resourceGroupName, String workspaceName, String computeName) { Mono>> mono = stopWithResponseAsync(resourceGroupName, workspaceName, computeName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginStopAsync( String resourceGroupName, String workspaceName, String computeName, Context context) { context = this.client.mergeContext(context); @@ -2347,15 +2364,15 @@ private PollerFlux, Void> beginStopAsync( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginStop( String resourceGroupName, String workspaceName, String computeName) { return beginStopAsync(resourceGroupName, workspaceName, computeName).getSyncPoller(); @@ -2364,16 +2381,16 @@ public SyncPoller, Void> beginStop( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginStop( String resourceGroupName, String workspaceName, String computeName, Context context) { return beginStopAsync(resourceGroupName, workspaceName, computeName, context).getSyncPoller(); @@ -2382,13 +2399,13 @@ public SyncPoller, Void> beginStop( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono stopAsync(String resourceGroupName, String workspaceName, String computeName) { @@ -2400,14 +2417,14 @@ private Mono stopAsync(String resourceGroupName, String workspaceName, Str /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono stopAsync(String resourceGroupName, String workspaceName, String computeName, Context context) { @@ -2419,7 +2436,7 @@ private Mono stopAsync(String resourceGroupName, String workspaceName, Str /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2434,7 +2451,7 @@ public void stop(String resourceGroupName, String workspaceName, String computeN /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -2450,16 +2467,16 @@ public void stop(String resourceGroupName, String workspaceName, String computeN /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> restartWithResponseAsync( + private Mono>> restartWithResponseAsync( String resourceGroupName, String workspaceName, String computeName) { if (this.client.getEndpoint() == null) { return Mono @@ -2503,17 +2520,17 @@ private Mono> restartWithResponseAsync( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> restartWithResponseAsync( + private Mono>> restartWithResponseAsync( String resourceGroupName, String workspaceName, String computeName, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -2554,24 +2571,124 @@ private Mono> restartWithResponseAsync( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginRestartAsync( + String resourceGroupName, String workspaceName, String computeName) { + Mono>> mono = restartWithResponseAsync(resourceGroupName, workspaceName, computeName); + return this + .client + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); + } + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginRestartAsync( + String resourceGroupName, String workspaceName, String computeName, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + restartWithResponseAsync(resourceGroupName, workspaceName, computeName, context); + return this + .client + .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context); + } + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginRestart( + String resourceGroupName, String workspaceName, String computeName) { + return beginRestartAsync(resourceGroupName, workspaceName, computeName).getSyncPoller(); + } + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, Void> beginRestart( + String resourceGroupName, String workspaceName, String computeName, Context context) { + return beginRestartAsync(resourceGroupName, workspaceName, computeName, context).getSyncPoller(); + } + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono restartAsync(String resourceGroupName, String workspaceName, String computeName) { - return restartWithResponseAsync(resourceGroupName, workspaceName, computeName) - .flatMap((Response res) -> Mono.empty()); + return beginRestartAsync(resourceGroupName, workspaceName, computeName) + .last() + .flatMap(this.client::getLroFinalResultOrError); } /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param computeName Name of the Azure Machine Learning compute. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return A {@link Mono} that completes when a successful response is received. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono restartAsync( + String resourceGroupName, String workspaceName, String computeName, Context context) { + return beginRestartAsync(resourceGroupName, workspaceName, computeName, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Posts a restart action to a compute instance. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -2586,19 +2703,17 @@ public void restart(String resourceGroupName, String workspaceName, String compu /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response restartWithResponse( - String resourceGroupName, String workspaceName, String computeName, Context context) { - return restartWithResponseAsync(resourceGroupName, workspaceName, computeName, context).block(); + public void restart(String resourceGroupName, String workspaceName, String computeName, Context context) { + restartAsync(resourceGroupName, workspaceName, computeName, context).block(); } /** @@ -2608,10 +2723,11 @@ public Response restartWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Machine Learning compute objects wrapped in ARM resource envelope. + * @return paginated list of Machine Learning compute objects wrapped in ARM resource envelope along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceNextSinglePageAsync(String nextLink) { + private Mono> listNextSinglePageAsync(String nextLink) { if (nextLink == null) { return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null.")); } @@ -2623,7 +2739,7 @@ private Mono> listByWorkspaceNextSinglePageA } final String accept = "application/json"; return FluxUtil - .withContext(context -> service.listByWorkspaceNext(nextLink, this.client.getEndpoint(), accept, context)) + .withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context)) .>map( res -> new PagedResponseBase<>( @@ -2644,11 +2760,11 @@ private Mono> listByWorkspaceNextSinglePageA * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Machine Learning compute objects wrapped in ARM resource envelope. + * @return paginated list of Machine Learning compute objects wrapped in ARM resource envelope along with {@link + * PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceNextSinglePageAsync( - String nextLink, Context context) { + private Mono> listNextSinglePageAsync(String nextLink, Context context) { if (nextLink == null) { return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null.")); } @@ -2661,7 +2777,7 @@ private Mono> listByWorkspaceNextSinglePageA final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listByWorkspaceNext(nextLink, this.client.getEndpoint(), accept, context) + .listNext(nextLink, this.client.getEndpoint(), accept, context) .map( res -> new PagedResponseBase<>( @@ -2680,7 +2796,7 @@ private Mono> listByWorkspaceNextSinglePageA * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 compute node information related to a AmlCompute. + * @return result of AmlCompute Nodes along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesNextSinglePageAsync(String nextLink) { @@ -2716,7 +2832,7 @@ private Mono> listNodesNextSinglePageAs * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 compute node information related to a AmlCompute. + * @return result of AmlCompute Nodes along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesNextSinglePageAsync( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesImpl.java similarity index 86% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesImpl.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesImpl.java index 696a32929219e..445d5da130f6b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningComputesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ComputesImpl.java @@ -9,40 +9,38 @@ import com.azure.core.http.rest.SimpleResponse; import com.azure.core.util.Context; import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.fluent.MachineLearningComputesClient; +import com.azure.resourcemanager.machinelearningservices.fluent.ComputesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeResourceInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeSecretsInner; import com.azure.resourcemanager.machinelearningservices.models.AmlComputeNodeInformation; import com.azure.resourcemanager.machinelearningservices.models.ComputeResource; import com.azure.resourcemanager.machinelearningservices.models.ComputeSecrets; -import com.azure.resourcemanager.machinelearningservices.models.MachineLearningComputes; +import com.azure.resourcemanager.machinelearningservices.models.Computes; import com.azure.resourcemanager.machinelearningservices.models.UnderlyingResourceAction; -import com.fasterxml.jackson.annotation.JsonIgnore; -public final class MachineLearningComputesImpl implements MachineLearningComputes { - @JsonIgnore private final ClientLogger logger = new ClientLogger(MachineLearningComputesImpl.class); +public final class ComputesImpl implements Computes { + private static final ClientLogger LOGGER = new ClientLogger(ComputesImpl.class); - private final MachineLearningComputesClient innerClient; + private final ComputesClient innerClient; private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - public MachineLearningComputesImpl( - MachineLearningComputesClient innerClient, + public ComputesImpl( + ComputesClient innerClient, com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { this.innerClient = innerClient; this.serviceManager = serviceManager; } - public PagedIterable listByWorkspace(String resourceGroupName, String workspaceName) { - PagedIterable inner = - this.serviceClient().listByWorkspace(resourceGroupName, workspaceName); + public PagedIterable list(String resourceGroupName, String workspaceName) { + PagedIterable inner = this.serviceClient().list(resourceGroupName, workspaceName); return Utils.mapPage(inner, inner1 -> new ComputeResourceImpl(inner1, this.manager())); } - public PagedIterable listByWorkspace( + public PagedIterable list( String resourceGroupName, String workspaceName, String skip, Context context) { PagedIterable inner = - this.serviceClient().listByWorkspace(resourceGroupName, workspaceName, skip, context); + this.serviceClient().list(resourceGroupName, workspaceName, skip, context); return Utils.mapPage(inner, inner1 -> new ComputeResourceImpl(inner1, this.manager())); } @@ -141,15 +139,14 @@ public void restart(String resourceGroupName, String workspaceName, String compu this.serviceClient().restart(resourceGroupName, workspaceName, computeName); } - public Response restartWithResponse( - String resourceGroupName, String workspaceName, String computeName, Context context) { - return this.serviceClient().restartWithResponse(resourceGroupName, workspaceName, computeName, context); + public void restart(String resourceGroupName, String workspaceName, String computeName, Context context) { + this.serviceClient().restart(resourceGroupName, workspaceName, computeName, context); } public ComputeResource getById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -157,14 +154,14 @@ public ComputeResource getById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String computeName = Utils.getValueFromIdByName(id, "computes"); if (computeName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'computes'.", id))); @@ -175,7 +172,7 @@ public ComputeResource getById(String id) { public Response getByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -183,14 +180,14 @@ public Response getByIdWithResponse(String id, Context context) } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String computeName = Utils.getValueFromIdByName(id, "computes"); if (computeName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'computes'.", id))); @@ -198,7 +195,7 @@ public Response getByIdWithResponse(String id, Context context) return this.getWithResponse(resourceGroupName, workspaceName, computeName, context); } - private MachineLearningComputesClient serviceClient() { + private ComputesClient serviceClient() { return this.innerClient; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/DiagnoseResponseResultImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/DiagnoseResponseResultImpl.java new file mode 100644 index 0000000000000..75e22c7aec84d --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/DiagnoseResponseResultImpl.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.machinelearningservices.implementation; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResult; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResultValue; + +public final class DiagnoseResponseResultImpl implements DiagnoseResponseResult { + private DiagnoseResponseResultInner innerObject; + + private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; + + DiagnoseResponseResultImpl( + DiagnoseResponseResultInner innerObject, + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + } + + public DiagnoseResponseResultValue value() { + return this.innerModel().value(); + } + + public DiagnoseResponseResultInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { + return this.serviceManager; + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ExternalFqdnResponseImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ExternalFqdnResponseImpl.java new file mode 100644 index 0000000000000..2867c90490d22 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ExternalFqdnResponseImpl.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.machinelearningservices.implementation; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner; +import com.azure.resourcemanager.machinelearningservices.models.ExternalFqdnResponse; +import com.azure.resourcemanager.machinelearningservices.models.FqdnEndpoints; +import java.util.Collections; +import java.util.List; + +public final class ExternalFqdnResponseImpl implements ExternalFqdnResponse { + private ExternalFqdnResponseInner innerObject; + + private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; + + ExternalFqdnResponseImpl( + ExternalFqdnResponseInner innerObject, + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + } + + public List value() { + List inner = this.innerModel().value(); + if (inner != null) { + return Collections.unmodifiableList(inner); + } else { + return Collections.emptyList(); + } + } + + public ExternalFqdnResponseInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { + return this.serviceManager; + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesClientImpl.java deleted file mode 100644 index d7156fbcd189d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesClientImpl.java +++ /dev/null @@ -1,1298 +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.machinelearningservices.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.machinelearningservices.fluent.MachineLearningServicesClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; -import com.azure.resourcemanager.machinelearningservices.models.CreateServiceRequest; -import com.azure.resourcemanager.machinelearningservices.models.OrderString; -import com.azure.resourcemanager.machinelearningservices.models.PaginatedServiceList; -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 MachineLearningServicesClient. */ -public final class MachineLearningServicesClientImpl implements MachineLearningServicesClient { - private final ClientLogger logger = new ClientLogger(MachineLearningServicesClientImpl.class); - - /** The proxy service used to perform REST calls. */ - private final MachineLearningServicesService service; - - /** The service client containing this operation class. */ - private final AzureMachineLearningWorkspacesImpl client; - - /** - * Initializes an instance of MachineLearningServicesClientImpl. - * - * @param client the instance of the service client containing this operation class. - */ - MachineLearningServicesClientImpl(AzureMachineLearningWorkspacesImpl client) { - this.service = - RestProxy - .create(MachineLearningServicesService.class, client.getHttpPipeline(), client.getSerializerAdapter()); - this.client = client; - } - - /** - * The interface defining all the services for AzureMachineLearningWorkspacesMachineLearningServices to be used by - * the proxy service to perform REST calls. - */ - @Host("{$host}") - @ServiceInterface(name = "AzureMachineLearning") - private interface MachineLearningServicesService { - @Headers({"Content-Type: application/json"}) - @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/services") - @ExpectedResponses({200}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listByWorkspace( - @HostParam("$host") String endpoint, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @QueryParam("api-version") String apiVersion, - @QueryParam("$skip") String skip, - @QueryParam("modelId") String modelId, - @QueryParam("modelName") String modelName, - @QueryParam("tag") String tag, - @QueryParam("tags") String tags, - @QueryParam("properties") String properties, - @QueryParam("runId") String runId, - @QueryParam("expand") Boolean expand, - @QueryParam("orderby") OrderString orderby, - @HeaderParam("Accept") String accept, - Context context); - - @Headers({"Content-Type: application/json"}) - @Get( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/services/{serviceName}") - @ExpectedResponses({200}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> get( - @HostParam("$host") String endpoint, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @QueryParam("api-version") String apiVersion, - @PathParam("serviceName") String serviceName, - @QueryParam("expand") Boolean expand, - @HeaderParam("Accept") String accept, - Context context); - - @Headers({"Content-Type: application/json"}) - @Delete( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/services/{serviceName}") - @ExpectedResponses({200, 204}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> delete( - @HostParam("$host") String endpoint, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @QueryParam("api-version") String apiVersion, - @PathParam("serviceName") String serviceName, - @HeaderParam("Accept") String accept, - Context context); - - @Headers({"Content-Type: application/json"}) - @Put( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/services/{serviceName}") - @ExpectedResponses({200, 201}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono>> createOrUpdate( - @HostParam("$host") String endpoint, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @QueryParam("api-version") String apiVersion, - @PathParam("serviceName") String serviceName, - @BodyParam("application/json") CreateServiceRequest properties, - @HeaderParam("Accept") String accept, - Context context); - - @Headers({"Content-Type: application/json"}) - @Get("{nextLink}") - @ExpectedResponses({200}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listByWorkspaceNext( - @PathParam(value = "nextLink", encoded = true) String nextLink, - @HostParam("$host") String endpoint, - @HeaderParam("Accept") String accept, - Context context); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceSinglePageAsync( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .listByWorkspace( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby, - accept, - context)) - .>map( - res -> - new PagedResponseBase<>( - res.getRequest(), - res.getStatusCode(), - res.getHeaders(), - res.getValue().value(), - res.getValue().nextLink(), - null)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceSinglePageAsync( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - context = this.client.mergeContext(context); - return service - .listByWorkspace( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby, - accept, - context) - .map( - res -> - new PagedResponseBase<>( - res.getRequest(), - res.getStatusCode(), - res.getHeaders(), - res.getValue().value(), - res.getValue().nextLink(), - null)); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby) { - return new PagedFlux<>( - () -> - listByWorkspaceSinglePageAsync( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink)); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync(String resourceGroupName, String workspaceName) { - final String skip = null; - final String modelId = null; - final String modelName = null; - final String tag = null; - final String tags = null; - final String properties = null; - final String runId = null; - final Boolean expand = null; - final OrderString orderby = null; - return new PagedFlux<>( - () -> - listByWorkspaceSinglePageAsync( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink)); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listByWorkspaceAsync( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - Context context) { - return new PagedFlux<>( - () -> - listByWorkspaceSinglePageAsync( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby, - context), - nextLink -> listByWorkspaceNextSinglePageAsync(nextLink, context)); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listByWorkspace(String resourceGroupName, String workspaceName) { - final String skip = null; - final String modelId = null; - final String modelName = null; - final String tag = null; - final String tags = null; - final String properties = null; - final String runId = null; - final Boolean expand = null; - final OrderString orderby = null; - return new PagedIterable<>( - listByWorkspaceAsync( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby)); - } - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @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 services in specified workspace. - */ - @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listByWorkspace( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - Context context) { - return new PagedIterable<>( - listByWorkspaceAsync( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby, - context)); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .get( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - serviceName, - expand, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> getWithResponseAsync( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand, 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName 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, - workspaceName, - this.client.getApiVersion(), - serviceName, - expand, - accept, - context); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand) { - return getWithResponseAsync(resourceGroupName, workspaceName, serviceName, expand) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono getAsync(String resourceGroupName, String workspaceName, String serviceName) { - final Boolean expand = null; - return getWithResponseAsync(resourceGroupName, workspaceName, serviceName, expand) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public ServiceResourceInner get(String resourceGroupName, String workspaceName, String serviceName) { - final Boolean expand = null; - return getAsync(resourceGroupName, workspaceName, serviceName, expand).block(); - } - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response getWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand, Context context) { - return getWithResponseAsync(resourceGroupName, workspaceName, serviceName, expand, context).block(); - } - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 workspaceName, String serviceName) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .delete( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - serviceName, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @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 workspaceName, String serviceName, 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName 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, - workspaceName, - this.client.getApiVersion(), - serviceName, - accept, - context); - } - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 workspaceName, String serviceName) { - return deleteWithResponseAsync(resourceGroupName, workspaceName, serviceName) - .flatMap((Response res) -> Mono.empty()); - } - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 workspaceName, String serviceName) { - deleteAsync(resourceGroupName, workspaceName, serviceName).block(); - } - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response deleteWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Context context) { - return deleteWithResponseAsync(resourceGroupName, workspaceName, serviceName, context).block(); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createOrUpdateWithResponseAsync( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName is required and cannot be null.")); - } - if (properties == null) { - return Mono.error(new IllegalArgumentException("Parameter properties is required and cannot be null.")); - } else { - properties.validate(); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .createOrUpdate( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - serviceName, - properties, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> createOrUpdateWithResponseAsync( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - if (serviceName == null) { - return Mono.error(new IllegalArgumentException("Parameter serviceName is required and cannot be null.")); - } - if (properties == null) { - return Mono.error(new IllegalArgumentException("Parameter properties is required and cannot be null.")); - } else { - properties.validate(); - } - final String accept = "application/json"; - context = this.client.mergeContext(context); - return service - .createOrUpdate( - this.client.getEndpoint(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - this.client.getApiVersion(), - serviceName, - properties, - accept, - context); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, ServiceResourceInner> beginCreateOrUpdateAsync( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties) { - Mono>> mono = - createOrUpdateWithResponseAsync(resourceGroupName, workspaceName, serviceName, properties); - return this - .client - .getLroResult( - mono, - this.client.getHttpPipeline(), - ServiceResourceInner.class, - ServiceResourceInner.class, - Context.NONE); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, ServiceResourceInner> beginCreateOrUpdateAsync( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context) { - context = this.client.mergeContext(context); - Mono>> mono = - createOrUpdateWithResponseAsync(resourceGroupName, workspaceName, serviceName, properties, context); - return this - .client - .getLroResult( - mono, this.client.getHttpPipeline(), ServiceResourceInner.class, ServiceResourceInner.class, context); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public SyncPoller, ServiceResourceInner> beginCreateOrUpdate( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties) { - return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties).getSyncPoller(); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public SyncPoller, ServiceResourceInner> beginCreateOrUpdate( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context) { - return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties, context) - .getSyncPoller(); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createOrUpdateAsync( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties) { - return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties) - .last() - .flatMap(this.client::getLroFinalResultOrError); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono createOrUpdateAsync( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context) { - return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties, context) - .last() - .flatMap(this.client::getLroFinalResultOrError); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public ServiceResourceInner createOrUpdate( - String resourceGroupName, String workspaceName, String serviceName, CreateServiceRequest properties) { - return createOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties).block(); - } - - /** - * Creates or updates service. This call will update a service if it exists. This is a nonrecoverable operation. If - * your intent is to create a new service, do a GET first to verify that it does not exist yet. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param properties The payload that is used to create or update the Service. - * @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 machine Learning service object wrapped into ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public ServiceResourceInner createOrUpdate( - String resourceGroupName, - String workspaceName, - String serviceName, - CreateServiceRequest properties, - Context context) { - return createOrUpdateAsync(resourceGroupName, workspaceName, serviceName, properties, 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 paginated list of Machine Learning service objects wrapped in ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceNextSinglePageAsync(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.listByWorkspaceNext(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 paginated list of Machine Learning service objects wrapped in ARM resource envelope. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceNextSinglePageAsync( - 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 - .listByWorkspaceNext(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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesImpl.java deleted file mode 100644 index 65e2594c6abdc..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesImpl.java +++ /dev/null @@ -1,222 +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.machinelearningservices.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.machinelearningservices.fluent.MachineLearningServicesClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; -import com.azure.resourcemanager.machinelearningservices.models.MachineLearningServices; -import com.azure.resourcemanager.machinelearningservices.models.OrderString; -import com.azure.resourcemanager.machinelearningservices.models.ServiceResource; -import com.fasterxml.jackson.annotation.JsonIgnore; - -public final class MachineLearningServicesImpl implements MachineLearningServices { - @JsonIgnore private final ClientLogger logger = new ClientLogger(MachineLearningServicesImpl.class); - - private final MachineLearningServicesClient innerClient; - - private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - - public MachineLearningServicesImpl( - MachineLearningServicesClient innerClient, - com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { - this.innerClient = innerClient; - this.serviceManager = serviceManager; - } - - public PagedIterable listByWorkspace(String resourceGroupName, String workspaceName) { - PagedIterable inner = - this.serviceClient().listByWorkspace(resourceGroupName, workspaceName); - return Utils.mapPage(inner, inner1 -> new ServiceResourceImpl(inner1, this.manager())); - } - - public PagedIterable listByWorkspace( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - Context context) { - PagedIterable inner = - this - .serviceClient() - .listByWorkspace( - resourceGroupName, - workspaceName, - skip, - modelId, - modelName, - tag, - tags, - properties, - runId, - expand, - orderby, - context); - return Utils.mapPage(inner, inner1 -> new ServiceResourceImpl(inner1, this.manager())); - } - - public ServiceResource get(String resourceGroupName, String workspaceName, String serviceName) { - ServiceResourceInner inner = this.serviceClient().get(resourceGroupName, workspaceName, serviceName); - if (inner != null) { - return new ServiceResourceImpl(inner, this.manager()); - } else { - return null; - } - } - - public Response getWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand, Context context) { - Response inner = - this.serviceClient().getWithResponse(resourceGroupName, workspaceName, serviceName, expand, context); - if (inner != null) { - return new SimpleResponse<>( - inner.getRequest(), - inner.getStatusCode(), - inner.getHeaders(), - new ServiceResourceImpl(inner.getValue(), this.manager())); - } else { - return null; - } - } - - public void delete(String resourceGroupName, String workspaceName, String serviceName) { - this.serviceClient().delete(resourceGroupName, workspaceName, serviceName); - } - - public Response deleteWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Context context) { - return this.serviceClient().deleteWithResponse(resourceGroupName, workspaceName, serviceName, context); - } - - public ServiceResource 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 workspaceName = Utils.getValueFromIdByName(id, "workspaces"); - if (workspaceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); - } - String serviceName = Utils.getValueFromIdByName(id, "services"); - if (serviceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'services'.", id))); - } - Boolean localExpand = null; - return this - .getWithResponse(resourceGroupName, workspaceName, serviceName, localExpand, Context.NONE) - .getValue(); - } - - public Response getByIdWithResponse(String id, Boolean expand, 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 workspaceName = Utils.getValueFromIdByName(id, "workspaces"); - if (workspaceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); - } - String serviceName = Utils.getValueFromIdByName(id, "services"); - if (serviceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'services'.", id))); - } - return this.getWithResponse(resourceGroupName, workspaceName, serviceName, expand, 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 workspaceName = Utils.getValueFromIdByName(id, "workspaces"); - if (workspaceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); - } - String serviceName = Utils.getValueFromIdByName(id, "services"); - if (serviceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'services'.", id))); - } - this.deleteWithResponse(resourceGroupName, workspaceName, serviceName, Context.NONE).getValue(); - } - - public Response 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 workspaceName = Utils.getValueFromIdByName(id, "workspaces"); - if (workspaceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); - } - String serviceName = Utils.getValueFromIdByName(id, "services"); - if (serviceName == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - String.format("The resource ID '%s' is not valid. Missing path segment 'services'.", id))); - } - return this.deleteWithResponse(resourceGroupName, workspaceName, serviceName, context); - } - - private MachineLearningServicesClient serviceClient() { - return this.innerClient; - } - - private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { - return this.serviceManager; - } - - public ServiceResourceImpl define(String name) { - return new ServiceResourceImpl(name, this.manager()); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksClientImpl.java deleted file mode 100644 index 5e755e4007069..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksClientImpl.java +++ /dev/null @@ -1,455 +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.machinelearningservices.implementation; - -import com.azure.core.annotation.ExpectedResponses; -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.Post; -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.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.machinelearningservices.fluent.NotebooksClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ListNotebookKeysResultInner; -import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; -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 NotebooksClient. */ -public final class NotebooksClientImpl implements NotebooksClient { - private final ClientLogger logger = new ClientLogger(NotebooksClientImpl.class); - - /** The proxy service used to perform REST calls. */ - private final NotebooksService service; - - /** The service client containing this operation class. */ - private final AzureMachineLearningWorkspacesImpl client; - - /** - * Initializes an instance of NotebooksClientImpl. - * - * @param client the instance of the service client containing this operation class. - */ - NotebooksClientImpl(AzureMachineLearningWorkspacesImpl client) { - this.service = - RestProxy.create(NotebooksService.class, client.getHttpPipeline(), client.getSerializerAdapter()); - this.client = client; - } - - /** - * The interface defining all the services for AzureMachineLearningWorkspacesNotebooks to be used by the proxy - * service to perform REST calls. - */ - @Host("{$host}") - @ServiceInterface(name = "AzureMachineLearning") - private interface NotebooksService { - @Headers({"Content-Type: application/json"}) - @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/prepareNotebook") - @ExpectedResponses({200, 202}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono>> prepare( - @HostParam("$host") String endpoint, - @QueryParam("api-version") String apiVersion, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @HeaderParam("Accept") String accept, - Context context); - - @Headers({"Content-Type: application/json"}) - @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/listNotebookKeys") - @ExpectedResponses({200}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listKeys( - @HostParam("$host") String endpoint, - @QueryParam("api-version") String apiVersion, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @HeaderParam("Accept") String accept, - Context context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> prepareWithResponseAsync(String resourceGroupName, String workspaceName) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .prepare( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> prepareWithResponseAsync( - String resourceGroupName, String workspaceName, 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - context = this.client.mergeContext(context); - return service - .prepare( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, NotebookResourceInfoInner> beginPrepareAsync( - String resourceGroupName, String workspaceName) { - Mono>> mono = prepareWithResponseAsync(resourceGroupName, workspaceName); - return this - .client - .getLroResult( - mono, - this.client.getHttpPipeline(), - NotebookResourceInfoInner.class, - NotebookResourceInfoInner.class, - Context.NONE); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, NotebookResourceInfoInner> beginPrepareAsync( - String resourceGroupName, String workspaceName, Context context) { - context = this.client.mergeContext(context); - Mono>> mono = prepareWithResponseAsync(resourceGroupName, workspaceName, context); - return this - .client - .getLroResult( - mono, - this.client.getHttpPipeline(), - NotebookResourceInfoInner.class, - NotebookResourceInfoInner.class, - context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public SyncPoller, NotebookResourceInfoInner> beginPrepare( - String resourceGroupName, String workspaceName) { - return beginPrepareAsync(resourceGroupName, workspaceName).getSyncPoller(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public SyncPoller, NotebookResourceInfoInner> beginPrepare( - String resourceGroupName, String workspaceName, Context context) { - return beginPrepareAsync(resourceGroupName, workspaceName, context).getSyncPoller(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono prepareAsync(String resourceGroupName, String workspaceName) { - return beginPrepareAsync(resourceGroupName, workspaceName) - .last() - .flatMap(this.client::getLroFinalResultOrError); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono prepareAsync( - String resourceGroupName, String workspaceName, Context context) { - return beginPrepareAsync(resourceGroupName, workspaceName, context) - .last() - .flatMap(this.client::getLroFinalResultOrError); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public NotebookResourceInfoInner prepare(String resourceGroupName, String workspaceName) { - return prepareAsync(resourceGroupName, workspaceName).block(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public NotebookResourceInfoInner prepare(String resourceGroupName, String workspaceName, Context context) { - return prepareAsync(resourceGroupName, workspaceName, context).block(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .listKeys( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName, 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - context = this.client.mergeContext(context); - return service - .listKeys( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono listKeysAsync(String resourceGroupName, String workspaceName) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public ListNotebookKeysResultInner listKeys(String resourceGroupName, String workspaceName) { - return listKeysAsync(resourceGroupName, workspaceName).block(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksImpl.java deleted file mode 100644 index bef3628c3b9b0..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksImpl.java +++ /dev/null @@ -1,82 +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.machinelearningservices.implementation; - -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.machinelearningservices.fluent.NotebooksClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ListNotebookKeysResultInner; -import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; -import com.azure.resourcemanager.machinelearningservices.models.ListNotebookKeysResult; -import com.azure.resourcemanager.machinelearningservices.models.NotebookResourceInfo; -import com.azure.resourcemanager.machinelearningservices.models.Notebooks; -import com.fasterxml.jackson.annotation.JsonIgnore; - -public final class NotebooksImpl implements Notebooks { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NotebooksImpl.class); - - private final NotebooksClient innerClient; - - private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - - public NotebooksImpl( - NotebooksClient innerClient, - com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { - this.innerClient = innerClient; - this.serviceManager = serviceManager; - } - - public NotebookResourceInfo prepare(String resourceGroupName, String workspaceName) { - NotebookResourceInfoInner inner = this.serviceClient().prepare(resourceGroupName, workspaceName); - if (inner != null) { - return new NotebookResourceInfoImpl(inner, this.manager()); - } else { - return null; - } - } - - public NotebookResourceInfo prepare(String resourceGroupName, String workspaceName, Context context) { - NotebookResourceInfoInner inner = this.serviceClient().prepare(resourceGroupName, workspaceName, context); - if (inner != null) { - return new NotebookResourceInfoImpl(inner, this.manager()); - } else { - return null; - } - } - - public ListNotebookKeysResult listKeys(String resourceGroupName, String workspaceName) { - ListNotebookKeysResultInner inner = this.serviceClient().listKeys(resourceGroupName, workspaceName); - if (inner != null) { - return new ListNotebookKeysResultImpl(inner, this.manager()); - } else { - return null; - } - } - - public Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context) { - Response inner = - this.serviceClient().listKeysWithResponse(resourceGroupName, workspaceName, context); - if (inner != null) { - return new SimpleResponse<>( - inner.getRequest(), - inner.getStatusCode(), - inner.getHeaders(), - new ListNotebookKeysResultImpl(inner.getValue(), this.manager())); - } else { - return null; - } - } - - private NotebooksClient serviceClient() { - return this.innerClient; - } - - private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { - return this.serviceManager; - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsClientImpl.java index 1cc4020370b2c..4598320d58ef7 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsClientImpl.java @@ -24,7 +24,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.OperationsClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.OperationInner; import com.azure.resourcemanager.machinelearningservices.models.OperationListResult; @@ -32,8 +31,6 @@ /** An instance of this class provides access to all the operations defined in OperationsClient. */ public final class OperationsClientImpl implements OperationsClient { - private final ClientLogger logger = new ClientLogger(OperationsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final OperationsService service; @@ -74,7 +71,8 @@ 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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync() { @@ -102,7 +100,8 @@ private Mono> listSinglePageAsync() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(Context context) { @@ -127,7 +126,7 @@ private Mono> listSinglePageAsync(Context context) * * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync() { @@ -141,7 +140,7 @@ private PagedFlux listAsync() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(Context context) { @@ -153,7 +152,8 @@ private PagedFlux listAsync(Context context) { * * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list() { @@ -167,7 +167,8 @@ public PagedIterable 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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(Context context) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsImpl.java index ebc5c313189c6..567275cbff64a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/OperationsImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.OperationInner; import com.azure.resourcemanager.machinelearningservices.models.Operation; import com.azure.resourcemanager.machinelearningservices.models.Operations; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class OperationsImpl implements Operations { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(OperationsImpl.class); private final OperationsClient innerClient; diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionImpl.java index 1093bad93f93b..ec17bda94ef31 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionImpl.java @@ -35,6 +35,10 @@ public String type() { return this.innerModel().type(); } + public Identity identity() { + return this.innerModel().identity(); + } + public String location() { return this.innerModel().location(); } @@ -48,6 +52,14 @@ public Map tags() { } } + public Sku sku() { + return this.innerModel().sku(); + } + + public SystemData systemData() { + return this.innerModel().systemData(); + } + public PrivateEndpoint privateEndpoint() { return this.innerModel().privateEndpoint(); } @@ -60,18 +72,6 @@ public PrivateEndpointConnectionProvisioningState provisioningState() { return this.innerModel().provisioningState(); } - public Identity identity() { - return this.innerModel().identity(); - } - - public Sku sku() { - return this.innerModel().sku(); - } - - public SystemData systemData() { - return this.innerModel().systemData(); - } - public Region region() { return Region.fromName(this.regionName()); } @@ -105,7 +105,7 @@ public PrivateEndpointConnection create() { serviceManager .serviceClient() .getPrivateEndpointConnections() - .putWithResponse( + .createOrUpdateWithResponse( resourceGroupName, workspaceName, privateEndpointConnectionName, this.innerModel(), Context.NONE) .getValue(); return this; @@ -116,7 +116,7 @@ public PrivateEndpointConnection create(Context context) { serviceManager .serviceClient() .getPrivateEndpointConnections() - .putWithResponse( + .createOrUpdateWithResponse( resourceGroupName, workspaceName, privateEndpointConnectionName, this.innerModel(), context) .getValue(); return this; @@ -138,7 +138,7 @@ public PrivateEndpointConnection apply() { serviceManager .serviceClient() .getPrivateEndpointConnections() - .putWithResponse( + .createOrUpdateWithResponse( resourceGroupName, workspaceName, privateEndpointConnectionName, this.innerModel(), Context.NONE) .getValue(); return this; @@ -149,7 +149,7 @@ public PrivateEndpointConnection apply(Context context) { serviceManager .serviceClient() .getPrivateEndpointConnections() - .putWithResponse( + .createOrUpdateWithResponse( resourceGroupName, workspaceName, privateEndpointConnectionName, this.innerModel(), context) .getValue(); return this; @@ -200,24 +200,24 @@ public PrivateEndpointConnectionImpl withTags(Map tags) { return this; } - public PrivateEndpointConnectionImpl withPrivateEndpoint(PrivateEndpoint privateEndpoint) { - this.innerModel().withPrivateEndpoint(privateEndpoint); + public PrivateEndpointConnectionImpl withIdentity(Identity identity) { + this.innerModel().withIdentity(identity); return this; } - public PrivateEndpointConnectionImpl withPrivateLinkServiceConnectionState( - PrivateLinkServiceConnectionState privateLinkServiceConnectionState) { - this.innerModel().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState); + public PrivateEndpointConnectionImpl withSku(Sku sku) { + this.innerModel().withSku(sku); return this; } - public PrivateEndpointConnectionImpl withIdentity(Identity identity) { - this.innerModel().withIdentity(identity); + public PrivateEndpointConnectionImpl withPrivateEndpoint(PrivateEndpoint privateEndpoint) { + this.innerModel().withPrivateEndpoint(privateEndpoint); return this; } - public PrivateEndpointConnectionImpl withSku(Sku sku) { - this.innerModel().withSku(sku); + public PrivateEndpointConnectionImpl withPrivateLinkServiceConnectionState( + PrivateLinkServiceConnectionState privateLinkServiceConnectionState) { + this.innerModel().withPrivateLinkServiceConnectionState(privateLinkServiceConnectionState); return this; } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsClientImpl.java index cf4ba0bd8cfe9..0d52c1ffed6cf 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsClientImpl.java @@ -19,20 +19,22 @@ import com.azure.core.annotation.ServiceInterface; import com.azure.core.annotation.ServiceMethod; import com.azure.core.annotation.UnexpectedResponseExceptionType; +import com.azure.core.http.rest.PagedFlux; +import com.azure.core.http.rest.PagedIterable; +import com.azure.core.http.rest.PagedResponse; +import com.azure.core.http.rest.PagedResponseBase; import com.azure.core.http.rest.Response; import com.azure.core.http.rest.RestProxy; import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.PrivateEndpointConnectionsClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnectionListResult; import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in PrivateEndpointConnectionsClient. */ public final class PrivateEndpointConnectionsClientImpl implements PrivateEndpointConnectionsClient { - private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final PrivateEndpointConnectionsService service; @@ -59,6 +61,21 @@ public final class PrivateEndpointConnectionsClientImpl implements PrivateEndpoi @Host("{$host}") @ServiceInterface(name = "AzureMachineLearning") private interface PrivateEndpointConnectionsService { + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/privateEndpointConnections") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> list( + @HostParam("$host") String endpoint, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @QueryParam("api-version") String apiVersion, + @PathParam("subscriptionId") String subscriptionId, + @HeaderParam("Accept") String accept, + Context context); + @Headers({"Content-Type: application/json"}) @Get( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" @@ -83,7 +100,7 @@ Mono> get( + "/{privateEndpointConnectionName}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> put( + Mono> createOrUpdate( @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId, @PathParam("resourceGroupName") String resourceGroupName, @@ -112,16 +129,189 @@ Mono> delete( Context context); } + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @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 private endpoint connection associated with the specified workspace along with {@link + * PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync( + String resourceGroupName, String workspaceName) { + if (this.client.getEndpoint() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (resourceGroupName == null) { + return Mono + .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); + } + if (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .list( + this.client.getEndpoint(), + resourceGroupName, + workspaceName, + this.client.getApiVersion(), + this.client.getSubscriptionId(), + accept, + context)) + .>map( + res -> + new PagedResponseBase<>( + res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(), null, null)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace along with {@link + * PagedResponse} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listSinglePageAsync( + String resourceGroupName, String workspaceName, Context context) { + if (this.client.getEndpoint() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getEndpoint() is required and cannot be null.")); + } + if (resourceGroupName == null) { + return Mono + .error(new IllegalArgumentException("Parameter resourceGroupName is required and cannot be null.")); + } + if (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + if (this.client.getSubscriptionId() == null) { + return Mono + .error( + new IllegalArgumentException( + "Parameter this.client.getSubscriptionId() is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .list( + this.client.getEndpoint(), + resourceGroupName, + workspaceName, + this.client.getApiVersion(), + this.client.getSubscriptionId(), + accept, + context) + .map( + res -> + new PagedResponseBase<>( + res.getRequest(), res.getStatusCode(), res.getHeaders(), res.getValue().value(), null, null)); + } + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync(String resourceGroupName, String workspaceName) { + return new PagedFlux<>(() -> listSinglePageAsync(resourceGroupName, workspaceName)); + } + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedFlux}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + private PagedFlux listAsync( + String resourceGroupName, String workspaceName, Context context) { + return new PagedFlux<>(() -> listSinglePageAsync(resourceGroupName, workspaceName, context)); + } + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list(String resourceGroupName, String workspaceName) { + return new PagedIterable<>(listAsync(resourceGroupName, workspaceName)); + } + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + @ServiceMethod(returns = ReturnType.COLLECTION) + public PagedIterable list( + String resourceGroupName, String workspaceName, Context context) { + return new PagedIterable<>(listAsync(resourceGroupName, workspaceName, context)); + } + /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -171,14 +361,15 @@ private Mono> getWithResponseAsync( /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -225,13 +416,14 @@ private Mono> getWithResponseAsync( /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync( @@ -250,7 +442,7 @@ private Mono getAsync( /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -267,14 +459,14 @@ public PrivateEndpointConnectionInner get( /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getWithResponse( @@ -285,17 +477,18 @@ public Response getWithResponse( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 Private Endpoint Connection resource. + * @return the Private Endpoint Connection resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> putWithResponseAsync( + private Mono> createOrUpdateWithResponseAsync( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -335,7 +528,7 @@ private Mono> putWithResponseAsync( .withContext( context -> service - .put( + .createOrUpdate( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -351,7 +544,7 @@ private Mono> putWithResponseAsync( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. @@ -359,10 +552,11 @@ private Mono> putWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 Private Endpoint Connection resource. + * @return the Private Endpoint Connection resource along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> putWithResponseAsync( + private Mono> createOrUpdateWithResponseAsync( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -401,7 +595,7 @@ private Mono> putWithResponseAsync( final String accept = "application/json"; context = this.client.mergeContext(context); return service - .put( + .createOrUpdate( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -416,22 +610,23 @@ private Mono> putWithResponseAsync( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 Private Endpoint Connection resource. + * @return the Private Endpoint Connection resource on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono putAsync( + private Mono createOrUpdateAsync( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, PrivateEndpointConnectionInner properties) { - return putWithResponseAsync(resourceGroupName, workspaceName, privateEndpointConnectionName, properties) + return createOrUpdateWithResponseAsync( + resourceGroupName, workspaceName, privateEndpointConnectionName, properties) .flatMap( (Response res) -> { if (res.getValue() != null) { @@ -445,7 +640,7 @@ private Mono putAsync( /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. @@ -455,18 +650,18 @@ private Mono putAsync( * @return the Private Endpoint Connection resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PrivateEndpointConnectionInner put( + public PrivateEndpointConnectionInner createOrUpdate( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, PrivateEndpointConnectionInner properties) { - return putAsync(resourceGroupName, workspaceName, privateEndpointConnectionName, properties).block(); + return createOrUpdateAsync(resourceGroupName, workspaceName, privateEndpointConnectionName, properties).block(); } /** * Update the state of specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param properties The private endpoint connection properties. @@ -474,16 +669,16 @@ public PrivateEndpointConnectionInner put( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 Private Endpoint Connection resource. + * @return the Private Endpoint Connection resource along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response putWithResponse( + public Response createOrUpdateWithResponse( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, PrivateEndpointConnectionInner properties, Context context) { - return putWithResponseAsync( + return createOrUpdateWithResponseAsync( resourceGroupName, workspaceName, privateEndpointConnectionName, properties, context) .block(); } @@ -491,13 +686,13 @@ public Response putWithResponse( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> deleteWithResponseAsync( @@ -547,14 +742,14 @@ private Mono> deleteWithResponseAsync( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> deleteWithResponseAsync( @@ -601,13 +796,13 @@ private Mono> deleteWithResponseAsync( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync( @@ -619,7 +814,7 @@ private Mono deleteAsync( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -634,14 +829,14 @@ public void delete(String resourceGroupName, String workspaceName, String privat /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response deleteWithResponse( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsImpl.java index 95ed5bd95517a..e3fd5043e9c86 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateEndpointConnectionsImpl.java @@ -4,6 +4,7 @@ package com.azure.resourcemanager.machinelearningservices.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; @@ -12,10 +13,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnection; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnections; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class PrivateEndpointConnectionsImpl implements PrivateEndpointConnections { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(PrivateEndpointConnectionsImpl.class); private final PrivateEndpointConnectionsClient innerClient; @@ -28,6 +28,19 @@ public PrivateEndpointConnectionsImpl( this.serviceManager = serviceManager; } + public PagedIterable list(String resourceGroupName, String workspaceName) { + PagedIterable inner = + this.serviceClient().list(resourceGroupName, workspaceName); + return Utils.mapPage(inner, inner1 -> new PrivateEndpointConnectionImpl(inner1, this.manager())); + } + + public PagedIterable list( + String resourceGroupName, String workspaceName, Context context) { + PagedIterable inner = + this.serviceClient().list(resourceGroupName, workspaceName, context); + return Utils.mapPage(inner, inner1 -> new PrivateEndpointConnectionImpl(inner1, this.manager())); + } + public PrivateEndpointConnection get( String resourceGroupName, String workspaceName, String privateEndpointConnectionName) { PrivateEndpointConnectionInner inner = @@ -70,7 +83,7 @@ public Response deleteWithResponse( public PrivateEndpointConnection getById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -78,14 +91,14 @@ public PrivateEndpointConnection getById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String privateEndpointConnectionName = Utils.getValueFromIdByName(id, "privateEndpointConnections"); if (privateEndpointConnectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -101,7 +114,7 @@ public PrivateEndpointConnection getById(String id) { public Response getByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -109,14 +122,14 @@ public Response getByIdWithResponse(String id, Contex } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String privateEndpointConnectionName = Utils.getValueFromIdByName(id, "privateEndpointConnections"); if (privateEndpointConnectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -130,7 +143,7 @@ public Response getByIdWithResponse(String id, Contex public void deleteById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -138,14 +151,14 @@ public void deleteById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String privateEndpointConnectionName = Utils.getValueFromIdByName(id, "privateEndpointConnections"); if (privateEndpointConnectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -153,15 +166,13 @@ public void deleteById(String id) { "The resource ID '%s' is not valid. Missing path segment 'privateEndpointConnections'.", id))); } - this - .deleteWithResponse(resourceGroupName, workspaceName, privateEndpointConnectionName, Context.NONE) - .getValue(); + this.deleteWithResponse(resourceGroupName, workspaceName, privateEndpointConnectionName, Context.NONE); } public Response deleteByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -169,14 +180,14 @@ public Response deleteByIdWithResponse(String id, Context context) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String privateEndpointConnectionName = Utils.getValueFromIdByName(id, "privateEndpointConnections"); if (privateEndpointConnectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesClientImpl.java index 325fcd67fc117..c4ec7405b52d6 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesClientImpl.java @@ -21,15 +21,12 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.PrivateLinkResourcesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateLinkResourceListResultInner; import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in PrivateLinkResourcesClient. */ public final class PrivateLinkResourcesClientImpl implements PrivateLinkResourcesClient { - private final ClientLogger logger = new ClientLogger(PrivateLinkResourcesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final PrivateLinkResourcesService service; @@ -61,7 +58,7 @@ private interface PrivateLinkResourcesService { + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/privateLinkResources") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listByWorkspace( + Mono> list( @HostParam("$host") String endpoint, @PathParam("subscriptionId") String subscriptionId, @PathParam("resourceGroupName") String resourceGroupName, @@ -74,15 +71,16 @@ Mono> listByWorkspace( /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceWithResponseAsync( + private Mono> listWithResponseAsync( String resourceGroupName, String workspaceName) { if (this.client.getEndpoint() == null) { return Mono @@ -108,7 +106,7 @@ private Mono> listByWorkspaceWithRe .withContext( context -> service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -122,16 +120,17 @@ private Mono> listByWorkspaceWithRe /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace along with {@link Response} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceWithResponseAsync( + private Mono> listWithResponseAsync( String resourceGroupName, String workspaceName, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -155,7 +154,7 @@ private Mono> listByWorkspaceWithRe final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -168,17 +167,17 @@ private Mono> listByWorkspaceWithRe /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono listByWorkspaceAsync( - String resourceGroupName, String workspaceName) { - return listByWorkspaceWithResponseAsync(resourceGroupName, workspaceName) + private Mono listAsync(String resourceGroupName, String workspaceName) { + return listWithResponseAsync(resourceGroupName, workspaceName) .flatMap( (Response res) -> { if (res.getValue() != null) { @@ -192,7 +191,7 @@ private Mono listByWorkspaceAsync( /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -200,24 +199,24 @@ private Mono listByWorkspaceAsync( * @return the private link resources that need to be created for a workspace. */ @ServiceMethod(returns = ReturnType.SINGLE) - public PrivateLinkResourceListResultInner listByWorkspace(String resourceGroupName, String workspaceName) { - return listByWorkspaceAsync(resourceGroupName, workspaceName).block(); + public PrivateLinkResourceListResultInner list(String resourceGroupName, String workspaceName) { + return listAsync(resourceGroupName, workspaceName).block(); } /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response listByWorkspaceWithResponse( + public Response listWithResponse( String resourceGroupName, String workspaceName, Context context) { - return listByWorkspaceWithResponseAsync(resourceGroupName, workspaceName, context).block(); + return listWithResponseAsync(resourceGroupName, workspaceName, context).block(); } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesImpl.java index 1a4e20c8cf307..a6c74e6f79535 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/PrivateLinkResourcesImpl.java @@ -12,10 +12,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateLinkResourceListResultInner; import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkResourceListResult; import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkResources; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class PrivateLinkResourcesImpl implements PrivateLinkResources { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourcesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(PrivateLinkResourcesImpl.class); private final PrivateLinkResourcesClient innerClient; @@ -28,9 +27,8 @@ public PrivateLinkResourcesImpl( this.serviceManager = serviceManager; } - public PrivateLinkResourceListResult listByWorkspace(String resourceGroupName, String workspaceName) { - PrivateLinkResourceListResultInner inner = - this.serviceClient().listByWorkspace(resourceGroupName, workspaceName); + public PrivateLinkResourceListResult list(String resourceGroupName, String workspaceName) { + PrivateLinkResourceListResultInner inner = this.serviceClient().list(resourceGroupName, workspaceName); if (inner != null) { return new PrivateLinkResourceListResultImpl(inner, this.manager()); } else { @@ -38,10 +36,10 @@ public PrivateLinkResourceListResult listByWorkspace(String resourceGroupName, S } } - public Response listByWorkspaceWithResponse( + public Response listWithResponse( String resourceGroupName, String workspaceName, Context context) { Response inner = - this.serviceClient().listByWorkspaceWithResponse(resourceGroupName, workspaceName, context); + this.serviceClient().listWithResponse(resourceGroupName, workspaceName, context); if (inner != null) { return new SimpleResponse<>( inner.getRequest(), diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasClientImpl.java index 6fe6c5442a17b..a1b625d60b611 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasClientImpl.java @@ -27,7 +27,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.QuotasClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.ResourceQuotaInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.UpdateWorkspaceQuotasResultInner; @@ -37,8 +36,6 @@ /** An instance of this class provides access to all the operations defined in QuotasClient. */ public final class QuotasClientImpl implements QuotasClient { - private final ClientLogger logger = new ClientLogger(QuotasClientImpl.class); - /** The proxy service used to perform REST calls. */ private final QuotasService service; @@ -108,7 +105,8 @@ Mono> listNext( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of update workspace quota. + * @return the result of update workspace quota along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -158,7 +156,8 @@ private Mono> updateWithResponseAsync * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of update workspace quota. + * @return the result of update workspace quota along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -204,7 +203,7 @@ private Mono> updateWithResponseAsync * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of update workspace quota. + * @return the result of update workspace quota on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync(String location, QuotaUpdateParameters parameters) { @@ -243,7 +242,7 @@ public UpdateWorkspaceQuotasResultInner update(String location, QuotaUpdateParam * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of update workspace quota. + * @return the result of update workspace quota along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response updateWithResponse( @@ -258,7 +257,8 @@ public Response updateWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location) { @@ -309,7 +309,8 @@ private Mono> listSinglePageAsync(String locat * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location, Context context) { @@ -356,7 +357,7 @@ private Mono> listSinglePageAsync(String locat * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location) { @@ -371,7 +372,7 @@ private PagedFlux listAsync(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location, Context context) { @@ -386,7 +387,8 @@ private PagedFlux listAsync(String location, Context context * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location) { @@ -401,7 +403,8 @@ public PagedIterable list(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location, Context context) { @@ -415,7 +418,8 @@ public PagedIterable list(String location, Context context) * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List WorkspaceQuotasByVMFamily operation response. + * @return the List WorkspaceQuotasByVMFamily operation response along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -451,7 +455,8 @@ private Mono> listNextSinglePageAsync(String n * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List WorkspaceQuotasByVMFamily operation response. + * @return the List WorkspaceQuotasByVMFamily operation response along with {@link PagedResponse} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasImpl.java index 025f92deecb6a..167cf7923dc9a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/QuotasImpl.java @@ -16,10 +16,9 @@ import com.azure.resourcemanager.machinelearningservices.models.Quotas; import com.azure.resourcemanager.machinelearningservices.models.ResourceQuota; import com.azure.resourcemanager.machinelearningservices.models.UpdateWorkspaceQuotasResult; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class QuotasImpl implements Quotas { - @JsonIgnore private final ClientLogger logger = new ClientLogger(QuotasImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(QuotasImpl.class); private final QuotasClient innerClient; diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ServiceResourceImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ServiceResourceImpl.java deleted file mode 100644 index 4ca6ab23228da..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ServiceResourceImpl.java +++ /dev/null @@ -1,244 +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.machinelearningservices.implementation; - -import com.azure.core.management.Region; -import com.azure.core.management.SystemData; -import com.azure.core.util.Context; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; -import com.azure.resourcemanager.machinelearningservices.models.CreateServiceRequest; -import com.azure.resourcemanager.machinelearningservices.models.CreateServiceRequestEnvironmentImageRequest; -import com.azure.resourcemanager.machinelearningservices.models.CreateServiceRequestKeys; -import com.azure.resourcemanager.machinelearningservices.models.Identity; -import com.azure.resourcemanager.machinelearningservices.models.ServiceResource; -import com.azure.resourcemanager.machinelearningservices.models.ServiceResponseBase; -import com.azure.resourcemanager.machinelearningservices.models.Sku; -import java.util.Collections; -import java.util.Map; - -public final class ServiceResourceImpl implements ServiceResource, ServiceResource.Definition, ServiceResource.Update { - private ServiceResourceInner innerObject; - - private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - - public String id() { - return this.innerModel().id(); - } - - public String name() { - return this.innerModel().name(); - } - - public String type() { - return this.innerModel().type(); - } - - public String location() { - return this.innerModel().location(); - } - - public Map tags() { - Map inner = this.innerModel().tags(); - if (inner != null) { - return Collections.unmodifiableMap(inner); - } else { - return Collections.emptyMap(); - } - } - - public ServiceResponseBase properties() { - return this.innerModel().properties(); - } - - public Identity identity() { - return this.innerModel().identity(); - } - - public Sku sku() { - return this.innerModel().sku(); - } - - public SystemData systemData() { - return this.innerModel().systemData(); - } - - public Region region() { - return Region.fromName(this.regionName()); - } - - public String regionName() { - return this.location(); - } - - public ServiceResourceInner innerModel() { - return this.innerObject; - } - - private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { - return this.serviceManager; - } - - private String resourceGroupName; - - private String workspaceName; - - private String serviceName; - - private CreateServiceRequest createProperties; - - private CreateServiceRequest updateProperties; - - public ServiceResourceImpl withExistingWorkspace(String resourceGroupName, String workspaceName) { - this.resourceGroupName = resourceGroupName; - this.workspaceName = workspaceName; - return this; - } - - public ServiceResource create() { - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .createOrUpdate(resourceGroupName, workspaceName, serviceName, createProperties, Context.NONE); - return this; - } - - public ServiceResource create(Context context) { - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .createOrUpdate(resourceGroupName, workspaceName, serviceName, createProperties, context); - return this; - } - - ServiceResourceImpl( - String name, com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { - this.innerObject = new ServiceResourceInner(); - this.serviceManager = serviceManager; - this.serviceName = name; - this.createProperties = new CreateServiceRequest(); - } - - public ServiceResourceImpl update() { - this.updateProperties = new CreateServiceRequest(); - return this; - } - - public ServiceResource apply() { - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .createOrUpdate(resourceGroupName, workspaceName, serviceName, updateProperties, Context.NONE); - return this; - } - - public ServiceResource apply(Context context) { - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .createOrUpdate(resourceGroupName, workspaceName, serviceName, updateProperties, context); - return this; - } - - ServiceResourceImpl( - ServiceResourceInner innerObject, - com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { - this.innerObject = innerObject; - this.serviceManager = serviceManager; - this.resourceGroupName = Utils.getValueFromIdByName(innerObject.id(), "resourceGroups"); - this.workspaceName = Utils.getValueFromIdByName(innerObject.id(), "workspaces"); - this.serviceName = Utils.getValueFromIdByName(innerObject.id(), "services"); - } - - public ServiceResource refresh() { - Boolean localExpand = null; - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .getWithResponse(resourceGroupName, workspaceName, serviceName, localExpand, Context.NONE) - .getValue(); - return this; - } - - public ServiceResource refresh(Context context) { - Boolean localExpand = null; - this.innerObject = - serviceManager - .serviceClient() - .getMachineLearningServices() - .getWithResponse(resourceGroupName, workspaceName, serviceName, localExpand, context) - .getValue(); - return this; - } - - public ServiceResourceImpl withRegion(Region location) { - this.createProperties.withLocation(location.toString()); - return this; - } - - public ServiceResourceImpl withRegion(String location) { - this.createProperties.withLocation(location); - return this; - } - - public ServiceResourceImpl withDescription(String description) { - if (isInCreateMode()) { - this.createProperties.withDescription(description); - return this; - } else { - this.updateProperties.withDescription(description); - return this; - } - } - - public ServiceResourceImpl withKvTags(Map kvTags) { - if (isInCreateMode()) { - this.createProperties.withKvTags(kvTags); - return this; - } else { - this.updateProperties.withKvTags(kvTags); - return this; - } - } - - public ServiceResourceImpl withProperties(Map properties) { - if (isInCreateMode()) { - this.createProperties.withProperties(properties); - return this; - } else { - this.updateProperties.withProperties(properties); - return this; - } - } - - public ServiceResourceImpl withKeys(CreateServiceRequestKeys keys) { - if (isInCreateMode()) { - this.createProperties.withKeys(keys); - return this; - } else { - this.updateProperties.withKeys(keys); - return this; - } - } - - public ServiceResourceImpl withEnvironmentImageRequest( - CreateServiceRequestEnvironmentImageRequest environmentImageRequest) { - if (isInCreateMode()) { - this.createProperties.withEnvironmentImageRequest(environmentImageRequest); - return this; - } else { - this.updateProperties.withEnvironmentImageRequest(environmentImageRequest); - return this; - } - } - - private boolean isInCreateMode() { - return this.innerModel().id() == null; - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsClientImpl.java deleted file mode 100644 index 3530debed2c8d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsClientImpl.java +++ /dev/null @@ -1,211 +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.machinelearningservices.implementation; - -import com.azure.core.annotation.ExpectedResponses; -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.Post; -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.Response; -import com.azure.core.http.rest.RestProxy; -import com.azure.core.management.exception.ManagementException; -import com.azure.core.util.Context; -import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.fluent.StorageAccountsClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; -import reactor.core.publisher.Mono; - -/** An instance of this class provides access to all the operations defined in StorageAccountsClient. */ -public final class StorageAccountsClientImpl implements StorageAccountsClient { - private final ClientLogger logger = new ClientLogger(StorageAccountsClientImpl.class); - - /** The proxy service used to perform REST calls. */ - private final StorageAccountsService service; - - /** The service client containing this operation class. */ - private final AzureMachineLearningWorkspacesImpl client; - - /** - * Initializes an instance of StorageAccountsClientImpl. - * - * @param client the instance of the service client containing this operation class. - */ - StorageAccountsClientImpl(AzureMachineLearningWorkspacesImpl client) { - this.service = - RestProxy.create(StorageAccountsService.class, client.getHttpPipeline(), client.getSerializerAdapter()); - this.client = client; - } - - /** - * The interface defining all the services for AzureMachineLearningWorkspacesStorageAccounts to be used by the proxy - * service to perform REST calls. - */ - @Host("{$host}") - @ServiceInterface(name = "AzureMachineLearning") - private interface StorageAccountsService { - @Headers({"Content-Type: application/json"}) - @Post( - "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" - + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/listStorageAccountKeys") - @ExpectedResponses({200}) - @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listKeys( - @HostParam("$host") String endpoint, - @QueryParam("api-version") String apiVersion, - @PathParam("subscriptionId") String subscriptionId, - @PathParam("resourceGroupName") String resourceGroupName, - @PathParam("workspaceName") String workspaceName, - @HeaderParam("Accept") String accept, - Context context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName) { - 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - return FluxUtil - .withContext( - context -> - service - .listKeys( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context)) - .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName, 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 (workspaceName == null) { - return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); - } - final String accept = "application/json"; - context = this.client.mergeContext(context); - return service - .listKeys( - this.client.getEndpoint(), - this.client.getApiVersion(), - this.client.getSubscriptionId(), - resourceGroupName, - workspaceName, - accept, - context); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - private Mono listKeysAsync(String resourceGroupName, String workspaceName) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public ListStorageAccountKeysResultInner listKeys(String resourceGroupName, String workspaceName) { - return listKeysAsync(resourceGroupName, workspaceName).block(); - } - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - @ServiceMethod(returns = ReturnType.SINGLE) - public Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsImpl.java deleted file mode 100644 index 204593a111129..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsImpl.java +++ /dev/null @@ -1,62 +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.machinelearningservices.implementation; - -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.machinelearningservices.fluent.StorageAccountsClient; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; -import com.azure.resourcemanager.machinelearningservices.models.ListStorageAccountKeysResult; -import com.azure.resourcemanager.machinelearningservices.models.StorageAccounts; -import com.fasterxml.jackson.annotation.JsonIgnore; - -public final class StorageAccountsImpl implements StorageAccounts { - @JsonIgnore private final ClientLogger logger = new ClientLogger(StorageAccountsImpl.class); - - private final StorageAccountsClient innerClient; - - private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - - public StorageAccountsImpl( - StorageAccountsClient innerClient, - com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { - this.innerClient = innerClient; - this.serviceManager = serviceManager; - } - - public ListStorageAccountKeysResult listKeys(String resourceGroupName, String workspaceName) { - ListStorageAccountKeysResultInner inner = this.serviceClient().listKeys(resourceGroupName, workspaceName); - if (inner != null) { - return new ListStorageAccountKeysResultImpl(inner, this.manager()); - } else { - return null; - } - } - - public Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context) { - Response inner = - this.serviceClient().listKeysWithResponse(resourceGroupName, workspaceName, context); - if (inner != null) { - return new SimpleResponse<>( - inner.getRequest(), - inner.getStatusCode(), - inner.getHeaders(), - new ListStorageAccountKeysResultImpl(inner.getValue(), this.manager())); - } else { - return null; - } - } - - private StorageAccountsClient serviceClient() { - return this.innerClient; - } - - private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { - return this.serviceManager; - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesClientImpl.java index 3c0c84e91b960..116185d388d4e 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesClientImpl.java @@ -25,7 +25,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.UsagesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.UsageInner; import com.azure.resourcemanager.machinelearningservices.models.ListUsagesResult; @@ -33,8 +32,6 @@ /** An instance of this class provides access to all the operations defined in UsagesClient. */ public final class UsagesClientImpl implements UsagesClient { - private final ClientLogger logger = new ClientLogger(UsagesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final UsagesService service; @@ -88,7 +85,8 @@ Mono> listNext( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location + * along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location) { @@ -139,7 +137,8 @@ private Mono> listSinglePageAsync(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location + * along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String location, Context context) { @@ -186,7 +185,8 @@ private Mono> listSinglePageAsync(String location, Con * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location) { @@ -201,7 +201,8 @@ private PagedFlux listAsync(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String location, Context context) { @@ -216,7 +217,8 @@ private PagedFlux listAsync(String location, Context context) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location) { @@ -231,7 +233,8 @@ public PagedIterable list(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String location, Context context) { @@ -245,7 +248,8 @@ public PagedIterable list(String location, Context context) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Usages operation response. + * @return the List Usages operation response along with {@link PagedResponse} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -281,7 +285,8 @@ private Mono> listNextSinglePageAsync(String nextLink) * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Usages operation response. + * @return the List Usages operation response along with {@link PagedResponse} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesImpl.java index 4b4b1cc5ebcd8..c1e9701914493 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/UsagesImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.UsageInner; import com.azure.resourcemanager.machinelearningservices.models.Usage; import com.azure.resourcemanager.machinelearningservices.models.Usages; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class UsagesImpl implements Usages { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UsagesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(UsagesImpl.class); private final UsagesClient innerClient; diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizeListResultImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizeListResultImpl.java index 8e9621b0b80e9..bd99f24374157 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizeListResultImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizeListResultImpl.java @@ -22,8 +22,8 @@ public final class VirtualMachineSizeListResultImpl implements VirtualMachineSiz this.serviceManager = serviceManager; } - public List amlCompute() { - List inner = this.innerModel().amlCompute(); + public List value() { + List inner = this.innerModel().value(); if (inner != null) { return Collections.unmodifiableList(inner); } else { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesClientImpl.java index 9aec335b867de..83784304d2208 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesClientImpl.java @@ -21,15 +21,12 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.VirtualMachineSizesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.VirtualMachineSizeListResultInner; import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in VirtualMachineSizesClient. */ public final class VirtualMachineSizesClientImpl implements VirtualMachineSizesClient { - private final ClientLogger logger = new ClientLogger(VirtualMachineSizesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final VirtualMachineSizesService service; @@ -74,7 +71,8 @@ Mono> 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 the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response along with {@link Response} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listWithResponseAsync(String location) { @@ -116,7 +114,8 @@ 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 the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response along with {@link Response} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listWithResponseAsync(String location, Context context) { @@ -154,7 +153,7 @@ 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 the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono listAsync(String location) { @@ -191,7 +190,7 @@ public VirtualMachineSizeListResultInner list(String location) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response listWithResponse(String location, Context context) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesImpl.java index 7a8f08e3ae95e..0bbf1fd38bbde 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/VirtualMachineSizesImpl.java @@ -12,10 +12,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.VirtualMachineSizeListResultInner; import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineSizeListResult; import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineSizes; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class VirtualMachineSizesImpl implements VirtualMachineSizes { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineSizesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(VirtualMachineSizesImpl.class); private final VirtualMachineSizesClient innerClient; diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionImpl.java index db3468ff5543b..36b626603b2cf 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionImpl.java @@ -8,7 +8,6 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceConnectionInner; import com.azure.resourcemanager.machinelearningservices.models.ValueFormat; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnection; -import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnectionDto; public final class WorkspaceConnectionImpl implements WorkspaceConnection, WorkspaceConnection.Definition { private WorkspaceConnectionInner innerObject; @@ -68,8 +67,6 @@ private com.azure.resourcemanager.machinelearningservices.MachineLearningService private String connectionName; - private WorkspaceConnectionDto createParameters; - public WorkspaceConnectionImpl withExistingWorkspace(String resourceGroupName, String workspaceName) { this.resourceGroupName = resourceGroupName; this.workspaceName = workspaceName; @@ -81,7 +78,7 @@ public WorkspaceConnection create() { serviceManager .serviceClient() .getWorkspaceConnections() - .createWithResponse(resourceGroupName, workspaceName, connectionName, createParameters, Context.NONE) + .createWithResponse(resourceGroupName, workspaceName, connectionName, this.innerModel(), Context.NONE) .getValue(); return this; } @@ -91,7 +88,7 @@ public WorkspaceConnection create(Context context) { serviceManager .serviceClient() .getWorkspaceConnections() - .createWithResponse(resourceGroupName, workspaceName, connectionName, createParameters, context) + .createWithResponse(resourceGroupName, workspaceName, connectionName, this.innerModel(), context) .getValue(); return this; } @@ -101,7 +98,6 @@ public WorkspaceConnection create(Context context) { this.innerObject = new WorkspaceConnectionInner(); this.serviceManager = serviceManager; this.connectionName = name; - this.createParameters = new WorkspaceConnectionDto(); } public WorkspaceConnection refresh() { @@ -124,33 +120,28 @@ public WorkspaceConnection refresh(Context context) { return this; } - public WorkspaceConnectionImpl withName(String name) { - this.createParameters.withName(name); - return this; - } - public WorkspaceConnectionImpl withCategory(String category) { - this.createParameters.withCategory(category); + this.innerModel().withCategory(category); return this; } public WorkspaceConnectionImpl withTarget(String target) { - this.createParameters.withTarget(target); + this.innerModel().withTarget(target); return this; } public WorkspaceConnectionImpl withAuthType(String authType) { - this.createParameters.withAuthType(authType); + this.innerModel().withAuthType(authType); return this; } public WorkspaceConnectionImpl withValue(String value) { - this.createParameters.withValue(value); + this.innerModel().withValue(value); return this; } public WorkspaceConnectionImpl withValueFormat(ValueFormat valueFormat) { - this.createParameters.withValueFormat(valueFormat); + this.innerModel().withValueFormat(valueFormat); return this; } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsClientImpl.java index 90d23d115a653..b0b9e57988ae0 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsClientImpl.java @@ -28,17 +28,13 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceConnectionsClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceConnectionInner; import com.azure.resourcemanager.machinelearningservices.models.PaginatedWorkspaceConnectionsList; -import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnectionDto; import reactor.core.publisher.Mono; /** An instance of this class provides access to all the operations defined in WorkspaceConnectionsClient. */ public final class WorkspaceConnectionsClientImpl implements WorkspaceConnectionsClient { - private final ClientLogger logger = new ClientLogger(WorkspaceConnectionsClientImpl.class); - /** The proxy service used to perform REST calls. */ private final WorkspaceConnectionsService service; @@ -94,7 +90,7 @@ Mono> create( @PathParam("workspaceName") String workspaceName, @PathParam("connectionName") String connectionName, @QueryParam("api-version") String apiVersion, - @BodyParam("application/json") WorkspaceConnectionDto parameters, + @BodyParam("application/json") WorkspaceConnectionInner parameters, @HeaderParam("Accept") String accept, Context context); @@ -134,14 +130,15 @@ Mono> delete( /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects along with {@link PagedResponse} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -190,7 +187,7 @@ private Mono> listSinglePageAsync( /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -198,7 +195,8 @@ private Mono> listSinglePageAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects along with {@link PagedResponse} on successful completion + * of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -244,14 +242,14 @@ private Mono> listSinglePageAsync( /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync( @@ -262,12 +260,12 @@ private PagedFlux listAsync( /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String workspaceName) { @@ -279,7 +277,7 @@ private PagedFlux listAsync(String resourceGroupName, /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -287,7 +285,7 @@ private PagedFlux listAsync(String resourceGroupName, * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync( @@ -298,12 +296,12 @@ private PagedFlux listAsync( /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String workspaceName) { @@ -315,7 +313,7 @@ public PagedIterable list(String resourceGroupName, St /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -323,7 +321,7 @@ public PagedIterable list(String resourceGroupName, St * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list( @@ -334,18 +332,18 @@ public PagedIterable list( /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 workspace connection. + * @return workspace connection along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> createWithResponseAsync( - String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionDto parameters) { + String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionInner parameters) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -394,7 +392,7 @@ private Mono> createWithResponseAsync( /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. @@ -402,14 +400,14 @@ private Mono> createWithResponseAsync( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 workspace connection. + * @return workspace connection along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> createWithResponseAsync( String resourceGroupName, String workspaceName, String connectionName, - WorkspaceConnectionDto parameters, + WorkspaceConnectionInner parameters, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -456,18 +454,18 @@ private Mono> createWithResponseAsync( /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 workspace connection. + * @return workspace connection on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createAsync( - String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionDto parameters) { + String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionInner parameters) { return createWithResponseAsync(resourceGroupName, workspaceName, connectionName, parameters) .flatMap( (Response res) -> { @@ -482,7 +480,7 @@ private Mono createAsync( /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. @@ -493,14 +491,14 @@ private Mono createAsync( */ @ServiceMethod(returns = ReturnType.SINGLE) public WorkspaceConnectionInner create( - String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionDto parameters) { + String resourceGroupName, String workspaceName, String connectionName, WorkspaceConnectionInner parameters) { return createAsync(resourceGroupName, workspaceName, connectionName, parameters).block(); } /** * Add a new workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param parameters The object for creating or updating a new workspace connection. @@ -508,14 +506,14 @@ public WorkspaceConnectionInner create( * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 workspace connection. + * @return workspace connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response createWithResponse( String resourceGroupName, String workspaceName, String connectionName, - WorkspaceConnectionDto parameters, + WorkspaceConnectionInner parameters, Context context) { return createWithResponseAsync(resourceGroupName, workspaceName, connectionName, parameters, context).block(); } @@ -523,13 +521,14 @@ public Response createWithResponse( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -576,14 +575,15 @@ private Mono> getWithResponseAsync( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @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 detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response} on successful completion of {@link + * Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getWithResponseAsync( @@ -627,13 +627,13 @@ private Mono> getWithResponseAsync( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 detail of a workspace connection. + * @return the detail of a workspace connection on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getAsync( @@ -652,7 +652,7 @@ private Mono getAsync( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -668,14 +668,14 @@ public WorkspaceConnectionInner get(String resourceGroupName, String workspaceNa /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @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 detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getWithResponse( @@ -686,13 +686,13 @@ public Response getWithResponse( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> deleteWithResponseAsync( @@ -739,14 +739,14 @@ private Mono> deleteWithResponseAsync( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> deleteWithResponseAsync( @@ -790,13 +790,13 @@ private Mono> deleteWithResponseAsync( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String workspaceName, String connectionName) { @@ -807,7 +807,7 @@ private Mono deleteAsync(String resourceGroupName, String workspaceName, S /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -822,14 +822,14 @@ public void delete(String resourceGroupName, String workspaceName, String connec /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response deleteWithResponse( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsImpl.java index 7cb1d6ab3fa0b..be168690202ee 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceConnectionsImpl.java @@ -13,10 +13,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceConnectionInner; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnection; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceConnections; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class WorkspaceConnectionsImpl implements WorkspaceConnections { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceConnectionsImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(WorkspaceConnectionsImpl.class); private final WorkspaceConnectionsClient innerClient; @@ -77,7 +76,7 @@ public Response deleteWithResponse( public WorkspaceConnection getById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -85,14 +84,14 @@ public WorkspaceConnection getById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String connectionName = Utils.getValueFromIdByName(id, "connections"); if (connectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'connections'.", id))); @@ -103,7 +102,7 @@ public WorkspaceConnection getById(String id) { public Response getByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -111,14 +110,14 @@ public Response getByIdWithResponse(String id, Context cont } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String connectionName = Utils.getValueFromIdByName(id, "connections"); if (connectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'connections'.", id))); @@ -129,7 +128,7 @@ public Response getByIdWithResponse(String id, Context cont public void deleteById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -137,25 +136,25 @@ public void deleteById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String connectionName = Utils.getValueFromIdByName(id, "connections"); if (connectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'connections'.", id))); } - this.deleteWithResponse(resourceGroupName, workspaceName, connectionName, Context.NONE).getValue(); + this.deleteWithResponse(resourceGroupName, workspaceName, connectionName, Context.NONE); } public Response deleteByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -163,14 +162,14 @@ public Response deleteByIdWithResponse(String id, Context context) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); } String connectionName = Utils.getValueFromIdByName(id, "connections"); if (connectionName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'connections'.", id))); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesClientImpl.java index 41defbc03575b..8a3c15351704b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesClientImpl.java @@ -25,7 +25,6 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceFeaturesClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.AmlUserFeatureInner; import com.azure.resourcemanager.machinelearningservices.models.ListAmlUserFeatureResult; @@ -33,8 +32,6 @@ /** An instance of this class provides access to all the operations defined in WorkspaceFeaturesClient. */ public final class WorkspaceFeaturesClientImpl implements WorkspaceFeaturesClient { - private final ClientLogger logger = new ClientLogger(WorkspaceFeaturesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final WorkspaceFeaturesService service; @@ -88,12 +85,13 @@ Mono> listNext( /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -145,13 +143,14 @@ private Mono> listSinglePageAsync( /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync( @@ -200,12 +199,12 @@ private Mono> listSinglePageAsync( /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String workspaceName) { @@ -216,13 +215,13 @@ private PagedFlux listAsync(String resourceGroupName, Strin /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String resourceGroupName, String workspaceName, Context context) { @@ -234,12 +233,12 @@ private PagedFlux listAsync(String resourceGroupName, Strin /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String workspaceName) { @@ -249,13 +248,13 @@ public PagedIterable list(String resourceGroupName, String /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String resourceGroupName, String workspaceName, Context context) { @@ -269,7 +268,8 @@ public PagedIterable list(String resourceGroupName, String * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink) { @@ -305,7 +305,8 @@ private Mono> listNextSinglePageAsync(String * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response along with {@link PagedResponse} on successful completion of + * {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNextSinglePageAsync(String nextLink, Context context) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesImpl.java index dec2c26e88bdd..308d9fd01547c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceFeaturesImpl.java @@ -11,10 +11,9 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.AmlUserFeatureInner; import com.azure.resourcemanager.machinelearningservices.models.AmlUserFeature; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceFeatures; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class WorkspaceFeaturesImpl implements WorkspaceFeatures { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceFeaturesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(WorkspaceFeaturesImpl.class); private final WorkspaceFeaturesClient innerClient; diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceImpl.java index 0f477e8e9d49c..05e81a929ee15 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceImpl.java @@ -11,13 +11,18 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceInner; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResult; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; import com.azure.resourcemanager.machinelearningservices.models.Identity; +import com.azure.resourcemanager.machinelearningservices.models.ListNotebookKeysResult; +import com.azure.resourcemanager.machinelearningservices.models.ListStorageAccountKeysResult; import com.azure.resourcemanager.machinelearningservices.models.ListWorkspaceKeysResult; import com.azure.resourcemanager.machinelearningservices.models.NotebookAccessTokenResult; import com.azure.resourcemanager.machinelearningservices.models.NotebookResourceInfo; import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnection; import com.azure.resourcemanager.machinelearningservices.models.ProvisioningState; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; import com.azure.resourcemanager.machinelearningservices.models.Sku; @@ -45,6 +50,10 @@ public String type() { return this.innerModel().type(); } + public Identity identity() { + return this.innerModel().identity(); + } + public String location() { return this.innerModel().location(); } @@ -58,6 +67,14 @@ public Map tags() { } } + public Sku sku() { + return this.innerModel().sku(); + } + + public SystemData systemData() { + return this.innerModel().systemData(); + } + public String workspaceId() { return this.innerModel().workspaceId(); } @@ -118,6 +135,10 @@ public Boolean allowPublicAccessWhenBehindVnet() { return this.innerModel().allowPublicAccessWhenBehindVnet(); } + public PublicNetworkAccess publicNetworkAccess() { + return this.innerModel().publicNetworkAccess(); + } + public List privateEndpointConnections() { List inner = this.innerModel().privateEndpointConnections(); if (inner != null) { @@ -162,16 +183,12 @@ public String tenantId() { return this.innerModel().tenantId(); } - public Identity identity() { - return this.innerModel().identity(); + public Boolean storageHnsEnabled() { + return this.innerModel().storageHnsEnabled(); } - public Sku sku() { - return this.innerModel().sku(); - } - - public SystemData systemData() { - return this.innerModel().systemData(); + public String mlFlowTrackingUri() { + return this.innerModel().mlFlowTrackingUri(); } public Region region() { @@ -280,6 +297,18 @@ public Workspace refresh(Context context) { return this; } + public DiagnoseResponseResult diagnose(DiagnoseWorkspaceParameters parameters) { + return serviceManager.workspaces().diagnose(resourceGroupName, workspaceName, parameters); + } + + public DiagnoseResponseResult diagnose() { + return serviceManager.workspaces().diagnose(resourceGroupName, workspaceName); + } + + public DiagnoseResponseResult diagnose(DiagnoseWorkspaceParameters parameters, Context context) { + return serviceManager.workspaces().diagnose(resourceGroupName, workspaceName, parameters, context); + } + public ListWorkspaceKeysResult listKeys() { return serviceManager.workspaces().listKeys(resourceGroupName, workspaceName); } @@ -306,6 +335,32 @@ public Response listNotebookAccessTokenWithResponse(C .listNotebookAccessTokenWithResponse(resourceGroupName, workspaceName, context); } + public NotebookResourceInfo prepareNotebook() { + return serviceManager.workspaces().prepareNotebook(resourceGroupName, workspaceName); + } + + public NotebookResourceInfo prepareNotebook(Context context) { + return serviceManager.workspaces().prepareNotebook(resourceGroupName, workspaceName, context); + } + + public ListStorageAccountKeysResult listStorageAccountKeys() { + return serviceManager.workspaces().listStorageAccountKeys(resourceGroupName, workspaceName); + } + + public Response listStorageAccountKeysWithResponse(Context context) { + return serviceManager + .workspaces() + .listStorageAccountKeysWithResponse(resourceGroupName, workspaceName, context); + } + + public ListNotebookKeysResult listNotebookKeys() { + return serviceManager.workspaces().listNotebookKeys(resourceGroupName, workspaceName); + } + + public Response listNotebookKeysWithResponse(Context context) { + return serviceManager.workspaces().listNotebookKeysWithResponse(resourceGroupName, workspaceName, context); + } + public WorkspaceImpl withRegion(Region location) { this.innerModel().withLocation(location.toString()); return this; @@ -326,6 +381,26 @@ public WorkspaceImpl withTags(Map tags) { } } + public WorkspaceImpl withIdentity(Identity identity) { + if (isInCreateMode()) { + this.innerModel().withIdentity(identity); + return this; + } else { + this.updateParameters.withIdentity(identity); + return this; + } + } + + public WorkspaceImpl withSku(Sku sku) { + if (isInCreateMode()) { + this.innerModel().withSku(sku); + return this; + } else { + this.updateParameters.withSku(sku); + return this; + } + } + public WorkspaceImpl withDescription(String description) { if (isInCreateMode()) { this.innerModel().withDescription(description); @@ -396,6 +471,16 @@ public WorkspaceImpl withAllowPublicAccessWhenBehindVnet(Boolean allowPublicAcce return this; } + public WorkspaceImpl withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) { + if (isInCreateMode()) { + this.innerModel().withPublicNetworkAccess(publicNetworkAccess); + return this; + } else { + this.updateParameters.withPublicNetworkAccess(publicNetworkAccess); + return this; + } + } + public WorkspaceImpl withSharedPrivateLinkResources(List sharedPrivateLinkResources) { this.innerModel().withSharedPrivateLinkResources(sharedPrivateLinkResources); return this; @@ -422,26 +507,6 @@ public WorkspaceImpl withPrimaryUserAssignedIdentity(String primaryUserAssignedI } } - public WorkspaceImpl withIdentity(Identity identity) { - if (isInCreateMode()) { - this.innerModel().withIdentity(identity); - return this; - } else { - this.updateParameters.withIdentity(identity); - return this; - } - } - - public WorkspaceImpl withSku(Sku sku) { - if (isInCreateMode()) { - this.innerModel().withSku(sku); - return this; - } else { - this.updateParameters.withSku(sku); - return this; - } - } - private boolean isInCreateMode() { return this.innerModel().id() == null; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacePropertiesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacePropertiesImpl.java new file mode 100644 index 0000000000000..02980f856c5b3 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacePropertiesImpl.java @@ -0,0 +1,157 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.implementation; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspacePropertiesInner; +import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; +import com.azure.resourcemanager.machinelearningservices.models.NotebookResourceInfo; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointConnection; +import com.azure.resourcemanager.machinelearningservices.models.ProvisioningState; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; +import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; +import com.azure.resourcemanager.machinelearningservices.models.WorkspaceProperties; +import java.util.Collections; +import java.util.List; +import java.util.stream.Collectors; + +public final class WorkspacePropertiesImpl implements WorkspaceProperties { + private WorkspacePropertiesInner innerObject; + + private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; + + WorkspacePropertiesImpl( + WorkspacePropertiesInner innerObject, + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { + this.innerObject = innerObject; + this.serviceManager = serviceManager; + } + + public String workspaceId() { + return this.innerModel().workspaceId(); + } + + public String description() { + return this.innerModel().description(); + } + + public String friendlyName() { + return this.innerModel().friendlyName(); + } + + public String keyVault() { + return this.innerModel().keyVault(); + } + + public String applicationInsights() { + return this.innerModel().applicationInsights(); + } + + public String containerRegistry() { + return this.innerModel().containerRegistry(); + } + + public String storageAccount() { + return this.innerModel().storageAccount(); + } + + public String discoveryUrl() { + return this.innerModel().discoveryUrl(); + } + + public ProvisioningState provisioningState() { + return this.innerModel().provisioningState(); + } + + public EncryptionProperty encryption() { + return this.innerModel().encryption(); + } + + public Boolean hbiWorkspace() { + return this.innerModel().hbiWorkspace(); + } + + public String serviceProvisionedResourceGroup() { + return this.innerModel().serviceProvisionedResourceGroup(); + } + + public Integer privateLinkCount() { + return this.innerModel().privateLinkCount(); + } + + public String imageBuildCompute() { + return this.innerModel().imageBuildCompute(); + } + + public Boolean allowPublicAccessWhenBehindVnet() { + return this.innerModel().allowPublicAccessWhenBehindVnet(); + } + + public PublicNetworkAccess publicNetworkAccess() { + return this.innerModel().publicNetworkAccess(); + } + + public List privateEndpointConnections() { + List inner = this.innerModel().privateEndpointConnections(); + if (inner != null) { + return Collections + .unmodifiableList( + inner + .stream() + .map(inner1 -> new PrivateEndpointConnectionImpl(inner1, this.manager())) + .collect(Collectors.toList())); + } else { + return Collections.emptyList(); + } + } + + public List sharedPrivateLinkResources() { + List inner = this.innerModel().sharedPrivateLinkResources(); + if (inner != null) { + return Collections.unmodifiableList(inner); + } else { + return Collections.emptyList(); + } + } + + public NotebookResourceInfo notebookInfo() { + NotebookResourceInfoInner inner = this.innerModel().notebookInfo(); + if (inner != null) { + return new NotebookResourceInfoImpl(inner, this.manager()); + } else { + return null; + } + } + + public ServiceManagedResourcesSettings serviceManagedResourcesSettings() { + return this.innerModel().serviceManagedResourcesSettings(); + } + + public String primaryUserAssignedIdentity() { + return this.innerModel().primaryUserAssignedIdentity(); + } + + public String tenantId() { + return this.innerModel().tenantId(); + } + + public Boolean storageHnsEnabled() { + return this.innerModel().storageHnsEnabled(); + } + + public String mlFlowTrackingUri() { + return this.innerModel().mlFlowTrackingUri(); + } + + public WorkspacePropertiesInner innerModel() { + return this.innerObject; + } + + private com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager() { + return this.serviceManager; + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusClientImpl.java similarity index 80% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsClientImpl.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusClientImpl.java index 60e248d95dc9a..9cdd9671d0645 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusClientImpl.java @@ -25,45 +25,42 @@ import com.azure.core.management.exception.ManagementException; import com.azure.core.util.Context; import com.azure.core.util.FluxUtil; -import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceOperationsClient; +import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceSkusClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceSkuInner; import com.azure.resourcemanager.machinelearningservices.models.SkuListResult; import reactor.core.publisher.Mono; -/** An instance of this class provides access to all the operations defined in WorkspaceOperationsClient. */ -public final class WorkspaceOperationsClientImpl implements WorkspaceOperationsClient { - private final ClientLogger logger = new ClientLogger(WorkspaceOperationsClientImpl.class); - +/** An instance of this class provides access to all the operations defined in WorkspaceSkusClient. */ +public final class WorkspaceSkusClientImpl implements WorkspaceSkusClient { /** The proxy service used to perform REST calls. */ - private final WorkspaceOperationsService service; + private final WorkspaceSkusService service; /** The service client containing this operation class. */ private final AzureMachineLearningWorkspacesImpl client; /** - * Initializes an instance of WorkspaceOperationsClientImpl. + * Initializes an instance of WorkspaceSkusClientImpl. * * @param client the instance of the service client containing this operation class. */ - WorkspaceOperationsClientImpl(AzureMachineLearningWorkspacesImpl client) { + WorkspaceSkusClientImpl(AzureMachineLearningWorkspacesImpl client) { this.service = - RestProxy.create(WorkspaceOperationsService.class, client.getHttpPipeline(), client.getSerializerAdapter()); + RestProxy.create(WorkspaceSkusService.class, client.getHttpPipeline(), client.getSerializerAdapter()); this.client = client; } /** - * The interface defining all the services for AzureMachineLearningWorkspacesWorkspaceOperations to be used by the - * proxy service to perform REST calls. + * The interface defining all the services for AzureMachineLearningWorkspacesWorkspaceSkus to be used by the proxy + * service to perform REST calls. */ @Host("{$host}") @ServiceInterface(name = "AzureMachineLearning") - private interface WorkspaceOperationsService { + private interface WorkspaceSkusService { @Headers({"Content-Type: application/json"}) @Get("/subscriptions/{subscriptionId}/providers/Microsoft.MachineLearningServices/workspaces/skus") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listSkus( + Mono> list( @HostParam("$host") String endpoint, @QueryParam("api-version") String apiVersion, @PathParam("subscriptionId") String subscriptionId, @@ -74,7 +71,7 @@ Mono> listSkus( @Get("{nextLink}") @ExpectedResponses({200}) @UnexpectedResponseExceptionType(ManagementException.class) - Mono> listSkusNext( + Mono> listNext( @PathParam(value = "nextLink", encoded = true) String nextLink, @HostParam("$host") String endpoint, @HeaderParam("Accept") String accept, @@ -86,10 +83,10 @@ Mono> listSkusNext( * * @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 skus with features. + * @return list of skus with features along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusSinglePageAsync() { + private Mono> listSinglePageAsync() { if (this.client.getEndpoint() == null) { return Mono .error( @@ -107,7 +104,7 @@ private Mono> listSkusSinglePageAsync() { .withContext( context -> service - .listSkus( + .list( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -132,10 +129,10 @@ private Mono> listSkusSinglePageAsync() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 skus with features. + * @return list of skus with features along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusSinglePageAsync(Context context) { + private Mono> listSinglePageAsync(Context context) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -151,7 +148,7 @@ private Mono> listSkusSinglePageAsync(Context c final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listSkus( + .list( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -173,11 +170,11 @@ private Mono> listSkusSinglePageAsync(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 list of skus with features. + * @return list of skus with features as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listSkusAsync() { - return new PagedFlux<>(() -> listSkusSinglePageAsync(), nextLink -> listSkusNextSinglePageAsync(nextLink)); + private PagedFlux listAsync() { + return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink)); } /** @@ -187,12 +184,12 @@ private PagedFlux listSkusAsync() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listSkusAsync(Context context) { + private PagedFlux listAsync(Context context) { return new PagedFlux<>( - () -> listSkusSinglePageAsync(context), nextLink -> listSkusNextSinglePageAsync(nextLink, context)); + () -> listSinglePageAsync(context), nextLink -> listNextSinglePageAsync(nextLink, context)); } /** @@ -200,11 +197,11 @@ private PagedFlux listSkusAsync(Context context) { * * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listSkus() { - return new PagedIterable<>(listSkusAsync()); + public PagedIterable list() { + return new PagedIterable<>(listAsync()); } /** @@ -214,11 +211,11 @@ public PagedIterable listSkus() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listSkus(Context context) { - return new PagedIterable<>(listSkusAsync(context)); + public PagedIterable list(Context context) { + return new PagedIterable<>(listAsync(context)); } /** @@ -228,10 +225,10 @@ public PagedIterable listSkus(Context context) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 skus with features. + * @return list of skus with features along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusNextSinglePageAsync(String nextLink) { + private Mono> listNextSinglePageAsync(String nextLink) { if (nextLink == null) { return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null.")); } @@ -243,7 +240,7 @@ private Mono> listSkusNextSinglePageAsync(Strin } final String accept = "application/json"; return FluxUtil - .withContext(context -> service.listSkusNext(nextLink, this.client.getEndpoint(), accept, context)) + .withContext(context -> service.listNext(nextLink, this.client.getEndpoint(), accept, context)) .>map( res -> new PagedResponseBase<>( @@ -264,10 +261,10 @@ private Mono> listSkusNextSinglePageAsync(Strin * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 skus with features. + * @return list of skus with features along with {@link PagedResponse} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusNextSinglePageAsync(String nextLink, Context context) { + private Mono> listNextSinglePageAsync(String nextLink, Context context) { if (nextLink == null) { return Mono.error(new IllegalArgumentException("Parameter nextLink is required and cannot be null.")); } @@ -280,7 +277,7 @@ private Mono> listSkusNextSinglePageAsync(Strin final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listSkusNext(nextLink, this.client.getEndpoint(), accept, context) + .listNext(nextLink, this.client.getEndpoint(), accept, context) .map( res -> new PagedResponseBase<>( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusImpl.java similarity index 70% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsImpl.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusImpl.java index 757f5afc2b2f8..5981a9f4e2880 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceOperationsImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspaceSkusImpl.java @@ -7,37 +7,36 @@ import com.azure.core.http.rest.PagedIterable; import com.azure.core.util.Context; import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceOperationsClient; +import com.azure.resourcemanager.machinelearningservices.fluent.WorkspaceSkusClient; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceSkuInner; -import com.azure.resourcemanager.machinelearningservices.models.WorkspaceOperations; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceSku; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.models.WorkspaceSkus; -public final class WorkspaceOperationsImpl implements WorkspaceOperations { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceOperationsImpl.class); +public final class WorkspaceSkusImpl implements WorkspaceSkus { + private static final ClientLogger LOGGER = new ClientLogger(WorkspaceSkusImpl.class); - private final WorkspaceOperationsClient innerClient; + private final WorkspaceSkusClient innerClient; private final com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager; - public WorkspaceOperationsImpl( - WorkspaceOperationsClient innerClient, + public WorkspaceSkusImpl( + WorkspaceSkusClient innerClient, com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager serviceManager) { this.innerClient = innerClient; this.serviceManager = serviceManager; } - public PagedIterable listSkus() { - PagedIterable inner = this.serviceClient().listSkus(); + public PagedIterable list() { + PagedIterable inner = this.serviceClient().list(); return Utils.mapPage(inner, inner1 -> new WorkspaceSkuImpl(inner1, this.manager())); } - public PagedIterable listSkus(Context context) { - PagedIterable inner = this.serviceClient().listSkus(context); + public PagedIterable list(Context context) { + PagedIterable inner = this.serviceClient().list(context); return Utils.mapPage(inner, inner1 -> new WorkspaceSkuImpl(inner1, this.manager())); } - private WorkspaceOperationsClient serviceClient() { + private WorkspaceSkusClient serviceClient() { return this.innerClient; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesClientImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesClientImpl.java index 741ed1c013b08..9fd7d905f4757 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesClientImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesClientImpl.java @@ -31,13 +31,18 @@ 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.machinelearningservices.fluent.WorkspacesClient; +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListNotebookKeysResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.ListWorkspaceKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookAccessTokenResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceInner; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceListResult; import com.azure.resourcemanager.machinelearningservices.models.WorkspaceUpdateParameters; import java.nio.ByteBuffer; @@ -46,8 +51,6 @@ /** An instance of this class provides access to all the operations defined in WorkspacesClient. */ public final class WorkspacesClientImpl implements WorkspacesClient { - private final ClientLogger logger = new ClientLogger(WorkspacesClientImpl.class); - /** The proxy service used to perform REST calls. */ private final WorkspacesService service; @@ -91,7 +94,7 @@ Mono> getByResourceGroup( @Put( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}") - @ExpectedResponses({200, 201, 202}) + @ExpectedResponses({200, 202}) @UnexpectedResponseExceptionType(ManagementException.class) Mono>> createOrUpdate( @HostParam("$host") String endpoint, @@ -149,6 +152,22 @@ Mono> listByResourceGroup( @HeaderParam("Accept") String accept, Context context); + @Headers({"Content-Type: application/json"}) + @Post( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/diagnose") + @ExpectedResponses({200, 202}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> diagnose( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @QueryParam("api-version") String apiVersion, + @BodyParam("application/json") DiagnoseWorkspaceParameters parameters, + @HeaderParam("Accept") String accept, + Context context); + @Headers({"Content-Type: application/json"}) @Post( "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" @@ -206,6 +225,66 @@ Mono> listNotebookAccessToken( @HeaderParam("Accept") String accept, Context context); + @Headers({"Content-Type: application/json"}) + @Post( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/prepareNotebook") + @ExpectedResponses({200, 202}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono>> prepareNotebook( + @HostParam("$host") String endpoint, + @QueryParam("api-version") String apiVersion, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Post( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/listStorageAccountKeys") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listStorageAccountKeys( + @HostParam("$host") String endpoint, + @QueryParam("api-version") String apiVersion, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Post( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/listNotebookKeys") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listNotebookKeys( + @HostParam("$host") String endpoint, + @QueryParam("api-version") String apiVersion, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @HeaderParam("Accept") String accept, + Context context); + + @Headers({"Content-Type: application/json"}) + @Get( + "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers" + + "/Microsoft.MachineLearningServices/workspaces/{workspaceName}/outboundNetworkDependenciesEndpoints") + @ExpectedResponses({200}) + @UnexpectedResponseExceptionType(ManagementException.class) + Mono> listOutboundNetworkDependenciesEndpoints( + @HostParam("$host") String endpoint, + @PathParam("subscriptionId") String subscriptionId, + @PathParam("resourceGroupName") String resourceGroupName, + @PathParam("workspaceName") String workspaceName, + @QueryParam("api-version") String apiVersion, + @HeaderParam("Accept") String accept, + Context context); + @Headers({"Content-Type: application/json"}) @Get("{nextLink}") @ExpectedResponses({200}) @@ -230,12 +309,13 @@ Mono> listBySubscriptionNext( /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getByResourceGroupWithResponseAsync( @@ -278,13 +358,14 @@ private Mono> getByResourceGroupWithResponseAsync( /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> getByResourceGroupWithResponseAsync( @@ -324,12 +405,12 @@ private Mono> getByResourceGroupWithResponseAsync( /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono getByResourceGroupAsync(String resourceGroupName, String workspaceName) { @@ -347,7 +428,7 @@ private Mono getByResourceGroupAsync(String resourceGroupName, S /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -362,13 +443,13 @@ public WorkspaceInner getByResourceGroup(String resourceGroupName, String worksp /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response getByResourceGroupWithResponse( @@ -379,13 +460,14 @@ public Response getByResourceGroupWithResponse( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -434,14 +516,15 @@ private Mono>> createOrUpdateWithResponseAsync( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> createOrUpdateWithResponseAsync( @@ -487,15 +570,15 @@ private Mono>> createOrUpdateWithResponseAsync( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link PollerFlux} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, WorkspaceInner> beginCreateOrUpdateAsync( String resourceGroupName, String workspaceName, WorkspaceInner parameters) { Mono>> mono = @@ -503,22 +586,26 @@ private PollerFlux, WorkspaceInner> beginCreateOrUpda return this .client .getLroResult( - mono, this.client.getHttpPipeline(), WorkspaceInner.class, WorkspaceInner.class, Context.NONE); + mono, + this.client.getHttpPipeline(), + WorkspaceInner.class, + WorkspaceInner.class, + this.client.getContext()); } /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link PollerFlux} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, WorkspaceInner> beginCreateOrUpdateAsync( String resourceGroupName, String workspaceName, WorkspaceInner parameters, Context context) { context = this.client.mergeContext(context); @@ -533,15 +620,15 @@ private PollerFlux, WorkspaceInner> beginCreateOrUpda /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link SyncPoller} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, WorkspaceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, WorkspaceInner parameters) { return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, parameters).getSyncPoller(); @@ -550,16 +637,16 @@ public SyncPoller, WorkspaceInner> beginCreateOrUpdat /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return the {@link SyncPoller} for polling of an object that represents a machine learning workspace. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, WorkspaceInner> beginCreateOrUpdate( String resourceGroupName, String workspaceName, WorkspaceInner parameters, Context context) { return beginCreateOrUpdateAsync(resourceGroupName, workspaceName, parameters, context).getSyncPoller(); @@ -568,13 +655,13 @@ public SyncPoller, WorkspaceInner> beginCreateOrUpdat /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -587,14 +674,14 @@ private Mono createOrUpdateAsync( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono createOrUpdateAsync( @@ -607,7 +694,7 @@ private Mono createOrUpdateAsync( /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -623,7 +710,7 @@ public WorkspaceInner createOrUpdate(String resourceGroupName, String workspaceN /** * Creates or updates a workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for creating or updating a machine learning workspace. * @param context The context to associate with this operation. @@ -641,12 +728,12 @@ public WorkspaceInner createOrUpdate( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync(String resourceGroupName, String workspaceName) { @@ -688,13 +775,13 @@ private Mono>> deleteWithResponseAsync(String resource /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono>> deleteWithResponseAsync( @@ -734,33 +821,34 @@ private Mono>> deleteWithResponseAsync( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync(String resourceGroupName, String workspaceName) { Mono>> mono = deleteWithResponseAsync(resourceGroupName, workspaceName); return this .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); } /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link PollerFlux} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String workspaceName, Context context) { context = this.client.mergeContext(context); @@ -773,14 +861,14 @@ private PollerFlux, Void> beginDeleteAsync( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete(String resourceGroupName, String workspaceName) { return beginDeleteAsync(resourceGroupName, workspaceName).getSyncPoller(); } @@ -788,15 +876,15 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, Context context) { return beginDeleteAsync(resourceGroupName, workspaceName, context).getSyncPoller(); @@ -805,12 +893,12 @@ public SyncPoller, Void> beginDelete( /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String workspaceName) { @@ -820,13 +908,13 @@ private Mono deleteAsync(String resourceGroupName, String workspaceName) { /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono deleteAsync(String resourceGroupName, String workspaceName, Context context) { @@ -838,7 +926,7 @@ private Mono deleteAsync(String resourceGroupName, String workspaceName, C /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -852,7 +940,7 @@ public void delete(String resourceGroupName, String workspaceName) { /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -867,13 +955,14 @@ public void delete(String resourceGroupName, String workspaceName, Context conte /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -922,14 +1011,15 @@ private Mono> updateWithResponseAsync( /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response} on successful + * completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> updateWithResponseAsync( @@ -975,13 +1065,13 @@ private Mono> updateWithResponseAsync( /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono updateAsync( @@ -1000,7 +1090,7 @@ private Mono updateAsync( /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1016,14 +1106,14 @@ public WorkspaceInner update(String resourceGroupName, String workspaceName, Wor /** * Updates a machine learning workspace with the specified parameters. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param parameters The parameters for updating a machine learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return an object that represents a machine learning workspace. + * @return an object that represents a machine learning workspace along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response updateWithResponse( @@ -1034,12 +1124,13 @@ public Response updateWithResponse( /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupSinglePageAsync( @@ -1088,13 +1179,14 @@ private Mono> listByResourceGroupSinglePageAsync( /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupSinglePageAsync( @@ -1140,12 +1232,12 @@ private Mono> listByResourceGroupSinglePageAsync( /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listByResourceGroupAsync(String resourceGroupName, String skip) { @@ -1157,11 +1249,11 @@ private PagedFlux listByResourceGroupAsync(String resourceGroupN /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listByResourceGroupAsync(String resourceGroupName) { @@ -1174,13 +1266,13 @@ private PagedFlux listByResourceGroupAsync(String resourceGroupN /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listByResourceGroupAsync(String resourceGroupName, String skip, Context context) { @@ -1192,11 +1284,12 @@ private PagedFlux listByResourceGroupAsync(String resourceGroupN /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listByResourceGroup(String resourceGroupName) { @@ -1207,13 +1300,14 @@ public PagedIterable listByResourceGroup(String resourceGroupNam /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listByResourceGroup(String resourceGroupName, String skip, Context context) { @@ -1221,19 +1315,19 @@ public PagedIterable listByResourceGroup(String resourceGroupNam } /** - * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and - * password for container registry. + * Diagnose workspace setup issue. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName) { + private Mono>> diagnoseWithResponseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -1253,37 +1347,41 @@ private Mono> listKeysWithResponseAsync( if (workspaceName == null) { return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); } + if (parameters != null) { + parameters.validate(); + } final String accept = "application/json"; return FluxUtil .withContext( context -> service - .listKeys( + .diagnose( this.client.getEndpoint(), - this.client.getApiVersion(), this.client.getSubscriptionId(), resourceGroupName, workspaceName, + this.client.getApiVersion(), + parameters, accept, context)) .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); } /** - * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and - * password for container registry. + * Diagnose workspace setup issue. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listKeysWithResponseAsync( - String resourceGroupName, String workspaceName, Context context) { + private Mono>> diagnoseWithResponseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -1303,48 +1401,189 @@ private Mono> listKeysWithResponseAsync( if (workspaceName == null) { return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); } + if (parameters != null) { + parameters.validate(); + } final String accept = "application/json"; context = this.client.mergeContext(context); return service - .listKeys( + .diagnose( this.client.getEndpoint(), - this.client.getApiVersion(), this.client.getSubscriptionId(), resourceGroupName, workspaceName, + this.client.getApiVersion(), + parameters, accept, context); } /** - * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and - * password for container registry. + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, DiagnoseResponseResultInner> beginDiagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + Mono>> mono = diagnoseWithResponseAsync(resourceGroupName, workspaceName, parameters); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + DiagnoseResponseResultInner.class, + DiagnoseResponseResultInner.class, + this.client.getContext()); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, DiagnoseResponseResultInner> beginDiagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + diagnoseWithResponseAsync(resourceGroupName, workspaceName, parameters, context); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + DiagnoseResponseResultInner.class, + DiagnoseResponseResultInner.class, + context); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, DiagnoseResponseResultInner> beginDiagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters).getSyncPoller(); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, DiagnoseResponseResultInner> beginDiagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters, context).getSyncPoller(); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono diagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono diagnoseAsync(String resourceGroupName, String workspaceName) { + final DiagnoseWorkspaceParameters parameters = null; + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono diagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Diagnose workspace setup issue. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono listKeysAsync(String resourceGroupName, String workspaceName) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName) - .flatMap( - (Response res) -> { - if (res.getValue() != null) { - return Mono.just(res.getValue()); - } else { - return Mono.empty(); - } - }); + public DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + return diagnoseAsync(resourceGroupName, workspaceName, parameters).block(); } /** - * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and - * password for container registry. + * Diagnose workspace setup issue. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1352,16 +1591,17 @@ private Mono listKeysAsync(String resourceGroupNam * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ListWorkspaceKeysResultInner listKeys(String resourceGroupName, String workspaceName) { - return listKeysAsync(resourceGroupName, workspaceName).block(); + public DiagnoseResponseResultInner diagnose(String resourceGroupName, String workspaceName) { + final DiagnoseWorkspaceParameters parameters = null; + return diagnoseAsync(resourceGroupName, workspaceName, parameters).block(); } /** - * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and - * password for container registry. + * Diagnose workspace setup issue. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. * @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. @@ -1369,24 +1609,24 @@ public ListWorkspaceKeysResultInner listKeys(String resourceGroupName, String wo * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - public Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context) { - return listKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); + public DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + return diagnoseAsync(resourceGroupName, workspaceName, parameters, context).block(); } /** - * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> resyncKeysWithResponseAsync( + private Mono> listKeysWithResponseAsync( String resourceGroupName, String workspaceName) { if (this.client.getEndpoint() == null) { return Mono @@ -1412,7 +1652,7 @@ private Mono>> resyncKeysWithResponseAsync( .withContext( context -> service - .resyncKeys( + .listKeys( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -1424,19 +1664,19 @@ private Mono>> resyncKeysWithResponseAsync( } /** - * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> resyncKeysWithResponseAsync( + private Mono> listKeysWithResponseAsync( String resourceGroupName, String workspaceName, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -1460,7 +1700,7 @@ private Mono>> resyncKeysWithResponseAsync( final String accept = "application/json"; context = this.client.mergeContext(context); return service - .resyncKeys( + .listKeys( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -1471,58 +1711,213 @@ private Mono>> resyncKeysWithResponseAsync( } /** - * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return the response body on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, Void> beginResyncKeysAsync(String resourceGroupName, String workspaceName) { - Mono>> mono = resyncKeysWithResponseAsync(resourceGroupName, workspaceName); - return this - .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, Context.NONE); + private Mono listKeysAsync(String resourceGroupName, String workspaceName) { + return listKeysWithResponseAsync(resourceGroupName, workspaceName) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); } /** - * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. - * @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. + * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - private PollerFlux, Void> beginResyncKeysAsync( - String resourceGroupName, String workspaceName, Context context) { - context = this.client.mergeContext(context); - Mono>> mono = resyncKeysWithResponseAsync(resourceGroupName, workspaceName, context); - return this - .client - .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context); - } + public ListWorkspaceKeysResultInner listKeys(String resourceGroupName, String workspaceName) { + return listKeysAsync(resourceGroupName, workspaceName).block(); + } + + /** + * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and + * password for container registry. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response listKeysWithResponse( + String resourceGroupName, String workspaceName, Context context) { + return listKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); + } + + /** + * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * password for container registry. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> resyncKeysWithResponseAsync( + String resourceGroupName, String workspaceName) { + 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .resyncKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } /** * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. + * @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. + * @return the {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> resyncKeysWithResponseAsync( + String resourceGroupName, String workspaceName, 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .resyncKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context); + } + + /** + * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * password for container registry. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginResyncKeysAsync(String resourceGroupName, String workspaceName) { + Mono>> mono = resyncKeysWithResponseAsync(resourceGroupName, workspaceName); + return this + .client + .getLroResult( + mono, this.client.getHttpPipeline(), Void.class, Void.class, this.client.getContext()); + } + + /** + * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * password for container registry. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, Void> beginResyncKeysAsync( + String resourceGroupName, String workspaceName, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = resyncKeysWithResponseAsync(resourceGroupName, workspaceName, context); + return this + .client + .getLroResult(mono, this.client.getHttpPipeline(), Void.class, Void.class, context); + } + + /** + * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * password for container registry. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginResyncKeys(String resourceGroupName, String workspaceName) { return beginResyncKeysAsync(resourceGroupName, workspaceName).getSyncPoller(); } @@ -1531,15 +1926,15 @@ public SyncPoller, Void> beginResyncKeys(String resourceGroupNa * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return the {@link SyncPoller} for polling of long-running operation. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginResyncKeys( String resourceGroupName, String workspaceName, Context context) { return beginResyncKeysAsync(resourceGroupName, workspaceName, context).getSyncPoller(); @@ -1549,12 +1944,12 @@ public SyncPoller, Void> beginResyncKeys( * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono resyncKeysAsync(String resourceGroupName, String workspaceName) { @@ -1567,13 +1962,13 @@ private Mono resyncKeysAsync(String resourceGroupName, String workspaceNam * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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. + * @return A {@link Mono} that completes when a successful response is received. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono resyncKeysAsync(String resourceGroupName, String workspaceName, Context context) { @@ -1586,7 +1981,7 @@ private Mono resyncKeysAsync(String resourceGroupName, String workspaceNam * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1601,7 +1996,7 @@ public void resyncKeys(String resourceGroupName, String workspaceName) { * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1620,7 +2015,8 @@ public void resyncKeys(String resourceGroupName, String workspaceName, Context c * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String skip) { @@ -1668,7 +2064,8 @@ private Mono> listSinglePageAsync(String skip) { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listSinglePageAsync(String skip, Context context) { @@ -1712,7 +2109,7 @@ private Mono> listSinglePageAsync(String skip, Con * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String skip) { @@ -1725,7 +2122,7 @@ private PagedFlux listAsync(String skip) { * * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync() { @@ -1742,7 +2139,7 @@ private PagedFlux listAsync() { * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link PagedFlux}. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listAsync(String skip, Context context) { @@ -1756,7 +2153,8 @@ private PagedFlux listAsync(String skip, Context context) { * * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list() { @@ -1772,7 +2170,8 @@ public PagedIterable 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 the result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable list(String skip, Context context) { @@ -1782,12 +2181,12 @@ public PagedIterable list(String skip, Context context) { /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNotebookAccessTokenWithResponseAsync( @@ -1830,13 +2229,13 @@ private Mono> listNotebookAccessTokenWi /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNotebookAccessTokenWithResponseAsync( @@ -1876,12 +2275,12 @@ private Mono> listNotebookAccessTokenWi /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body on successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono listNotebookAccessTokenAsync( @@ -1900,7 +2299,7 @@ private Mono listNotebookAccessTokenAsync( /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. @@ -1915,13 +2314,13 @@ public NotebookAccessTokenResultInner listNotebookAccessToken(String resourceGro /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ @ServiceMethod(returns = ReturnType.SINGLE) public Response listNotebookAccessTokenWithResponse( @@ -1929,6 +2328,702 @@ public Response listNotebookAccessTokenWithRespo return listNotebookAccessTokenWithResponseAsync(resourceGroupName, workspaceName, context).block(); } + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> prepareNotebookWithResponseAsync( + String resourceGroupName, String workspaceName) { + 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .prepareNotebook( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono>> prepareNotebookWithResponseAsync( + String resourceGroupName, String workspaceName, 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .prepareNotebook( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, NotebookResourceInfoInner> beginPrepareNotebookAsync( + String resourceGroupName, String workspaceName) { + Mono>> mono = prepareNotebookWithResponseAsync(resourceGroupName, workspaceName); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + NotebookResourceInfoInner.class, + NotebookResourceInfoInner.class, + this.client.getContext()); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link PollerFlux} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + private PollerFlux, NotebookResourceInfoInner> beginPrepareNotebookAsync( + String resourceGroupName, String workspaceName, Context context) { + context = this.client.mergeContext(context); + Mono>> mono = + prepareNotebookWithResponseAsync(resourceGroupName, workspaceName, context); + return this + .client + .getLroResult( + mono, + this.client.getHttpPipeline(), + NotebookResourceInfoInner.class, + NotebookResourceInfoInner.class, + context); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, NotebookResourceInfoInner> beginPrepareNotebook( + String resourceGroupName, String workspaceName) { + return beginPrepareNotebookAsync(resourceGroupName, workspaceName).getSyncPoller(); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the {@link SyncPoller} for polling of long-running operation. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) + public SyncPoller, NotebookResourceInfoInner> beginPrepareNotebook( + String resourceGroupName, String workspaceName, Context context) { + return beginPrepareNotebookAsync(resourceGroupName, workspaceName, context).getSyncPoller(); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono prepareNotebookAsync(String resourceGroupName, String workspaceName) { + return beginPrepareNotebookAsync(resourceGroupName, workspaceName) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono prepareNotebookAsync( + String resourceGroupName, String workspaceName, Context context) { + return beginPrepareNotebookAsync(resourceGroupName, workspaceName, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public NotebookResourceInfoInner prepareNotebook(String resourceGroupName, String workspaceName) { + return prepareNotebookAsync(resourceGroupName, workspaceName).block(); + } + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public NotebookResourceInfoInner prepareNotebook(String resourceGroupName, String workspaceName, Context context) { + return prepareNotebookAsync(resourceGroupName, workspaceName, context).block(); + } + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listStorageAccountKeysWithResponseAsync( + String resourceGroupName, String workspaceName) { + 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .listStorageAccountKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listStorageAccountKeysWithResponseAsync( + String resourceGroupName, String workspaceName, 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .listStorageAccountKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context); + } + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono listStorageAccountKeysAsync( + String resourceGroupName, String workspaceName) { + return listStorageAccountKeysWithResponseAsync(resourceGroupName, workspaceName) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); + } + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public ListStorageAccountKeysResultInner listStorageAccountKeys(String resourceGroupName, String workspaceName) { + return listStorageAccountKeysAsync(resourceGroupName, workspaceName).block(); + } + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response listStorageAccountKeysWithResponse( + String resourceGroupName, String workspaceName, Context context) { + return listStorageAccountKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); + } + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNotebookKeysWithResponseAsync( + String resourceGroupName, String workspaceName) { + 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .listNotebookKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listNotebookKeysWithResponseAsync( + String resourceGroupName, String workspaceName, 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .listNotebookKeys( + this.client.getEndpoint(), + this.client.getApiVersion(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + accept, + context); + } + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono listNotebookKeysAsync(String resourceGroupName, String workspaceName) { + return listNotebookKeysWithResponseAsync(resourceGroupName, workspaceName) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); + } + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public ListNotebookKeysResultInner listNotebookKeys(String resourceGroupName, String workspaceName) { + return listNotebookKeysAsync(resourceGroupName, workspaceName).block(); + } + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response listNotebookKeysWithResponse( + String resourceGroupName, String workspaceName, Context context) { + return listNotebookKeysWithResponseAsync(resourceGroupName, workspaceName, context).block(); + } + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listOutboundNetworkDependenciesEndpointsWithResponseAsync( + String resourceGroupName, String workspaceName) { + 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + return FluxUtil + .withContext( + context -> + service + .listOutboundNetworkDependenciesEndpoints( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + this.client.getApiVersion(), + accept, + context)) + .contextWrite(context -> context.putAll(FluxUtil.toReactorContext(this.client.getContext()).readOnly())); + } + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response} on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono> listOutboundNetworkDependenciesEndpointsWithResponseAsync( + String resourceGroupName, String workspaceName, 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 (workspaceName == null) { + return Mono.error(new IllegalArgumentException("Parameter workspaceName is required and cannot be null.")); + } + final String accept = "application/json"; + context = this.client.mergeContext(context); + return service + .listOutboundNetworkDependenciesEndpoints( + this.client.getEndpoint(), + this.client.getSubscriptionId(), + resourceGroupName, + workspaceName, + this.client.getApiVersion(), + accept, + context); + } + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body on successful completion of {@link Mono}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + private Mono listOutboundNetworkDependenciesEndpointsAsync( + String resourceGroupName, String workspaceName) { + return listOutboundNetworkDependenciesEndpointsWithResponseAsync(resourceGroupName, workspaceName) + .flatMap( + (Response res) -> { + if (res.getValue() != null) { + return Mono.just(res.getValue()); + } else { + return Mono.empty(); + } + }); + } + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public ExternalFqdnResponseInner listOutboundNetworkDependenciesEndpoints( + String resourceGroupName, String workspaceName) { + return listOutboundNetworkDependenciesEndpointsAsync(resourceGroupName, workspaceName).block(); + } + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public Response listOutboundNetworkDependenciesEndpointsWithResponse( + String resourceGroupName, String workspaceName, Context context) { + return listOutboundNetworkDependenciesEndpointsWithResponseAsync(resourceGroupName, workspaceName, context) + .block(); + } + /** * Get the next page of items. * @@ -1936,7 +3031,8 @@ public Response listNotebookAccessTokenWithRespo * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupNextSinglePageAsync(String nextLink) { @@ -1973,7 +3069,8 @@ private Mono> listByResourceGroupNextSinglePageAsy * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listByResourceGroupNextSinglePageAsync( @@ -2009,7 +3106,8 @@ private Mono> listByResourceGroupNextSinglePageAsy * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listBySubscriptionNextSinglePageAsync(String nextLink) { @@ -2046,7 +3144,8 @@ private Mono> listBySubscriptionNextSinglePageAsyn * @throws IllegalArgumentException thrown if parameters fail the validation. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces along with {@link PagedResponse} on + * successful completion of {@link Mono}. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listBySubscriptionNextSinglePageAsync( diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesImpl.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesImpl.java index 888ca436ae316..3db3c28f9ced3 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesImpl.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacesImpl.java @@ -10,17 +10,27 @@ import com.azure.core.util.Context; import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.WorkspacesClient; +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListNotebookKeysResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ListStorageAccountKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.ListWorkspaceKeysResultInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookAccessTokenResultInner; +import com.azure.resourcemanager.machinelearningservices.fluent.models.NotebookResourceInfoInner; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceInner; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResult; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; +import com.azure.resourcemanager.machinelearningservices.models.ExternalFqdnResponse; +import com.azure.resourcemanager.machinelearningservices.models.ListNotebookKeysResult; +import com.azure.resourcemanager.machinelearningservices.models.ListStorageAccountKeysResult; import com.azure.resourcemanager.machinelearningservices.models.ListWorkspaceKeysResult; import com.azure.resourcemanager.machinelearningservices.models.NotebookAccessTokenResult; +import com.azure.resourcemanager.machinelearningservices.models.NotebookResourceInfo; import com.azure.resourcemanager.machinelearningservices.models.Workspace; import com.azure.resourcemanager.machinelearningservices.models.Workspaces; -import com.fasterxml.jackson.annotation.JsonIgnore; public final class WorkspacesImpl implements Workspaces { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspacesImpl.class); + private static final ClientLogger LOGGER = new ClientLogger(WorkspacesImpl.class); private final WorkspacesClient innerClient; @@ -76,6 +86,36 @@ public PagedIterable listByResourceGroup(String resourceGroupName, St return Utils.mapPage(inner, inner1 -> new WorkspaceImpl(inner1, this.manager())); } + public DiagnoseResponseResult diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + DiagnoseResponseResultInner inner = this.serviceClient().diagnose(resourceGroupName, workspaceName, parameters); + if (inner != null) { + return new DiagnoseResponseResultImpl(inner, this.manager()); + } else { + return null; + } + } + + public DiagnoseResponseResult diagnose(String resourceGroupName, String workspaceName) { + DiagnoseResponseResultInner inner = this.serviceClient().diagnose(resourceGroupName, workspaceName); + if (inner != null) { + return new DiagnoseResponseResultImpl(inner, this.manager()); + } else { + return null; + } + } + + public DiagnoseResponseResult diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + DiagnoseResponseResultInner inner = + this.serviceClient().diagnose(resourceGroupName, workspaceName, parameters, context); + if (inner != null) { + return new DiagnoseResponseResultImpl(inner, this.manager()); + } else { + return null; + } + } + public ListWorkspaceKeysResult listKeys(String resourceGroupName, String workspaceName) { ListWorkspaceKeysResultInner inner = this.serviceClient().listKeys(resourceGroupName, workspaceName); if (inner != null) { @@ -143,10 +183,106 @@ public Response listNotebookAccessTokenWithResponse( } } + public NotebookResourceInfo prepareNotebook(String resourceGroupName, String workspaceName) { + NotebookResourceInfoInner inner = this.serviceClient().prepareNotebook(resourceGroupName, workspaceName); + if (inner != null) { + return new NotebookResourceInfoImpl(inner, this.manager()); + } else { + return null; + } + } + + public NotebookResourceInfo prepareNotebook(String resourceGroupName, String workspaceName, Context context) { + NotebookResourceInfoInner inner = + this.serviceClient().prepareNotebook(resourceGroupName, workspaceName, context); + if (inner != null) { + return new NotebookResourceInfoImpl(inner, this.manager()); + } else { + return null; + } + } + + public ListStorageAccountKeysResult listStorageAccountKeys(String resourceGroupName, String workspaceName) { + ListStorageAccountKeysResultInner inner = + this.serviceClient().listStorageAccountKeys(resourceGroupName, workspaceName); + if (inner != null) { + return new ListStorageAccountKeysResultImpl(inner, this.manager()); + } else { + return null; + } + } + + public Response listStorageAccountKeysWithResponse( + String resourceGroupName, String workspaceName, Context context) { + Response inner = + this.serviceClient().listStorageAccountKeysWithResponse(resourceGroupName, workspaceName, context); + if (inner != null) { + return new SimpleResponse<>( + inner.getRequest(), + inner.getStatusCode(), + inner.getHeaders(), + new ListStorageAccountKeysResultImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + + public ListNotebookKeysResult listNotebookKeys(String resourceGroupName, String workspaceName) { + ListNotebookKeysResultInner inner = this.serviceClient().listNotebookKeys(resourceGroupName, workspaceName); + if (inner != null) { + return new ListNotebookKeysResultImpl(inner, this.manager()); + } else { + return null; + } + } + + public Response listNotebookKeysWithResponse( + String resourceGroupName, String workspaceName, Context context) { + Response inner = + this.serviceClient().listNotebookKeysWithResponse(resourceGroupName, workspaceName, context); + if (inner != null) { + return new SimpleResponse<>( + inner.getRequest(), + inner.getStatusCode(), + inner.getHeaders(), + new ListNotebookKeysResultImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + + public ExternalFqdnResponse listOutboundNetworkDependenciesEndpoints( + String resourceGroupName, String workspaceName) { + ExternalFqdnResponseInner inner = + this.serviceClient().listOutboundNetworkDependenciesEndpoints(resourceGroupName, workspaceName); + if (inner != null) { + return new ExternalFqdnResponseImpl(inner, this.manager()); + } else { + return null; + } + } + + public Response listOutboundNetworkDependenciesEndpointsWithResponse( + String resourceGroupName, String workspaceName, Context context) { + Response inner = + this + .serviceClient() + .listOutboundNetworkDependenciesEndpointsWithResponse(resourceGroupName, workspaceName, context); + if (inner != null) { + return new SimpleResponse<>( + inner.getRequest(), + inner.getStatusCode(), + inner.getHeaders(), + new ExternalFqdnResponseImpl(inner.getValue(), this.manager())); + } else { + return null; + } + } + public Workspace getById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -154,7 +290,7 @@ public Workspace getById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); @@ -165,7 +301,7 @@ public Workspace getById(String id) { public Response getByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -173,7 +309,7 @@ public Response getByIdWithResponse(String id, Context context) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); @@ -184,7 +320,7 @@ public Response getByIdWithResponse(String id, Context context) { public void deleteById(String id) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -192,7 +328,7 @@ public void deleteById(String id) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); @@ -203,7 +339,7 @@ public void deleteById(String id) { public void deleteByIdWithResponse(String id, Context context) { String resourceGroupName = Utils.getValueFromIdByName(id, "resourceGroups"); if (resourceGroupName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String @@ -211,7 +347,7 @@ public void deleteByIdWithResponse(String id, Context context) { } String workspaceName = Utils.getValueFromIdByName(id, "workspaces"); if (workspaceName == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( String.format("The resource ID '%s' is not valid. Missing path segment 'workspaces'.", id))); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequest.java deleted file mode 100644 index 346384dd52511..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequest.java +++ /dev/null @@ -1,374 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** The AciServiceCreateRequest model. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") -@JsonTypeName("ACI") -@Fluent -public final class AciServiceCreateRequest extends CreateServiceRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceCreateRequest.class); - - /* - * The container resource requirements. - */ - @JsonProperty(value = "containerResourceRequirements") - private ContainerResourceRequirements containerResourceRequirements; - - /* - * Whether or not authentication is enabled on the service. - */ - @JsonProperty(value = "authEnabled") - private Boolean authEnabled; - - /* - * Whether or not SSL is enabled. - */ - @JsonProperty(value = "sslEnabled") - private Boolean sslEnabled; - - /* - * Whether or not Application Insights is enabled. - */ - @JsonProperty(value = "appInsightsEnabled") - private Boolean appInsightsEnabled; - - /* - * Details of the data collection options specified. - */ - @JsonProperty(value = "dataCollection") - private AciServiceCreateRequestDataCollection dataCollection; - - /* - * The public SSL certificate in PEM format to use if SSL is enabled. - */ - @JsonProperty(value = "sslCertificate") - private String sslCertificate; - - /* - * The public SSL key in PEM format for the certificate. - */ - @JsonProperty(value = "sslKey") - private String sslKey; - - /* - * The CName for the service. - */ - @JsonProperty(value = "cname") - private String cname; - - /* - * The Dns label for the service. - */ - @JsonProperty(value = "dnsNameLabel") - private String dnsNameLabel; - - /* - * The virtual network configuration. - */ - @JsonProperty(value = "vnetConfiguration") - private AciServiceCreateRequestVnetConfiguration vnetConfiguration; - - /* - * The encryption properties. - */ - @JsonProperty(value = "encryptionProperties") - private AciServiceCreateRequestEncryptionProperties encryptionProperties; - - /** - * Get the containerResourceRequirements property: The container resource requirements. - * - * @return the containerResourceRequirements value. - */ - public ContainerResourceRequirements containerResourceRequirements() { - return this.containerResourceRequirements; - } - - /** - * Set the containerResourceRequirements property: The container resource requirements. - * - * @param containerResourceRequirements the containerResourceRequirements value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withContainerResourceRequirements( - ContainerResourceRequirements containerResourceRequirements) { - this.containerResourceRequirements = containerResourceRequirements; - return this; - } - - /** - * Get the authEnabled property: Whether or not authentication is enabled on the service. - * - * @return the authEnabled value. - */ - public Boolean authEnabled() { - return this.authEnabled; - } - - /** - * Set the authEnabled property: Whether or not authentication is enabled on the service. - * - * @param authEnabled the authEnabled value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withAuthEnabled(Boolean authEnabled) { - this.authEnabled = authEnabled; - return this; - } - - /** - * Get the sslEnabled property: Whether or not SSL is enabled. - * - * @return the sslEnabled value. - */ - public Boolean sslEnabled() { - return this.sslEnabled; - } - - /** - * Set the sslEnabled property: Whether or not SSL is enabled. - * - * @param sslEnabled the sslEnabled value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withSslEnabled(Boolean sslEnabled) { - this.sslEnabled = sslEnabled; - return this; - } - - /** - * Get the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @return the appInsightsEnabled value. - */ - public Boolean appInsightsEnabled() { - return this.appInsightsEnabled; - } - - /** - * Set the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @param appInsightsEnabled the appInsightsEnabled value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withAppInsightsEnabled(Boolean appInsightsEnabled) { - this.appInsightsEnabled = appInsightsEnabled; - return this; - } - - /** - * Get the dataCollection property: Details of the data collection options specified. - * - * @return the dataCollection value. - */ - public AciServiceCreateRequestDataCollection dataCollection() { - return this.dataCollection; - } - - /** - * Set the dataCollection property: Details of the data collection options specified. - * - * @param dataCollection the dataCollection value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withDataCollection(AciServiceCreateRequestDataCollection dataCollection) { - this.dataCollection = dataCollection; - return this; - } - - /** - * Get the sslCertificate property: The public SSL certificate in PEM format to use if SSL is enabled. - * - * @return the sslCertificate value. - */ - public String sslCertificate() { - return this.sslCertificate; - } - - /** - * Set the sslCertificate property: The public SSL certificate in PEM format to use if SSL is enabled. - * - * @param sslCertificate the sslCertificate value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withSslCertificate(String sslCertificate) { - this.sslCertificate = sslCertificate; - return this; - } - - /** - * Get the sslKey property: The public SSL key in PEM format for the certificate. - * - * @return the sslKey value. - */ - public String sslKey() { - return this.sslKey; - } - - /** - * Set the sslKey property: The public SSL key in PEM format for the certificate. - * - * @param sslKey the sslKey value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withSslKey(String sslKey) { - this.sslKey = sslKey; - return this; - } - - /** - * Get the cname property: The CName for the service. - * - * @return the cname value. - */ - public String cname() { - return this.cname; - } - - /** - * Set the cname property: The CName for the service. - * - * @param cname the cname value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withCname(String cname) { - this.cname = cname; - return this; - } - - /** - * Get the dnsNameLabel property: The Dns label for the service. - * - * @return the dnsNameLabel value. - */ - public String dnsNameLabel() { - return this.dnsNameLabel; - } - - /** - * Set the dnsNameLabel property: The Dns label for the service. - * - * @param dnsNameLabel the dnsNameLabel value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withDnsNameLabel(String dnsNameLabel) { - this.dnsNameLabel = dnsNameLabel; - return this; - } - - /** - * Get the vnetConfiguration property: The virtual network configuration. - * - * @return the vnetConfiguration value. - */ - public AciServiceCreateRequestVnetConfiguration vnetConfiguration() { - return this.vnetConfiguration; - } - - /** - * Set the vnetConfiguration property: The virtual network configuration. - * - * @param vnetConfiguration the vnetConfiguration value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withVnetConfiguration(AciServiceCreateRequestVnetConfiguration vnetConfiguration) { - this.vnetConfiguration = vnetConfiguration; - return this; - } - - /** - * Get the encryptionProperties property: The encryption properties. - * - * @return the encryptionProperties value. - */ - public AciServiceCreateRequestEncryptionProperties encryptionProperties() { - return this.encryptionProperties; - } - - /** - * Set the encryptionProperties property: The encryption properties. - * - * @param encryptionProperties the encryptionProperties value to set. - * @return the AciServiceCreateRequest object itself. - */ - public AciServiceCreateRequest withEncryptionProperties( - AciServiceCreateRequestEncryptionProperties encryptionProperties) { - this.encryptionProperties = encryptionProperties; - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withKeys(CreateServiceRequestKeys keys) { - super.withKeys(keys); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withEnvironmentImageRequest( - CreateServiceRequestEnvironmentImageRequest environmentImageRequest) { - super.withEnvironmentImageRequest(environmentImageRequest); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequest withLocation(String location) { - super.withLocation(location); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - if (containerResourceRequirements() != null) { - containerResourceRequirements().validate(); - } - if (dataCollection() != null) { - dataCollection().validate(); - } - if (vnetConfiguration() != null) { - vnetConfiguration().validate(); - } - if (encryptionProperties() != null) { - encryptionProperties().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestDataCollection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestDataCollection.java deleted file mode 100644 index b4258545d009a..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestDataCollection.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Details of the data collection options specified. */ -@Immutable -public final class AciServiceCreateRequestDataCollection extends ModelDataCollection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceCreateRequestDataCollection.class); - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestDataCollection withEventHubEnabled(Boolean eventHubEnabled) { - super.withEventHubEnabled(eventHubEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestDataCollection withStorageEnabled(Boolean storageEnabled) { - super.withStorageEnabled(storageEnabled); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestEncryptionProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestEncryptionProperties.java deleted file mode 100644 index 5b64ba2318e67..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestEncryptionProperties.java +++ /dev/null @@ -1,46 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The encryption properties. */ -@Immutable -public final class AciServiceCreateRequestEncryptionProperties extends EncryptionProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceCreateRequestEncryptionProperties.class); - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestEncryptionProperties withVaultBaseUrl(String vaultBaseUrl) { - super.withVaultBaseUrl(vaultBaseUrl); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestEncryptionProperties withKeyName(String keyName) { - super.withKeyName(keyName); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestEncryptionProperties withKeyVersion(String keyVersion) { - super.withKeyVersion(keyVersion); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestVnetConfiguration.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestVnetConfiguration.java deleted file mode 100644 index 90bc635061464..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestVnetConfiguration.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The virtual network configuration. */ -@Immutable -public final class AciServiceCreateRequestVnetConfiguration extends VnetConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceCreateRequestVnetConfiguration.class); - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestVnetConfiguration withVnetName(String vnetName) { - super.withVnetName(vnetName); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceCreateRequestVnetConfiguration withSubnetName(String subnetName) { - super.withSubnetName(subnetName); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponse.java deleted file mode 100644 index 547fad2ec7666..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponse.java +++ /dev/null @@ -1,515 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.List; -import java.util.Map; - -/** The response for an ACI service. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") -@JsonTypeName("ACI") -@Fluent -public final class AciServiceResponse extends ServiceResponseBase { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceResponse.class); - - /* - * The container resource requirements. - */ - @JsonProperty(value = "containerResourceRequirements") - private ContainerResourceRequirements containerResourceRequirements; - - /* - * The Uri for sending scoring requests. - */ - @JsonProperty(value = "scoringUri", access = JsonProperty.Access.WRITE_ONLY) - private String scoringUri; - - /* - * The name of the Azure location/region. - */ - @JsonProperty(value = "location") - private String location; - - /* - * Whether or not authentication is enabled on the service. - */ - @JsonProperty(value = "authEnabled") - private Boolean authEnabled; - - /* - * Whether or not SSL is enabled. - */ - @JsonProperty(value = "sslEnabled") - private Boolean sslEnabled; - - /* - * Whether or not Application Insights is enabled. - */ - @JsonProperty(value = "appInsightsEnabled") - private Boolean appInsightsEnabled; - - /* - * Details of the data collection options specified. - */ - @JsonProperty(value = "dataCollection") - private AciServiceResponseDataCollection dataCollection; - - /* - * The public SSL certificate in PEM format to use if SSL is enabled. - */ - @JsonProperty(value = "sslCertificate") - private String sslCertificate; - - /* - * The public SSL key in PEM format for the certificate. - */ - @JsonProperty(value = "sslKey") - private String sslKey; - - /* - * The CName for the service. - */ - @JsonProperty(value = "cname") - private String cname; - - /* - * The public IP address for the service. - */ - @JsonProperty(value = "publicIp") - private String publicIp; - - /* - * The public Fqdn for the service. - */ - @JsonProperty(value = "publicFqdn") - private String publicFqdn; - - /* - * The Uri for sending swagger requests. - */ - @JsonProperty(value = "swaggerUri", access = JsonProperty.Access.WRITE_ONLY) - private String swaggerUri; - - /* - * Details on the models and configurations. - */ - @JsonProperty(value = "modelConfigMap", access = JsonProperty.Access.WRITE_ONLY) - private Map modelConfigMap; - - /* - * The list of models. - */ - @JsonProperty(value = "models") - private List models; - - /* - * The Environment, models and assets used for inferencing. - */ - @JsonProperty(value = "environmentImageRequest") - private AciServiceResponseEnvironmentImageRequest environmentImageRequest; - - /* - * The virtual network configuration. - */ - @JsonProperty(value = "vnetConfiguration") - private AciServiceResponseVnetConfiguration vnetConfiguration; - - /* - * The encryption properties. - */ - @JsonProperty(value = "encryptionProperties") - private AciServiceResponseEncryptionProperties encryptionProperties; - - /** - * Get the containerResourceRequirements property: The container resource requirements. - * - * @return the containerResourceRequirements value. - */ - public ContainerResourceRequirements containerResourceRequirements() { - return this.containerResourceRequirements; - } - - /** - * Set the containerResourceRequirements property: The container resource requirements. - * - * @param containerResourceRequirements the containerResourceRequirements value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withContainerResourceRequirements( - ContainerResourceRequirements containerResourceRequirements) { - this.containerResourceRequirements = containerResourceRequirements; - return this; - } - - /** - * Get the scoringUri property: The Uri for sending scoring requests. - * - * @return the scoringUri value. - */ - public String scoringUri() { - return this.scoringUri; - } - - /** - * Get the location property: The name of the Azure location/region. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The name of the Azure location/region. - * - * @param location the location value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withLocation(String location) { - this.location = location; - return this; - } - - /** - * Get the authEnabled property: Whether or not authentication is enabled on the service. - * - * @return the authEnabled value. - */ - public Boolean authEnabled() { - return this.authEnabled; - } - - /** - * Set the authEnabled property: Whether or not authentication is enabled on the service. - * - * @param authEnabled the authEnabled value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withAuthEnabled(Boolean authEnabled) { - this.authEnabled = authEnabled; - return this; - } - - /** - * Get the sslEnabled property: Whether or not SSL is enabled. - * - * @return the sslEnabled value. - */ - public Boolean sslEnabled() { - return this.sslEnabled; - } - - /** - * Set the sslEnabled property: Whether or not SSL is enabled. - * - * @param sslEnabled the sslEnabled value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withSslEnabled(Boolean sslEnabled) { - this.sslEnabled = sslEnabled; - return this; - } - - /** - * Get the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @return the appInsightsEnabled value. - */ - public Boolean appInsightsEnabled() { - return this.appInsightsEnabled; - } - - /** - * Set the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @param appInsightsEnabled the appInsightsEnabled value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withAppInsightsEnabled(Boolean appInsightsEnabled) { - this.appInsightsEnabled = appInsightsEnabled; - return this; - } - - /** - * Get the dataCollection property: Details of the data collection options specified. - * - * @return the dataCollection value. - */ - public AciServiceResponseDataCollection dataCollection() { - return this.dataCollection; - } - - /** - * Set the dataCollection property: Details of the data collection options specified. - * - * @param dataCollection the dataCollection value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withDataCollection(AciServiceResponseDataCollection dataCollection) { - this.dataCollection = dataCollection; - return this; - } - - /** - * Get the sslCertificate property: The public SSL certificate in PEM format to use if SSL is enabled. - * - * @return the sslCertificate value. - */ - public String sslCertificate() { - return this.sslCertificate; - } - - /** - * Set the sslCertificate property: The public SSL certificate in PEM format to use if SSL is enabled. - * - * @param sslCertificate the sslCertificate value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withSslCertificate(String sslCertificate) { - this.sslCertificate = sslCertificate; - return this; - } - - /** - * Get the sslKey property: The public SSL key in PEM format for the certificate. - * - * @return the sslKey value. - */ - public String sslKey() { - return this.sslKey; - } - - /** - * Set the sslKey property: The public SSL key in PEM format for the certificate. - * - * @param sslKey the sslKey value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withSslKey(String sslKey) { - this.sslKey = sslKey; - return this; - } - - /** - * Get the cname property: The CName for the service. - * - * @return the cname value. - */ - public String cname() { - return this.cname; - } - - /** - * Set the cname property: The CName for the service. - * - * @param cname the cname value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withCname(String cname) { - this.cname = cname; - return this; - } - - /** - * Get the publicIp property: The public IP address for the service. - * - * @return the publicIp value. - */ - public String publicIp() { - return this.publicIp; - } - - /** - * Set the publicIp property: The public IP address for the service. - * - * @param publicIp the publicIp value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withPublicIp(String publicIp) { - this.publicIp = publicIp; - return this; - } - - /** - * Get the publicFqdn property: The public Fqdn for the service. - * - * @return the publicFqdn value. - */ - public String publicFqdn() { - return this.publicFqdn; - } - - /** - * Set the publicFqdn property: The public Fqdn for the service. - * - * @param publicFqdn the publicFqdn value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withPublicFqdn(String publicFqdn) { - this.publicFqdn = publicFqdn; - return this; - } - - /** - * Get the swaggerUri property: The Uri for sending swagger requests. - * - * @return the swaggerUri value. - */ - public String swaggerUri() { - return this.swaggerUri; - } - - /** - * Get the modelConfigMap property: Details on the models and configurations. - * - * @return the modelConfigMap value. - */ - public Map modelConfigMap() { - return this.modelConfigMap; - } - - /** - * Get the models property: The list of models. - * - * @return the models value. - */ - public List models() { - return this.models; - } - - /** - * Set the models property: The list of models. - * - * @param models the models value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withModels(List models) { - this.models = models; - return this; - } - - /** - * Get the environmentImageRequest property: The Environment, models and assets used for inferencing. - * - * @return the environmentImageRequest value. - */ - public AciServiceResponseEnvironmentImageRequest environmentImageRequest() { - return this.environmentImageRequest; - } - - /** - * Set the environmentImageRequest property: The Environment, models and assets used for inferencing. - * - * @param environmentImageRequest the environmentImageRequest value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withEnvironmentImageRequest( - AciServiceResponseEnvironmentImageRequest environmentImageRequest) { - this.environmentImageRequest = environmentImageRequest; - return this; - } - - /** - * Get the vnetConfiguration property: The virtual network configuration. - * - * @return the vnetConfiguration value. - */ - public AciServiceResponseVnetConfiguration vnetConfiguration() { - return this.vnetConfiguration; - } - - /** - * Set the vnetConfiguration property: The virtual network configuration. - * - * @param vnetConfiguration the vnetConfiguration value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withVnetConfiguration(AciServiceResponseVnetConfiguration vnetConfiguration) { - this.vnetConfiguration = vnetConfiguration; - return this; - } - - /** - * Get the encryptionProperties property: The encryption properties. - * - * @return the encryptionProperties value. - */ - public AciServiceResponseEncryptionProperties encryptionProperties() { - return this.encryptionProperties; - } - - /** - * Set the encryptionProperties property: The encryption properties. - * - * @param encryptionProperties the encryptionProperties value to set. - * @return the AciServiceResponse object itself. - */ - public AciServiceResponse withEncryptionProperties(AciServiceResponseEncryptionProperties encryptionProperties) { - this.encryptionProperties = encryptionProperties; - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponse withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponse withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponse withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponse withDeploymentType(DeploymentType deploymentType) { - super.withDeploymentType(deploymentType); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - if (containerResourceRequirements() != null) { - containerResourceRequirements().validate(); - } - if (dataCollection() != null) { - dataCollection().validate(); - } - if (models() != null) { - models().forEach(e -> e.validate()); - } - if (environmentImageRequest() != null) { - environmentImageRequest().validate(); - } - if (vnetConfiguration() != null) { - vnetConfiguration().validate(); - } - if (encryptionProperties() != null) { - encryptionProperties().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseDataCollection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseDataCollection.java deleted file mode 100644 index 0db27a8f5d4ad..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseDataCollection.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Details of the data collection options specified. */ -@Immutable -public final class AciServiceResponseDataCollection extends ModelDataCollection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceResponseDataCollection.class); - - /** {@inheritDoc} */ - @Override - public AciServiceResponseDataCollection withEventHubEnabled(Boolean eventHubEnabled) { - super.withEventHubEnabled(eventHubEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseDataCollection withStorageEnabled(Boolean storageEnabled) { - super.withStorageEnabled(storageEnabled); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEncryptionProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEncryptionProperties.java deleted file mode 100644 index 3acb1e15c472b..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEncryptionProperties.java +++ /dev/null @@ -1,46 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The encryption properties. */ -@Immutable -public final class AciServiceResponseEncryptionProperties extends EncryptionProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceResponseEncryptionProperties.class); - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEncryptionProperties withVaultBaseUrl(String vaultBaseUrl) { - super.withVaultBaseUrl(vaultBaseUrl); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEncryptionProperties withKeyName(String keyName) { - super.withKeyName(keyName); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEncryptionProperties withKeyVersion(String keyVersion) { - super.withKeyVersion(keyVersion); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEnvironmentImageRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEnvironmentImageRequest.java deleted file mode 100644 index ba94417057a59..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEnvironmentImageRequest.java +++ /dev/null @@ -1,69 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** The Environment, models and assets used for inferencing. */ -@Immutable -public final class AciServiceResponseEnvironmentImageRequest extends EnvironmentImageResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceResponseEnvironmentImageRequest.class); - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withDriverProgram(String driverProgram) { - super.withDriverProgram(driverProgram); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withAssets(List assets) { - super.withAssets(assets); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withModelIds(List modelIds) { - super.withModelIds(modelIds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withModels(List models) { - super.withModels(models); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withEnvironment(EnvironmentImageResponseEnvironment environment) { - super.withEnvironment(environment); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseEnvironmentImageRequest withEnvironmentReference( - EnvironmentImageResponseEnvironmentReference environmentReference) { - super.withEnvironmentReference(environmentReference); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseVnetConfiguration.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseVnetConfiguration.java deleted file mode 100644 index a4079908b4b62..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseVnetConfiguration.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The virtual network configuration. */ -@Immutable -public final class AciServiceResponseVnetConfiguration extends VnetConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AciServiceResponseVnetConfiguration.class); - - /** {@inheritDoc} */ - @Override - public AciServiceResponseVnetConfiguration withVnetName(String vnetName) { - super.withVnetName(vnetName); - return this; - } - - /** {@inheritDoc} */ - @Override - public AciServiceResponseVnetConfiguration withSubnetName(String subnetName) { - super.withSubnetName(subnetName); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Aks.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Aks.java index 827ecd5192a8a..2b75d885fa705 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Aks.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Aks.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,8 +14,6 @@ @JsonTypeName("AKS") @Fluent public final class Aks extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Aks.class); - /* * AKS properties */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecrets.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecrets.java index 327b173b2d1cb..220c967046360 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecrets.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecrets.java @@ -5,9 +5,7 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeSecretsInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -17,8 +15,6 @@ @JsonTypeName("AKS") @Fluent public final class AksComputeSecrets extends ComputeSecretsInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksComputeSecrets.class); - /* * Content of kubeconfig file that can be used to connect to the Kubernetes * cluster. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java new file mode 100644 index 0000000000000..5f6defbed74cf --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java @@ -0,0 +1,104 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of AksComputeSecrets. */ +@Fluent +public class AksComputeSecretsProperties { + /* + * Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + */ + @JsonProperty(value = "userKubeConfig") + private String userKubeConfig; + + /* + * Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + */ + @JsonProperty(value = "adminKubeConfig") + private String adminKubeConfig; + + /* + * Image registry pull secret. + */ + @JsonProperty(value = "imagePullSecretName") + private String imagePullSecretName; + + /** + * Get the userKubeConfig property: Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + * + * @return the userKubeConfig value. + */ + public String userKubeConfig() { + return this.userKubeConfig; + } + + /** + * Set the userKubeConfig property: Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + * + * @param userKubeConfig the userKubeConfig value to set. + * @return the AksComputeSecretsProperties object itself. + */ + public AksComputeSecretsProperties withUserKubeConfig(String userKubeConfig) { + this.userKubeConfig = userKubeConfig; + return this; + } + + /** + * Get the adminKubeConfig property: Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + * + * @return the adminKubeConfig value. + */ + public String adminKubeConfig() { + return this.adminKubeConfig; + } + + /** + * Set the adminKubeConfig property: Content of kubeconfig file that can be used to connect to the Kubernetes + * cluster. + * + * @param adminKubeConfig the adminKubeConfig value to set. + * @return the AksComputeSecretsProperties object itself. + */ + public AksComputeSecretsProperties withAdminKubeConfig(String adminKubeConfig) { + this.adminKubeConfig = adminKubeConfig; + return this; + } + + /** + * Get the imagePullSecretName property: Image registry pull secret. + * + * @return the imagePullSecretName value. + */ + public String imagePullSecretName() { + return this.imagePullSecretName; + } + + /** + * Set the imagePullSecretName property: Image registry pull secret. + * + * @param imagePullSecretName the imagePullSecretName value to set. + * @return the AksComputeSecretsProperties object itself. + */ + public AksComputeSecretsProperties withImagePullSecretName(String imagePullSecretName) { + this.imagePullSecretName = imagePullSecretName; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksNetworkingConfiguration.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksNetworkingConfiguration.java index ab8af5fcbe071..0ef8d146f752d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksNetworkingConfiguration.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksNetworkingConfiguration.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Advance configuration for AKS networking. */ @Fluent public final class AksNetworkingConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksNetworkingConfiguration.class); - /* * Virtual network subnet resource ID the compute nodes belong to */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksProperties.java index 164cc3cd619a6..ad0ddcba86d7c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksProperties.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.List; /** AKS properties. */ @Fluent public final class AksProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksProperties.class); - /* * Cluster full qualified domain name */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatus.java deleted file mode 100644 index 8d343511365d5..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatus.java +++ /dev/null @@ -1,131 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The AksReplicaStatus model. */ -@Fluent -public class AksReplicaStatus { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksReplicaStatus.class); - - /* - * The desired number of replicas. - */ - @JsonProperty(value = "desiredReplicas") - private Integer desiredReplicas; - - /* - * The number of updated replicas. - */ - @JsonProperty(value = "updatedReplicas") - private Integer updatedReplicas; - - /* - * The number of available replicas. - */ - @JsonProperty(value = "availableReplicas") - private Integer availableReplicas; - - /* - * The error details. - */ - @JsonProperty(value = "error") - private AksReplicaStatusError error; - - /** - * Get the desiredReplicas property: The desired number of replicas. - * - * @return the desiredReplicas value. - */ - public Integer desiredReplicas() { - return this.desiredReplicas; - } - - /** - * Set the desiredReplicas property: The desired number of replicas. - * - * @param desiredReplicas the desiredReplicas value to set. - * @return the AksReplicaStatus object itself. - */ - public AksReplicaStatus withDesiredReplicas(Integer desiredReplicas) { - this.desiredReplicas = desiredReplicas; - return this; - } - - /** - * Get the updatedReplicas property: The number of updated replicas. - * - * @return the updatedReplicas value. - */ - public Integer updatedReplicas() { - return this.updatedReplicas; - } - - /** - * Set the updatedReplicas property: The number of updated replicas. - * - * @param updatedReplicas the updatedReplicas value to set. - * @return the AksReplicaStatus object itself. - */ - public AksReplicaStatus withUpdatedReplicas(Integer updatedReplicas) { - this.updatedReplicas = updatedReplicas; - return this; - } - - /** - * Get the availableReplicas property: The number of available replicas. - * - * @return the availableReplicas value. - */ - public Integer availableReplicas() { - return this.availableReplicas; - } - - /** - * Set the availableReplicas property: The number of available replicas. - * - * @param availableReplicas the availableReplicas value to set. - * @return the AksReplicaStatus object itself. - */ - public AksReplicaStatus withAvailableReplicas(Integer availableReplicas) { - this.availableReplicas = availableReplicas; - return this; - } - - /** - * Get the error property: The error details. - * - * @return the error value. - */ - public AksReplicaStatusError error() { - return this.error; - } - - /** - * Set the error property: The error details. - * - * @param error the error value to set. - * @return the AksReplicaStatus object itself. - */ - public AksReplicaStatus withError(AksReplicaStatusError error) { - this.error = error; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (error() != null) { - error().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatusError.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatusError.java deleted file mode 100644 index 00ca59abbc68d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatusError.java +++ /dev/null @@ -1,24 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.management.exception.ManagementError; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The error details. */ -@Immutable -public final class AksReplicaStatusError extends ManagementError { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksReplicaStatusError.class); - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequest.java deleted file mode 100644 index d5f3f4739e8d6..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequest.java +++ /dev/null @@ -1,450 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** The request to create an AKS service. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") -@JsonTypeName("AKS") -@Fluent -public final class AksServiceCreateRequest extends CreateEndpointVariantRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceCreateRequest.class); - - /* - * The number of replicas on the cluster. - */ - @JsonProperty(value = "numReplicas") - private Integer numReplicas; - - /* - * Details of the data collection options specified. - */ - @JsonProperty(value = "dataCollection") - private AksServiceCreateRequestDataCollection dataCollection; - - /* - * The name of the compute resource. - */ - @JsonProperty(value = "computeName") - private String computeName; - - /* - * Whether or not Application Insights is enabled. - */ - @JsonProperty(value = "appInsightsEnabled") - private Boolean appInsightsEnabled; - - /* - * The auto scaler properties. - */ - @JsonProperty(value = "autoScaler") - private AksServiceCreateRequestAutoScaler autoScaler; - - /* - * The container resource requirements. - */ - @JsonProperty(value = "containerResourceRequirements") - private ContainerResourceRequirements containerResourceRequirements; - - /* - * The maximum number of concurrent requests per container. - */ - @JsonProperty(value = "maxConcurrentRequestsPerContainer") - private Integer maxConcurrentRequestsPerContainer; - - /* - * Maximum time a request will wait in the queue (in milliseconds). After - * this time, the service will return 503 (Service Unavailable) - */ - @JsonProperty(value = "maxQueueWaitMs") - private Integer maxQueueWaitMs; - - /* - * Kubernetes namespace for the service. - */ - @JsonProperty(value = "namespace") - private String namespace; - - /* - * The scoring timeout in milliseconds. - */ - @JsonProperty(value = "scoringTimeoutMs") - private Integer scoringTimeoutMs; - - /* - * Whether or not authentication is enabled. - */ - @JsonProperty(value = "authEnabled") - private Boolean authEnabled; - - /* - * The liveness probe requirements. - */ - @JsonProperty(value = "livenessProbeRequirements") - private AksServiceCreateRequestLivenessProbeRequirements livenessProbeRequirements; - - /* - * Whether or not AAD authentication is enabled. - */ - @JsonProperty(value = "aadAuthEnabled") - private Boolean aadAuthEnabled; - - /** - * Get the numReplicas property: The number of replicas on the cluster. - * - * @return the numReplicas value. - */ - public Integer numReplicas() { - return this.numReplicas; - } - - /** - * Set the numReplicas property: The number of replicas on the cluster. - * - * @param numReplicas the numReplicas value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withNumReplicas(Integer numReplicas) { - this.numReplicas = numReplicas; - return this; - } - - /** - * Get the dataCollection property: Details of the data collection options specified. - * - * @return the dataCollection value. - */ - public AksServiceCreateRequestDataCollection dataCollection() { - return this.dataCollection; - } - - /** - * Set the dataCollection property: Details of the data collection options specified. - * - * @param dataCollection the dataCollection value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withDataCollection(AksServiceCreateRequestDataCollection dataCollection) { - this.dataCollection = dataCollection; - return this; - } - - /** - * Get the computeName property: The name of the compute resource. - * - * @return the computeName value. - */ - public String computeName() { - return this.computeName; - } - - /** - * Set the computeName property: The name of the compute resource. - * - * @param computeName the computeName value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withComputeName(String computeName) { - this.computeName = computeName; - return this; - } - - /** - * Get the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @return the appInsightsEnabled value. - */ - public Boolean appInsightsEnabled() { - return this.appInsightsEnabled; - } - - /** - * Set the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @param appInsightsEnabled the appInsightsEnabled value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withAppInsightsEnabled(Boolean appInsightsEnabled) { - this.appInsightsEnabled = appInsightsEnabled; - return this; - } - - /** - * Get the autoScaler property: The auto scaler properties. - * - * @return the autoScaler value. - */ - public AksServiceCreateRequestAutoScaler autoScaler() { - return this.autoScaler; - } - - /** - * Set the autoScaler property: The auto scaler properties. - * - * @param autoScaler the autoScaler value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withAutoScaler(AksServiceCreateRequestAutoScaler autoScaler) { - this.autoScaler = autoScaler; - return this; - } - - /** - * Get the containerResourceRequirements property: The container resource requirements. - * - * @return the containerResourceRequirements value. - */ - public ContainerResourceRequirements containerResourceRequirements() { - return this.containerResourceRequirements; - } - - /** - * Set the containerResourceRequirements property: The container resource requirements. - * - * @param containerResourceRequirements the containerResourceRequirements value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withContainerResourceRequirements( - ContainerResourceRequirements containerResourceRequirements) { - this.containerResourceRequirements = containerResourceRequirements; - return this; - } - - /** - * Get the maxConcurrentRequestsPerContainer property: The maximum number of concurrent requests per container. - * - * @return the maxConcurrentRequestsPerContainer value. - */ - public Integer maxConcurrentRequestsPerContainer() { - return this.maxConcurrentRequestsPerContainer; - } - - /** - * Set the maxConcurrentRequestsPerContainer property: The maximum number of concurrent requests per container. - * - * @param maxConcurrentRequestsPerContainer the maxConcurrentRequestsPerContainer value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withMaxConcurrentRequestsPerContainer(Integer maxConcurrentRequestsPerContainer) { - this.maxConcurrentRequestsPerContainer = maxConcurrentRequestsPerContainer; - return this; - } - - /** - * Get the maxQueueWaitMs property: Maximum time a request will wait in the queue (in milliseconds). After this - * time, the service will return 503 (Service Unavailable). - * - * @return the maxQueueWaitMs value. - */ - public Integer maxQueueWaitMs() { - return this.maxQueueWaitMs; - } - - /** - * Set the maxQueueWaitMs property: Maximum time a request will wait in the queue (in milliseconds). After this - * time, the service will return 503 (Service Unavailable). - * - * @param maxQueueWaitMs the maxQueueWaitMs value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withMaxQueueWaitMs(Integer maxQueueWaitMs) { - this.maxQueueWaitMs = maxQueueWaitMs; - return this; - } - - /** - * Get the namespace property: Kubernetes namespace for the service. - * - * @return the namespace value. - */ - public String namespace() { - return this.namespace; - } - - /** - * Set the namespace property: Kubernetes namespace for the service. - * - * @param namespace the namespace value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withNamespace(String namespace) { - this.namespace = namespace; - return this; - } - - /** - * Get the scoringTimeoutMs property: The scoring timeout in milliseconds. - * - * @return the scoringTimeoutMs value. - */ - public Integer scoringTimeoutMs() { - return this.scoringTimeoutMs; - } - - /** - * Set the scoringTimeoutMs property: The scoring timeout in milliseconds. - * - * @param scoringTimeoutMs the scoringTimeoutMs value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withScoringTimeoutMs(Integer scoringTimeoutMs) { - this.scoringTimeoutMs = scoringTimeoutMs; - return this; - } - - /** - * Get the authEnabled property: Whether or not authentication is enabled. - * - * @return the authEnabled value. - */ - public Boolean authEnabled() { - return this.authEnabled; - } - - /** - * Set the authEnabled property: Whether or not authentication is enabled. - * - * @param authEnabled the authEnabled value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withAuthEnabled(Boolean authEnabled) { - this.authEnabled = authEnabled; - return this; - } - - /** - * Get the livenessProbeRequirements property: The liveness probe requirements. - * - * @return the livenessProbeRequirements value. - */ - public AksServiceCreateRequestLivenessProbeRequirements livenessProbeRequirements() { - return this.livenessProbeRequirements; - } - - /** - * Set the livenessProbeRequirements property: The liveness probe requirements. - * - * @param livenessProbeRequirements the livenessProbeRequirements value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withLivenessProbeRequirements( - AksServiceCreateRequestLivenessProbeRequirements livenessProbeRequirements) { - this.livenessProbeRequirements = livenessProbeRequirements; - return this; - } - - /** - * Get the aadAuthEnabled property: Whether or not AAD authentication is enabled. - * - * @return the aadAuthEnabled value. - */ - public Boolean aadAuthEnabled() { - return this.aadAuthEnabled; - } - - /** - * Set the aadAuthEnabled property: Whether or not AAD authentication is enabled. - * - * @param aadAuthEnabled the aadAuthEnabled value to set. - * @return the AksServiceCreateRequest object itself. - */ - public AksServiceCreateRequest withAadAuthEnabled(Boolean aadAuthEnabled) { - this.aadAuthEnabled = aadAuthEnabled; - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withIsDefault(Boolean isDefault) { - super.withIsDefault(isDefault); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withTrafficPercentile(Float trafficPercentile) { - super.withTrafficPercentile(trafficPercentile); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withType(VariantType type) { - super.withType(type); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withKeys(CreateServiceRequestKeys keys) { - super.withKeys(keys); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withEnvironmentImageRequest( - CreateServiceRequestEnvironmentImageRequest environmentImageRequest) { - super.withEnvironmentImageRequest(environmentImageRequest); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequest withLocation(String location) { - super.withLocation(location); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - if (dataCollection() != null) { - dataCollection().validate(); - } - if (autoScaler() != null) { - autoScaler().validate(); - } - if (containerResourceRequirements() != null) { - containerResourceRequirements().validate(); - } - if (livenessProbeRequirements() != null) { - livenessProbeRequirements().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestAutoScaler.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestAutoScaler.java deleted file mode 100644 index 64e0244a1e88c..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestAutoScaler.java +++ /dev/null @@ -1,60 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The auto scaler properties. */ -@Immutable -public final class AksServiceCreateRequestAutoScaler extends AutoScaler { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceCreateRequestAutoScaler.class); - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestAutoScaler withAutoscaleEnabled(Boolean autoscaleEnabled) { - super.withAutoscaleEnabled(autoscaleEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestAutoScaler withMinReplicas(Integer minReplicas) { - super.withMinReplicas(minReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestAutoScaler withMaxReplicas(Integer maxReplicas) { - super.withMaxReplicas(maxReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestAutoScaler withTargetUtilization(Integer targetUtilization) { - super.withTargetUtilization(targetUtilization); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestAutoScaler withRefreshPeriodInSeconds(Integer refreshPeriodInSeconds) { - super.withRefreshPeriodInSeconds(refreshPeriodInSeconds); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestDataCollection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestDataCollection.java deleted file mode 100644 index d5100711a66f3..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestDataCollection.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Details of the data collection options specified. */ -@Immutable -public final class AksServiceCreateRequestDataCollection extends ModelDataCollection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceCreateRequestDataCollection.class); - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestDataCollection withEventHubEnabled(Boolean eventHubEnabled) { - super.withEventHubEnabled(eventHubEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestDataCollection withStorageEnabled(Boolean storageEnabled) { - super.withStorageEnabled(storageEnabled); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestLivenessProbeRequirements.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestLivenessProbeRequirements.java deleted file mode 100644 index ef3774c5c72fb..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestLivenessProbeRequirements.java +++ /dev/null @@ -1,61 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The liveness probe requirements. */ -@Immutable -public final class AksServiceCreateRequestLivenessProbeRequirements extends LivenessProbeRequirements { - @JsonIgnore - private final ClientLogger logger = new ClientLogger(AksServiceCreateRequestLivenessProbeRequirements.class); - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestLivenessProbeRequirements withFailureThreshold(Integer failureThreshold) { - super.withFailureThreshold(failureThreshold); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestLivenessProbeRequirements withSuccessThreshold(Integer successThreshold) { - super.withSuccessThreshold(successThreshold); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestLivenessProbeRequirements withTimeoutSeconds(Integer timeoutSeconds) { - super.withTimeoutSeconds(timeoutSeconds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestLivenessProbeRequirements withPeriodSeconds(Integer periodSeconds) { - super.withPeriodSeconds(periodSeconds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceCreateRequestLivenessProbeRequirements withInitialDelaySeconds(Integer initialDelaySeconds) { - super.withInitialDelaySeconds(initialDelaySeconds); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponse.java deleted file mode 100644 index 6c10e448a0dc4..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponse.java +++ /dev/null @@ -1,558 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.List; -import java.util.Map; - -/** The response for an AKS service. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") -@JsonTypeName("AKS") -@Fluent -public final class AksServiceResponse extends AksVariantResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponse.class); - - /* - * The list of models. - */ - @JsonProperty(value = "models") - private List models; - - /* - * The container resource requirements. - */ - @JsonProperty(value = "containerResourceRequirements") - private ContainerResourceRequirements containerResourceRequirements; - - /* - * The maximum number of concurrent requests per container. - */ - @JsonProperty(value = "maxConcurrentRequestsPerContainer") - private Integer maxConcurrentRequestsPerContainer; - - /* - * Maximum time a request will wait in the queue (in milliseconds). After - * this time, the service will return 503 (Service Unavailable) - */ - @JsonProperty(value = "maxQueueWaitMs") - private Integer maxQueueWaitMs; - - /* - * The name of the compute resource. - */ - @JsonProperty(value = "computeName") - private String computeName; - - /* - * The Kubernetes namespace of the deployment. - */ - @JsonProperty(value = "namespace") - private String namespace; - - /* - * The number of replicas on the cluster. - */ - @JsonProperty(value = "numReplicas") - private Integer numReplicas; - - /* - * Details of the data collection options specified. - */ - @JsonProperty(value = "dataCollection") - private AksServiceResponseDataCollection dataCollection; - - /* - * Whether or not Application Insights is enabled. - */ - @JsonProperty(value = "appInsightsEnabled") - private Boolean appInsightsEnabled; - - /* - * The auto scaler properties. - */ - @JsonProperty(value = "autoScaler") - private AksServiceResponseAutoScaler autoScaler; - - /* - * The Uri for sending scoring requests. - */ - @JsonProperty(value = "scoringUri", access = JsonProperty.Access.WRITE_ONLY) - private String scoringUri; - - /* - * The deployment status. - */ - @JsonProperty(value = "deploymentStatus", access = JsonProperty.Access.WRITE_ONLY) - private AksServiceResponseDeploymentStatus deploymentStatus; - - /* - * The scoring timeout in milliseconds. - */ - @JsonProperty(value = "scoringTimeoutMs") - private Integer scoringTimeoutMs; - - /* - * The liveness probe requirements. - */ - @JsonProperty(value = "livenessProbeRequirements") - private AksServiceResponseLivenessProbeRequirements livenessProbeRequirements; - - /* - * Whether or not authentication is enabled. - */ - @JsonProperty(value = "authEnabled") - private Boolean authEnabled; - - /* - * Whether or not AAD authentication is enabled. - */ - @JsonProperty(value = "aadAuthEnabled") - private Boolean aadAuthEnabled; - - /* - * The Uri for sending swagger requests. - */ - @JsonProperty(value = "swaggerUri", access = JsonProperty.Access.WRITE_ONLY) - private String swaggerUri; - - /* - * Details on the models and configurations. - */ - @JsonProperty(value = "modelConfigMap", access = JsonProperty.Access.WRITE_ONLY) - private Map modelConfigMap; - - /* - * The Environment, models and assets used for inferencing. - */ - @JsonProperty(value = "environmentImageRequest") - private AksServiceResponseEnvironmentImageRequest environmentImageRequest; - - /** - * Get the models property: The list of models. - * - * @return the models value. - */ - public List models() { - return this.models; - } - - /** - * Set the models property: The list of models. - * - * @param models the models value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withModels(List models) { - this.models = models; - return this; - } - - /** - * Get the containerResourceRequirements property: The container resource requirements. - * - * @return the containerResourceRequirements value. - */ - public ContainerResourceRequirements containerResourceRequirements() { - return this.containerResourceRequirements; - } - - /** - * Set the containerResourceRequirements property: The container resource requirements. - * - * @param containerResourceRequirements the containerResourceRequirements value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withContainerResourceRequirements( - ContainerResourceRequirements containerResourceRequirements) { - this.containerResourceRequirements = containerResourceRequirements; - return this; - } - - /** - * Get the maxConcurrentRequestsPerContainer property: The maximum number of concurrent requests per container. - * - * @return the maxConcurrentRequestsPerContainer value. - */ - public Integer maxConcurrentRequestsPerContainer() { - return this.maxConcurrentRequestsPerContainer; - } - - /** - * Set the maxConcurrentRequestsPerContainer property: The maximum number of concurrent requests per container. - * - * @param maxConcurrentRequestsPerContainer the maxConcurrentRequestsPerContainer value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withMaxConcurrentRequestsPerContainer(Integer maxConcurrentRequestsPerContainer) { - this.maxConcurrentRequestsPerContainer = maxConcurrentRequestsPerContainer; - return this; - } - - /** - * Get the maxQueueWaitMs property: Maximum time a request will wait in the queue (in milliseconds). After this - * time, the service will return 503 (Service Unavailable). - * - * @return the maxQueueWaitMs value. - */ - public Integer maxQueueWaitMs() { - return this.maxQueueWaitMs; - } - - /** - * Set the maxQueueWaitMs property: Maximum time a request will wait in the queue (in milliseconds). After this - * time, the service will return 503 (Service Unavailable). - * - * @param maxQueueWaitMs the maxQueueWaitMs value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withMaxQueueWaitMs(Integer maxQueueWaitMs) { - this.maxQueueWaitMs = maxQueueWaitMs; - return this; - } - - /** - * Get the computeName property: The name of the compute resource. - * - * @return the computeName value. - */ - public String computeName() { - return this.computeName; - } - - /** - * Set the computeName property: The name of the compute resource. - * - * @param computeName the computeName value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withComputeName(String computeName) { - this.computeName = computeName; - return this; - } - - /** - * Get the namespace property: The Kubernetes namespace of the deployment. - * - * @return the namespace value. - */ - public String namespace() { - return this.namespace; - } - - /** - * Set the namespace property: The Kubernetes namespace of the deployment. - * - * @param namespace the namespace value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withNamespace(String namespace) { - this.namespace = namespace; - return this; - } - - /** - * Get the numReplicas property: The number of replicas on the cluster. - * - * @return the numReplicas value. - */ - public Integer numReplicas() { - return this.numReplicas; - } - - /** - * Set the numReplicas property: The number of replicas on the cluster. - * - * @param numReplicas the numReplicas value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withNumReplicas(Integer numReplicas) { - this.numReplicas = numReplicas; - return this; - } - - /** - * Get the dataCollection property: Details of the data collection options specified. - * - * @return the dataCollection value. - */ - public AksServiceResponseDataCollection dataCollection() { - return this.dataCollection; - } - - /** - * Set the dataCollection property: Details of the data collection options specified. - * - * @param dataCollection the dataCollection value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withDataCollection(AksServiceResponseDataCollection dataCollection) { - this.dataCollection = dataCollection; - return this; - } - - /** - * Get the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @return the appInsightsEnabled value. - */ - public Boolean appInsightsEnabled() { - return this.appInsightsEnabled; - } - - /** - * Set the appInsightsEnabled property: Whether or not Application Insights is enabled. - * - * @param appInsightsEnabled the appInsightsEnabled value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withAppInsightsEnabled(Boolean appInsightsEnabled) { - this.appInsightsEnabled = appInsightsEnabled; - return this; - } - - /** - * Get the autoScaler property: The auto scaler properties. - * - * @return the autoScaler value. - */ - public AksServiceResponseAutoScaler autoScaler() { - return this.autoScaler; - } - - /** - * Set the autoScaler property: The auto scaler properties. - * - * @param autoScaler the autoScaler value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withAutoScaler(AksServiceResponseAutoScaler autoScaler) { - this.autoScaler = autoScaler; - return this; - } - - /** - * Get the scoringUri property: The Uri for sending scoring requests. - * - * @return the scoringUri value. - */ - public String scoringUri() { - return this.scoringUri; - } - - /** - * Get the deploymentStatus property: The deployment status. - * - * @return the deploymentStatus value. - */ - public AksServiceResponseDeploymentStatus deploymentStatus() { - return this.deploymentStatus; - } - - /** - * Get the scoringTimeoutMs property: The scoring timeout in milliseconds. - * - * @return the scoringTimeoutMs value. - */ - public Integer scoringTimeoutMs() { - return this.scoringTimeoutMs; - } - - /** - * Set the scoringTimeoutMs property: The scoring timeout in milliseconds. - * - * @param scoringTimeoutMs the scoringTimeoutMs value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withScoringTimeoutMs(Integer scoringTimeoutMs) { - this.scoringTimeoutMs = scoringTimeoutMs; - return this; - } - - /** - * Get the livenessProbeRequirements property: The liveness probe requirements. - * - * @return the livenessProbeRequirements value. - */ - public AksServiceResponseLivenessProbeRequirements livenessProbeRequirements() { - return this.livenessProbeRequirements; - } - - /** - * Set the livenessProbeRequirements property: The liveness probe requirements. - * - * @param livenessProbeRequirements the livenessProbeRequirements value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withLivenessProbeRequirements( - AksServiceResponseLivenessProbeRequirements livenessProbeRequirements) { - this.livenessProbeRequirements = livenessProbeRequirements; - return this; - } - - /** - * Get the authEnabled property: Whether or not authentication is enabled. - * - * @return the authEnabled value. - */ - public Boolean authEnabled() { - return this.authEnabled; - } - - /** - * Set the authEnabled property: Whether or not authentication is enabled. - * - * @param authEnabled the authEnabled value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withAuthEnabled(Boolean authEnabled) { - this.authEnabled = authEnabled; - return this; - } - - /** - * Get the aadAuthEnabled property: Whether or not AAD authentication is enabled. - * - * @return the aadAuthEnabled value. - */ - public Boolean aadAuthEnabled() { - return this.aadAuthEnabled; - } - - /** - * Set the aadAuthEnabled property: Whether or not AAD authentication is enabled. - * - * @param aadAuthEnabled the aadAuthEnabled value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withAadAuthEnabled(Boolean aadAuthEnabled) { - this.aadAuthEnabled = aadAuthEnabled; - return this; - } - - /** - * Get the swaggerUri property: The Uri for sending swagger requests. - * - * @return the swaggerUri value. - */ - public String swaggerUri() { - return this.swaggerUri; - } - - /** - * Get the modelConfigMap property: Details on the models and configurations. - * - * @return the modelConfigMap value. - */ - public Map modelConfigMap() { - return this.modelConfigMap; - } - - /** - * Get the environmentImageRequest property: The Environment, models and assets used for inferencing. - * - * @return the environmentImageRequest value. - */ - public AksServiceResponseEnvironmentImageRequest environmentImageRequest() { - return this.environmentImageRequest; - } - - /** - * Set the environmentImageRequest property: The Environment, models and assets used for inferencing. - * - * @param environmentImageRequest the environmentImageRequest value to set. - * @return the AksServiceResponse object itself. - */ - public AksServiceResponse withEnvironmentImageRequest( - AksServiceResponseEnvironmentImageRequest environmentImageRequest) { - this.environmentImageRequest = environmentImageRequest; - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withIsDefault(Boolean isDefault) { - super.withIsDefault(isDefault); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withTrafficPercentile(Float trafficPercentile) { - super.withTrafficPercentile(trafficPercentile); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withType(VariantType type) { - super.withType(type); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponse withDeploymentType(DeploymentType deploymentType) { - super.withDeploymentType(deploymentType); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - if (models() != null) { - models().forEach(e -> e.validate()); - } - if (containerResourceRequirements() != null) { - containerResourceRequirements().validate(); - } - if (dataCollection() != null) { - dataCollection().validate(); - } - if (autoScaler() != null) { - autoScaler().validate(); - } - if (deploymentStatus() != null) { - deploymentStatus().validate(); - } - if (livenessProbeRequirements() != null) { - livenessProbeRequirements().validate(); - } - if (environmentImageRequest() != null) { - environmentImageRequest().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseAutoScaler.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseAutoScaler.java deleted file mode 100644 index e9fe00f42a2c6..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseAutoScaler.java +++ /dev/null @@ -1,60 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The auto scaler properties. */ -@Immutable -public final class AksServiceResponseAutoScaler extends AutoScaler { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponseAutoScaler.class); - - /** {@inheritDoc} */ - @Override - public AksServiceResponseAutoScaler withAutoscaleEnabled(Boolean autoscaleEnabled) { - super.withAutoscaleEnabled(autoscaleEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseAutoScaler withMinReplicas(Integer minReplicas) { - super.withMinReplicas(minReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseAutoScaler withMaxReplicas(Integer maxReplicas) { - super.withMaxReplicas(maxReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseAutoScaler withTargetUtilization(Integer targetUtilization) { - super.withTargetUtilization(targetUtilization); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseAutoScaler withRefreshPeriodInSeconds(Integer refreshPeriodInSeconds) { - super.withRefreshPeriodInSeconds(refreshPeriodInSeconds); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDataCollection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDataCollection.java deleted file mode 100644 index 0c361fd407758..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDataCollection.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Details of the data collection options specified. */ -@Immutable -public final class AksServiceResponseDataCollection extends ModelDataCollection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponseDataCollection.class); - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDataCollection withEventHubEnabled(Boolean eventHubEnabled) { - super.withEventHubEnabled(eventHubEnabled); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDataCollection withStorageEnabled(Boolean storageEnabled) { - super.withStorageEnabled(storageEnabled); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDeploymentStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDeploymentStatus.java deleted file mode 100644 index 937053855d9c3..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDeploymentStatus.java +++ /dev/null @@ -1,53 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The deployment status. */ -@Immutable -public final class AksServiceResponseDeploymentStatus extends AksReplicaStatus { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponseDeploymentStatus.class); - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDeploymentStatus withDesiredReplicas(Integer desiredReplicas) { - super.withDesiredReplicas(desiredReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDeploymentStatus withUpdatedReplicas(Integer updatedReplicas) { - super.withUpdatedReplicas(updatedReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDeploymentStatus withAvailableReplicas(Integer availableReplicas) { - super.withAvailableReplicas(availableReplicas); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseDeploymentStatus withError(AksReplicaStatusError error) { - super.withError(error); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseEnvironmentImageRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseEnvironmentImageRequest.java deleted file mode 100644 index b13ae06551b8c..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseEnvironmentImageRequest.java +++ /dev/null @@ -1,69 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** The Environment, models and assets used for inferencing. */ -@Immutable -public final class AksServiceResponseEnvironmentImageRequest extends EnvironmentImageResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponseEnvironmentImageRequest.class); - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withDriverProgram(String driverProgram) { - super.withDriverProgram(driverProgram); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withAssets(List assets) { - super.withAssets(assets); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withModelIds(List modelIds) { - super.withModelIds(modelIds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withModels(List models) { - super.withModels(models); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withEnvironment(EnvironmentImageResponseEnvironment environment) { - super.withEnvironment(environment); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseEnvironmentImageRequest withEnvironmentReference( - EnvironmentImageResponseEnvironmentReference environmentReference) { - super.withEnvironmentReference(environmentReference); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseLivenessProbeRequirements.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseLivenessProbeRequirements.java deleted file mode 100644 index de32b17bcdd92..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseLivenessProbeRequirements.java +++ /dev/null @@ -1,60 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The liveness probe requirements. */ -@Immutable -public final class AksServiceResponseLivenessProbeRequirements extends LivenessProbeRequirements { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksServiceResponseLivenessProbeRequirements.class); - - /** {@inheritDoc} */ - @Override - public AksServiceResponseLivenessProbeRequirements withFailureThreshold(Integer failureThreshold) { - super.withFailureThreshold(failureThreshold); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseLivenessProbeRequirements withSuccessThreshold(Integer successThreshold) { - super.withSuccessThreshold(successThreshold); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseLivenessProbeRequirements withTimeoutSeconds(Integer timeoutSeconds) { - super.withTimeoutSeconds(timeoutSeconds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseLivenessProbeRequirements withPeriodSeconds(Integer periodSeconds) { - super.withPeriodSeconds(periodSeconds); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksServiceResponseLivenessProbeRequirements withInitialDelaySeconds(Integer initialDelaySeconds) { - super.withInitialDelaySeconds(initialDelaySeconds); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksVariantResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksVariantResponse.java deleted file mode 100644 index 077bc667c6dab..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksVariantResponse.java +++ /dev/null @@ -1,143 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** The response for an AKS variant. */ -@JsonTypeInfo( - use = JsonTypeInfo.Id.NAME, - include = JsonTypeInfo.As.PROPERTY, - property = "computeType", - defaultImpl = AksVariantResponse.class) -@JsonTypeName("Custom") -@JsonSubTypes({@JsonSubTypes.Type(name = "AKS", value = AksServiceResponse.class)}) -@Fluent -public class AksVariantResponse extends ServiceResponseBase { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AksVariantResponse.class); - - /* - * Is this the default variant. - */ - @JsonProperty(value = "isDefault") - private Boolean isDefault; - - /* - * The amount of traffic variant receives. - */ - @JsonProperty(value = "trafficPercentile") - private Float trafficPercentile; - - /* - * The type of the variant. - */ - @JsonProperty(value = "type") - private VariantType type; - - /** - * Get the isDefault property: Is this the default variant. - * - * @return the isDefault value. - */ - public Boolean isDefault() { - return this.isDefault; - } - - /** - * Set the isDefault property: Is this the default variant. - * - * @param isDefault the isDefault value to set. - * @return the AksVariantResponse object itself. - */ - public AksVariantResponse withIsDefault(Boolean isDefault) { - this.isDefault = isDefault; - return this; - } - - /** - * Get the trafficPercentile property: The amount of traffic variant receives. - * - * @return the trafficPercentile value. - */ - public Float trafficPercentile() { - return this.trafficPercentile; - } - - /** - * Set the trafficPercentile property: The amount of traffic variant receives. - * - * @param trafficPercentile the trafficPercentile value to set. - * @return the AksVariantResponse object itself. - */ - public AksVariantResponse withTrafficPercentile(Float trafficPercentile) { - this.trafficPercentile = trafficPercentile; - return this; - } - - /** - * Get the type property: The type of the variant. - * - * @return the type value. - */ - public VariantType type() { - return this.type; - } - - /** - * Set the type property: The type of the variant. - * - * @param type the type value to set. - * @return the AksVariantResponse object itself. - */ - public AksVariantResponse withType(VariantType type) { - this.type = type; - return this; - } - - /** {@inheritDoc} */ - @Override - public AksVariantResponse withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksVariantResponse withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksVariantResponse withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public AksVariantResponse withDeploymentType(DeploymentType deploymentType) { - super.withDeploymentType(deploymentType); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AllocationState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AllocationState.java index fc9e6b8590fa5..1045bfd09669d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AllocationState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AllocationState.java @@ -27,7 +27,11 @@ public static AllocationState fromString(String name) { return fromString(name, AllocationState.class); } - /** @return known AllocationState values. */ + /** + * Gets known AllocationState values. + * + * @return known AllocationState values. + */ public static Collection values() { return values(AllocationState.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlCompute.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlCompute.java index 131e844f80818..e6d5e2781004a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlCompute.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlCompute.java @@ -5,27 +5,23 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; -/** An Azure Machine Learning compute. */ +/** Properties(top level) of AmlCompute. */ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") @JsonTypeName("AmlCompute") @Fluent public final class AmlCompute extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlCompute.class); - /* - * AML Compute properties + * Properties of AmlCompute */ @JsonProperty(value = "properties") private AmlComputeProperties properties; /** - * Get the properties property: AML Compute properties. + * Get the properties property: Properties of AmlCompute. * * @return the properties value. */ @@ -34,7 +30,7 @@ public AmlComputeProperties properties() { } /** - * Set the properties property: AML Compute properties. + * Set the properties property: Properties of AmlCompute. * * @param properties the properties value to set. * @return the AmlCompute object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodeInformation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodeInformation.java index eeca40fdbe0c5..df7e07a0a8405 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodeInformation.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodeInformation.java @@ -5,35 +5,31 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Compute node information related to a AmlCompute. */ @Immutable public final class AmlComputeNodeInformation { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlComputeNodeInformation.class); - /* - * ID of the compute node. + * Node ID. ID of the compute node. */ @JsonProperty(value = "nodeId", access = JsonProperty.Access.WRITE_ONLY) private String nodeId; /* - * Private IP address of the compute node. + * Private IP address. Private IP address of the compute node. */ @JsonProperty(value = "privateIpAddress", access = JsonProperty.Access.WRITE_ONLY) private String privateIpAddress; /* - * Public IP address of the compute node. + * Public IP address. Public IP address of the compute node. */ @JsonProperty(value = "publicIpAddress", access = JsonProperty.Access.WRITE_ONLY) private String publicIpAddress; /* - * SSH port number of the node. + * Port. SSH port number of the node. */ @JsonProperty(value = "port", access = JsonProperty.Access.WRITE_ONLY) private Integer port; @@ -46,13 +42,13 @@ public final class AmlComputeNodeInformation { private NodeState nodeState; /* - * ID of the Experiment running on the node, if any else null. + * Run ID. ID of the Experiment running on the node, if any else null. */ @JsonProperty(value = "runId", access = JsonProperty.Access.WRITE_ONLY) private String runId; /** - * Get the nodeId property: ID of the compute node. + * Get the nodeId property: Node ID. ID of the compute node. * * @return the nodeId value. */ @@ -61,7 +57,7 @@ public String nodeId() { } /** - * Get the privateIpAddress property: Private IP address of the compute node. + * Get the privateIpAddress property: Private IP address. Private IP address of the compute node. * * @return the privateIpAddress value. */ @@ -70,7 +66,7 @@ public String privateIpAddress() { } /** - * Get the publicIpAddress property: Public IP address of the compute node. + * Get the publicIpAddress property: Public IP address. Public IP address of the compute node. * * @return the publicIpAddress value. */ @@ -79,7 +75,7 @@ public String publicIpAddress() { } /** - * Get the port property: SSH port number of the node. + * Get the port property: Port. SSH port number of the node. * * @return the port value. */ @@ -98,7 +94,7 @@ public NodeState nodeState() { } /** - * Get the runId property: ID of the Experiment running on the node, if any else null. + * Get the runId property: Run ID. ID of the Experiment running on the node, if any else null. * * @return the runId value. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodesInformation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodesInformation.java index 7486bc203c020..3192e82551b80 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodesInformation.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeNodesInformation.java @@ -5,26 +5,24 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; import java.util.List; -/** Compute node information related to a AmlCompute. */ -@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") -@JsonTypeName("AmlCompute") +/** Result of AmlCompute Nodes. */ @Immutable -public final class AmlComputeNodesInformation extends ComputeNodesInformation { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlComputeNodesInformation.class); - +public final class AmlComputeNodesInformation { /* * The collection of returned AmlCompute nodes details. */ @JsonProperty(value = "nodes", access = JsonProperty.Access.WRITE_ONLY) private List nodes; + /* + * The continuation token. + */ + @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY) + private String nextLink; + /** * Get the nodes property: The collection of returned AmlCompute nodes details. * @@ -34,14 +32,21 @@ public List nodes() { return this.nodes; } + /** + * Get the nextLink property: The continuation token. + * + * @return the nextLink value. + */ + public String nextLink() { + return this.nextLink; + } + /** * Validates the instance. * * @throws IllegalArgumentException thrown if the instance is not valid. */ - @Override public void validate() { - super.validate(); if (nodes() != null) { nodes().forEach(e -> e.validate()); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeProperties.java index 20b05a7e6725a..3c922cf9bf987 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlComputeProperties.java @@ -6,8 +6,6 @@ import com.azure.core.annotation.Fluent; import com.azure.core.management.exception.ManagementError; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.time.OffsetDateTime; import java.util.List; @@ -15,8 +13,6 @@ /** AML Compute properties. */ @Fluent public final class AmlComputeProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlComputeProperties.class); - /* * Compute OS Type */ @@ -67,54 +63,57 @@ public final class AmlComputeProperties { private ResourceId subnet; /* - * State of the public SSH port. Possible values are: Disabled - Indicates - * that the public ssh port is closed on all nodes of the cluster. Enabled - * - Indicates that the public ssh port is open on all nodes of the - * cluster. NotSpecified - Indicates that the public ssh port is closed on - * all nodes of the cluster if VNet is defined, else is open all public - * nodes. It can be default only during cluster creation time, after - * creation it will be either enabled or disabled. + * Close remote Login Access Port State of the public SSH port. Possible + * values are: Disabled - Indicates that the public ssh port is closed on + * all nodes of the cluster. Enabled - Indicates that the public ssh port + * is open on all nodes of the cluster. NotSpecified - Indicates that the + * public ssh port is closed on all nodes of the cluster if VNet is + * defined, else is open all public nodes. It can be default only during + * cluster creation time, after creation it will be either enabled or + * disabled. */ @JsonProperty(value = "remoteLoginPortPublicAccess") private RemoteLoginPortPublicAccess remoteLoginPortPublicAccess; /* - * Allocation state of the compute. Possible values are: steady - Indicates - * that the compute is not resizing. There are no changes to the number of - * compute nodes in the compute in progress. A compute enters this state - * when it is created and when no operations are being performed on the - * compute to change the number of compute nodes. resizing - Indicates that - * the compute is resizing; that is, compute nodes are being added to or - * removed from the compute. + * Allocation state. Allocation state of the compute. Possible values are: + * steady - Indicates that the compute is not resizing. There are no + * changes to the number of compute nodes in the compute in progress. A + * compute enters this state when it is created and when no operations are + * being performed on the compute to change the number of compute nodes. + * resizing - Indicates that the compute is resizing; that is, compute + * nodes are being added to or removed from the compute. */ @JsonProperty(value = "allocationState", access = JsonProperty.Access.WRITE_ONLY) private AllocationState allocationState; /* - * The time at which the compute entered its current allocation state. + * Allocation state transition time. The time at which the compute entered + * its current allocation state. */ @JsonProperty(value = "allocationStateTransitionTime", access = JsonProperty.Access.WRITE_ONLY) private OffsetDateTime allocationStateTransitionTime; /* - * Collection of errors encountered by various compute nodes during node - * setup. + * Errors. Collection of errors encountered by various compute nodes during + * node setup. */ @JsonProperty(value = "errors", access = JsonProperty.Access.WRITE_ONLY) private List errors; /* - * The number of compute nodes currently assigned to the compute. + * Current node count. The number of compute nodes currently assigned to + * the compute. */ @JsonProperty(value = "currentNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer currentNodeCount; /* - * The target number of compute nodes for the compute. If the - * allocationState is resizing, this property denotes the target node count - * for the ongoing resize operation. If the allocationState is steady, this - * property denotes the target node count for the previous resize - * operation. + * Target node count. The target number of compute nodes for the compute. + * If the allocationState is resizing, this property denotes the target + * node count for the ongoing resize operation. If the allocationState is + * steady, this property denotes the target node count for the previous + * resize operation. */ @JsonProperty(value = "targetNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer targetNodeCount; @@ -126,10 +125,11 @@ public final class AmlComputeProperties { private NodeStateCounts nodeStateCounts; /* - * Enable or disable node public IP address provisioning. Possible values - * are: Possible values are: true - Indicates that the compute nodes will - * have public IPs provisioned. false - Indicates that the compute nodes - * will have a private endpoint and no public IPs. + * Enable node public IP. Enable or disable node public IP address + * provisioning. Possible values are: Possible values are: true - Indicates + * that the compute nodes will have public IPs provisioned. false - + * Indicates that the compute nodes will have a private endpoint and no + * public IPs. */ @JsonProperty(value = "enableNodePublicIp") private Boolean enableNodePublicIp; @@ -297,11 +297,11 @@ public AmlComputeProperties withSubnet(ResourceId subnet) { } /** - * Get the remoteLoginPortPublicAccess property: State of the public SSH port. Possible values are: Disabled - - * Indicates that the public ssh port is closed on all nodes of the cluster. Enabled - Indicates that the public ssh - * port is open on all nodes of the cluster. NotSpecified - Indicates that the public ssh port is closed on all - * nodes of the cluster if VNet is defined, else is open all public nodes. It can be default only during cluster - * creation time, after creation it will be either enabled or disabled. + * Get the remoteLoginPortPublicAccess property: Close remote Login Access Port State of the public SSH port. + * Possible values are: Disabled - Indicates that the public ssh port is closed on all nodes of the cluster. Enabled + * - Indicates that the public ssh port is open on all nodes of the cluster. NotSpecified - Indicates that the + * public ssh port is closed on all nodes of the cluster if VNet is defined, else is open all public nodes. It can + * be default only during cluster creation time, after creation it will be either enabled or disabled. * * @return the remoteLoginPortPublicAccess value. */ @@ -310,11 +310,11 @@ public RemoteLoginPortPublicAccess remoteLoginPortPublicAccess() { } /** - * Set the remoteLoginPortPublicAccess property: State of the public SSH port. Possible values are: Disabled - - * Indicates that the public ssh port is closed on all nodes of the cluster. Enabled - Indicates that the public ssh - * port is open on all nodes of the cluster. NotSpecified - Indicates that the public ssh port is closed on all - * nodes of the cluster if VNet is defined, else is open all public nodes. It can be default only during cluster - * creation time, after creation it will be either enabled or disabled. + * Set the remoteLoginPortPublicAccess property: Close remote Login Access Port State of the public SSH port. + * Possible values are: Disabled - Indicates that the public ssh port is closed on all nodes of the cluster. Enabled + * - Indicates that the public ssh port is open on all nodes of the cluster. NotSpecified - Indicates that the + * public ssh port is closed on all nodes of the cluster if VNet is defined, else is open all public nodes. It can + * be default only during cluster creation time, after creation it will be either enabled or disabled. * * @param remoteLoginPortPublicAccess the remoteLoginPortPublicAccess value to set. * @return the AmlComputeProperties object itself. @@ -326,11 +326,11 @@ public AmlComputeProperties withRemoteLoginPortPublicAccess( } /** - * Get the allocationState property: Allocation state of the compute. Possible values are: steady - Indicates that - * the compute is not resizing. There are no changes to the number of compute nodes in the compute in progress. A - * compute enters this state when it is created and when no operations are being performed on the compute to change - * the number of compute nodes. resizing - Indicates that the compute is resizing; that is, compute nodes are being - * added to or removed from the compute. + * Get the allocationState property: Allocation state. Allocation state of the compute. Possible values are: steady + * - Indicates that the compute is not resizing. There are no changes to the number of compute nodes in the compute + * in progress. A compute enters this state when it is created and when no operations are being performed on the + * compute to change the number of compute nodes. resizing - Indicates that the compute is resizing; that is, + * compute nodes are being added to or removed from the compute. * * @return the allocationState value. */ @@ -339,8 +339,8 @@ public AllocationState allocationState() { } /** - * Get the allocationStateTransitionTime property: The time at which the compute entered its current allocation - * state. + * Get the allocationStateTransitionTime property: Allocation state transition time. The time at which the compute + * entered its current allocation state. * * @return the allocationStateTransitionTime value. */ @@ -349,7 +349,7 @@ public OffsetDateTime allocationStateTransitionTime() { } /** - * Get the errors property: Collection of errors encountered by various compute nodes during node setup. + * Get the errors property: Errors. Collection of errors encountered by various compute nodes during node setup. * * @return the errors value. */ @@ -358,7 +358,8 @@ public List errors() { } /** - * Get the currentNodeCount property: The number of compute nodes currently assigned to the compute. + * Get the currentNodeCount property: Current node count. The number of compute nodes currently assigned to the + * compute. * * @return the currentNodeCount value. */ @@ -367,9 +368,9 @@ public Integer currentNodeCount() { } /** - * Get the targetNodeCount property: The target number of compute nodes for the compute. If the allocationState is - * resizing, this property denotes the target node count for the ongoing resize operation. If the allocationState is - * steady, this property denotes the target node count for the previous resize operation. + * Get the targetNodeCount property: Target node count. The target number of compute nodes for the compute. If the + * allocationState is resizing, this property denotes the target node count for the ongoing resize operation. If the + * allocationState is steady, this property denotes the target node count for the previous resize operation. * * @return the targetNodeCount value. */ @@ -387,9 +388,9 @@ public NodeStateCounts nodeStateCounts() { } /** - * Get the enableNodePublicIp property: Enable or disable node public IP address provisioning. Possible values are: - * Possible values are: true - Indicates that the compute nodes will have public IPs provisioned. false - Indicates - * that the compute nodes will have a private endpoint and no public IPs. + * Get the enableNodePublicIp property: Enable node public IP. Enable or disable node public IP address + * provisioning. Possible values are: Possible values are: true - Indicates that the compute nodes will have public + * IPs provisioned. false - Indicates that the compute nodes will have a private endpoint and no public IPs. * * @return the enableNodePublicIp value. */ @@ -398,9 +399,9 @@ public Boolean enableNodePublicIp() { } /** - * Set the enableNodePublicIp property: Enable or disable node public IP address provisioning. Possible values are: - * Possible values are: true - Indicates that the compute nodes will have public IPs provisioned. false - Indicates - * that the compute nodes will have a private endpoint and no public IPs. + * Set the enableNodePublicIp property: Enable node public IP. Enable or disable node public IP address + * provisioning. Possible values are: Possible values are: true - Indicates that the compute nodes will have public + * IPs provisioned. false - Indicates that the compute nodes will have a private endpoint and no public IPs. * * @param enableNodePublicIp the enableNodePublicIp value to set. * @return the AmlComputeProperties object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ApplicationSharingPolicy.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ApplicationSharingPolicy.java index b3c92449a120b..5b9a39707ea2b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ApplicationSharingPolicy.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ApplicationSharingPolicy.java @@ -27,7 +27,11 @@ public static ApplicationSharingPolicy fromString(String name) { return fromString(name, ApplicationSharingPolicy.class); } - /** @return known ApplicationSharingPolicy values. */ + /** + * Gets known ApplicationSharingPolicy values. + * + * @return known ApplicationSharingPolicy values. + */ public static Collection values() { return values(ApplicationSharingPolicy.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AssignedUser.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AssignedUser.java index 9e3bbaba58ba3..9c95d82fb4e3b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AssignedUser.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AssignedUser.java @@ -6,14 +6,11 @@ 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; /** A user that can be assigned to a compute instance. */ @Fluent public final class AssignedUser { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AssignedUser.class); - /* * User’s AAD Object Id. */ @@ -73,14 +70,16 @@ public AssignedUser withTenantId(String tenantId) { */ public void validate() { if (objectId() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property objectId in model AssignedUser")); } if (tenantId() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property tenantId in model AssignedUser")); } } + + private static final ClientLogger LOGGER = new ClientLogger(AssignedUser.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AuthKeys.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AuthKeys.java deleted file mode 100644 index 1182be63cd593..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AuthKeys.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The AuthKeys model. */ -@Fluent -public class AuthKeys { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AuthKeys.class); - - /* - * The primary key. - */ - @JsonProperty(value = "primaryKey") - private String primaryKey; - - /* - * The secondary key. - */ - @JsonProperty(value = "secondaryKey") - private String secondaryKey; - - /** - * Get the primaryKey property: The primary key. - * - * @return the primaryKey value. - */ - public String primaryKey() { - return this.primaryKey; - } - - /** - * Set the primaryKey property: The primary key. - * - * @param primaryKey the primaryKey value to set. - * @return the AuthKeys object itself. - */ - public AuthKeys withPrimaryKey(String primaryKey) { - this.primaryKey = primaryKey; - return this; - } - - /** - * Get the secondaryKey property: The secondary key. - * - * @return the secondaryKey value. - */ - public String secondaryKey() { - return this.secondaryKey; - } - - /** - * Set the secondaryKey property: The secondary key. - * - * @param secondaryKey the secondaryKey value to set. - * @return the AuthKeys object itself. - */ - public AuthKeys withSecondaryKey(String secondaryKey) { - this.secondaryKey = secondaryKey; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoPauseProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoPauseProperties.java index b47fe8d92a41f..dd5e93903a791 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoPauseProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoPauseProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Auto pause properties. */ @Fluent public final class AutoPauseProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AutoPauseProperties.class); - /* * The delayInMinutes property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaleProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaleProperties.java index d18e45822e754..c34d194e85ca7 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaleProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaleProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Auto scale properties. */ @Fluent public final class AutoScaleProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AutoScaleProperties.class); - /* * The minNodeCount property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaler.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaler.java deleted file mode 100644 index 1176762cb3323..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaler.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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The Auto Scaler properties. */ -@Fluent -public class AutoScaler { - @JsonIgnore private final ClientLogger logger = new ClientLogger(AutoScaler.class); - - /* - * Option to enable/disable auto scaling. - */ - @JsonProperty(value = "autoscaleEnabled") - private Boolean autoscaleEnabled; - - /* - * The minimum number of replicas to scale down to. - */ - @JsonProperty(value = "minReplicas") - private Integer minReplicas; - - /* - * The maximum number of replicas in the cluster. - */ - @JsonProperty(value = "maxReplicas") - private Integer maxReplicas; - - /* - * The target utilization percentage to use for determining whether to - * scale the cluster. - */ - @JsonProperty(value = "targetUtilization") - private Integer targetUtilization; - - /* - * The amount of seconds to wait between auto scale updates. - */ - @JsonProperty(value = "refreshPeriodInSeconds") - private Integer refreshPeriodInSeconds; - - /** - * Get the autoscaleEnabled property: Option to enable/disable auto scaling. - * - * @return the autoscaleEnabled value. - */ - public Boolean autoscaleEnabled() { - return this.autoscaleEnabled; - } - - /** - * Set the autoscaleEnabled property: Option to enable/disable auto scaling. - * - * @param autoscaleEnabled the autoscaleEnabled value to set. - * @return the AutoScaler object itself. - */ - public AutoScaler withAutoscaleEnabled(Boolean autoscaleEnabled) { - this.autoscaleEnabled = autoscaleEnabled; - return this; - } - - /** - * Get the minReplicas property: The minimum number of replicas to scale down to. - * - * @return the minReplicas value. - */ - public Integer minReplicas() { - return this.minReplicas; - } - - /** - * Set the minReplicas property: The minimum number of replicas to scale down to. - * - * @param minReplicas the minReplicas value to set. - * @return the AutoScaler object itself. - */ - public AutoScaler withMinReplicas(Integer minReplicas) { - this.minReplicas = minReplicas; - return this; - } - - /** - * Get the maxReplicas property: The maximum number of replicas in the cluster. - * - * @return the maxReplicas value. - */ - public Integer maxReplicas() { - return this.maxReplicas; - } - - /** - * Set the maxReplicas property: The maximum number of replicas in the cluster. - * - * @param maxReplicas the maxReplicas value to set. - * @return the AutoScaler object itself. - */ - public AutoScaler withMaxReplicas(Integer maxReplicas) { - this.maxReplicas = maxReplicas; - return this; - } - - /** - * Get the targetUtilization property: The target utilization percentage to use for determining whether to scale the - * cluster. - * - * @return the targetUtilization value. - */ - public Integer targetUtilization() { - return this.targetUtilization; - } - - /** - * Set the targetUtilization property: The target utilization percentage to use for determining whether to scale the - * cluster. - * - * @param targetUtilization the targetUtilization value to set. - * @return the AutoScaler object itself. - */ - public AutoScaler withTargetUtilization(Integer targetUtilization) { - this.targetUtilization = targetUtilization; - return this; - } - - /** - * Get the refreshPeriodInSeconds property: The amount of seconds to wait between auto scale updates. - * - * @return the refreshPeriodInSeconds value. - */ - public Integer refreshPeriodInSeconds() { - return this.refreshPeriodInSeconds; - } - - /** - * Set the refreshPeriodInSeconds property: The amount of seconds to wait between auto scale updates. - * - * @param refreshPeriodInSeconds the refreshPeriodInSeconds value to set. - * @return the AutoScaler object itself. - */ - public AutoScaler withRefreshPeriodInSeconds(Integer refreshPeriodInSeconds) { - this.refreshPeriodInSeconds = refreshPeriodInSeconds; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BaseComputeResource.java similarity index 54% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolProperties.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BaseComputeResource.java index 6aa2392a84abd..df75a4ffda848 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BaseComputeResource.java @@ -5,37 +5,33 @@ package com.azure.resourcemanager.machinelearningservices.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; -/** Properties specific to Synapse Spark pools. */ +/** The BaseComputeResource model. */ @Fluent -public class SynapseSparkPoolProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SynapseSparkPoolProperties.class); - +public class BaseComputeResource { /* - * AKS properties + * Compute properties */ @JsonProperty(value = "properties") - private SynapseSparkPoolPropertiesAutoGenerated properties; + private Compute properties; /** - * Get the properties property: AKS properties. + * Get the properties property: Compute properties. * * @return the properties value. */ - public SynapseSparkPoolPropertiesAutoGenerated properties() { + public Compute properties() { return this.properties; } /** - * Set the properties property: AKS properties. + * Set the properties property: Compute properties. * * @param properties the properties value to set. - * @return the SynapseSparkPoolProperties object itself. + * @return the BaseComputeResource object itself. */ - public SynapseSparkPoolProperties withProperties(SynapseSparkPoolPropertiesAutoGenerated properties) { + public BaseComputeResource withProperties(Compute properties) { this.properties = properties; return this; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BillingCurrency.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BillingCurrency.java index 8bf384777e4ef..b64c1aac0e205 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BillingCurrency.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/BillingCurrency.java @@ -24,7 +24,11 @@ public static BillingCurrency fromString(String name) { return fromString(name, BillingCurrency.class); } - /** @return known BillingCurrency values. */ + /** + * Gets known BillingCurrency values. + * + * @return known BillingCurrency values. + */ public static Collection values() { return values(BillingCurrency.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterPurpose.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterPurpose.java index b40057e337f5e..e120be98c2bac 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterPurpose.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterPurpose.java @@ -30,7 +30,11 @@ public static ClusterPurpose fromString(String name) { return fromString(name, ClusterPurpose.class); } - /** @return known ClusterPurpose values. */ + /** + * Gets known ClusterPurpose values. + * + * @return known ClusterPurpose values. + */ public static Collection values() { return values(ClusterPurpose.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterUpdateParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterUpdateParameters.java index 0b2907843aec9..0649392c95049 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterUpdateParameters.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterUpdateParameters.java @@ -5,40 +5,47 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.fluent.models.ClusterUpdateProperties; import com.fasterxml.jackson.annotation.JsonProperty; /** AmlCompute update parameters. */ -@JsonFlatten @Fluent -public class ClusterUpdateParameters { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterUpdateParameters.class); - +public final class ClusterUpdateParameters { /* - * Desired scale settings for the amlCompute. + * The properties of the amlCompute. */ - @JsonProperty(value = "properties.scaleSettings") - private ScaleSettings scaleSettings; + @JsonProperty(value = "properties") + private ClusterUpdateProperties innerProperties; /** - * Get the scaleSettings property: Desired scale settings for the amlCompute. + * Get the innerProperties property: The properties of the amlCompute. * - * @return the scaleSettings value. + * @return the innerProperties value. */ - public ScaleSettings scaleSettings() { - return this.scaleSettings; + private ClusterUpdateProperties innerProperties() { + return this.innerProperties; } /** - * Set the scaleSettings property: Desired scale settings for the amlCompute. + * Get the properties property: Properties of ClusterUpdate. * - * @param scaleSettings the scaleSettings value to set. + * @return the properties value. + */ + public ScaleSettingsInformation properties() { + return this.innerProperties() == null ? null : this.innerProperties().properties(); + } + + /** + * Set the properties property: Properties of ClusterUpdate. + * + * @param properties the properties value to set. * @return the ClusterUpdateParameters object itself. */ - public ClusterUpdateParameters withScaleSettings(ScaleSettings scaleSettings) { - this.scaleSettings = scaleSettings; + public ClusterUpdateParameters withProperties(ScaleSettingsInformation properties) { + if (this.innerProperties() == null) { + this.innerProperties = new ClusterUpdateProperties(); + } + this.innerProperties().withProperties(properties); return this; } @@ -48,8 +55,8 @@ public ClusterUpdateParameters withScaleSettings(ScaleSettings scaleSettings) { * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { - if (scaleSettings() != null) { - scaleSettings().validate(); + if (innerProperties() != null) { + innerProperties().validate(); } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Compute.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Compute.java index c1dd9dd931e13..8704bf6ad250d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Compute.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Compute.java @@ -6,8 +6,6 @@ import com.azure.core.annotation.Fluent; import com.azure.core.management.exception.ManagementError; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonSubTypes; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -24,6 +22,7 @@ @JsonTypeName("Compute") @JsonSubTypes({ @JsonSubTypes.Type(name = "AKS", value = Aks.class), + @JsonSubTypes.Type(name = "Kubernetes", value = Kubernetes.class), @JsonSubTypes.Type(name = "AmlCompute", value = AmlCompute.class), @JsonSubTypes.Type(name = "ComputeInstance", value = ComputeInstance.class), @JsonSubTypes.Type(name = "VirtualMachine", value = VirtualMachine.class), @@ -35,8 +34,6 @@ }) @Fluent public class Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Compute.class); - /* * Location for the underlying compute */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeEnvironmentType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeEnvironmentType.java deleted file mode 100644 index a792b0e5311ef..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeEnvironmentType.java +++ /dev/null @@ -1,34 +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.machinelearningservices.models; - -import com.azure.core.util.ExpandableStringEnum; -import com.fasterxml.jackson.annotation.JsonCreator; -import java.util.Collection; - -/** Defines values for ComputeEnvironmentType. */ -public final class ComputeEnvironmentType extends ExpandableStringEnum { - /** Static value ACI for ComputeEnvironmentType. */ - public static final ComputeEnvironmentType ACI = fromString("ACI"); - - /** Static value AKS for ComputeEnvironmentType. */ - public static final ComputeEnvironmentType AKS = fromString("AKS"); - - /** - * Creates or finds a ComputeEnvironmentType from its string representation. - * - * @param name a name to look for. - * @return the corresponding ComputeEnvironmentType. - */ - @JsonCreator - public static ComputeEnvironmentType fromString(String name) { - return fromString(name, ComputeEnvironmentType.class); - } - - /** @return known ComputeEnvironmentType values. */ - public static Collection values() { - return values(ComputeEnvironmentType.class); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstance.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstance.java index ebec62e3516f4..015ab754d0469 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstance.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstance.java @@ -5,27 +5,23 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; -/** An Azure Machine Learning compute instance. */ +/** Properties(top level) of ComputeInstance. */ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") @JsonTypeName("ComputeInstance") @Fluent public final class ComputeInstance extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstance.class); - /* - * Compute Instance properties + * Properties of ComputeInstance */ @JsonProperty(value = "properties") private ComputeInstanceProperties properties; /** - * Get the properties property: Compute Instance properties. + * Get the properties property: Properties of ComputeInstance. * * @return the properties value. */ @@ -34,7 +30,7 @@ public ComputeInstanceProperties properties() { } /** - * Set the properties property: Compute Instance properties. + * Set the properties property: Properties of ComputeInstance. * * @param properties the properties value to set. * @return the ComputeInstance object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceApplication.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceApplication.java index 86c28dd40f4c4..64cbbd8662bd5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceApplication.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceApplication.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Defines an Aml Instance application and its connectivity endpoint URI. */ @Fluent public final class ComputeInstanceApplication { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceApplication.class); - /* * Name of the ComputeInstance application. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceAuthorizationType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceAuthorizationType.java index e0359524a8a7b..893902b55315f 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceAuthorizationType.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceAuthorizationType.java @@ -24,7 +24,11 @@ public static ComputeInstanceAuthorizationType fromString(String name) { return fromString(name, ComputeInstanceAuthorizationType.class); } - /** @return known ComputeInstanceAuthorizationType values. */ + /** + * Gets known ComputeInstanceAuthorizationType values. + * + * @return known ComputeInstanceAuthorizationType values. + */ public static Collection values() { return values(ComputeInstanceAuthorizationType.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceConnectivityEndpoints.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceConnectivityEndpoints.java index 204280629147d..407ef2585c559 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceConnectivityEndpoints.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceConnectivityEndpoints.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Defines all connectivity endpoints and properties for an ComputeInstance. */ @Immutable public final class ComputeInstanceConnectivityEndpoints { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceConnectivityEndpoints.class); - /* * Public IP Address of this ComputeInstance. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceCreatedBy.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceCreatedBy.java index c7bff50980ef5..a7e4edbd173a2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceCreatedBy.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceCreatedBy.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Describes information on user who created this ComputeInstance. */ @Immutable public final class ComputeInstanceCreatedBy { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceCreatedBy.class); - /* * Name of the user. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceLastOperation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceLastOperation.java index 40594df484cf6..5c058bba005a5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceLastOperation.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceLastOperation.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.time.OffsetDateTime; /** The last operation on ComputeInstance. */ @Fluent public final class ComputeInstanceLastOperation { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceLastOperation.class); - /* * Name of the last operation. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceProperties.java index 9e76ddfdb8f33..65e826b2cc074 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceProperties.java @@ -6,16 +6,12 @@ import com.azure.core.annotation.Fluent; import com.azure.core.management.exception.ManagementError; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Compute Instance properties. */ @Fluent public final class ComputeInstanceProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceProperties.class); - /* * Virtual Machine Size */ @@ -29,9 +25,10 @@ public final class ComputeInstanceProperties { private ResourceId subnet; /* - * Policy for sharing applications on this compute instance among users of - * parent workspace. If Personal, only the creator can access applications - * on this compute instance. When Shared, any workspace user can access + * Sharing policy for applications on this compute instance Policy for + * sharing applications on this compute instance among users of parent + * workspace. If Personal, only the creator can access applications on this + * compute instance. When Shared, any workspace user can access * applications on this instance depending on his/her assigned role. */ @JsonProperty(value = "applicationSharingPolicy") @@ -63,7 +60,7 @@ public final class ComputeInstanceProperties { private ComputeInstanceCreatedBy createdBy; /* - * Collection of errors encountered on this ComputeInstance. + * Errors. Collection of errors encountered on this ComputeInstance. */ @JsonProperty(value = "errors", access = JsonProperty.Access.WRITE_ONLY) private List errors; @@ -75,8 +72,8 @@ public final class ComputeInstanceProperties { private ComputeInstanceState state; /* - * The Compute Instance Authorization type. Available values are personal - * (default). + * Compute Instance Authorization type. The Compute Instance Authorization + * type. Available values are personal (default). */ @JsonProperty(value = "computeInstanceAuthorizationType") private ComputeInstanceAuthorizationType computeInstanceAuthorizationType; @@ -140,9 +137,10 @@ public ComputeInstanceProperties withSubnet(ResourceId subnet) { } /** - * Get the applicationSharingPolicy property: Policy for sharing applications on this compute instance among users - * of parent workspace. If Personal, only the creator can access applications on this compute instance. When Shared, - * any workspace user can access applications on this instance depending on his/her assigned role. + * Get the applicationSharingPolicy property: Sharing policy for applications on this compute instance Policy for + * sharing applications on this compute instance among users of parent workspace. If Personal, only the creator can + * access applications on this compute instance. When Shared, any workspace user can access applications on this + * instance depending on his/her assigned role. * * @return the applicationSharingPolicy value. */ @@ -151,9 +149,10 @@ public ApplicationSharingPolicy applicationSharingPolicy() { } /** - * Set the applicationSharingPolicy property: Policy for sharing applications on this compute instance among users - * of parent workspace. If Personal, only the creator can access applications on this compute instance. When Shared, - * any workspace user can access applications on this instance depending on his/her assigned role. + * Set the applicationSharingPolicy property: Sharing policy for applications on this compute instance Policy for + * sharing applications on this compute instance among users of parent workspace. If Personal, only the creator can + * access applications on this compute instance. When Shared, any workspace user can access applications on this + * instance depending on his/her assigned role. * * @param applicationSharingPolicy the applicationSharingPolicy value to set. * @return the ComputeInstanceProperties object itself. @@ -211,7 +210,7 @@ public ComputeInstanceCreatedBy createdBy() { } /** - * Get the errors property: Collection of errors encountered on this ComputeInstance. + * Get the errors property: Errors. Collection of errors encountered on this ComputeInstance. * * @return the errors value. */ @@ -229,8 +228,8 @@ public ComputeInstanceState state() { } /** - * Get the computeInstanceAuthorizationType property: The Compute Instance Authorization type. Available values are - * personal (default). + * Get the computeInstanceAuthorizationType property: Compute Instance Authorization type. The Compute Instance + * Authorization type. Available values are personal (default). * * @return the computeInstanceAuthorizationType value. */ @@ -239,8 +238,8 @@ public ComputeInstanceAuthorizationType computeInstanceAuthorizationType() { } /** - * Set the computeInstanceAuthorizationType property: The Compute Instance Authorization type. Available values are - * personal (default). + * Set the computeInstanceAuthorizationType property: Compute Instance Authorization type. The Compute Instance + * Authorization type. Available values are personal (default). * * @param computeInstanceAuthorizationType the computeInstanceAuthorizationType value to set. * @return the ComputeInstanceProperties object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceSshSettings.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceSshSettings.java index 3256a9a55cb93..96e318c431aba 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceSshSettings.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceSshSettings.java @@ -5,20 +5,16 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Specifies policy and settings for SSH access. */ @Fluent public final class ComputeInstanceSshSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeInstanceSshSettings.class); - /* - * State of the public SSH port. Possible values are: Disabled - Indicates - * that the public ssh port is closed on this instance. Enabled - Indicates - * that the public ssh port is open and accessible according to the - * VNet/subnet policy if applicable. + * Access policy for SSH State of the public SSH port. Possible values are: + * Disabled - Indicates that the public ssh port is closed on this + * instance. Enabled - Indicates that the public ssh port is open and + * accessible according to the VNet/subnet policy if applicable. */ @JsonProperty(value = "sshPublicAccess") private SshPublicAccess sshPublicAccess; @@ -43,9 +39,9 @@ public final class ComputeInstanceSshSettings { private String adminPublicKey; /** - * Get the sshPublicAccess property: State of the public SSH port. Possible values are: Disabled - Indicates that - * the public ssh port is closed on this instance. Enabled - Indicates that the public ssh port is open and - * accessible according to the VNet/subnet policy if applicable. + * Get the sshPublicAccess property: Access policy for SSH State of the public SSH port. Possible values are: + * Disabled - Indicates that the public ssh port is closed on this instance. Enabled - Indicates that the public ssh + * port is open and accessible according to the VNet/subnet policy if applicable. * * @return the sshPublicAccess value. */ @@ -54,9 +50,9 @@ public SshPublicAccess sshPublicAccess() { } /** - * Set the sshPublicAccess property: State of the public SSH port. Possible values are: Disabled - Indicates that - * the public ssh port is closed on this instance. Enabled - Indicates that the public ssh port is open and - * accessible according to the VNet/subnet policy if applicable. + * Set the sshPublicAccess property: Access policy for SSH State of the public SSH port. Possible values are: + * Disabled - Indicates that the public ssh port is closed on this instance. Enabled - Indicates that the public ssh + * port is open and accessible according to the VNet/subnet policy if applicable. * * @param sshPublicAccess the sshPublicAccess value to set. * @return the ComputeInstanceSshSettings object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceState.java index 4b2c5e63b9063..f140f8b251ba8 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceState.java @@ -66,7 +66,11 @@ public static ComputeInstanceState fromString(String name) { return fromString(name, ComputeInstanceState.class); } - /** @return known ComputeInstanceState values. */ + /** + * Gets known ComputeInstanceState values. + * + * @return known ComputeInstanceState values. + */ public static Collection values() { return values(ComputeInstanceState.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeNodesInformation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeNodesInformation.java deleted file mode 100644 index 7c6cb966ff93e..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeNodesInformation.java +++ /dev/null @@ -1,49 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; -import com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; - -/** Compute nodes information related to a Machine Learning compute. Might differ for every type of compute. */ -@JsonTypeInfo( - use = JsonTypeInfo.Id.NAME, - include = JsonTypeInfo.As.PROPERTY, - property = "computeType", - defaultImpl = ComputeNodesInformation.class) -@JsonTypeName("ComputeNodesInformation") -@JsonSubTypes({@JsonSubTypes.Type(name = "AmlCompute", value = AmlComputeNodesInformation.class)}) -@Immutable -public class ComputeNodesInformation { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeNodesInformation.class); - - /* - * The continuation token. - */ - @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY) - private String nextLink; - - /** - * Get the nextLink property: The continuation token. - * - * @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() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeResource.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeResource.java index 1c750848ed8c0..3c0e762a2013f 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeResource.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeResource.java @@ -36,32 +36,25 @@ public interface ComputeResource { String type(); /** - * Gets the location property: The geo-location where the resource lives. - * - * @return the location value. - */ - String location(); - - /** - * Gets the tags property: Resource tags. + * Gets the identity property: The identity of the resource. * - * @return the tags value. + * @return the identity value. */ - Map tags(); + Identity identity(); /** - * Gets the properties property: Compute properties. + * Gets the location property: Specifies the location of the resource. * - * @return the properties value. + * @return the location value. */ - Compute properties(); + String location(); /** - * Gets the identity property: The identity of the resource. + * Gets the tags property: Contains resource tags defined as key/value pairs. * - * @return the identity value. + * @return the tags value. */ - Identity identity(); + Map tags(); /** * Gets the sku property: The sku of the workspace. @@ -71,12 +64,19 @@ public interface ComputeResource { Sku sku(); /** - * Gets the systemData property: Read only system data. + * Gets the systemData property: System data. * * @return the systemData value. */ SystemData systemData(); + /** + * Gets the properties property: Compute properties. + * + * @return the properties value. + */ + Compute properties(); + /** * Gets the region of the resource. * @@ -100,40 +100,19 @@ public interface ComputeResource { /** The entirety of the ComputeResource definition. */ interface Definition - extends DefinitionStages.Blank, - DefinitionStages.WithLocation, - DefinitionStages.WithParentResource, - DefinitionStages.WithCreate { + extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate { } /** The ComputeResource definition stages. */ interface DefinitionStages { /** The first stage of the ComputeResource definition. */ - interface Blank extends WithLocation { - } - /** The stage of the ComputeResource definition allowing to specify location. */ - interface WithLocation { - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithParentResource withRegion(Region location); - - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithParentResource withRegion(String location); + interface Blank extends WithParentResource { } /** The stage of the ComputeResource definition allowing to specify parent resource. */ interface WithParentResource { /** * Specifies resourceGroupName, workspaceName. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @return the next definition stage. */ @@ -144,10 +123,11 @@ interface WithParentResource { * resource to be created, but also allows for any other optional properties to be specified. */ interface WithCreate - extends DefinitionStages.WithTags, - DefinitionStages.WithProperties, + extends DefinitionStages.WithLocation, + DefinitionStages.WithTags, DefinitionStages.WithIdentity, - DefinitionStages.WithSku { + DefinitionStages.WithSku, + DefinitionStages.WithProperties { /** * Executes the create request. * @@ -163,25 +143,33 @@ interface WithCreate */ ComputeResource create(Context context); } - /** The stage of the ComputeResource definition allowing to specify tags. */ - interface WithTags { + /** The stage of the ComputeResource definition allowing to specify location. */ + interface WithLocation { /** - * Specifies the tags property: Resource tags.. + * Specifies the region for the resource. * - * @param tags Resource tags. + * @param location Specifies the location of the resource. * @return the next definition stage. */ - WithCreate withTags(Map tags); + WithCreate withRegion(Region location); + + /** + * Specifies the region for the resource. + * + * @param location Specifies the location of the resource. + * @return the next definition stage. + */ + WithCreate withRegion(String location); } - /** The stage of the ComputeResource definition allowing to specify properties. */ - interface WithProperties { + /** The stage of the ComputeResource definition allowing to specify tags. */ + interface WithTags { /** - * Specifies the properties property: Compute properties. + * Specifies the tags property: Contains resource tags defined as key/value pairs.. * - * @param properties Compute properties. + * @param tags Contains resource tags defined as key/value pairs. * @return the next definition stage. */ - WithCreate withProperties(Compute properties); + WithCreate withTags(Map tags); } /** The stage of the ComputeResource definition allowing to specify identity. */ interface WithIdentity { @@ -203,6 +191,16 @@ interface WithSku { */ WithCreate withSku(Sku sku); } + /** The stage of the ComputeResource definition allowing to specify properties. */ + interface WithProperties { + /** + * Specifies the properties property: Compute properties. + * + * @param properties Compute properties. + * @return the next definition stage. + */ + WithCreate withProperties(Compute properties); + } } /** * Begins update for the ComputeResource resource. @@ -212,7 +210,7 @@ interface WithSku { ComputeResource.Update update(); /** The template for ComputeResource update. */ - interface Update extends UpdateStages.WithScaleSettings { + interface Update extends UpdateStages.WithProperties { /** * Executes the update request. * @@ -230,15 +228,15 @@ interface Update extends UpdateStages.WithScaleSettings { } /** The ComputeResource update stages. */ interface UpdateStages { - /** The stage of the ComputeResource update allowing to specify scaleSettings. */ - interface WithScaleSettings { + /** The stage of the ComputeResource update allowing to specify properties. */ + interface WithProperties { /** - * Specifies the scaleSettings property: Desired scale settings for the amlCompute.. + * Specifies the properties property: Properties of ClusterUpdate. * - * @param scaleSettings Desired scale settings for the amlCompute. + * @param properties Properties of ClusterUpdate. * @return the next definition stage. */ - Update withScaleSettings(ScaleSettings scaleSettings); + Update withProperties(ScaleSettingsInformation properties); } } /** @@ -261,7 +259,8 @@ interface WithScaleSettings { * * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ PagedIterable listNodes(); @@ -272,7 +271,8 @@ interface WithScaleSettings { * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ PagedIterable listNodes(Context context); @@ -292,7 +292,8 @@ interface WithScaleSettings { * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response}. */ Response listKeysWithResponse(Context context); @@ -347,7 +348,6 @@ interface WithScaleSettings { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. */ - Response restartWithResponse(Context context); + void restart(Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeType.java index 455f07506ec83..2d8c57d4b89c1 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeType.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeType.java @@ -13,6 +13,9 @@ public final class ComputeType extends ExpandableStringEnum { /** Static value AKS for ComputeType. */ public static final ComputeType AKS = fromString("AKS"); + /** Static value Kubernetes for ComputeType. */ + public static final ComputeType KUBERNETES = fromString("Kubernetes"); + /** Static value AmlCompute for ComputeType. */ public static final ComputeType AML_COMPUTE = fromString("AmlCompute"); @@ -48,7 +51,11 @@ public static ComputeType fromString(String name) { return fromString(name, ComputeType.class); } - /** @return known ComputeType values. */ + /** + * Gets known ComputeType values. + * + * @return known ComputeType values. + */ public static Collection values() { return values(ComputeType.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputes.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Computes.java similarity index 82% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputes.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Computes.java index 9868bffd19e7f..6fea67c6cecc2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputes.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Computes.java @@ -8,40 +8,39 @@ import com.azure.core.http.rest.Response; import com.azure.core.util.Context; -/** Resource collection API of MachineLearningComputes. */ -public interface MachineLearningComputes { +/** Resource collection API of Computes. */ +public interface Computes { /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ - PagedIterable listByWorkspace(String resourceGroupName, String workspaceName); + PagedIterable list(String resourceGroupName, String workspaceName); /** * Gets computes in specified workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param skip Continuation token for pagination. * @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 computes in specified workspace. + * @return computes in specified workspace as paginated response with {@link PagedIterable}. */ - PagedIterable listByWorkspace( - String resourceGroupName, String workspaceName, String skip, Context context); + PagedIterable list(String resourceGroupName, String workspaceName, String skip, Context context); /** * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -55,14 +54,14 @@ PagedIterable listByWorkspace( * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use * 'keys' nested resource to get them. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response}. */ Response getWithResponse( String resourceGroupName, String workspaceName, String computeName, Context context); @@ -70,7 +69,7 @@ Response getWithResponse( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -88,7 +87,7 @@ void delete( /** * Deletes specified Machine Learning compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param underlyingResourceAction Delete the underlying compute if 'Delete', or detach the underlying compute from @@ -108,13 +107,14 @@ void delete( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ PagedIterable listNodes( String resourceGroupName, String workspaceName, String computeName); @@ -122,14 +122,15 @@ PagedIterable listNodes( /** * Get the details (e.g IP address, port etc) of all the compute nodes in the compute. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 details (e. + * @return the details (e.g IP address, port etc) of all the compute nodes in the compute as paginated response with + * {@link PagedIterable}. */ PagedIterable listNodes( String resourceGroupName, String workspaceName, String computeName, Context context); @@ -137,7 +138,7 @@ PagedIterable listNodes( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -150,14 +151,15 @@ PagedIterable listNodes( /** * Gets secrets related to Machine Learning compute (storage keys, service credentials, etc). * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @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 secrets related to Machine Learning compute (storage keys, service credentials, etc). + * @return secrets related to Machine Learning compute (storage keys, service credentials, etc) along with {@link + * Response}. */ Response listKeysWithResponse( String resourceGroupName, String workspaceName, String computeName, Context context); @@ -165,7 +167,7 @@ Response listKeysWithResponse( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -177,7 +179,7 @@ Response listKeysWithResponse( /** * Posts a start action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -190,7 +192,7 @@ Response listKeysWithResponse( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -202,7 +204,7 @@ Response listKeysWithResponse( /** * Posts a stop action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. @@ -215,7 +217,7 @@ Response listKeysWithResponse( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -227,17 +229,15 @@ Response listKeysWithResponse( /** * Posts a restart action to a compute instance. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param computeName Name of the Azure Machine Learning compute. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. */ - Response restartWithResponse( - String resourceGroupName, String workspaceName, String computeName, Context context); + void restart(String resourceGroupName, String workspaceName, String computeName, Context context); /** * Gets compute definition by its name. Any secrets (storage keys, service credentials, etc) are not returned - use @@ -247,7 +247,7 @@ Response restartWithResponse( * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response}. */ ComputeResource getById(String id); @@ -260,7 +260,7 @@ Response restartWithResponse( * @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 compute definition by its name. + * @return compute definition by its name along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistry.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistry.java deleted file mode 100644 index 6e7e304461b6b..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistry.java +++ /dev/null @@ -1,102 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The ContainerRegistry model. */ -@Fluent -public class ContainerRegistry { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ContainerRegistry.class); - - /* - * The address property. - */ - @JsonProperty(value = "address") - private String address; - - /* - * The username property. - */ - @JsonProperty(value = "username") - private String username; - - /* - * The password property. - */ - @JsonProperty(value = "password") - private String password; - - /** - * Get the address property: The address property. - * - * @return the address value. - */ - public String address() { - return this.address; - } - - /** - * Set the address property: The address property. - * - * @param address the address value to set. - * @return the ContainerRegistry object itself. - */ - public ContainerRegistry withAddress(String address) { - this.address = address; - return this; - } - - /** - * Get the username property: The username property. - * - * @return the username value. - */ - public String username() { - return this.username; - } - - /** - * Set the username property: The username property. - * - * @param username the username value to set. - * @return the ContainerRegistry object itself. - */ - public ContainerRegistry withUsername(String username) { - this.username = username; - return this; - } - - /** - * Get the password property: The password property. - * - * @return the password value. - */ - public String password() { - return this.password; - } - - /** - * Set the password property: The password property. - * - * @param password the password value to set. - * @return the ContainerRegistry object itself. - */ - public ContainerRegistry withPassword(String password) { - this.password = password; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistryResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistryResponse.java deleted file mode 100644 index 61727e355949b..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistryResponse.java +++ /dev/null @@ -1,50 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The ContainerRegistryResponse model. */ -@Fluent -public class ContainerRegistryResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ContainerRegistryResponse.class); - - /* - * The address property. - */ - @JsonProperty(value = "address") - private String address; - - /** - * Get the address property: The address property. - * - * @return the address value. - */ - public String address() { - return this.address; - } - - /** - * Set the address property: The address property. - * - * @param address the address value to set. - * @return the ContainerRegistryResponse object itself. - */ - public ContainerRegistryResponse withAddress(String address) { - this.address = address; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerResourceRequirements.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerResourceRequirements.java deleted file mode 100644 index 195bab4744dd0..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerResourceRequirements.java +++ /dev/null @@ -1,196 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The resource requirements for the container (cpu and memory). */ -@Fluent -public final class ContainerResourceRequirements { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ContainerResourceRequirements.class); - - /* - * The minimum amount of CPU cores to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - */ - @JsonProperty(value = "cpu") - private Double cpu; - - /* - * The maximum amount of CPU cores allowed to be used by the container. - * More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - */ - @JsonProperty(value = "cpuLimit") - private Double cpuLimit; - - /* - * The minimum amount of memory (in GB) to be used by the container. More - * info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - */ - @JsonProperty(value = "memoryInGB") - private Double memoryInGB; - - /* - * The maximum amount of memory (in GB) allowed to be used by the - * container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/ - */ - @JsonProperty(value = "memoryInGBLimit") - private Double memoryInGBLimit; - - /* - * The number of GPU cores in the container. - */ - @JsonProperty(value = "gpu") - private Integer gpu; - - /* - * The number of FPGA PCIE devices exposed to the container. Must be - * multiple of 2. - */ - @JsonProperty(value = "fpga") - private Integer fpga; - - /** - * Get the cpu property: The minimum amount of CPU cores to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @return the cpu value. - */ - public Double cpu() { - return this.cpu; - } - - /** - * Set the cpu property: The minimum amount of CPU cores to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @param cpu the cpu value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withCpu(Double cpu) { - this.cpu = cpu; - return this; - } - - /** - * Get the cpuLimit property: The maximum amount of CPU cores allowed to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @return the cpuLimit value. - */ - public Double cpuLimit() { - return this.cpuLimit; - } - - /** - * Set the cpuLimit property: The maximum amount of CPU cores allowed to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @param cpuLimit the cpuLimit value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withCpuLimit(Double cpuLimit) { - this.cpuLimit = cpuLimit; - return this; - } - - /** - * Get the memoryInGB property: The minimum amount of memory (in GB) to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @return the memoryInGB value. - */ - public Double memoryInGB() { - return this.memoryInGB; - } - - /** - * Set the memoryInGB property: The minimum amount of memory (in GB) to be used by the container. More info: - * https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @param memoryInGB the memoryInGB value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withMemoryInGB(Double memoryInGB) { - this.memoryInGB = memoryInGB; - return this; - } - - /** - * Get the memoryInGBLimit property: The maximum amount of memory (in GB) allowed to be used by the container. More - * info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @return the memoryInGBLimit value. - */ - public Double memoryInGBLimit() { - return this.memoryInGBLimit; - } - - /** - * Set the memoryInGBLimit property: The maximum amount of memory (in GB) allowed to be used by the container. More - * info: https://kubernetes.io/docs/concepts/configuration/manage-compute-resources-container/. - * - * @param memoryInGBLimit the memoryInGBLimit value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withMemoryInGBLimit(Double memoryInGBLimit) { - this.memoryInGBLimit = memoryInGBLimit; - return this; - } - - /** - * Get the gpu property: The number of GPU cores in the container. - * - * @return the gpu value. - */ - public Integer gpu() { - return this.gpu; - } - - /** - * Set the gpu property: The number of GPU cores in the container. - * - * @param gpu the gpu value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withGpu(Integer gpu) { - this.gpu = gpu; - return this; - } - - /** - * Get the fpga property: The number of FPGA PCIE devices exposed to the container. Must be multiple of 2. - * - * @return the fpga value. - */ - public Integer fpga() { - return this.fpga; - } - - /** - * Set the fpga property: The number of FPGA PCIE devices exposed to the container. Must be multiple of 2. - * - * @param fpga the fpga value to set. - * @return the ContainerResourceRequirements object itself. - */ - public ContainerResourceRequirements withFpga(Integer fpga) { - this.fpga = fpga; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CosmosDbSettings.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CosmosDbSettings.java index b0c6e7eb973a4..045b918445740 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CosmosDbSettings.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CosmosDbSettings.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The CosmosDbSettings model. */ @Fluent public final class CosmosDbSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(CosmosDbSettings.class); - /* * The throughput of the collections in cosmosdb database */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateEndpointVariantRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateEndpointVariantRequest.java deleted file mode 100644 index 737269cd7431e..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateEndpointVariantRequest.java +++ /dev/null @@ -1,158 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** The Variant properties. */ -@JsonTypeInfo( - use = JsonTypeInfo.Id.NAME, - include = JsonTypeInfo.As.PROPERTY, - property = "computeType", - defaultImpl = CreateEndpointVariantRequest.class) -@JsonTypeName("Custom") -@JsonSubTypes({@JsonSubTypes.Type(name = "AKS", value = AksServiceCreateRequest.class)}) -@Fluent -public class CreateEndpointVariantRequest extends CreateServiceRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(CreateEndpointVariantRequest.class); - - /* - * Is this the default variant. - */ - @JsonProperty(value = "isDefault") - private Boolean isDefault; - - /* - * The amount of traffic variant receives. - */ - @JsonProperty(value = "trafficPercentile") - private Float trafficPercentile; - - /* - * The type of the variant. - */ - @JsonProperty(value = "type") - private VariantType type; - - /** - * Get the isDefault property: Is this the default variant. - * - * @return the isDefault value. - */ - public Boolean isDefault() { - return this.isDefault; - } - - /** - * Set the isDefault property: Is this the default variant. - * - * @param isDefault the isDefault value to set. - * @return the CreateEndpointVariantRequest object itself. - */ - public CreateEndpointVariantRequest withIsDefault(Boolean isDefault) { - this.isDefault = isDefault; - return this; - } - - /** - * Get the trafficPercentile property: The amount of traffic variant receives. - * - * @return the trafficPercentile value. - */ - public Float trafficPercentile() { - return this.trafficPercentile; - } - - /** - * Set the trafficPercentile property: The amount of traffic variant receives. - * - * @param trafficPercentile the trafficPercentile value to set. - * @return the CreateEndpointVariantRequest object itself. - */ - public CreateEndpointVariantRequest withTrafficPercentile(Float trafficPercentile) { - this.trafficPercentile = trafficPercentile; - return this; - } - - /** - * Get the type property: The type of the variant. - * - * @return the type value. - */ - public VariantType type() { - return this.type; - } - - /** - * Set the type property: The type of the variant. - * - * @param type the type value to set. - * @return the CreateEndpointVariantRequest object itself. - */ - public CreateEndpointVariantRequest withType(VariantType type) { - this.type = type; - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withDescription(String description) { - super.withDescription(description); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withKvTags(Map kvTags) { - super.withKvTags(kvTags); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withProperties(Map properties) { - super.withProperties(properties); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withKeys(CreateServiceRequestKeys keys) { - super.withKeys(keys); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withEnvironmentImageRequest( - CreateServiceRequestEnvironmentImageRequest environmentImageRequest) { - super.withEnvironmentImageRequest(environmentImageRequest); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateEndpointVariantRequest withLocation(String location) { - super.withLocation(location); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequest.java deleted file mode 100644 index 8d15b962c8bef..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequest.java +++ /dev/null @@ -1,201 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** The base class for creating a service. */ -@JsonTypeInfo( - use = JsonTypeInfo.Id.NAME, - include = JsonTypeInfo.As.PROPERTY, - property = "computeType", - defaultImpl = CreateServiceRequest.class) -@JsonTypeName("CreateServiceRequest") -@JsonSubTypes({ - @JsonSubTypes.Type(name = "ACI", value = AciServiceCreateRequest.class), - @JsonSubTypes.Type(name = "Custom", value = CreateEndpointVariantRequest.class) -}) -@Fluent -public class CreateServiceRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(CreateServiceRequest.class); - - /* - * The description of the service. - */ - @JsonProperty(value = "description") - private String description; - - /* - * The service tag dictionary. Tags are mutable. - */ - @JsonProperty(value = "kvTags") - private Map kvTags; - - /* - * The service properties dictionary. Properties are immutable. - */ - @JsonProperty(value = "properties") - private Map properties; - - /* - * The authentication keys. - */ - @JsonProperty(value = "keys") - private CreateServiceRequestKeys keys; - - /* - * The Environment, models and assets needed for inferencing. - */ - @JsonProperty(value = "environmentImageRequest") - private CreateServiceRequestEnvironmentImageRequest environmentImageRequest; - - /* - * The name of the Azure location/region. - */ - @JsonProperty(value = "location") - private String location; - - /** - * Get the description property: The description of the service. - * - * @return the description value. - */ - public String description() { - return this.description; - } - - /** - * Set the description property: The description of the service. - * - * @param description the description value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withDescription(String description) { - this.description = description; - return this; - } - - /** - * Get the kvTags property: The service tag dictionary. Tags are mutable. - * - * @return the kvTags value. - */ - public Map kvTags() { - return this.kvTags; - } - - /** - * Set the kvTags property: The service tag dictionary. Tags are mutable. - * - * @param kvTags the kvTags value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withKvTags(Map kvTags) { - this.kvTags = kvTags; - return this; - } - - /** - * Get the properties property: The service properties dictionary. Properties are immutable. - * - * @return the properties value. - */ - public Map properties() { - return this.properties; - } - - /** - * Set the properties property: The service properties dictionary. Properties are immutable. - * - * @param properties the properties value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withProperties(Map properties) { - this.properties = properties; - return this; - } - - /** - * Get the keys property: The authentication keys. - * - * @return the keys value. - */ - public CreateServiceRequestKeys keys() { - return this.keys; - } - - /** - * Set the keys property: The authentication keys. - * - * @param keys the keys value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withKeys(CreateServiceRequestKeys keys) { - this.keys = keys; - return this; - } - - /** - * Get the environmentImageRequest property: The Environment, models and assets needed for inferencing. - * - * @return the environmentImageRequest value. - */ - public CreateServiceRequestEnvironmentImageRequest environmentImageRequest() { - return this.environmentImageRequest; - } - - /** - * Set the environmentImageRequest property: The Environment, models and assets needed for inferencing. - * - * @param environmentImageRequest the environmentImageRequest value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withEnvironmentImageRequest( - CreateServiceRequestEnvironmentImageRequest environmentImageRequest) { - this.environmentImageRequest = environmentImageRequest; - return this; - } - - /** - * Get the location property: The name of the Azure location/region. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The name of the Azure location/region. - * - * @param location the location value to set. - * @return the CreateServiceRequest object itself. - */ - public CreateServiceRequest withLocation(String location) { - this.location = location; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (keys() != null) { - keys().validate(); - } - if (environmentImageRequest() != null) { - environmentImageRequest().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestEnvironmentImageRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestEnvironmentImageRequest.java deleted file mode 100644 index 8763b677c4882..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestEnvironmentImageRequest.java +++ /dev/null @@ -1,69 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** The Environment, models and assets needed for inferencing. */ -@Immutable -public final class CreateServiceRequestEnvironmentImageRequest extends EnvironmentImageRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(CreateServiceRequestEnvironmentImageRequest.class); - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withDriverProgram(String driverProgram) { - super.withDriverProgram(driverProgram); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withAssets(List assets) { - super.withAssets(assets); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withModelIds(List modelIds) { - super.withModelIds(modelIds); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withModels(List models) { - super.withModels(models); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withEnvironment(EnvironmentImageRequestEnvironment environment) { - super.withEnvironment(environment); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestEnvironmentImageRequest withEnvironmentReference( - EnvironmentImageRequestEnvironmentReference environmentReference) { - super.withEnvironmentReference(environmentReference); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestKeys.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestKeys.java deleted file mode 100644 index 483be60416d97..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestKeys.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The authentication keys. */ -@Immutable -public final class CreateServiceRequestKeys extends AuthKeys { - @JsonIgnore private final ClientLogger logger = new ClientLogger(CreateServiceRequestKeys.class); - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestKeys withPrimaryKey(String primaryKey) { - super.withPrimaryKey(primaryKey); - return this; - } - - /** {@inheritDoc} */ - @Override - public CreateServiceRequestKeys withSecondaryKey(String secondaryKey) { - super.withSecondaryKey(secondaryKey); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataFactory.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataFactory.java index 3047134d84633..399af17bee058 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataFactory.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataFactory.java @@ -4,19 +4,15 @@ package com.azure.resourcemanager.machinelearningservices.models; -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.core.annotation.Fluent; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; /** A DataFactory compute. */ @JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") @JsonTypeName("DataFactory") -@Immutable +@Fluent public final class DataFactory extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DataFactory.class); - /** {@inheritDoc} */ @Override public DataFactory withComputeLocation(String computeLocation) { diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalytics.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalytics.java index 0f6d849895ff8..5e91061f19172 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalytics.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalytics.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,8 +14,6 @@ @JsonTypeName("DataLakeAnalytics") @Fluent public final class DataLakeAnalytics extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DataLakeAnalytics.class); - /* * The properties property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalyticsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalyticsProperties.java index 835214b03edd9..7375b91935237 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalyticsProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DataLakeAnalyticsProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The DataLakeAnalyticsProperties model. */ @Fluent public final class DataLakeAnalyticsProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DataLakeAnalyticsProperties.class); - /* * DataLake Store Account Name */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Databricks.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Databricks.java index 57c26719a5cec..a5f87ff229c5a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Databricks.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Databricks.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,16 +14,14 @@ @JsonTypeName("Databricks") @Fluent public final class Databricks extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Databricks.class); - /* - * The properties property. + * Properties of Databricks */ @JsonProperty(value = "properties") private DatabricksProperties properties; /** - * Get the properties property: The properties property. + * Get the properties property: Properties of Databricks. * * @return the properties value. */ @@ -34,7 +30,7 @@ public DatabricksProperties properties() { } /** - * Set the properties property: The properties property. + * Set the properties property: Properties of Databricks. * * @param properties the properties value to set. * @return the Databricks object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecrets.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecrets.java index c2b4c58a737f2..fee2834209934 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecrets.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecrets.java @@ -5,9 +5,7 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeSecretsInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -17,8 +15,6 @@ @JsonTypeName("Databricks") @Fluent public final class DatabricksComputeSecrets extends ComputeSecretsInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabricksComputeSecrets.class); - /* * access token for databricks account. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.java new file mode 100644 index 0000000000000..8cc2dcf0bf120 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.java @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of Databricks Compute Secrets. */ +@Fluent +public class DatabricksComputeSecretsProperties { + /* + * access token for databricks account. + */ + @JsonProperty(value = "databricksAccessToken") + private String databricksAccessToken; + + /** + * Get the databricksAccessToken property: access token for databricks account. + * + * @return the databricksAccessToken value. + */ + public String databricksAccessToken() { + return this.databricksAccessToken; + } + + /** + * Set the databricksAccessToken property: access token for databricks account. + * + * @param databricksAccessToken the databricksAccessToken value to set. + * @return the DatabricksComputeSecretsProperties object itself. + */ + public DatabricksComputeSecretsProperties withDatabricksAccessToken(String databricksAccessToken) { + this.databricksAccessToken = databricksAccessToken; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksProperties.java index 548500bc86e86..23815d470526e 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** The DatabricksProperties model. */ +/** Properties of Databricks. */ @Fluent public final class DatabricksProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabricksProperties.class); - /* * Databricks access token */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatasetReference.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatasetReference.java deleted file mode 100644 index 74a05061443b4..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatasetReference.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The dataset reference object. */ -@Fluent -public final class DatasetReference { - @JsonIgnore private final ClientLogger logger = new ClientLogger(DatasetReference.class); - - /* - * The name of the dataset reference. - */ - @JsonProperty(value = "name") - private String name; - - /* - * The id of the dataset reference. - */ - @JsonProperty(value = "id") - private String id; - - /** - * Get the name property: The name of the dataset reference. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: The name of the dataset reference. - * - * @param name the name value to set. - * @return the DatasetReference object itself. - */ - public DatasetReference withName(String name) { - this.name = name; - return this; - } - - /** - * Get the id property: The id of the dataset reference. - * - * @return the id value. - */ - public String id() { - return this.id; - } - - /** - * Set the id property: The id of the dataset reference. - * - * @param id the id value to set. - * @return the DatasetReference object itself. - */ - public DatasetReference withId(String id) { - this.id = id; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DeploymentType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DeploymentType.java deleted file mode 100644 index 13d771f612849..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DeploymentType.java +++ /dev/null @@ -1,37 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.models; - -import com.azure.core.util.ExpandableStringEnum; -import com.fasterxml.jackson.annotation.JsonCreator; -import java.util.Collection; - -/** Defines values for DeploymentType. */ -public final class DeploymentType extends ExpandableStringEnum { - /** Static value GRPCRealtimeEndpoint for DeploymentType. */ - public static final DeploymentType GRPCREALTIME_ENDPOINT = fromString("GRPCRealtimeEndpoint"); - - /** Static value HttpRealtimeEndpoint for DeploymentType. */ - public static final DeploymentType HTTP_REALTIME_ENDPOINT = fromString("HttpRealtimeEndpoint"); - - /** Static value Batch for DeploymentType. */ - public static final DeploymentType BATCH = fromString("Batch"); - - /** - * Creates or finds a DeploymentType from its string representation. - * - * @param name a name to look for. - * @return the corresponding DeploymentType. - */ - @JsonCreator - public static DeploymentType fromString(String name) { - return fromString(name, DeploymentType.class); - } - - /** @return known DeploymentType values. */ - public static Collection values() { - return values(DeploymentType.class); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseRequestProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseRequestProperties.java new file mode 100644 index 0000000000000..06e4b9095dc15 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseRequestProperties.java @@ -0,0 +1,265 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** The DiagnoseRequestProperties model. */ +@Fluent +public final class DiagnoseRequestProperties { + /* + * Setting for diagnosing user defined routing + */ + @JsonProperty(value = "udr") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map udr; + + /* + * Setting for diagnosing network security group + */ + @JsonProperty(value = "nsg") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map nsg; + + /* + * Setting for diagnosing resource lock + */ + @JsonProperty(value = "resourceLock") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map resourceLock; + + /* + * Setting for diagnosing dns resolution + */ + @JsonProperty(value = "dnsResolution") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map dnsResolution; + + /* + * Setting for diagnosing dependent storage account + */ + @JsonProperty(value = "storageAccount") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map storageAccount; + + /* + * Setting for diagnosing dependent key vault + */ + @JsonProperty(value = "keyVault") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map keyVault; + + /* + * Setting for diagnosing dependent container registry + */ + @JsonProperty(value = "containerRegistry") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map containerRegistry; + + /* + * Setting for diagnosing dependent application insights + */ + @JsonProperty(value = "applicationInsights") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map applicationInsights; + + /* + * Setting for diagnosing unclassified category of problems + */ + @JsonProperty(value = "others") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map others; + + /** + * Get the udr property: Setting for diagnosing user defined routing. + * + * @return the udr value. + */ + public Map udr() { + return this.udr; + } + + /** + * Set the udr property: Setting for diagnosing user defined routing. + * + * @param udr the udr value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withUdr(Map udr) { + this.udr = udr; + return this; + } + + /** + * Get the nsg property: Setting for diagnosing network security group. + * + * @return the nsg value. + */ + public Map nsg() { + return this.nsg; + } + + /** + * Set the nsg property: Setting for diagnosing network security group. + * + * @param nsg the nsg value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withNsg(Map nsg) { + this.nsg = nsg; + return this; + } + + /** + * Get the resourceLock property: Setting for diagnosing resource lock. + * + * @return the resourceLock value. + */ + public Map resourceLock() { + return this.resourceLock; + } + + /** + * Set the resourceLock property: Setting for diagnosing resource lock. + * + * @param resourceLock the resourceLock value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withResourceLock(Map resourceLock) { + this.resourceLock = resourceLock; + return this; + } + + /** + * Get the dnsResolution property: Setting for diagnosing dns resolution. + * + * @return the dnsResolution value. + */ + public Map dnsResolution() { + return this.dnsResolution; + } + + /** + * Set the dnsResolution property: Setting for diagnosing dns resolution. + * + * @param dnsResolution the dnsResolution value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withDnsResolution(Map dnsResolution) { + this.dnsResolution = dnsResolution; + return this; + } + + /** + * Get the storageAccount property: Setting for diagnosing dependent storage account. + * + * @return the storageAccount value. + */ + public Map storageAccount() { + return this.storageAccount; + } + + /** + * Set the storageAccount property: Setting for diagnosing dependent storage account. + * + * @param storageAccount the storageAccount value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withStorageAccount(Map storageAccount) { + this.storageAccount = storageAccount; + return this; + } + + /** + * Get the keyVault property: Setting for diagnosing dependent key vault. + * + * @return the keyVault value. + */ + public Map keyVault() { + return this.keyVault; + } + + /** + * Set the keyVault property: Setting for diagnosing dependent key vault. + * + * @param keyVault the keyVault value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withKeyVault(Map keyVault) { + this.keyVault = keyVault; + return this; + } + + /** + * Get the containerRegistry property: Setting for diagnosing dependent container registry. + * + * @return the containerRegistry value. + */ + public Map containerRegistry() { + return this.containerRegistry; + } + + /** + * Set the containerRegistry property: Setting for diagnosing dependent container registry. + * + * @param containerRegistry the containerRegistry value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withContainerRegistry(Map containerRegistry) { + this.containerRegistry = containerRegistry; + return this; + } + + /** + * Get the applicationInsights property: Setting for diagnosing dependent application insights. + * + * @return the applicationInsights value. + */ + public Map applicationInsights() { + return this.applicationInsights; + } + + /** + * Set the applicationInsights property: Setting for diagnosing dependent application insights. + * + * @param applicationInsights the applicationInsights value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withApplicationInsights(Map applicationInsights) { + this.applicationInsights = applicationInsights; + return this; + } + + /** + * Get the others property: Setting for diagnosing unclassified category of problems. + * + * @return the others value. + */ + public Map others() { + return this.others; + } + + /** + * Set the others property: Setting for diagnosing unclassified category of problems. + * + * @param others the others value to set. + * @return the DiagnoseRequestProperties object itself. + */ + public DiagnoseRequestProperties withOthers(Map others) { + this.others = others; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResult.java new file mode 100644 index 0000000000000..47fb0e61ea1e6 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResult.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; + +/** An immutable client-side representation of DiagnoseResponseResult. */ +public interface DiagnoseResponseResult { + /** + * Gets the value property: The value property. + * + * @return the value value. + */ + DiagnoseResponseResultValue value(); + + /** + * Gets the inner com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner + * object. + * + * @return the inner object. + */ + DiagnoseResponseResultInner innerModel(); +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResultValue.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResultValue.java new file mode 100644 index 0000000000000..243299bb9cef0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResultValue.java @@ -0,0 +1,282 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The DiagnoseResponseResultValue model. */ +@Fluent +public final class DiagnoseResponseResultValue { + /* + * The userDefinedRouteResults property. + */ + @JsonProperty(value = "userDefinedRouteResults") + private List userDefinedRouteResults; + + /* + * The networkSecurityRuleResults property. + */ + @JsonProperty(value = "networkSecurityRuleResults") + private List networkSecurityRuleResults; + + /* + * The resourceLockResults property. + */ + @JsonProperty(value = "resourceLockResults") + private List resourceLockResults; + + /* + * The dnsResolutionResults property. + */ + @JsonProperty(value = "dnsResolutionResults") + private List dnsResolutionResults; + + /* + * The storageAccountResults property. + */ + @JsonProperty(value = "storageAccountResults") + private List storageAccountResults; + + /* + * The keyVaultResults property. + */ + @JsonProperty(value = "keyVaultResults") + private List keyVaultResults; + + /* + * The containerRegistryResults property. + */ + @JsonProperty(value = "containerRegistryResults") + private List containerRegistryResults; + + /* + * The applicationInsightsResults property. + */ + @JsonProperty(value = "applicationInsightsResults") + private List applicationInsightsResults; + + /* + * The otherResults property. + */ + @JsonProperty(value = "otherResults") + private List otherResults; + + /** + * Get the userDefinedRouteResults property: The userDefinedRouteResults property. + * + * @return the userDefinedRouteResults value. + */ + public List userDefinedRouteResults() { + return this.userDefinedRouteResults; + } + + /** + * Set the userDefinedRouteResults property: The userDefinedRouteResults property. + * + * @param userDefinedRouteResults the userDefinedRouteResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withUserDefinedRouteResults(List userDefinedRouteResults) { + this.userDefinedRouteResults = userDefinedRouteResults; + return this; + } + + /** + * Get the networkSecurityRuleResults property: The networkSecurityRuleResults property. + * + * @return the networkSecurityRuleResults value. + */ + public List networkSecurityRuleResults() { + return this.networkSecurityRuleResults; + } + + /** + * Set the networkSecurityRuleResults property: The networkSecurityRuleResults property. + * + * @param networkSecurityRuleResults the networkSecurityRuleResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withNetworkSecurityRuleResults(List networkSecurityRuleResults) { + this.networkSecurityRuleResults = networkSecurityRuleResults; + return this; + } + + /** + * Get the resourceLockResults property: The resourceLockResults property. + * + * @return the resourceLockResults value. + */ + public List resourceLockResults() { + return this.resourceLockResults; + } + + /** + * Set the resourceLockResults property: The resourceLockResults property. + * + * @param resourceLockResults the resourceLockResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withResourceLockResults(List resourceLockResults) { + this.resourceLockResults = resourceLockResults; + return this; + } + + /** + * Get the dnsResolutionResults property: The dnsResolutionResults property. + * + * @return the dnsResolutionResults value. + */ + public List dnsResolutionResults() { + return this.dnsResolutionResults; + } + + /** + * Set the dnsResolutionResults property: The dnsResolutionResults property. + * + * @param dnsResolutionResults the dnsResolutionResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withDnsResolutionResults(List dnsResolutionResults) { + this.dnsResolutionResults = dnsResolutionResults; + return this; + } + + /** + * Get the storageAccountResults property: The storageAccountResults property. + * + * @return the storageAccountResults value. + */ + public List storageAccountResults() { + return this.storageAccountResults; + } + + /** + * Set the storageAccountResults property: The storageAccountResults property. + * + * @param storageAccountResults the storageAccountResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withStorageAccountResults(List storageAccountResults) { + this.storageAccountResults = storageAccountResults; + return this; + } + + /** + * Get the keyVaultResults property: The keyVaultResults property. + * + * @return the keyVaultResults value. + */ + public List keyVaultResults() { + return this.keyVaultResults; + } + + /** + * Set the keyVaultResults property: The keyVaultResults property. + * + * @param keyVaultResults the keyVaultResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withKeyVaultResults(List keyVaultResults) { + this.keyVaultResults = keyVaultResults; + return this; + } + + /** + * Get the containerRegistryResults property: The containerRegistryResults property. + * + * @return the containerRegistryResults value. + */ + public List containerRegistryResults() { + return this.containerRegistryResults; + } + + /** + * Set the containerRegistryResults property: The containerRegistryResults property. + * + * @param containerRegistryResults the containerRegistryResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withContainerRegistryResults(List containerRegistryResults) { + this.containerRegistryResults = containerRegistryResults; + return this; + } + + /** + * Get the applicationInsightsResults property: The applicationInsightsResults property. + * + * @return the applicationInsightsResults value. + */ + public List applicationInsightsResults() { + return this.applicationInsightsResults; + } + + /** + * Set the applicationInsightsResults property: The applicationInsightsResults property. + * + * @param applicationInsightsResults the applicationInsightsResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withApplicationInsightsResults(List applicationInsightsResults) { + this.applicationInsightsResults = applicationInsightsResults; + return this; + } + + /** + * Get the otherResults property: The otherResults property. + * + * @return the otherResults value. + */ + public List otherResults() { + return this.otherResults; + } + + /** + * Set the otherResults property: The otherResults property. + * + * @param otherResults the otherResults value to set. + * @return the DiagnoseResponseResultValue object itself. + */ + public DiagnoseResponseResultValue withOtherResults(List otherResults) { + this.otherResults = otherResults; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (userDefinedRouteResults() != null) { + userDefinedRouteResults().forEach(e -> e.validate()); + } + if (networkSecurityRuleResults() != null) { + networkSecurityRuleResults().forEach(e -> e.validate()); + } + if (resourceLockResults() != null) { + resourceLockResults().forEach(e -> e.validate()); + } + if (dnsResolutionResults() != null) { + dnsResolutionResults().forEach(e -> e.validate()); + } + if (storageAccountResults() != null) { + storageAccountResults().forEach(e -> e.validate()); + } + if (keyVaultResults() != null) { + keyVaultResults().forEach(e -> e.validate()); + } + if (containerRegistryResults() != null) { + containerRegistryResults().forEach(e -> e.validate()); + } + if (applicationInsightsResults() != null) { + applicationInsightsResults().forEach(e -> e.validate()); + } + if (otherResults() != null) { + otherResults().forEach(e -> e.validate()); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResult.java new file mode 100644 index 0000000000000..5db646d1d90be --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResult.java @@ -0,0 +1,65 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Immutable; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Result of Diagnose. */ +@Immutable +public final class DiagnoseResult { + /* + * Code for workspace setup error + */ + @JsonProperty(value = "code", access = JsonProperty.Access.WRITE_ONLY) + private String code; + + /* + * Level of workspace setup error + */ + @JsonProperty(value = "level", access = JsonProperty.Access.WRITE_ONLY) + private DiagnoseResultLevel level; + + /* + * Message of workspace setup error + */ + @JsonProperty(value = "message", access = JsonProperty.Access.WRITE_ONLY) + private String message; + + /** + * Get the code property: Code for workspace setup error. + * + * @return the code value. + */ + public String code() { + return this.code; + } + + /** + * Get the level property: Level of workspace setup error. + * + * @return the level value. + */ + public DiagnoseResultLevel level() { + return this.level; + } + + /** + * Get the message property: Message of workspace setup error. + * + * @return the message value. + */ + public String message() { + return this.message; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResultLevel.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResultLevel.java new file mode 100644 index 0000000000000..7929a363fb469 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResultLevel.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.machinelearningservices.models; + +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** Defines values for DiagnoseResultLevel. */ +public final class DiagnoseResultLevel extends ExpandableStringEnum { + /** Static value Warning for DiagnoseResultLevel. */ + public static final DiagnoseResultLevel WARNING = fromString("Warning"); + + /** Static value Error for DiagnoseResultLevel. */ + public static final DiagnoseResultLevel ERROR = fromString("Error"); + + /** Static value Information for DiagnoseResultLevel. */ + public static final DiagnoseResultLevel INFORMATION = fromString("Information"); + + /** + * Creates or finds a DiagnoseResultLevel from its string representation. + * + * @param name a name to look for. + * @return the corresponding DiagnoseResultLevel. + */ + @JsonCreator + public static DiagnoseResultLevel fromString(String name) { + return fromString(name, DiagnoseResultLevel.class); + } + + /** + * Gets known DiagnoseResultLevel values. + * + * @return known DiagnoseResultLevel values. + */ + public static Collection values() { + return values(DiagnoseResultLevel.class); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseWorkspaceParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseWorkspaceParameters.java new file mode 100644 index 0000000000000..abac7e8656095 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseWorkspaceParameters.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Parameters to diagnose a workspace. */ +@Fluent +public final class DiagnoseWorkspaceParameters { + /* + * Value of Parameters + */ + @JsonProperty(value = "value") + private DiagnoseRequestProperties value; + + /** + * Get the value property: Value of Parameters. + * + * @return the value value. + */ + public DiagnoseRequestProperties value() { + return this.value; + } + + /** + * Set the value property: Value of Parameters. + * + * @param value the value value to set. + * @return the DiagnoseWorkspaceParameters object itself. + */ + public DiagnoseWorkspaceParameters withValue(DiagnoseRequestProperties value) { + this.value = value; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (value() != null) { + value().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperties.java deleted file mode 100644 index 82adb616d98b8..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperties.java +++ /dev/null @@ -1,118 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The EncryptionProperties model. */ -@Fluent -public class EncryptionProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EncryptionProperties.class); - - /* - * vault base Url - */ - @JsonProperty(value = "vaultBaseUrl", required = true) - private String vaultBaseUrl; - - /* - * Encryption Key name - */ - @JsonProperty(value = "keyName", required = true) - private String keyName; - - /* - * Encryption Key Version - */ - @JsonProperty(value = "keyVersion", required = true) - private String keyVersion; - - /** - * Get the vaultBaseUrl property: vault base Url. - * - * @return the vaultBaseUrl value. - */ - public String vaultBaseUrl() { - return this.vaultBaseUrl; - } - - /** - * Set the vaultBaseUrl property: vault base Url. - * - * @param vaultBaseUrl the vaultBaseUrl value to set. - * @return the EncryptionProperties object itself. - */ - public EncryptionProperties withVaultBaseUrl(String vaultBaseUrl) { - this.vaultBaseUrl = vaultBaseUrl; - return this; - } - - /** - * Get the keyName property: Encryption Key name. - * - * @return the keyName value. - */ - public String keyName() { - return this.keyName; - } - - /** - * Set the keyName property: Encryption Key name. - * - * @param keyName the keyName value to set. - * @return the EncryptionProperties object itself. - */ - public EncryptionProperties withKeyName(String keyName) { - this.keyName = keyName; - return this; - } - - /** - * Get the keyVersion property: Encryption Key Version. - * - * @return the keyVersion value. - */ - public String keyVersion() { - return this.keyVersion; - } - - /** - * Set the keyVersion property: Encryption Key Version. - * - * @param keyVersion the keyVersion value to set. - * @return the EncryptionProperties object itself. - */ - public EncryptionProperties withKeyVersion(String keyVersion) { - this.keyVersion = keyVersion; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (vaultBaseUrl() == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException( - "Missing required property vaultBaseUrl in model EncryptionProperties")); - } - if (keyName() == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException("Missing required property keyName in model EncryptionProperties")); - } - if (keyVersion() == null) { - throw logger - .logExceptionAsError( - new IllegalArgumentException("Missing required property keyVersion in model EncryptionProperties")); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperty.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperty.java index d785a15ea4ade..5fce8b8d3e2aa 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperty.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperty.java @@ -6,14 +6,11 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The EncryptionProperty model. */ @Fluent public final class EncryptionProperty { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EncryptionProperty.class); - /* * Indicates whether or not the encryption is enabled for the workspace. */ @@ -100,7 +97,7 @@ public EncryptionProperty withKeyVaultProperties(KeyVaultProperties keyVaultProp */ public void validate() { if (status() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property status in model EncryptionProperty")); } @@ -108,7 +105,7 @@ public void validate() { identity().validate(); } if (keyVaultProperties() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property keyVaultProperties in model EncryptionProperty")); @@ -116,4 +113,6 @@ public void validate() { keyVaultProperties().validate(); } } + + private static final ClientLogger LOGGER = new ClientLogger(EncryptionProperty.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionStatus.java index 2642e3553b714..f3b532d067493 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionStatus.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionStatus.java @@ -27,7 +27,11 @@ public static EncryptionStatus fromString(String name) { return fromString(name, EncryptionStatus.class); } - /** @return known EncryptionStatus values. */ + /** + * Gets known EncryptionStatus values. + * + * @return known EncryptionStatus values. + */ public static Collection values() { return values(EncryptionStatus.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequest.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequest.java deleted file mode 100644 index be4b32d72d69b..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequest.java +++ /dev/null @@ -1,194 +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.machinelearningservices.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.List; - -/** Request to create a Docker image based on Environment. */ -@Fluent -public class EnvironmentImageRequest { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentImageRequest.class); - - /* - * The name of the driver file. - */ - @JsonProperty(value = "driverProgram") - private String driverProgram; - - /* - * The list of assets. - */ - @JsonProperty(value = "assets") - private List assets; - - /* - * The list of model Ids. - */ - @JsonProperty(value = "modelIds") - private List modelIds; - - /* - * The list of models. - */ - @JsonProperty(value = "models") - private List models; - - /* - * The details of the AZURE ML environment. - */ - @JsonProperty(value = "environment") - private EnvironmentImageRequestEnvironment environment; - - /* - * The unique identifying details of the AZURE ML environment. - */ - @JsonProperty(value = "environmentReference") - private EnvironmentImageRequestEnvironmentReference environmentReference; - - /** - * Get the driverProgram property: The name of the driver file. - * - * @return the driverProgram value. - */ - public String driverProgram() { - return this.driverProgram; - } - - /** - * Set the driverProgram property: The name of the driver file. - * - * @param driverProgram the driverProgram value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withDriverProgram(String driverProgram) { - this.driverProgram = driverProgram; - return this; - } - - /** - * Get the assets property: The list of assets. - * - * @return the assets value. - */ - public List assets() { - return this.assets; - } - - /** - * Set the assets property: The list of assets. - * - * @param assets the assets value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withAssets(List assets) { - this.assets = assets; - return this; - } - - /** - * Get the modelIds property: The list of model Ids. - * - * @return the modelIds value. - */ - public List modelIds() { - return this.modelIds; - } - - /** - * Set the modelIds property: The list of model Ids. - * - * @param modelIds the modelIds value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withModelIds(List modelIds) { - this.modelIds = modelIds; - return this; - } - - /** - * Get the models property: The list of models. - * - * @return the models value. - */ - public List models() { - return this.models; - } - - /** - * Set the models property: The list of models. - * - * @param models the models value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withModels(List models) { - this.models = models; - return this; - } - - /** - * Get the environment property: The details of the AZURE ML environment. - * - * @return the environment value. - */ - public EnvironmentImageRequestEnvironment environment() { - return this.environment; - } - - /** - * Set the environment property: The details of the AZURE ML environment. - * - * @param environment the environment value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withEnvironment(EnvironmentImageRequestEnvironment environment) { - this.environment = environment; - return this; - } - - /** - * Get the environmentReference property: The unique identifying details of the AZURE ML environment. - * - * @return the environmentReference value. - */ - public EnvironmentImageRequestEnvironmentReference environmentReference() { - return this.environmentReference; - } - - /** - * Set the environmentReference property: The unique identifying details of the AZURE ML environment. - * - * @param environmentReference the environmentReference value to set. - * @return the EnvironmentImageRequest object itself. - */ - public EnvironmentImageRequest withEnvironmentReference( - EnvironmentImageRequestEnvironmentReference environmentReference) { - this.environmentReference = environmentReference; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (assets() != null) { - assets().forEach(e -> e.validate()); - } - if (models() != null) { - models().forEach(e -> e.validate()); - } - if (environment() != null) { - environment().validate(); - } - if (environmentReference() != null) { - environmentReference().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironment.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironment.java deleted file mode 100644 index 3dab366636fb8..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironment.java +++ /dev/null @@ -1,82 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.Map; - -/** The details of the AZURE ML environment. */ -@Immutable -public final class EnvironmentImageRequestEnvironment extends ModelEnvironmentDefinition { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentImageRequestEnvironment.class); - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withName(String name) { - super.withName(name); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withVersion(String version) { - super.withVersion(version); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withPython(ModelEnvironmentDefinitionPython python) { - super.withPython(python); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withEnvironmentVariables(Map environmentVariables) { - super.withEnvironmentVariables(environmentVariables); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withDocker(ModelEnvironmentDefinitionDocker docker) { - super.withDocker(docker); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withSpark(ModelEnvironmentDefinitionSpark spark) { - super.withSpark(spark); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withR(ModelEnvironmentDefinitionR r) { - super.withR(r); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironment withInferencingStackVersion(String inferencingStackVersion) { - super.withInferencingStackVersion(inferencingStackVersion); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironmentReference.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironmentReference.java deleted file mode 100644 index e2d879ecfc79a..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironmentReference.java +++ /dev/null @@ -1,39 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The unique identifying details of the AZURE ML environment. */ -@Immutable -public final class EnvironmentImageRequestEnvironmentReference extends EnvironmentReference { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentImageRequestEnvironmentReference.class); - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironmentReference withName(String name) { - super.withName(name); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageRequestEnvironmentReference withVersion(String version) { - super.withVersion(version); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponse.java deleted file mode 100644 index 6296bc7595c21..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponse.java +++ /dev/null @@ -1,194 +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.machinelearningservices.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.List; - -/** Request to create a Docker image based on Environment. */ -@Fluent -public class EnvironmentImageResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentImageResponse.class); - - /* - * The name of the driver file. - */ - @JsonProperty(value = "driverProgram") - private String driverProgram; - - /* - * The list of assets. - */ - @JsonProperty(value = "assets") - private List assets; - - /* - * The list of model Ids. - */ - @JsonProperty(value = "modelIds") - private List modelIds; - - /* - * The list of models. - */ - @JsonProperty(value = "models") - private List models; - - /* - * The details of the AZURE ML environment. - */ - @JsonProperty(value = "environment") - private EnvironmentImageResponseEnvironment environment; - - /* - * The unique identifying details of the AZURE ML environment. - */ - @JsonProperty(value = "environmentReference") - private EnvironmentImageResponseEnvironmentReference environmentReference; - - /** - * Get the driverProgram property: The name of the driver file. - * - * @return the driverProgram value. - */ - public String driverProgram() { - return this.driverProgram; - } - - /** - * Set the driverProgram property: The name of the driver file. - * - * @param driverProgram the driverProgram value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withDriverProgram(String driverProgram) { - this.driverProgram = driverProgram; - return this; - } - - /** - * Get the assets property: The list of assets. - * - * @return the assets value. - */ - public List assets() { - return this.assets; - } - - /** - * Set the assets property: The list of assets. - * - * @param assets the assets value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withAssets(List assets) { - this.assets = assets; - return this; - } - - /** - * Get the modelIds property: The list of model Ids. - * - * @return the modelIds value. - */ - public List modelIds() { - return this.modelIds; - } - - /** - * Set the modelIds property: The list of model Ids. - * - * @param modelIds the modelIds value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withModelIds(List modelIds) { - this.modelIds = modelIds; - return this; - } - - /** - * Get the models property: The list of models. - * - * @return the models value. - */ - public List models() { - return this.models; - } - - /** - * Set the models property: The list of models. - * - * @param models the models value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withModels(List models) { - this.models = models; - return this; - } - - /** - * Get the environment property: The details of the AZURE ML environment. - * - * @return the environment value. - */ - public EnvironmentImageResponseEnvironment environment() { - return this.environment; - } - - /** - * Set the environment property: The details of the AZURE ML environment. - * - * @param environment the environment value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withEnvironment(EnvironmentImageResponseEnvironment environment) { - this.environment = environment; - return this; - } - - /** - * Get the environmentReference property: The unique identifying details of the AZURE ML environment. - * - * @return the environmentReference value. - */ - public EnvironmentImageResponseEnvironmentReference environmentReference() { - return this.environmentReference; - } - - /** - * Set the environmentReference property: The unique identifying details of the AZURE ML environment. - * - * @param environmentReference the environmentReference value to set. - * @return the EnvironmentImageResponse object itself. - */ - public EnvironmentImageResponse withEnvironmentReference( - EnvironmentImageResponseEnvironmentReference environmentReference) { - this.environmentReference = environmentReference; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (assets() != null) { - assets().forEach(e -> e.validate()); - } - if (models() != null) { - models().forEach(e -> e.validate()); - } - if (environment() != null) { - environment().validate(); - } - if (environmentReference() != null) { - environmentReference().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironment.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironment.java deleted file mode 100644 index e5cd71316c824..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironment.java +++ /dev/null @@ -1,82 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.Map; - -/** The details of the AZURE ML environment. */ -@Immutable -public final class EnvironmentImageResponseEnvironment extends ModelEnvironmentDefinitionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentImageResponseEnvironment.class); - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withName(String name) { - super.withName(name); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withVersion(String version) { - super.withVersion(version); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withPython(ModelEnvironmentDefinitionResponsePython python) { - super.withPython(python); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withEnvironmentVariables(Map environmentVariables) { - super.withEnvironmentVariables(environmentVariables); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withDocker(ModelEnvironmentDefinitionResponseDocker docker) { - super.withDocker(docker); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withSpark(ModelEnvironmentDefinitionResponseSpark spark) { - super.withSpark(spark); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withR(ModelEnvironmentDefinitionResponseR r) { - super.withR(r); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironment withInferencingStackVersion(String inferencingStackVersion) { - super.withInferencingStackVersion(inferencingStackVersion); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironmentReference.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironmentReference.java deleted file mode 100644 index 44e3884772b45..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironmentReference.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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The unique identifying details of the AZURE ML environment. */ -@Immutable -public final class EnvironmentImageResponseEnvironmentReference extends EnvironmentReference { - @JsonIgnore - private final ClientLogger logger = new ClientLogger(EnvironmentImageResponseEnvironmentReference.class); - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironmentReference withName(String name) { - super.withName(name); - return this; - } - - /** {@inheritDoc} */ - @Override - public EnvironmentImageResponseEnvironmentReference withVersion(String version) { - super.withVersion(version); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentReference.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentReference.java deleted file mode 100644 index a9fa90eb103cc..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentReference.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The EnvironmentReference model. */ -@Fluent -public class EnvironmentReference { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EnvironmentReference.class); - - /* - * Name of the environment. - */ - @JsonProperty(value = "name") - private String name; - - /* - * Version of the environment. - */ - @JsonProperty(value = "version") - private String version; - - /** - * Get the name property: Name of the environment. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: Name of the environment. - * - * @param name the name value to set. - * @return the EnvironmentReference object itself. - */ - public EnvironmentReference withName(String name) { - this.name = name; - return this; - } - - /** - * Get the version property: Version of the environment. - * - * @return the version value. - */ - public String version() { - return this.version; - } - - /** - * Set the version property: Version of the environment. - * - * @param version the version value to set. - * @return the EnvironmentReference object itself. - */ - public EnvironmentReference withVersion(String version) { - this.version = version; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrice.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrice.java index 2fa6057aac106..2cb70ea1118fe 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrice.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrice.java @@ -6,34 +6,31 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The estimated price info for using a VM of a particular OS type, tier, etc. */ @Fluent public final class EstimatedVMPrice { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EstimatedVMPrice.class); - /* - * The price charged for using the VM. + * Retail price The price charged for using the VM. */ @JsonProperty(value = "retailPrice", required = true) private double retailPrice; /* - * Operating system type used by the VM. + * OS type Operating system type used by the VM. */ @JsonProperty(value = "osType", required = true) private VMPriceOSType osType; /* - * The type of the VM. + * VM tier The type of the VM. */ @JsonProperty(value = "vmTier", required = true) private VMTier vmTier; /** - * Get the retailPrice property: The price charged for using the VM. + * Get the retailPrice property: Retail price The price charged for using the VM. * * @return the retailPrice value. */ @@ -42,7 +39,7 @@ public double retailPrice() { } /** - * Set the retailPrice property: The price charged for using the VM. + * Set the retailPrice property: Retail price The price charged for using the VM. * * @param retailPrice the retailPrice value to set. * @return the EstimatedVMPrice object itself. @@ -53,7 +50,7 @@ public EstimatedVMPrice withRetailPrice(double retailPrice) { } /** - * Get the osType property: Operating system type used by the VM. + * Get the osType property: OS type Operating system type used by the VM. * * @return the osType value. */ @@ -62,7 +59,7 @@ public VMPriceOSType osType() { } /** - * Set the osType property: Operating system type used by the VM. + * Set the osType property: OS type Operating system type used by the VM. * * @param osType the osType value to set. * @return the EstimatedVMPrice object itself. @@ -73,7 +70,7 @@ public EstimatedVMPrice withOsType(VMPriceOSType osType) { } /** - * Get the vmTier property: The type of the VM. + * Get the vmTier property: VM tier The type of the VM. * * @return the vmTier value. */ @@ -82,7 +79,7 @@ public VMTier vmTier() { } /** - * Set the vmTier property: The type of the VM. + * Set the vmTier property: VM tier The type of the VM. * * @param vmTier the vmTier value to set. * @return the EstimatedVMPrice object itself. @@ -99,14 +96,16 @@ public EstimatedVMPrice withVmTier(VMTier vmTier) { */ public void validate() { if (osType() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property osType in model EstimatedVMPrice")); } if (vmTier() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property vmTier in model EstimatedVMPrice")); } } + + private static final ClientLogger LOGGER = new ClientLogger(EstimatedVMPrice.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrices.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrices.java index f9a9e8e327015..4bfac165042e6 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrices.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EstimatedVMPrices.java @@ -6,38 +6,36 @@ 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.List; /** The estimated price info for using a VM. */ @Fluent public final class EstimatedVMPrices { - @JsonIgnore private final ClientLogger logger = new ClientLogger(EstimatedVMPrices.class); - /* - * Three lettered code specifying the currency of the VM price. Example: - * USD + * Billing currency Three lettered code specifying the currency of the VM + * price. Example: USD */ @JsonProperty(value = "billingCurrency", required = true) private BillingCurrency billingCurrency; /* - * The unit of time measurement for the specified VM price. Example: - * OneHour + * Unit of time measure The unit of time measurement for the specified VM + * price. Example: OneHour */ @JsonProperty(value = "unitOfMeasure", required = true) private UnitOfMeasure unitOfMeasure; /* - * The list of estimated prices for using a VM of a particular OS type, - * tier, etc. + * List of estimated VM prices. The list of estimated prices for using a VM + * of a particular OS type, tier, etc. */ @JsonProperty(value = "values", required = true) private List values; /** - * Get the billingCurrency property: Three lettered code specifying the currency of the VM price. Example: USD. + * Get the billingCurrency property: Billing currency Three lettered code specifying the currency of the VM price. + * Example: USD. * * @return the billingCurrency value. */ @@ -46,7 +44,8 @@ public BillingCurrency billingCurrency() { } /** - * Set the billingCurrency property: Three lettered code specifying the currency of the VM price. Example: USD. + * Set the billingCurrency property: Billing currency Three lettered code specifying the currency of the VM price. + * Example: USD. * * @param billingCurrency the billingCurrency value to set. * @return the EstimatedVMPrices object itself. @@ -57,7 +56,8 @@ public EstimatedVMPrices withBillingCurrency(BillingCurrency billingCurrency) { } /** - * Get the unitOfMeasure property: The unit of time measurement for the specified VM price. Example: OneHour. + * Get the unitOfMeasure property: Unit of time measure The unit of time measurement for the specified VM price. + * Example: OneHour. * * @return the unitOfMeasure value. */ @@ -66,7 +66,8 @@ public UnitOfMeasure unitOfMeasure() { } /** - * Set the unitOfMeasure property: The unit of time measurement for the specified VM price. Example: OneHour. + * Set the unitOfMeasure property: Unit of time measure The unit of time measurement for the specified VM price. + * Example: OneHour. * * @param unitOfMeasure the unitOfMeasure value to set. * @return the EstimatedVMPrices object itself. @@ -77,7 +78,8 @@ public EstimatedVMPrices withUnitOfMeasure(UnitOfMeasure unitOfMeasure) { } /** - * Get the values property: The list of estimated prices for using a VM of a particular OS type, tier, etc. + * Get the values property: List of estimated VM prices. The list of estimated prices for using a VM of a particular + * OS type, tier, etc. * * @return the values value. */ @@ -86,7 +88,8 @@ public List values() { } /** - * Set the values property: The list of estimated prices for using a VM of a particular OS type, tier, etc. + * Set the values property: List of estimated VM prices. The list of estimated prices for using a VM of a particular + * OS type, tier, etc. * * @param values the values value to set. * @return the EstimatedVMPrices object itself. @@ -103,22 +106,24 @@ public EstimatedVMPrices withValues(List values) { */ public void validate() { if (billingCurrency() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property billingCurrency in model EstimatedVMPrices")); } if (unitOfMeasure() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property unitOfMeasure in model EstimatedVMPrices")); } if (values() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property values in model EstimatedVMPrices")); } else { values().forEach(e -> e.validate()); } } + + private static final ClientLogger LOGGER = new ClientLogger(EstimatedVMPrices.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ExternalFqdnResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ExternalFqdnResponse.java new file mode 100644 index 0000000000000..b271348a8515f --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ExternalFqdnResponse.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner; +import java.util.List; + +/** An immutable client-side representation of ExternalFqdnResponse. */ +public interface ExternalFqdnResponse { + /** + * Gets the value property: The value property. + * + * @return the value value. + */ + List value(); + + /** + * Gets the inner com.azure.resourcemanager.machinelearningservices.fluent.models.ExternalFqdnResponseInner object. + * + * @return the inner object. + */ + ExternalFqdnResponseInner innerModel(); +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoint.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoint.java new file mode 100644 index 0000000000000..e4c4fdca4b312 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoint.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The FqdnEndpoint model. */ +@Fluent +public final class FqdnEndpoint { + /* + * The domainName property. + */ + @JsonProperty(value = "domainName") + private String domainName; + + /* + * The endpointDetails property. + */ + @JsonProperty(value = "endpointDetails") + private List endpointDetails; + + /** + * Get the domainName property: The domainName property. + * + * @return the domainName value. + */ + public String domainName() { + return this.domainName; + } + + /** + * Set the domainName property: The domainName property. + * + * @param domainName the domainName value to set. + * @return the FqdnEndpoint object itself. + */ + public FqdnEndpoint withDomainName(String domainName) { + this.domainName = domainName; + return this; + } + + /** + * Get the endpointDetails property: The endpointDetails property. + * + * @return the endpointDetails value. + */ + public List endpointDetails() { + return this.endpointDetails; + } + + /** + * Set the endpointDetails property: The endpointDetails property. + * + * @param endpointDetails the endpointDetails value to set. + * @return the FqdnEndpoint object itself. + */ + public FqdnEndpoint withEndpointDetails(List endpointDetails) { + this.endpointDetails = endpointDetails; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (endpointDetails() != null) { + endpointDetails().forEach(e -> e.validate()); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointDetail.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointDetail.java new file mode 100644 index 0000000000000..e72b427894db1 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointDetail.java @@ -0,0 +1,46 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The FqdnEndpointDetail model. */ +@Fluent +public final class FqdnEndpointDetail { + /* + * The port property. + */ + @JsonProperty(value = "port") + private Integer port; + + /** + * Get the port property: The port property. + * + * @return the port value. + */ + public Integer port() { + return this.port; + } + + /** + * Set the port property: The port property. + * + * @param port the port value to set. + * @return the FqdnEndpointDetail object itself. + */ + public FqdnEndpointDetail withPort(Integer port) { + this.port = port; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoints.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoints.java new file mode 100644 index 0000000000000..17b1df1d4f6c2 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoints.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The FqdnEndpoints model. */ +@Fluent +public final class FqdnEndpoints { + /* + * The properties property. + */ + @JsonProperty(value = "properties") + private FqdnEndpointsProperties properties; + + /** + * Get the properties property: The properties property. + * + * @return the properties value. + */ + public FqdnEndpointsProperties properties() { + return this.properties; + } + + /** + * Set the properties property: The properties property. + * + * @param properties the properties value to set. + * @return the FqdnEndpoints object itself. + */ + public FqdnEndpoints withProperties(FqdnEndpointsProperties properties) { + this.properties = properties; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (properties() != null) { + properties().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointsProperties.java new file mode 100644 index 0000000000000..3b9fafcc353b5 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointsProperties.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The FqdnEndpointsProperties model. */ +@Fluent +public final class FqdnEndpointsProperties { + /* + * The category property. + */ + @JsonProperty(value = "category") + private String category; + + /* + * The endpoints property. + */ + @JsonProperty(value = "endpoints") + private List endpoints; + + /** + * Get the category property: The category property. + * + * @return the category value. + */ + public String category() { + return this.category; + } + + /** + * Set the category property: The category property. + * + * @param category the category value to set. + * @return the FqdnEndpointsProperties object itself. + */ + public FqdnEndpointsProperties withCategory(String category) { + this.category = category; + return this; + } + + /** + * Get the endpoints property: The endpoints property. + * + * @return the endpoints value. + */ + public List endpoints() { + return this.endpoints; + } + + /** + * Set the endpoints property: The endpoints property. + * + * @param endpoints the endpoints value to set. + * @return the FqdnEndpointsProperties object itself. + */ + public FqdnEndpointsProperties withEndpoints(List endpoints) { + this.endpoints = endpoints; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (endpoints() != null) { + endpoints().forEach(e -> e.validate()); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsight.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsight.java index e825b22ae52a1..fb8bb84fe6dbe 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsight.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsight.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,16 +14,14 @@ @JsonTypeName("HDInsight") @Fluent public final class HDInsight extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(HDInsight.class); - /* - * The properties property. + * HDInsight compute properties */ @JsonProperty(value = "properties") private HDInsightProperties properties; /** - * Get the properties property: The properties property. + * Get the properties property: HDInsight compute properties. * * @return the properties value. */ @@ -34,7 +30,7 @@ public HDInsightProperties properties() { } /** - * Set the properties property: The properties property. + * Set the properties property: HDInsight compute properties. * * @param properties the properties value to set. * @return the HDInsight object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsightProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsightProperties.java index 09716e6cd52ce..f484107944f6f 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsightProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/HDInsightProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** The HDInsightProperties model. */ +/** HDInsight compute properties. */ @Fluent public final class HDInsightProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(HDInsightProperties.class); - /* * Port open for ssh connections on the master node of the cluster. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Identity.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Identity.java index 0031081c73667..529716114e068 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Identity.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Identity.java @@ -5,16 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.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.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; /** Identity for the resource. */ @Fluent public class Identity { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Identity.class); - /* * The principal ID of resource identity. */ @@ -37,6 +34,7 @@ public class Identity { * The user assigned identities associated with the resource. */ @JsonProperty(value = "userAssignedIdentities") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) private Map userAssignedIdentities; /** diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/IdentityForCmk.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/IdentityForCmk.java index e518959e77ccf..afea83caed132 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/IdentityForCmk.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/IdentityForCmk.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Identity that will be used to access key vault for encryption at rest. */ @Fluent public final class IdentityForCmk { - @JsonIgnore private final ClientLogger logger = new ClientLogger(IdentityForCmk.class); - /* * The ArmId of the user assigned identity that will be used to access the * customer managed key vault diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ImageAsset.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ImageAsset.java deleted file mode 100644 index 66bfe78287b36..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ImageAsset.java +++ /dev/null @@ -1,128 +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.machinelearningservices.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; - -/** An Image asset. */ -@Fluent -public final class ImageAsset { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ImageAsset.class); - - /* - * The Asset Id. - */ - @JsonProperty(value = "id") - private String id; - - /* - * The mime type. - */ - @JsonProperty(value = "mimeType") - private String mimeType; - - /* - * The Url of the Asset. - */ - @JsonProperty(value = "url") - private String url; - - /* - * Whether the Asset is unpacked. - */ - @JsonProperty(value = "unpack") - private Boolean unpack; - - /** - * Get the id property: The Asset Id. - * - * @return the id value. - */ - public String id() { - return this.id; - } - - /** - * Set the id property: The Asset Id. - * - * @param id the id value to set. - * @return the ImageAsset object itself. - */ - public ImageAsset withId(String id) { - this.id = id; - return this; - } - - /** - * Get the mimeType property: The mime type. - * - * @return the mimeType value. - */ - public String mimeType() { - return this.mimeType; - } - - /** - * Set the mimeType property: The mime type. - * - * @param mimeType the mimeType value to set. - * @return the ImageAsset object itself. - */ - public ImageAsset withMimeType(String mimeType) { - this.mimeType = mimeType; - return this; - } - - /** - * Get the url property: The Url of the Asset. - * - * @return the url value. - */ - public String url() { - return this.url; - } - - /** - * Set the url property: The Url of the Asset. - * - * @param url the url value to set. - * @return the ImageAsset object itself. - */ - public ImageAsset withUrl(String url) { - this.url = url; - return this; - } - - /** - * Get the unpack property: Whether the Asset is unpacked. - * - * @return the unpack value. - */ - public Boolean unpack() { - return this.unpack; - } - - /** - * Set the unpack property: Whether the Asset is unpacked. - * - * @param unpack the unpack value to set. - * @return the ImageAsset object itself. - */ - public ImageAsset withUnpack(Boolean unpack) { - this.unpack = unpack; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchema.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchema.java new file mode 100644 index 0000000000000..42df13661f4a2 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchema.java @@ -0,0 +1,78 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Instance type schema. */ +@Fluent +public final class InstanceTypeSchema { + /* + * Node Selector + */ + @JsonProperty(value = "nodeSelector") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map nodeSelector; + + /* + * Resource requests/limits for this instance type + */ + @JsonProperty(value = "resources") + private InstanceTypeSchemaResources resources; + + /** + * Get the nodeSelector property: Node Selector. + * + * @return the nodeSelector value. + */ + public Map nodeSelector() { + return this.nodeSelector; + } + + /** + * Set the nodeSelector property: Node Selector. + * + * @param nodeSelector the nodeSelector value to set. + * @return the InstanceTypeSchema object itself. + */ + public InstanceTypeSchema withNodeSelector(Map nodeSelector) { + this.nodeSelector = nodeSelector; + return this; + } + + /** + * Get the resources property: Resource requests/limits for this instance type. + * + * @return the resources value. + */ + public InstanceTypeSchemaResources resources() { + return this.resources; + } + + /** + * Set the resources property: Resource requests/limits for this instance type. + * + * @param resources the resources value to set. + * @return the InstanceTypeSchema object itself. + */ + public InstanceTypeSchema withResources(InstanceTypeSchemaResources resources) { + this.resources = resources; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (resources() != null) { + resources().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchemaResources.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchemaResources.java new file mode 100644 index 0000000000000..d35ef07cab9f0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchemaResources.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Resource requests/limits for this instance type. */ +@Fluent +public final class InstanceTypeSchemaResources { + /* + * Resource requests for this instance type + */ + @JsonProperty(value = "requests") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map requests; + + /* + * Resource limits for this instance type + */ + @JsonProperty(value = "limits") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map limits; + + /** + * Get the requests property: Resource requests for this instance type. + * + * @return the requests value. + */ + public Map requests() { + return this.requests; + } + + /** + * Set the requests property: Resource requests for this instance type. + * + * @param requests the requests value to set. + * @return the InstanceTypeSchemaResources object itself. + */ + public InstanceTypeSchemaResources withRequests(Map requests) { + this.requests = requests; + return this; + } + + /** + * Get the limits property: Resource limits for this instance type. + * + * @return the limits value. + */ + public Map limits() { + return this.limits; + } + + /** + * Set the limits property: Resource limits for this instance type. + * + * @param limits the limits value to set. + * @return the InstanceTypeSchemaResources object itself. + */ + public InstanceTypeSchemaResources withLimits(Map limits) { + this.limits = limits; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KeyVaultProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KeyVaultProperties.java index 97fe28248bb73..3bbb5b6e68b6b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KeyVaultProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KeyVaultProperties.java @@ -6,14 +6,11 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The KeyVaultProperties model. */ @Fluent public final class KeyVaultProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(KeyVaultProperties.class); - /* * The ArmId of the keyVault where the customer owned encryption key is * present. @@ -103,16 +100,18 @@ public KeyVaultProperties withIdentityClientId(String identityClientId) { */ public void validate() { if (keyVaultArmId() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property keyVaultArmId in model KeyVaultProperties")); } if (keyIdentifier() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property keyIdentifier in model KeyVaultProperties")); } } + + private static final ClientLogger LOGGER = new ClientLogger(KeyVaultProperties.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java new file mode 100644 index 0000000000000..6585644e7f065 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java @@ -0,0 +1,83 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; +import com.fasterxml.jackson.annotation.JsonTypeInfo; +import com.fasterxml.jackson.annotation.JsonTypeName; + +/** A Machine Learning compute based on Kubernetes Compute. */ +@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "computeType") +@JsonTypeName("Kubernetes") +@Fluent +public final class Kubernetes extends Compute { + /* + * Properties of Kubernetes + */ + @JsonProperty(value = "properties") + private KubernetesProperties properties; + + /** + * Get the properties property: Properties of Kubernetes. + * + * @return the properties value. + */ + public KubernetesProperties properties() { + return this.properties; + } + + /** + * Set the properties property: Properties of Kubernetes. + * + * @param properties the properties value to set. + * @return the Kubernetes object itself. + */ + public Kubernetes withProperties(KubernetesProperties properties) { + this.properties = properties; + return this; + } + + /** {@inheritDoc} */ + @Override + public Kubernetes withComputeLocation(String computeLocation) { + super.withComputeLocation(computeLocation); + return this; + } + + /** {@inheritDoc} */ + @Override + public Kubernetes withDescription(String description) { + super.withDescription(description); + return this; + } + + /** {@inheritDoc} */ + @Override + public Kubernetes withResourceId(String resourceId) { + super.withResourceId(resourceId); + return this; + } + + /** {@inheritDoc} */ + @Override + public Kubernetes withDisableLocalAuth(Boolean disableLocalAuth) { + super.withDisableLocalAuth(disableLocalAuth); + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + @Override + public void validate() { + super.validate(); + if (properties() != null) { + properties().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesProperties.java new file mode 100644 index 0000000000000..8db54468179ef --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesProperties.java @@ -0,0 +1,241 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Kubernetes properties. */ +@Fluent +public final class KubernetesProperties { + /* + * Relay connection string. + */ + @JsonProperty(value = "relayConnectionString") + private String relayConnectionString; + + /* + * ServiceBus connection string. + */ + @JsonProperty(value = "serviceBusConnectionString") + private String serviceBusConnectionString; + + /* + * Extension principal-id. + */ + @JsonProperty(value = "extensionPrincipalId") + private String extensionPrincipalId; + + /* + * Extension instance release train. + */ + @JsonProperty(value = "extensionInstanceReleaseTrain") + private String extensionInstanceReleaseTrain; + + /* + * VC name. + */ + @JsonProperty(value = "vcName") + private String vcName; + + /* + * Compute namespace + */ + @JsonProperty(value = "namespace") + private String namespace; + + /* + * Default instance type + */ + @JsonProperty(value = "defaultInstanceType") + private String defaultInstanceType; + + /* + * Instance Type Schema + */ + @JsonProperty(value = "instanceTypes") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map instanceTypes; + + /** + * Get the relayConnectionString property: Relay connection string. + * + * @return the relayConnectionString value. + */ + public String relayConnectionString() { + return this.relayConnectionString; + } + + /** + * Set the relayConnectionString property: Relay connection string. + * + * @param relayConnectionString the relayConnectionString value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withRelayConnectionString(String relayConnectionString) { + this.relayConnectionString = relayConnectionString; + return this; + } + + /** + * Get the serviceBusConnectionString property: ServiceBus connection string. + * + * @return the serviceBusConnectionString value. + */ + public String serviceBusConnectionString() { + return this.serviceBusConnectionString; + } + + /** + * Set the serviceBusConnectionString property: ServiceBus connection string. + * + * @param serviceBusConnectionString the serviceBusConnectionString value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withServiceBusConnectionString(String serviceBusConnectionString) { + this.serviceBusConnectionString = serviceBusConnectionString; + return this; + } + + /** + * Get the extensionPrincipalId property: Extension principal-id. + * + * @return the extensionPrincipalId value. + */ + public String extensionPrincipalId() { + return this.extensionPrincipalId; + } + + /** + * Set the extensionPrincipalId property: Extension principal-id. + * + * @param extensionPrincipalId the extensionPrincipalId value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withExtensionPrincipalId(String extensionPrincipalId) { + this.extensionPrincipalId = extensionPrincipalId; + return this; + } + + /** + * Get the extensionInstanceReleaseTrain property: Extension instance release train. + * + * @return the extensionInstanceReleaseTrain value. + */ + public String extensionInstanceReleaseTrain() { + return this.extensionInstanceReleaseTrain; + } + + /** + * Set the extensionInstanceReleaseTrain property: Extension instance release train. + * + * @param extensionInstanceReleaseTrain the extensionInstanceReleaseTrain value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withExtensionInstanceReleaseTrain(String extensionInstanceReleaseTrain) { + this.extensionInstanceReleaseTrain = extensionInstanceReleaseTrain; + return this; + } + + /** + * Get the vcName property: VC name. + * + * @return the vcName value. + */ + public String vcName() { + return this.vcName; + } + + /** + * Set the vcName property: VC name. + * + * @param vcName the vcName value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withVcName(String vcName) { + this.vcName = vcName; + return this; + } + + /** + * Get the namespace property: Compute namespace. + * + * @return the namespace value. + */ + public String namespace() { + return this.namespace; + } + + /** + * Set the namespace property: Compute namespace. + * + * @param namespace the namespace value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withNamespace(String namespace) { + this.namespace = namespace; + return this; + } + + /** + * Get the defaultInstanceType property: Default instance type. + * + * @return the defaultInstanceType value. + */ + public String defaultInstanceType() { + return this.defaultInstanceType; + } + + /** + * Set the defaultInstanceType property: Default instance type. + * + * @param defaultInstanceType the defaultInstanceType value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withDefaultInstanceType(String defaultInstanceType) { + this.defaultInstanceType = defaultInstanceType; + return this; + } + + /** + * Get the instanceTypes property: Instance Type Schema. + * + * @return the instanceTypes value. + */ + public Map instanceTypes() { + return this.instanceTypes; + } + + /** + * Set the instanceTypes property: Instance Type Schema. + * + * @param instanceTypes the instanceTypes value to set. + * @return the KubernetesProperties object itself. + */ + public KubernetesProperties withInstanceTypes(Map instanceTypes) { + this.instanceTypes = instanceTypes; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (instanceTypes() != null) { + instanceTypes() + .values() + .forEach( + e -> { + if (e != null) { + e.validate(); + } + }); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesSchema.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesSchema.java new file mode 100644 index 0000000000000..239c703a3b414 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesSchema.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Kubernetes Compute Schema. */ +@Fluent +public class KubernetesSchema { + /* + * Properties of Kubernetes + */ + @JsonProperty(value = "properties") + private KubernetesProperties properties; + + /** + * Get the properties property: Properties of Kubernetes. + * + * @return the properties value. + */ + public KubernetesProperties properties() { + return this.properties; + } + + /** + * Set the properties property: Properties of Kubernetes. + * + * @param properties the properties value to set. + * @return the KubernetesSchema object itself. + */ + public KubernetesSchema withProperties(KubernetesProperties properties) { + this.properties = properties; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (properties() != null) { + properties().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListAmlUserFeatureResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListAmlUserFeatureResult.java index 514e183c87d92..3883cb7fcf28a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListAmlUserFeatureResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListAmlUserFeatureResult.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.AmlUserFeatureInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The List Aml user feature operation response. */ @Immutable public final class ListAmlUserFeatureResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListAmlUserFeatureResult.class); - /* * The list of AML user facing features. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListUsagesResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListUsagesResult.java index 9c9368d772a29..3b0c8ad5f839d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListUsagesResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListUsagesResult.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.UsageInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The List Usages operation response. */ @Immutable public final class ListUsagesResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListUsagesResult.class); - /* * The list of AML resource usages. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListWorkspaceQuotas.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListWorkspaceQuotas.java index 555fca684dd37..b3cd5494583c1 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListWorkspaceQuotas.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ListWorkspaceQuotas.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.ResourceQuotaInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The List WorkspaceQuotasByVMFamily operation response. */ @Immutable public final class ListWorkspaceQuotas { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ListWorkspaceQuotas.class); - /* * The list of Workspace Quotas by VM Family */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LivenessProbeRequirements.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LivenessProbeRequirements.java deleted file mode 100644 index 23ef4ce23e195..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LivenessProbeRequirements.java +++ /dev/null @@ -1,154 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The liveness probe requirements. */ -@Fluent -public class LivenessProbeRequirements { - @JsonIgnore private final ClientLogger logger = new ClientLogger(LivenessProbeRequirements.class); - - /* - * The number of failures to allow before returning an unhealthy status. - */ - @JsonProperty(value = "failureThreshold") - private Integer failureThreshold; - - /* - * The number of successful probes before returning a healthy status. - */ - @JsonProperty(value = "successThreshold") - private Integer successThreshold; - - /* - * The probe timeout in seconds. - */ - @JsonProperty(value = "timeoutSeconds") - private Integer timeoutSeconds; - - /* - * The length of time between probes in seconds. - */ - @JsonProperty(value = "periodSeconds") - private Integer periodSeconds; - - /* - * The delay before the first probe in seconds. - */ - @JsonProperty(value = "initialDelaySeconds") - private Integer initialDelaySeconds; - - /** - * Get the failureThreshold property: The number of failures to allow before returning an unhealthy status. - * - * @return the failureThreshold value. - */ - public Integer failureThreshold() { - return this.failureThreshold; - } - - /** - * Set the failureThreshold property: The number of failures to allow before returning an unhealthy status. - * - * @param failureThreshold the failureThreshold value to set. - * @return the LivenessProbeRequirements object itself. - */ - public LivenessProbeRequirements withFailureThreshold(Integer failureThreshold) { - this.failureThreshold = failureThreshold; - return this; - } - - /** - * Get the successThreshold property: The number of successful probes before returning a healthy status. - * - * @return the successThreshold value. - */ - public Integer successThreshold() { - return this.successThreshold; - } - - /** - * Set the successThreshold property: The number of successful probes before returning a healthy status. - * - * @param successThreshold the successThreshold value to set. - * @return the LivenessProbeRequirements object itself. - */ - public LivenessProbeRequirements withSuccessThreshold(Integer successThreshold) { - this.successThreshold = successThreshold; - return this; - } - - /** - * Get the timeoutSeconds property: The probe timeout in seconds. - * - * @return the timeoutSeconds value. - */ - public Integer timeoutSeconds() { - return this.timeoutSeconds; - } - - /** - * Set the timeoutSeconds property: The probe timeout in seconds. - * - * @param timeoutSeconds the timeoutSeconds value to set. - * @return the LivenessProbeRequirements object itself. - */ - public LivenessProbeRequirements withTimeoutSeconds(Integer timeoutSeconds) { - this.timeoutSeconds = timeoutSeconds; - return this; - } - - /** - * Get the periodSeconds property: The length of time between probes in seconds. - * - * @return the periodSeconds value. - */ - public Integer periodSeconds() { - return this.periodSeconds; - } - - /** - * Set the periodSeconds property: The length of time between probes in seconds. - * - * @param periodSeconds the periodSeconds value to set. - * @return the LivenessProbeRequirements object itself. - */ - public LivenessProbeRequirements withPeriodSeconds(Integer periodSeconds) { - this.periodSeconds = periodSeconds; - return this; - } - - /** - * Get the initialDelaySeconds property: The delay before the first probe in seconds. - * - * @return the initialDelaySeconds value. - */ - public Integer initialDelaySeconds() { - return this.initialDelaySeconds; - } - - /** - * Set the initialDelaySeconds property: The delay before the first probe in seconds. - * - * @param initialDelaySeconds the initialDelaySeconds value to set. - * @return the LivenessProbeRequirements object itself. - */ - public LivenessProbeRequirements withInitialDelaySeconds(Integer initialDelaySeconds) { - this.initialDelaySeconds = initialDelaySeconds; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LoadBalancerType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LoadBalancerType.java index 53f6f45d5da28..e76253b43df45 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LoadBalancerType.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LoadBalancerType.java @@ -27,7 +27,11 @@ public static LoadBalancerType fromString(String name) { return fromString(name, LoadBalancerType.class); } - /** @return known LoadBalancerType values. */ + /** + * Gets known LoadBalancerType values. + * + * @return known LoadBalancerType values. + */ public static Collection values() { return values(LoadBalancerType.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateHeaders.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateHeaders.java deleted file mode 100644 index 740f059743e84..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateHeaders.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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The MachineLearningComputesCreateOrUpdateHeaders model. */ -@Fluent -public final class MachineLearningComputesCreateOrUpdateHeaders { - @JsonIgnore - private final ClientLogger logger = new ClientLogger(MachineLearningComputesCreateOrUpdateHeaders.class); - - /* - * The Azure-AsyncOperation property. - */ - @JsonProperty(value = "Azure-AsyncOperation") - private String azureAsyncOperation; - - /** - * Get the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @return the azureAsyncOperation value. - */ - public String azureAsyncOperation() { - return this.azureAsyncOperation; - } - - /** - * Set the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @param azureAsyncOperation the azureAsyncOperation value to set. - * @return the MachineLearningComputesCreateOrUpdateHeaders object itself. - */ - public MachineLearningComputesCreateOrUpdateHeaders withAzureAsyncOperation(String azureAsyncOperation) { - this.azureAsyncOperation = azureAsyncOperation; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateResponse.java deleted file mode 100644 index a30e727835bd4..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateResponse.java +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.models; - -import com.azure.core.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeResourceInner; - -/** Contains all response data for the createOrUpdate operation. */ -public final class MachineLearningComputesCreateOrUpdateResponse - extends ResponseBase { - /** - * Creates an instance of MachineLearningComputesCreateOrUpdateResponse. - * - * @param request the request which resulted in this MachineLearningComputesCreateOrUpdateResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public MachineLearningComputesCreateOrUpdateResponse( - HttpRequest request, - int statusCode, - HttpHeaders rawHeaders, - ComputeResourceInner value, - MachineLearningComputesCreateOrUpdateHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } - - /** @return the deserialized response body. */ - @Override - public ComputeResourceInner getValue() { - return super.getValue(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteHeaders.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteHeaders.java deleted file mode 100644 index b8600ac86e2f8..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteHeaders.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The MachineLearningComputesDeleteHeaders model. */ -@Fluent -public final class MachineLearningComputesDeleteHeaders { - @JsonIgnore private final ClientLogger logger = new ClientLogger(MachineLearningComputesDeleteHeaders.class); - - /* - * The Azure-AsyncOperation property. - */ - @JsonProperty(value = "Azure-AsyncOperation") - private String azureAsyncOperation; - - /* - * The Location property. - */ - @JsonProperty(value = "Location") - private String location; - - /** - * Get the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @return the azureAsyncOperation value. - */ - public String azureAsyncOperation() { - return this.azureAsyncOperation; - } - - /** - * Set the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @param azureAsyncOperation the azureAsyncOperation value to set. - * @return the MachineLearningComputesDeleteHeaders object itself. - */ - public MachineLearningComputesDeleteHeaders withAzureAsyncOperation(String azureAsyncOperation) { - this.azureAsyncOperation = azureAsyncOperation; - return this; - } - - /** - * Get the location property: The Location property. - * - * @return the location value. - */ - public String location() { - return this.location; - } - - /** - * Set the location property: The Location property. - * - * @param location the location value to set. - * @return the MachineLearningComputesDeleteHeaders object itself. - */ - public MachineLearningComputesDeleteHeaders withLocation(String location) { - this.location = location; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteResponse.java deleted file mode 100644 index b9eec18c74966..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteResponse.java +++ /dev/null @@ -1,31 +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.machinelearningservices.models; - -import com.azure.core.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; - -/** Contains all response data for the delete operation. */ -public final class MachineLearningComputesDeleteResponse - extends ResponseBase { - /** - * Creates an instance of MachineLearningComputesDeleteResponse. - * - * @param request the request which resulted in this MachineLearningComputesDeleteResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public MachineLearningComputesDeleteResponse( - HttpRequest request, - int statusCode, - HttpHeaders rawHeaders, - Void value, - MachineLearningComputesDeleteHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServices.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServices.java deleted file mode 100644 index 8ed27e049b414..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServices.java +++ /dev/null @@ -1,170 +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.machinelearningservices.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 MachineLearningServices. */ -public interface MachineLearningServices { - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @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 services in specified workspace. - */ - PagedIterable listByWorkspace(String resourceGroupName, String workspaceName); - - /** - * Gets services in specified workspace. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param skip Continuation token for pagination. - * @param modelId The Model Id. - * @param modelName The Model name. - * @param tag The object tag. - * @param tags A set of tags with which to filter the returned services. It is a comma separated string of tags key - * or tags key=value Example: tagKey1,tagKey2,tagKey3=value3 . - * @param properties A set of properties with which to filter the returned services. It is a comma separated string - * of properties key and/or properties key=value Example: propKey1,propKey2,propKey3=value3 . - * @param runId runId for model associated with service. - * @param expand Set to True to include Model details. - * @param orderby The option to order the response. - * @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 services in specified workspace. - */ - PagedIterable listByWorkspace( - String resourceGroupName, - String workspaceName, - String skip, - String modelId, - String modelName, - String tag, - String tags, - String properties, - String runId, - Boolean expand, - OrderString orderby, - Context context); - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - ServiceResource get(String resourceGroupName, String workspaceName, String serviceName); - - /** - * Get a Service by name. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param expand Set to True to include Model details. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - Response getWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Boolean expand, Context context); - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @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 workspaceName, String serviceName); - - /** - * Delete a specific Service.. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param serviceName Name of the Azure Machine Learning service. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - Response deleteWithResponse( - String resourceGroupName, String workspaceName, String serviceName, Context context); - - /** - * Get a Service by name. - * - * @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 a Service by name. - */ - ServiceResource getById(String id); - - /** - * Get a Service by name. - * - * @param id the resource ID. - * @param expand Set to True to include Model details. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return a Service by name. - */ - Response getByIdWithResponse(String id, Boolean expand, Context context); - - /** - * Delete a specific Service.. - * - * @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 a specific Service.. - * - * @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 the response. - */ - Response deleteByIdWithResponse(String id, Context context); - - /** - * Begins definition for a new ServiceResource resource. - * - * @param name resource name. - * @return the first stage of the new ServiceResource definition. - */ - ServiceResource.DefinitionStages.Blank define(String name); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateHeaders.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateHeaders.java deleted file mode 100644 index b29ece78b30bb..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateHeaders.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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The MachineLearningServicesCreateOrUpdateHeaders model. */ -@Fluent -public final class MachineLearningServicesCreateOrUpdateHeaders { - @JsonIgnore - private final ClientLogger logger = new ClientLogger(MachineLearningServicesCreateOrUpdateHeaders.class); - - /* - * The Azure-AsyncOperation property. - */ - @JsonProperty(value = "Azure-AsyncOperation") - private String azureAsyncOperation; - - /** - * Get the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @return the azureAsyncOperation value. - */ - public String azureAsyncOperation() { - return this.azureAsyncOperation; - } - - /** - * Set the azureAsyncOperation property: The Azure-AsyncOperation property. - * - * @param azureAsyncOperation the azureAsyncOperation value to set. - * @return the MachineLearningServicesCreateOrUpdateHeaders object itself. - */ - public MachineLearningServicesCreateOrUpdateHeaders withAzureAsyncOperation(String azureAsyncOperation) { - this.azureAsyncOperation = azureAsyncOperation; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateResponse.java deleted file mode 100644 index bb074ed812a7d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateResponse.java +++ /dev/null @@ -1,38 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.models; - -import com.azure.core.http.HttpHeaders; -import com.azure.core.http.HttpRequest; -import com.azure.core.http.rest.ResponseBase; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; - -/** Contains all response data for the createOrUpdate operation. */ -public final class MachineLearningServicesCreateOrUpdateResponse - extends ResponseBase { - /** - * Creates an instance of MachineLearningServicesCreateOrUpdateResponse. - * - * @param request the request which resulted in this MachineLearningServicesCreateOrUpdateResponse. - * @param statusCode the status code of the HTTP response. - * @param rawHeaders the raw headers of the HTTP response. - * @param value the deserialized value of the HTTP response. - * @param headers the deserialized headers of the HTTP response. - */ - public MachineLearningServicesCreateOrUpdateResponse( - HttpRequest request, - int statusCode, - HttpHeaders rawHeaders, - ServiceResourceInner value, - MachineLearningServicesCreateOrUpdateHeaders headers) { - super(request, statusCode, rawHeaders, value, headers); - } - - /** @return the deserialized response body. */ - @Override - public ServiceResourceInner getValue() { - return super.getValue(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Model.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Model.java deleted file mode 100644 index a2c16f00a778d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Model.java +++ /dev/null @@ -1,601 +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.machinelearningservices.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.time.OffsetDateTime; -import java.util.List; -import java.util.Map; - -/** An Azure Machine Learning Model. */ -@Fluent -public final class Model { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Model.class); - - /* - * The Model Id. - */ - @JsonProperty(value = "id") - private String id; - - /* - * The Model name. - */ - @JsonProperty(value = "name", required = true) - private String name; - - /* - * The Model framework. - */ - @JsonProperty(value = "framework") - private String framework; - - /* - * The Model framework version. - */ - @JsonProperty(value = "frameworkVersion") - private String frameworkVersion; - - /* - * The Model version assigned by Model Management Service. - */ - @JsonProperty(value = "version") - private Long version; - - /* - * The list of datasets associated with the model. - */ - @JsonProperty(value = "datasets") - private List datasets; - - /* - * The URL of the Model. Usually a SAS URL. - */ - @JsonProperty(value = "url", required = true) - private String url; - - /* - * The MIME type of Model content. For more details about MIME type, please - * open https://www.iana.org/assignments/media-types/media-types.xhtml - */ - @JsonProperty(value = "mimeType", required = true) - private String mimeType; - - /* - * The Model description text. - */ - @JsonProperty(value = "description") - private String description; - - /* - * The Model creation time (UTC). - */ - @JsonProperty(value = "createdTime") - private OffsetDateTime createdTime; - - /* - * The Model last modified time (UTC). - */ - @JsonProperty(value = "modifiedTime") - private OffsetDateTime modifiedTime; - - /* - * Indicates whether we need to unpack the Model during docker Image - * creation. - */ - @JsonProperty(value = "unpack") - private Boolean unpack; - - /* - * The Parent Model Id. - */ - @JsonProperty(value = "parentModelId") - private String parentModelId; - - /* - * The RunId that created this model. - */ - @JsonProperty(value = "runId") - private String runId; - - /* - * The name of the experiment where this model was created. - */ - @JsonProperty(value = "experimentName") - private String experimentName; - - /* - * The Model tag dictionary. Items are mutable. - */ - @JsonProperty(value = "kvTags") - private Map kvTags; - - /* - * The Model property dictionary. Properties are immutable. - */ - @JsonProperty(value = "properties") - private Map properties; - - /* - * Models derived from this model - */ - @JsonProperty(value = "derivedModelIds") - private List derivedModelIds; - - /* - * Sample Input Data for the Model. A reference to a dataset in the - * workspace in the format aml://dataset/{datasetId} - */ - @JsonProperty(value = "sampleInputData") - private String sampleInputData; - - /* - * Sample Output Data for the Model. A reference to a dataset in the - * workspace in the format aml://dataset/{datasetId} - */ - @JsonProperty(value = "sampleOutputData") - private String sampleOutputData; - - /* - * Resource requirements for the model - */ - @JsonProperty(value = "resourceRequirements") - private ContainerResourceRequirements resourceRequirements; - - /** - * Get the id property: The Model Id. - * - * @return the id value. - */ - public String id() { - return this.id; - } - - /** - * Set the id property: The Model Id. - * - * @param id the id value to set. - * @return the Model object itself. - */ - public Model withId(String id) { - this.id = id; - return this; - } - - /** - * Get the name property: The Model name. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: The Model name. - * - * @param name the name value to set. - * @return the Model object itself. - */ - public Model withName(String name) { - this.name = name; - return this; - } - - /** - * Get the framework property: The Model framework. - * - * @return the framework value. - */ - public String framework() { - return this.framework; - } - - /** - * Set the framework property: The Model framework. - * - * @param framework the framework value to set. - * @return the Model object itself. - */ - public Model withFramework(String framework) { - this.framework = framework; - return this; - } - - /** - * Get the frameworkVersion property: The Model framework version. - * - * @return the frameworkVersion value. - */ - public String frameworkVersion() { - return this.frameworkVersion; - } - - /** - * Set the frameworkVersion property: The Model framework version. - * - * @param frameworkVersion the frameworkVersion value to set. - * @return the Model object itself. - */ - public Model withFrameworkVersion(String frameworkVersion) { - this.frameworkVersion = frameworkVersion; - return this; - } - - /** - * Get the version property: The Model version assigned by Model Management Service. - * - * @return the version value. - */ - public Long version() { - return this.version; - } - - /** - * Set the version property: The Model version assigned by Model Management Service. - * - * @param version the version value to set. - * @return the Model object itself. - */ - public Model withVersion(Long version) { - this.version = version; - return this; - } - - /** - * Get the datasets property: The list of datasets associated with the model. - * - * @return the datasets value. - */ - public List datasets() { - return this.datasets; - } - - /** - * Set the datasets property: The list of datasets associated with the model. - * - * @param datasets the datasets value to set. - * @return the Model object itself. - */ - public Model withDatasets(List datasets) { - this.datasets = datasets; - return this; - } - - /** - * Get the url property: The URL of the Model. Usually a SAS URL. - * - * @return the url value. - */ - public String url() { - return this.url; - } - - /** - * Set the url property: The URL of the Model. Usually a SAS URL. - * - * @param url the url value to set. - * @return the Model object itself. - */ - public Model withUrl(String url) { - this.url = url; - return this; - } - - /** - * Get the mimeType property: The MIME type of Model content. For more details about MIME type, please open - * https://www.iana.org/assignments/media-types/media-types.xhtml. - * - * @return the mimeType value. - */ - public String mimeType() { - return this.mimeType; - } - - /** - * Set the mimeType property: The MIME type of Model content. For more details about MIME type, please open - * https://www.iana.org/assignments/media-types/media-types.xhtml. - * - * @param mimeType the mimeType value to set. - * @return the Model object itself. - */ - public Model withMimeType(String mimeType) { - this.mimeType = mimeType; - return this; - } - - /** - * Get the description property: The Model description text. - * - * @return the description value. - */ - public String description() { - return this.description; - } - - /** - * Set the description property: The Model description text. - * - * @param description the description value to set. - * @return the Model object itself. - */ - public Model withDescription(String description) { - this.description = description; - return this; - } - - /** - * Get the createdTime property: The Model creation time (UTC). - * - * @return the createdTime value. - */ - public OffsetDateTime createdTime() { - return this.createdTime; - } - - /** - * Set the createdTime property: The Model creation time (UTC). - * - * @param createdTime the createdTime value to set. - * @return the Model object itself. - */ - public Model withCreatedTime(OffsetDateTime createdTime) { - this.createdTime = createdTime; - return this; - } - - /** - * Get the modifiedTime property: The Model last modified time (UTC). - * - * @return the modifiedTime value. - */ - public OffsetDateTime modifiedTime() { - return this.modifiedTime; - } - - /** - * Set the modifiedTime property: The Model last modified time (UTC). - * - * @param modifiedTime the modifiedTime value to set. - * @return the Model object itself. - */ - public Model withModifiedTime(OffsetDateTime modifiedTime) { - this.modifiedTime = modifiedTime; - return this; - } - - /** - * Get the unpack property: Indicates whether we need to unpack the Model during docker Image creation. - * - * @return the unpack value. - */ - public Boolean unpack() { - return this.unpack; - } - - /** - * Set the unpack property: Indicates whether we need to unpack the Model during docker Image creation. - * - * @param unpack the unpack value to set. - * @return the Model object itself. - */ - public Model withUnpack(Boolean unpack) { - this.unpack = unpack; - return this; - } - - /** - * Get the parentModelId property: The Parent Model Id. - * - * @return the parentModelId value. - */ - public String parentModelId() { - return this.parentModelId; - } - - /** - * Set the parentModelId property: The Parent Model Id. - * - * @param parentModelId the parentModelId value to set. - * @return the Model object itself. - */ - public Model withParentModelId(String parentModelId) { - this.parentModelId = parentModelId; - return this; - } - - /** - * Get the runId property: The RunId that created this model. - * - * @return the runId value. - */ - public String runId() { - return this.runId; - } - - /** - * Set the runId property: The RunId that created this model. - * - * @param runId the runId value to set. - * @return the Model object itself. - */ - public Model withRunId(String runId) { - this.runId = runId; - return this; - } - - /** - * Get the experimentName property: The name of the experiment where this model was created. - * - * @return the experimentName value. - */ - public String experimentName() { - return this.experimentName; - } - - /** - * Set the experimentName property: The name of the experiment where this model was created. - * - * @param experimentName the experimentName value to set. - * @return the Model object itself. - */ - public Model withExperimentName(String experimentName) { - this.experimentName = experimentName; - return this; - } - - /** - * Get the kvTags property: The Model tag dictionary. Items are mutable. - * - * @return the kvTags value. - */ - public Map kvTags() { - return this.kvTags; - } - - /** - * Set the kvTags property: The Model tag dictionary. Items are mutable. - * - * @param kvTags the kvTags value to set. - * @return the Model object itself. - */ - public Model withKvTags(Map kvTags) { - this.kvTags = kvTags; - return this; - } - - /** - * Get the properties property: The Model property dictionary. Properties are immutable. - * - * @return the properties value. - */ - public Map properties() { - return this.properties; - } - - /** - * Set the properties property: The Model property dictionary. Properties are immutable. - * - * @param properties the properties value to set. - * @return the Model object itself. - */ - public Model withProperties(Map properties) { - this.properties = properties; - return this; - } - - /** - * Get the derivedModelIds property: Models derived from this model. - * - * @return the derivedModelIds value. - */ - public List derivedModelIds() { - return this.derivedModelIds; - } - - /** - * Set the derivedModelIds property: Models derived from this model. - * - * @param derivedModelIds the derivedModelIds value to set. - * @return the Model object itself. - */ - public Model withDerivedModelIds(List derivedModelIds) { - this.derivedModelIds = derivedModelIds; - return this; - } - - /** - * Get the sampleInputData property: Sample Input Data for the Model. A reference to a dataset in the workspace in - * the format aml://dataset/{datasetId}. - * - * @return the sampleInputData value. - */ - public String sampleInputData() { - return this.sampleInputData; - } - - /** - * Set the sampleInputData property: Sample Input Data for the Model. A reference to a dataset in the workspace in - * the format aml://dataset/{datasetId}. - * - * @param sampleInputData the sampleInputData value to set. - * @return the Model object itself. - */ - public Model withSampleInputData(String sampleInputData) { - this.sampleInputData = sampleInputData; - return this; - } - - /** - * Get the sampleOutputData property: Sample Output Data for the Model. A reference to a dataset in the workspace in - * the format aml://dataset/{datasetId}. - * - * @return the sampleOutputData value. - */ - public String sampleOutputData() { - return this.sampleOutputData; - } - - /** - * Set the sampleOutputData property: Sample Output Data for the Model. A reference to a dataset in the workspace in - * the format aml://dataset/{datasetId}. - * - * @param sampleOutputData the sampleOutputData value to set. - * @return the Model object itself. - */ - public Model withSampleOutputData(String sampleOutputData) { - this.sampleOutputData = sampleOutputData; - return this; - } - - /** - * Get the resourceRequirements property: Resource requirements for the model. - * - * @return the resourceRequirements value. - */ - public ContainerResourceRequirements resourceRequirements() { - return this.resourceRequirements; - } - - /** - * Set the resourceRequirements property: Resource requirements for the model. - * - * @param resourceRequirements the resourceRequirements value to set. - * @return the Model object itself. - */ - public Model withResourceRequirements(ContainerResourceRequirements resourceRequirements) { - this.resourceRequirements = resourceRequirements; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (name() == null) { - throw logger - .logExceptionAsError(new IllegalArgumentException("Missing required property name in model Model")); - } - if (datasets() != null) { - datasets().forEach(e -> e.validate()); - } - if (url() == null) { - throw logger - .logExceptionAsError(new IllegalArgumentException("Missing required property url in model Model")); - } - if (mimeType() == null) { - throw logger - .logExceptionAsError(new IllegalArgumentException("Missing required property mimeType in model Model")); - } - if (resourceRequirements() != null) { - resourceRequirements().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDataCollection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDataCollection.java deleted file mode 100644 index 29190b6886340..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDataCollection.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The Model data collection properties. */ -@Fluent -public class ModelDataCollection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelDataCollection.class); - - /* - * Option for enabling/disabling Event Hub. - */ - @JsonProperty(value = "eventHubEnabled") - private Boolean eventHubEnabled; - - /* - * Option for enabling/disabling storage. - */ - @JsonProperty(value = "storageEnabled") - private Boolean storageEnabled; - - /** - * Get the eventHubEnabled property: Option for enabling/disabling Event Hub. - * - * @return the eventHubEnabled value. - */ - public Boolean eventHubEnabled() { - return this.eventHubEnabled; - } - - /** - * Set the eventHubEnabled property: Option for enabling/disabling Event Hub. - * - * @param eventHubEnabled the eventHubEnabled value to set. - * @return the ModelDataCollection object itself. - */ - public ModelDataCollection withEventHubEnabled(Boolean eventHubEnabled) { - this.eventHubEnabled = eventHubEnabled; - return this; - } - - /** - * Get the storageEnabled property: Option for enabling/disabling storage. - * - * @return the storageEnabled value. - */ - public Boolean storageEnabled() { - return this.storageEnabled; - } - - /** - * Set the storageEnabled property: Option for enabling/disabling storage. - * - * @param storageEnabled the storageEnabled value to set. - * @return the ModelDataCollection object itself. - */ - public ModelDataCollection withStorageEnabled(Boolean storageEnabled) { - this.storageEnabled = storageEnabled; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSection.java deleted file mode 100644 index b19bbe29de9be..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSection.java +++ /dev/null @@ -1,107 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The ModelDockerSection model. */ -@Fluent -public class ModelDockerSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelDockerSection.class); - - /* - * Base image used for Docker-based runs. Mutually exclusive with - * BaseDockerfile. - */ - @JsonProperty(value = "baseImage") - private String baseImage; - - /* - * Base Dockerfile used for Docker-based runs. Mutually exclusive with - * BaseImage. - */ - @JsonProperty(value = "baseDockerfile") - private String baseDockerfile; - - /* - * Image registry that contains the base image. - */ - @JsonProperty(value = "baseImageRegistry") - private ModelDockerSectionBaseImageRegistry baseImageRegistry; - - /** - * Get the baseImage property: Base image used for Docker-based runs. Mutually exclusive with BaseDockerfile. - * - * @return the baseImage value. - */ - public String baseImage() { - return this.baseImage; - } - - /** - * Set the baseImage property: Base image used for Docker-based runs. Mutually exclusive with BaseDockerfile. - * - * @param baseImage the baseImage value to set. - * @return the ModelDockerSection object itself. - */ - public ModelDockerSection withBaseImage(String baseImage) { - this.baseImage = baseImage; - return this; - } - - /** - * Get the baseDockerfile property: Base Dockerfile used for Docker-based runs. Mutually exclusive with BaseImage. - * - * @return the baseDockerfile value. - */ - public String baseDockerfile() { - return this.baseDockerfile; - } - - /** - * Set the baseDockerfile property: Base Dockerfile used for Docker-based runs. Mutually exclusive with BaseImage. - * - * @param baseDockerfile the baseDockerfile value to set. - * @return the ModelDockerSection object itself. - */ - public ModelDockerSection withBaseDockerfile(String baseDockerfile) { - this.baseDockerfile = baseDockerfile; - return this; - } - - /** - * Get the baseImageRegistry property: Image registry that contains the base image. - * - * @return the baseImageRegistry value. - */ - public ModelDockerSectionBaseImageRegistry baseImageRegistry() { - return this.baseImageRegistry; - } - - /** - * Set the baseImageRegistry property: Image registry that contains the base image. - * - * @param baseImageRegistry the baseImageRegistry value to set. - * @return the ModelDockerSection object itself. - */ - public ModelDockerSection withBaseImageRegistry(ModelDockerSectionBaseImageRegistry baseImageRegistry) { - this.baseImageRegistry = baseImageRegistry; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (baseImageRegistry() != null) { - baseImageRegistry().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionBaseImageRegistry.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionBaseImageRegistry.java deleted file mode 100644 index 05f34bf6d7f14..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionBaseImageRegistry.java +++ /dev/null @@ -1,46 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Image registry that contains the base image. */ -@Immutable -public final class ModelDockerSectionBaseImageRegistry extends ContainerRegistry { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelDockerSectionBaseImageRegistry.class); - - /** {@inheritDoc} */ - @Override - public ModelDockerSectionBaseImageRegistry withAddress(String address) { - super.withAddress(address); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelDockerSectionBaseImageRegistry withUsername(String username) { - super.withUsername(username); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelDockerSectionBaseImageRegistry withPassword(String password) { - super.withPassword(password); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponse.java deleted file mode 100644 index bb426053edd59..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponse.java +++ /dev/null @@ -1,108 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The ModelDockerSectionResponse model. */ -@Fluent -public class ModelDockerSectionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelDockerSectionResponse.class); - - /* - * Base image used for Docker-based runs. Mutually exclusive with - * BaseDockerfile. - */ - @JsonProperty(value = "baseImage") - private String baseImage; - - /* - * Base Dockerfile used for Docker-based runs. Mutually exclusive with - * BaseImage. - */ - @JsonProperty(value = "baseDockerfile") - private String baseDockerfile; - - /* - * Image registry that contains the base image. - */ - @JsonProperty(value = "baseImageRegistry") - private ModelDockerSectionResponseBaseImageRegistry baseImageRegistry; - - /** - * Get the baseImage property: Base image used for Docker-based runs. Mutually exclusive with BaseDockerfile. - * - * @return the baseImage value. - */ - public String baseImage() { - return this.baseImage; - } - - /** - * Set the baseImage property: Base image used for Docker-based runs. Mutually exclusive with BaseDockerfile. - * - * @param baseImage the baseImage value to set. - * @return the ModelDockerSectionResponse object itself. - */ - public ModelDockerSectionResponse withBaseImage(String baseImage) { - this.baseImage = baseImage; - return this; - } - - /** - * Get the baseDockerfile property: Base Dockerfile used for Docker-based runs. Mutually exclusive with BaseImage. - * - * @return the baseDockerfile value. - */ - public String baseDockerfile() { - return this.baseDockerfile; - } - - /** - * Set the baseDockerfile property: Base Dockerfile used for Docker-based runs. Mutually exclusive with BaseImage. - * - * @param baseDockerfile the baseDockerfile value to set. - * @return the ModelDockerSectionResponse object itself. - */ - public ModelDockerSectionResponse withBaseDockerfile(String baseDockerfile) { - this.baseDockerfile = baseDockerfile; - return this; - } - - /** - * Get the baseImageRegistry property: Image registry that contains the base image. - * - * @return the baseImageRegistry value. - */ - public ModelDockerSectionResponseBaseImageRegistry baseImageRegistry() { - return this.baseImageRegistry; - } - - /** - * Set the baseImageRegistry property: Image registry that contains the base image. - * - * @param baseImageRegistry the baseImageRegistry value to set. - * @return the ModelDockerSectionResponse object itself. - */ - public ModelDockerSectionResponse withBaseImageRegistry( - ModelDockerSectionResponseBaseImageRegistry baseImageRegistry) { - this.baseImageRegistry = baseImageRegistry; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (baseImageRegistry() != null) { - baseImageRegistry().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponseBaseImageRegistry.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponseBaseImageRegistry.java deleted file mode 100644 index 260b39cac4b94..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponseBaseImageRegistry.java +++ /dev/null @@ -1,32 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Image registry that contains the base image. */ -@Immutable -public final class ModelDockerSectionResponseBaseImageRegistry extends ContainerRegistryResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelDockerSectionResponseBaseImageRegistry.class); - - /** {@inheritDoc} */ - @Override - public ModelDockerSectionResponseBaseImageRegistry withAddress(String address) { - super.withAddress(address); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinition.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinition.java deleted file mode 100644 index cf2a9c9131afa..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinition.java +++ /dev/null @@ -1,248 +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.machinelearningservices.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; - -/** The ModelEnvironmentDefinition model. */ -@Fluent -public class ModelEnvironmentDefinition { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinition.class); - - /* - * The name of the environment. - */ - @JsonProperty(value = "name") - private String name; - - /* - * The environment version. - */ - @JsonProperty(value = "version") - private String version; - - /* - * Settings for a Python environment. - */ - @JsonProperty(value = "python") - private ModelEnvironmentDefinitionPython python; - - /* - * Definition of environment variables to be defined in the environment. - */ - @JsonProperty(value = "environmentVariables") - private Map environmentVariables; - - /* - * The definition of a Docker container. - */ - @JsonProperty(value = "docker") - private ModelEnvironmentDefinitionDocker docker; - - /* - * The configuration for a Spark environment. - */ - @JsonProperty(value = "spark") - private ModelEnvironmentDefinitionSpark spark; - - /* - * Settings for a R environment. - */ - @JsonProperty(value = "r") - private ModelEnvironmentDefinitionR r; - - /* - * The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - */ - @JsonProperty(value = "inferencingStackVersion") - private String inferencingStackVersion; - - /** - * Get the name property: The name of the environment. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: The name of the environment. - * - * @param name the name value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withName(String name) { - this.name = name; - return this; - } - - /** - * Get the version property: The environment version. - * - * @return the version value. - */ - public String version() { - return this.version; - } - - /** - * Set the version property: The environment version. - * - * @param version the version value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withVersion(String version) { - this.version = version; - return this; - } - - /** - * Get the python property: Settings for a Python environment. - * - * @return the python value. - */ - public ModelEnvironmentDefinitionPython python() { - return this.python; - } - - /** - * Set the python property: Settings for a Python environment. - * - * @param python the python value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withPython(ModelEnvironmentDefinitionPython python) { - this.python = python; - return this; - } - - /** - * Get the environmentVariables property: Definition of environment variables to be defined in the environment. - * - * @return the environmentVariables value. - */ - public Map environmentVariables() { - return this.environmentVariables; - } - - /** - * Set the environmentVariables property: Definition of environment variables to be defined in the environment. - * - * @param environmentVariables the environmentVariables value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withEnvironmentVariables(Map environmentVariables) { - this.environmentVariables = environmentVariables; - return this; - } - - /** - * Get the docker property: The definition of a Docker container. - * - * @return the docker value. - */ - public ModelEnvironmentDefinitionDocker docker() { - return this.docker; - } - - /** - * Set the docker property: The definition of a Docker container. - * - * @param docker the docker value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withDocker(ModelEnvironmentDefinitionDocker docker) { - this.docker = docker; - return this; - } - - /** - * Get the spark property: The configuration for a Spark environment. - * - * @return the spark value. - */ - public ModelEnvironmentDefinitionSpark spark() { - return this.spark; - } - - /** - * Set the spark property: The configuration for a Spark environment. - * - * @param spark the spark value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withSpark(ModelEnvironmentDefinitionSpark spark) { - this.spark = spark; - return this; - } - - /** - * Get the r property: Settings for a R environment. - * - * @return the r value. - */ - public ModelEnvironmentDefinitionR r() { - return this.r; - } - - /** - * Set the r property: Settings for a R environment. - * - * @param r the r value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withR(ModelEnvironmentDefinitionR r) { - this.r = r; - return this; - } - - /** - * Get the inferencingStackVersion property: The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - * - * @return the inferencingStackVersion value. - */ - public String inferencingStackVersion() { - return this.inferencingStackVersion; - } - - /** - * Set the inferencingStackVersion property: The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - * - * @param inferencingStackVersion the inferencingStackVersion value to set. - * @return the ModelEnvironmentDefinition object itself. - */ - public ModelEnvironmentDefinition withInferencingStackVersion(String inferencingStackVersion) { - this.inferencingStackVersion = inferencingStackVersion; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (python() != null) { - python().validate(); - } - if (docker() != null) { - docker().validate(); - } - if (spark() != null) { - spark().validate(); - } - if (r() != null) { - r().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionDocker.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionDocker.java deleted file mode 100644 index 87501eeef023c..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionDocker.java +++ /dev/null @@ -1,47 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The definition of a Docker container. */ -@Immutable -public final class ModelEnvironmentDefinitionDocker extends ModelDockerSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionDocker.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionDocker withBaseImage(String baseImage) { - super.withBaseImage(baseImage); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionDocker withBaseDockerfile(String baseDockerfile) { - super.withBaseDockerfile(baseDockerfile); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionDocker withBaseImageRegistry( - ModelDockerSectionBaseImageRegistry baseImageRegistry) { - super.withBaseImageRegistry(baseImageRegistry); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionPython.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionPython.java deleted file mode 100644 index 71163545b408f..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionPython.java +++ /dev/null @@ -1,53 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Settings for a Python environment. */ -@Immutable -public final class ModelEnvironmentDefinitionPython extends ModelPythonSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionPython.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionPython withInterpreterPath(String interpreterPath) { - super.withInterpreterPath(interpreterPath); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionPython withUserManagedDependencies(Boolean userManagedDependencies) { - super.withUserManagedDependencies(userManagedDependencies); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionPython withCondaDependencies(Object condaDependencies) { - super.withCondaDependencies(condaDependencies); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionPython withBaseCondaEnvironment(String baseCondaEnvironment) { - super.withBaseCondaEnvironment(baseCondaEnvironment); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionR.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionR.java deleted file mode 100644 index 463559c627aab..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionR.java +++ /dev/null @@ -1,82 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** Settings for a R environment. */ -@Immutable -public final class ModelEnvironmentDefinitionR extends RSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionR.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withRVersion(String rVersion) { - super.withRVersion(rVersion); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withUserManaged(Boolean userManaged) { - super.withUserManaged(userManaged); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withRscriptPath(String rscriptPath) { - super.withRscriptPath(rscriptPath); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withSnapshotDate(String snapshotDate) { - super.withSnapshotDate(snapshotDate); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withCranPackages(List cranPackages) { - super.withCranPackages(cranPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withGitHubPackages(List gitHubPackages) { - super.withGitHubPackages(gitHubPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withCustomUrlPackages(List customUrlPackages) { - super.withCustomUrlPackages(customUrlPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionR withBioConductorPackages(List bioConductorPackages) { - super.withBioConductorPackages(bioConductorPackages); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponse.java deleted file mode 100644 index 9386e0f315496..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponse.java +++ /dev/null @@ -1,248 +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.machinelearningservices.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; - -/** The ModelEnvironmentDefinitionResponse model. */ -@Fluent -public class ModelEnvironmentDefinitionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionResponse.class); - - /* - * The name of the environment. - */ - @JsonProperty(value = "name") - private String name; - - /* - * The environment version. - */ - @JsonProperty(value = "version") - private String version; - - /* - * Settings for a Python environment. - */ - @JsonProperty(value = "python") - private ModelEnvironmentDefinitionResponsePython python; - - /* - * Definition of environment variables to be defined in the environment. - */ - @JsonProperty(value = "environmentVariables") - private Map environmentVariables; - - /* - * The definition of a Docker container. - */ - @JsonProperty(value = "docker") - private ModelEnvironmentDefinitionResponseDocker docker; - - /* - * The configuration for a Spark environment. - */ - @JsonProperty(value = "spark") - private ModelEnvironmentDefinitionResponseSpark spark; - - /* - * Settings for a R environment. - */ - @JsonProperty(value = "r") - private ModelEnvironmentDefinitionResponseR r; - - /* - * The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - */ - @JsonProperty(value = "inferencingStackVersion") - private String inferencingStackVersion; - - /** - * Get the name property: The name of the environment. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: The name of the environment. - * - * @param name the name value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withName(String name) { - this.name = name; - return this; - } - - /** - * Get the version property: The environment version. - * - * @return the version value. - */ - public String version() { - return this.version; - } - - /** - * Set the version property: The environment version. - * - * @param version the version value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withVersion(String version) { - this.version = version; - return this; - } - - /** - * Get the python property: Settings for a Python environment. - * - * @return the python value. - */ - public ModelEnvironmentDefinitionResponsePython python() { - return this.python; - } - - /** - * Set the python property: Settings for a Python environment. - * - * @param python the python value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withPython(ModelEnvironmentDefinitionResponsePython python) { - this.python = python; - return this; - } - - /** - * Get the environmentVariables property: Definition of environment variables to be defined in the environment. - * - * @return the environmentVariables value. - */ - public Map environmentVariables() { - return this.environmentVariables; - } - - /** - * Set the environmentVariables property: Definition of environment variables to be defined in the environment. - * - * @param environmentVariables the environmentVariables value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withEnvironmentVariables(Map environmentVariables) { - this.environmentVariables = environmentVariables; - return this; - } - - /** - * Get the docker property: The definition of a Docker container. - * - * @return the docker value. - */ - public ModelEnvironmentDefinitionResponseDocker docker() { - return this.docker; - } - - /** - * Set the docker property: The definition of a Docker container. - * - * @param docker the docker value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withDocker(ModelEnvironmentDefinitionResponseDocker docker) { - this.docker = docker; - return this; - } - - /** - * Get the spark property: The configuration for a Spark environment. - * - * @return the spark value. - */ - public ModelEnvironmentDefinitionResponseSpark spark() { - return this.spark; - } - - /** - * Set the spark property: The configuration for a Spark environment. - * - * @param spark the spark value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withSpark(ModelEnvironmentDefinitionResponseSpark spark) { - this.spark = spark; - return this; - } - - /** - * Get the r property: Settings for a R environment. - * - * @return the r value. - */ - public ModelEnvironmentDefinitionResponseR r() { - return this.r; - } - - /** - * Set the r property: Settings for a R environment. - * - * @param r the r value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withR(ModelEnvironmentDefinitionResponseR r) { - this.r = r; - return this; - } - - /** - * Get the inferencingStackVersion property: The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - * - * @return the inferencingStackVersion value. - */ - public String inferencingStackVersion() { - return this.inferencingStackVersion; - } - - /** - * Set the inferencingStackVersion property: The inferencing stack version added to the image. To avoid adding an - * inferencing stack, do not set this value. Valid values: "latest". - * - * @param inferencingStackVersion the inferencingStackVersion value to set. - * @return the ModelEnvironmentDefinitionResponse object itself. - */ - public ModelEnvironmentDefinitionResponse withInferencingStackVersion(String inferencingStackVersion) { - this.inferencingStackVersion = inferencingStackVersion; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (python() != null) { - python().validate(); - } - if (docker() != null) { - docker().validate(); - } - if (spark() != null) { - spark().validate(); - } - if (r() != null) { - r().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseDocker.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseDocker.java deleted file mode 100644 index 4fc43ea55f645..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseDocker.java +++ /dev/null @@ -1,47 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The definition of a Docker container. */ -@Immutable -public final class ModelEnvironmentDefinitionResponseDocker extends ModelDockerSectionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionResponseDocker.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseDocker withBaseImage(String baseImage) { - super.withBaseImage(baseImage); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseDocker withBaseDockerfile(String baseDockerfile) { - super.withBaseDockerfile(baseDockerfile); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseDocker withBaseImageRegistry( - ModelDockerSectionResponseBaseImageRegistry baseImageRegistry) { - super.withBaseImageRegistry(baseImageRegistry); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponsePython.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponsePython.java deleted file mode 100644 index 728354b3fd67b..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponsePython.java +++ /dev/null @@ -1,53 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** Settings for a Python environment. */ -@Immutable -public final class ModelEnvironmentDefinitionResponsePython extends ModelPythonSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionResponsePython.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponsePython withInterpreterPath(String interpreterPath) { - super.withInterpreterPath(interpreterPath); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponsePython withUserManagedDependencies(Boolean userManagedDependencies) { - super.withUserManagedDependencies(userManagedDependencies); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponsePython withCondaDependencies(Object condaDependencies) { - super.withCondaDependencies(condaDependencies); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponsePython withBaseCondaEnvironment(String baseCondaEnvironment) { - super.withBaseCondaEnvironment(baseCondaEnvironment); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseR.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseR.java deleted file mode 100644 index 68a5322bf7c00..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseR.java +++ /dev/null @@ -1,82 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** Settings for a R environment. */ -@Immutable -public final class ModelEnvironmentDefinitionResponseR extends RSectionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionResponseR.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withRVersion(String rVersion) { - super.withRVersion(rVersion); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withUserManaged(Boolean userManaged) { - super.withUserManaged(userManaged); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withRscriptPath(String rscriptPath) { - super.withRscriptPath(rscriptPath); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withSnapshotDate(String snapshotDate) { - super.withSnapshotDate(snapshotDate); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withCranPackages(List cranPackages) { - super.withCranPackages(cranPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withGitHubPackages(List gitHubPackages) { - super.withGitHubPackages(gitHubPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withCustomUrlPackages(List customUrlPackages) { - super.withCustomUrlPackages(customUrlPackages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseR withBioConductorPackages(List bioConductorPackages) { - super.withBioConductorPackages(bioConductorPackages); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseSpark.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseSpark.java deleted file mode 100644 index fa7fddf6f4b47..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseSpark.java +++ /dev/null @@ -1,47 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** The configuration for a Spark environment. */ -@Immutable -public final class ModelEnvironmentDefinitionResponseSpark extends ModelSparkSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionResponseSpark.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseSpark withRepositories(List repositories) { - super.withRepositories(repositories); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseSpark withPackages(List packages) { - super.withPackages(packages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionResponseSpark withPrecachePackages(Boolean precachePackages) { - super.withPrecachePackages(precachePackages); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionSpark.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionSpark.java deleted file mode 100644 index 9479542c2fb52..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionSpark.java +++ /dev/null @@ -1,47 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import java.util.List; - -/** The configuration for a Spark environment. */ -@Immutable -public final class ModelEnvironmentDefinitionSpark extends ModelSparkSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelEnvironmentDefinitionSpark.class); - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionSpark withRepositories(List repositories) { - super.withRepositories(repositories); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionSpark withPackages(List packages) { - super.withPackages(packages); - return this; - } - - /** {@inheritDoc} */ - @Override - public ModelEnvironmentDefinitionSpark withPrecachePackages(Boolean precachePackages) { - super.withPrecachePackages(precachePackages); - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - @Override - public void validate() { - super.validate(); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelPythonSection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelPythonSection.java deleted file mode 100644 index e1fbaca84de74..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelPythonSection.java +++ /dev/null @@ -1,135 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The ModelPythonSection model. */ -@Fluent -public class ModelPythonSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelPythonSection.class); - - /* - * The python interpreter path to use if an environment build is not - * required. The path specified gets used to call the user script. - */ - @JsonProperty(value = "interpreterPath") - private String interpreterPath; - - /* - * True means that AzureML reuses an existing python environment; False - * means that AzureML will create a python environment based on the Conda - * dependencies specification. - */ - @JsonProperty(value = "userManagedDependencies") - private Boolean userManagedDependencies; - - /* - * A JObject containing Conda dependencies. - */ - @JsonProperty(value = "condaDependencies") - private Object condaDependencies; - - /* - * The baseCondaEnvironment property. - */ - @JsonProperty(value = "baseCondaEnvironment") - private String baseCondaEnvironment; - - /** - * Get the interpreterPath property: The python interpreter path to use if an environment build is not required. The - * path specified gets used to call the user script. - * - * @return the interpreterPath value. - */ - public String interpreterPath() { - return this.interpreterPath; - } - - /** - * Set the interpreterPath property: The python interpreter path to use if an environment build is not required. The - * path specified gets used to call the user script. - * - * @param interpreterPath the interpreterPath value to set. - * @return the ModelPythonSection object itself. - */ - public ModelPythonSection withInterpreterPath(String interpreterPath) { - this.interpreterPath = interpreterPath; - return this; - } - - /** - * Get the userManagedDependencies property: True means that AzureML reuses an existing python environment; False - * means that AzureML will create a python environment based on the Conda dependencies specification. - * - * @return the userManagedDependencies value. - */ - public Boolean userManagedDependencies() { - return this.userManagedDependencies; - } - - /** - * Set the userManagedDependencies property: True means that AzureML reuses an existing python environment; False - * means that AzureML will create a python environment based on the Conda dependencies specification. - * - * @param userManagedDependencies the userManagedDependencies value to set. - * @return the ModelPythonSection object itself. - */ - public ModelPythonSection withUserManagedDependencies(Boolean userManagedDependencies) { - this.userManagedDependencies = userManagedDependencies; - return this; - } - - /** - * Get the condaDependencies property: A JObject containing Conda dependencies. - * - * @return the condaDependencies value. - */ - public Object condaDependencies() { - return this.condaDependencies; - } - - /** - * Set the condaDependencies property: A JObject containing Conda dependencies. - * - * @param condaDependencies the condaDependencies value to set. - * @return the ModelPythonSection object itself. - */ - public ModelPythonSection withCondaDependencies(Object condaDependencies) { - this.condaDependencies = condaDependencies; - return this; - } - - /** - * Get the baseCondaEnvironment property: The baseCondaEnvironment property. - * - * @return the baseCondaEnvironment value. - */ - public String baseCondaEnvironment() { - return this.baseCondaEnvironment; - } - - /** - * Set the baseCondaEnvironment property: The baseCondaEnvironment property. - * - * @param baseCondaEnvironment the baseCondaEnvironment value to set. - * @return the ModelPythonSection object itself. - */ - public ModelPythonSection withBaseCondaEnvironment(String baseCondaEnvironment) { - this.baseCondaEnvironment = baseCondaEnvironment; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelSparkSection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelSparkSection.java deleted file mode 100644 index 7e9c84572afd7..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelSparkSection.java +++ /dev/null @@ -1,106 +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.machinelearningservices.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.List; - -/** The ModelSparkSection model. */ -@Fluent -public class ModelSparkSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ModelSparkSection.class); - - /* - * The list of spark repositories. - */ - @JsonProperty(value = "repositories") - private List repositories; - - /* - * The Spark packages to use. - */ - @JsonProperty(value = "packages") - private List packages; - - /* - * Whether to precache the packages. - */ - @JsonProperty(value = "precachePackages") - private Boolean precachePackages; - - /** - * Get the repositories property: The list of spark repositories. - * - * @return the repositories value. - */ - public List repositories() { - return this.repositories; - } - - /** - * Set the repositories property: The list of spark repositories. - * - * @param repositories the repositories value to set. - * @return the ModelSparkSection object itself. - */ - public ModelSparkSection withRepositories(List repositories) { - this.repositories = repositories; - return this; - } - - /** - * Get the packages property: The Spark packages to use. - * - * @return the packages value. - */ - public List packages() { - return this.packages; - } - - /** - * Set the packages property: The Spark packages to use. - * - * @param packages the packages value to set. - * @return the ModelSparkSection object itself. - */ - public ModelSparkSection withPackages(List packages) { - this.packages = packages; - return this; - } - - /** - * Get the precachePackages property: Whether to precache the packages. - * - * @return the precachePackages value. - */ - public Boolean precachePackages() { - return this.precachePackages; - } - - /** - * Set the precachePackages property: Whether to precache the packages. - * - * @param precachePackages the precachePackages value to set. - * @return the ModelSparkSection object itself. - */ - public ModelSparkSection withPrecachePackages(Boolean precachePackages) { - this.precachePackages = precachePackages; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (packages() != null) { - packages().forEach(e -> e.validate()); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeState.java index 9a3c2905f35d9..ee5de93ec5e59 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeState.java @@ -39,7 +39,11 @@ public static NodeState fromString(String name) { return fromString(name, NodeState.class); } - /** @return known NodeState values. */ + /** + * Gets known NodeState values. + * + * @return known NodeState values. + */ public static Collection values() { return values(NodeState.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeStateCounts.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeStateCounts.java index 257b3e76fb3ae..15f6c4aae7425 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeStateCounts.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeStateCounts.java @@ -5,53 +5,52 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Counts of various compute node states on the amlCompute. */ @Immutable public final class NodeStateCounts { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NodeStateCounts.class); - /* - * Number of compute nodes in idle state. + * Idle node count. Number of compute nodes in idle state. */ @JsonProperty(value = "idleNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer idleNodeCount; /* - * Number of compute nodes which are running jobs. + * Running node count. Number of compute nodes which are running jobs. */ @JsonProperty(value = "runningNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer runningNodeCount; /* - * Number of compute nodes which are being prepared. + * Preparing node count. Number of compute nodes which are being prepared. */ @JsonProperty(value = "preparingNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer preparingNodeCount; /* - * Number of compute nodes which are in unusable state. + * Unusable node count. Number of compute nodes which are in unusable + * state. */ @JsonProperty(value = "unusableNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer unusableNodeCount; /* - * Number of compute nodes which are leaving the amlCompute. + * Leaving node count. Number of compute nodes which are leaving the + * amlCompute. */ @JsonProperty(value = "leavingNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer leavingNodeCount; /* - * Number of compute nodes which are in preempted state. + * Preempted node count. Number of compute nodes which are in preempted + * state. */ @JsonProperty(value = "preemptedNodeCount", access = JsonProperty.Access.WRITE_ONLY) private Integer preemptedNodeCount; /** - * Get the idleNodeCount property: Number of compute nodes in idle state. + * Get the idleNodeCount property: Idle node count. Number of compute nodes in idle state. * * @return the idleNodeCount value. */ @@ -60,7 +59,7 @@ public Integer idleNodeCount() { } /** - * Get the runningNodeCount property: Number of compute nodes which are running jobs. + * Get the runningNodeCount property: Running node count. Number of compute nodes which are running jobs. * * @return the runningNodeCount value. */ @@ -69,7 +68,7 @@ public Integer runningNodeCount() { } /** - * Get the preparingNodeCount property: Number of compute nodes which are being prepared. + * Get the preparingNodeCount property: Preparing node count. Number of compute nodes which are being prepared. * * @return the preparingNodeCount value. */ @@ -78,7 +77,7 @@ public Integer preparingNodeCount() { } /** - * Get the unusableNodeCount property: Number of compute nodes which are in unusable state. + * Get the unusableNodeCount property: Unusable node count. Number of compute nodes which are in unusable state. * * @return the unusableNodeCount value. */ @@ -87,7 +86,7 @@ public Integer unusableNodeCount() { } /** - * Get the leavingNodeCount property: Number of compute nodes which are leaving the amlCompute. + * Get the leavingNodeCount property: Leaving node count. Number of compute nodes which are leaving the amlCompute. * * @return the leavingNodeCount value. */ @@ -96,7 +95,7 @@ public Integer leavingNodeCount() { } /** - * Get the preemptedNodeCount property: Number of compute nodes which are in preempted state. + * Get the preemptedNodeCount property: Preempted node count. Number of compute nodes which are in preempted state. * * @return the preemptedNodeCount value. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NotebookPreparationError.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NotebookPreparationError.java index 261571e348c5e..4b0c2d9a8a4e8 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NotebookPreparationError.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NotebookPreparationError.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The NotebookPreparationError model. */ @Fluent public final class NotebookPreparationError { - @JsonIgnore private final ClientLogger logger = new ClientLogger(NotebookPreparationError.class); - /* * The errorMessage property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Notebooks.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Notebooks.java deleted file mode 100644 index e3059bf7d7a7d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Notebooks.java +++ /dev/null @@ -1,54 +0,0 @@ -// Copyright (c) Microsoft Corporation. All rights reserved. -// Licensed under the MIT License. -// Code generated by Microsoft (R) AutoRest Code Generator. - -package com.azure.resourcemanager.machinelearningservices.models; - -import com.azure.core.http.rest.Response; -import com.azure.core.util.Context; - -/** Resource collection API of Notebooks. */ -public interface Notebooks { - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - NotebookResourceInfo prepare(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - NotebookResourceInfo prepare(String resourceGroupName, String workspaceName, Context context); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - ListNotebookKeysResult listKeys(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationDisplay.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationDisplay.java index a882ba1d78c7a..1701099290e8d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationDisplay.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationDisplay.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Display name of operation. */ @Fluent public final class OperationDisplay { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationDisplay.class); - /* * The resource provider name: Microsoft.MachineLearningExperimentation */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationListResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationListResult.java index bc6be7f314e07..b7c0f6f18415d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationListResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationListResult.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.OperationInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** An array of operations supported by the resource provider. */ @Fluent public final class OperationListResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(OperationListResult.class); - /* * List of AML workspace operations supported by the AML workspace resource * provider. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationName.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationName.java index cc881989d4924..6aaeb8228dc27 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationName.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationName.java @@ -39,7 +39,11 @@ public static OperationName fromString(String name) { return fromString(name, OperationName.class); } - /** @return known OperationName values. */ + /** + * Gets known OperationName values. + * + * @return known OperationName values. + */ public static Collection values() { return values(OperationName.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationStatus.java index 2957b9b001180..79b768be7acc6 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationStatus.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OperationStatus.java @@ -45,7 +45,11 @@ public static OperationStatus fromString(String name) { return fromString(name, OperationStatus.class); } - /** @return known OperationStatus values. */ + /** + * Gets known OperationStatus values. + * + * @return known OperationStatus values. + */ public static Collection values() { return values(OperationStatus.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Operations.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Operations.java index 6552b8aaef2bf..c1fe9a6a8d8a7 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Operations.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Operations.java @@ -14,7 +14,8 @@ 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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ PagedIterable list(); @@ -25,7 +26,8 @@ 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 an array of operations supported by the resource provider. + * @return an array of operations supported by the resource provider as paginated response with {@link + * PagedIterable}. */ PagedIterable list(Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OrderString.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OrderString.java deleted file mode 100644 index 33abdf8df224d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OrderString.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.machinelearningservices.models; - -import com.azure.core.util.ExpandableStringEnum; -import com.fasterxml.jackson.annotation.JsonCreator; -import java.util.Collection; - -/** Defines values for OrderString. */ -public final class OrderString extends ExpandableStringEnum { - /** Static value CreatedAtDesc for OrderString. */ - public static final OrderString CREATED_AT_DESC = fromString("CreatedAtDesc"); - - /** Static value CreatedAtAsc for OrderString. */ - public static final OrderString CREATED_AT_ASC = fromString("CreatedAtAsc"); - - /** Static value UpdatedAtDesc for OrderString. */ - public static final OrderString UPDATED_AT_DESC = fromString("UpdatedAtDesc"); - - /** Static value UpdatedAtAsc for OrderString. */ - public static final OrderString UPDATED_AT_ASC = fromString("UpdatedAtAsc"); - - /** - * Creates or finds a OrderString from its string representation. - * - * @param name a name to look for. - * @return the corresponding OrderString. - */ - @JsonCreator - public static OrderString fromString(String name) { - return fromString(name, OrderString.class); - } - - /** @return known OrderString values. */ - public static Collection values() { - return values(OrderString.class); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OsType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OsType.java index 13e7b7db821e5..0ff3cba53af8a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OsType.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OsType.java @@ -27,7 +27,11 @@ public static OsType fromString(String name) { return fromString(name, OsType.class); } - /** @return known OsType values. */ + /** + * Gets known OsType values. + * + * @return known OsType values. + */ public static Collection values() { return values(OsType.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedComputeResourcesList.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedComputeResourcesList.java index 9b7f2cb7c2009..2d59cb3011127 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedComputeResourcesList.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedComputeResourcesList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeResourceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Paginated list of Machine Learning compute objects wrapped in ARM resource envelope. */ @Fluent public final class PaginatedComputeResourcesList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PaginatedComputeResourcesList.class); - /* * An array of Machine Learning compute objects wrapped in ARM resource * envelope. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedServiceList.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedServiceList.java deleted file mode 100644 index 526312035bc07..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedServiceList.java +++ /dev/null @@ -1,61 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; -import java.util.List; - -/** Paginated list of Machine Learning service objects wrapped in ARM resource envelope. */ -@Immutable -public final class PaginatedServiceList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PaginatedServiceList.class); - - /* - * An array of Machine Learning compute objects wrapped in ARM resource - * envelope. - */ - @JsonProperty(value = "value", access = JsonProperty.Access.WRITE_ONLY) - private List value; - - /* - * A continuation link (absolute URI) to the next page of results in the - * list. - */ - @JsonProperty(value = "nextLink", access = JsonProperty.Access.WRITE_ONLY) - private String nextLink; - - /** - * Get the value property: An array of Machine Learning compute objects wrapped in ARM resource envelope. - * - * @return the value value. - */ - public List value() { - return this.value; - } - - /** - * Get the nextLink property: A continuation link (absolute URI) to the next page of results in the list. - * - * @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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedWorkspaceConnectionsList.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedWorkspaceConnectionsList.java index 8325b16c8b3c5..abe6821b1a70c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedWorkspaceConnectionsList.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedWorkspaceConnectionsList.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceConnectionInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Paginated list of Workspace connection objects. */ @Fluent public final class PaginatedWorkspaceConnectionsList { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PaginatedWorkspaceConnectionsList.class); - /* * An array of Workspace connection objects. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Password.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Password.java index 1335ec78692c2..a4cc0aa31f34e 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Password.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Password.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The Password model. */ @Immutable public final class Password { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Password.class); - /* * The name property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PersonalComputeInstanceSettings.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PersonalComputeInstanceSettings.java index 103291581b094..d0417db25ef33 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PersonalComputeInstanceSettings.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PersonalComputeInstanceSettings.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Settings for a personal compute instance. */ @Fluent public final class PersonalComputeInstanceSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PersonalComputeInstanceSettings.class); - /* * A user explicitly assigned to a personal compute instance. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpoint.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpoint.java index a1d45eaa1ee69..6ed3f5a0a24fe 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpoint.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpoint.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The Private Endpoint resource. */ @Immutable public final class PrivateEndpoint { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpoint.class); - /* * The ARM identifier for Private Endpoint */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnection.java index 8de57733b4894..e864273302360 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnection.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnection.java @@ -34,19 +34,40 @@ public interface PrivateEndpointConnection { String type(); /** - * Gets the location property: The geo-location where the resource lives. + * Gets the identity property: The identity of the resource. + * + * @return the identity value. + */ + Identity identity(); + + /** + * Gets the location property: Specifies the location of the resource. * * @return the location value. */ String location(); /** - * Gets the tags property: Resource tags. + * Gets the tags property: Contains resource tags defined as key/value pairs. * * @return the tags value. */ Map tags(); + /** + * Gets the sku property: The sku of the workspace. + * + * @return the sku value. + */ + Sku sku(); + + /** + * Gets the systemData property: System data. + * + * @return the systemData value. + */ + SystemData systemData(); + /** * Gets the privateEndpoint property: The resource of private end point. * @@ -69,27 +90,6 @@ public interface PrivateEndpointConnection { */ PrivateEndpointConnectionProvisioningState provisioningState(); - /** - * Gets the identity property: The identity of the resource. - * - * @return the identity value. - */ - Identity identity(); - - /** - * Gets the sku property: The sku of the workspace. - * - * @return the sku value. - */ - Sku sku(); - - /** - * Gets the systemData property: Read only system data. - * - * @return the systemData value. - */ - SystemData systemData(); - /** * Gets the region of the resource. * @@ -114,40 +114,19 @@ public interface PrivateEndpointConnection { /** The entirety of the PrivateEndpointConnection definition. */ interface Definition - extends DefinitionStages.Blank, - DefinitionStages.WithLocation, - DefinitionStages.WithParentResource, - DefinitionStages.WithCreate { + extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate { } /** The PrivateEndpointConnection definition stages. */ interface DefinitionStages { /** The first stage of the PrivateEndpointConnection definition. */ - interface Blank extends WithLocation { - } - /** The stage of the PrivateEndpointConnection definition allowing to specify location. */ - interface WithLocation { - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithParentResource withRegion(Region location); - - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithParentResource withRegion(String location); + interface Blank extends WithParentResource { } /** The stage of the PrivateEndpointConnection definition allowing to specify parent resource. */ interface WithParentResource { /** * Specifies resourceGroupName, workspaceName. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @return the next definition stage. */ @@ -158,11 +137,12 @@ interface WithParentResource { * the resource to be created, but also allows for any other optional properties to be specified. */ interface WithCreate - extends DefinitionStages.WithTags, - DefinitionStages.WithPrivateEndpoint, - DefinitionStages.WithPrivateLinkServiceConnectionState, + extends DefinitionStages.WithLocation, + DefinitionStages.WithTags, DefinitionStages.WithIdentity, - DefinitionStages.WithSku { + DefinitionStages.WithSku, + DefinitionStages.WithPrivateEndpoint, + DefinitionStages.WithPrivateLinkServiceConnectionState { /** * Executes the create request. * @@ -178,40 +158,33 @@ interface WithCreate */ PrivateEndpointConnection create(Context context); } - /** The stage of the PrivateEndpointConnection definition allowing to specify tags. */ - interface WithTags { + /** The stage of the PrivateEndpointConnection definition allowing to specify location. */ + interface WithLocation { /** - * Specifies the tags property: Resource tags.. + * Specifies the region for the resource. * - * @param tags Resource tags. + * @param location Specifies the location of the resource. * @return the next definition stage. */ - WithCreate withTags(Map tags); - } - /** The stage of the PrivateEndpointConnection definition allowing to specify privateEndpoint. */ - interface WithPrivateEndpoint { + WithCreate withRegion(Region location); + /** - * Specifies the privateEndpoint property: The resource of private end point.. + * Specifies the region for the resource. * - * @param privateEndpoint The resource of private end point. + * @param location Specifies the location of the resource. * @return the next definition stage. */ - WithCreate withPrivateEndpoint(PrivateEndpoint privateEndpoint); + WithCreate withRegion(String location); } - /** - * The stage of the PrivateEndpointConnection definition allowing to specify privateLinkServiceConnectionState. - */ - interface WithPrivateLinkServiceConnectionState { + /** The stage of the PrivateEndpointConnection definition allowing to specify tags. */ + interface WithTags { /** - * Specifies the privateLinkServiceConnectionState property: A collection of information about the state of - * the connection between service consumer and provider.. + * Specifies the tags property: Contains resource tags defined as key/value pairs.. * - * @param privateLinkServiceConnectionState A collection of information about the state of the connection - * between service consumer and provider. + * @param tags Contains resource tags defined as key/value pairs. * @return the next definition stage. */ - WithCreate withPrivateLinkServiceConnectionState( - PrivateLinkServiceConnectionState privateLinkServiceConnectionState); + WithCreate withTags(Map tags); } /** The stage of the PrivateEndpointConnection definition allowing to specify identity. */ interface WithIdentity { @@ -233,6 +206,31 @@ interface WithSku { */ WithCreate withSku(Sku sku); } + /** The stage of the PrivateEndpointConnection definition allowing to specify privateEndpoint. */ + interface WithPrivateEndpoint { + /** + * Specifies the privateEndpoint property: The resource of private end point.. + * + * @param privateEndpoint The resource of private end point. + * @return the next definition stage. + */ + WithCreate withPrivateEndpoint(PrivateEndpoint privateEndpoint); + } + /** + * The stage of the PrivateEndpointConnection definition allowing to specify privateLinkServiceConnectionState. + */ + interface WithPrivateLinkServiceConnectionState { + /** + * Specifies the privateLinkServiceConnectionState property: A collection of information about the state of + * the connection between service consumer and provider.. + * + * @param privateLinkServiceConnectionState A collection of information about the state of the connection + * between service consumer and provider. + * @return the next definition stage. + */ + WithCreate withPrivateLinkServiceConnectionState( + PrivateLinkServiceConnectionState privateLinkServiceConnectionState); + } } /** * Begins update for the PrivateEndpointConnection resource. @@ -244,10 +242,10 @@ interface WithSku { /** The template for PrivateEndpointConnection update. */ interface Update extends UpdateStages.WithTags, - UpdateStages.WithPrivateEndpoint, - UpdateStages.WithPrivateLinkServiceConnectionState, UpdateStages.WithIdentity, - UpdateStages.WithSku { + UpdateStages.WithSku, + UpdateStages.WithPrivateEndpoint, + UpdateStages.WithPrivateLinkServiceConnectionState { /** * Executes the update request. * @@ -268,13 +266,33 @@ interface UpdateStages { /** The stage of the PrivateEndpointConnection update allowing to specify tags. */ interface WithTags { /** - * Specifies the tags property: Resource tags.. + * Specifies the tags property: Contains resource tags defined as key/value pairs.. * - * @param tags Resource tags. + * @param tags Contains resource tags defined as key/value pairs. * @return the next definition stage. */ Update withTags(Map tags); } + /** The stage of the PrivateEndpointConnection update allowing to specify identity. */ + interface WithIdentity { + /** + * Specifies the identity property: The identity of the resource.. + * + * @param identity The identity of the resource. + * @return the next definition stage. + */ + Update withIdentity(Identity identity); + } + /** The stage of the PrivateEndpointConnection update allowing to specify sku. */ + interface WithSku { + /** + * Specifies the sku property: The sku of the workspace.. + * + * @param sku The sku of the workspace. + * @return the next definition stage. + */ + Update withSku(Sku sku); + } /** The stage of the PrivateEndpointConnection update allowing to specify privateEndpoint. */ interface WithPrivateEndpoint { /** @@ -298,26 +316,6 @@ interface WithPrivateLinkServiceConnectionState { Update withPrivateLinkServiceConnectionState( PrivateLinkServiceConnectionState privateLinkServiceConnectionState); } - /** The stage of the PrivateEndpointConnection update allowing to specify identity. */ - interface WithIdentity { - /** - * Specifies the identity property: The identity of the resource.. - * - * @param identity The identity of the resource. - * @return the next definition stage. - */ - Update withIdentity(Identity identity); - } - /** The stage of the PrivateEndpointConnection update allowing to specify sku. */ - interface WithSku { - /** - * Specifies the sku property: The sku of the workspace.. - * - * @param sku The sku of the workspace. - * @return the next definition stage. - */ - Update withSku(Sku sku); - } } /** * Refreshes the resource to sync with Azure. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionListResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionListResult.java new file mode 100644 index 0000000000000..f1e41d8a0a1a8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionListResult.java @@ -0,0 +1,51 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** List of private endpoint connection associated with the specified workspace. */ +@Fluent +public final class PrivateEndpointConnectionListResult { + /* + * Array of private endpoint connections + */ + @JsonProperty(value = "value") + private List value; + + /** + * Get the value property: Array of private endpoint connections. + * + * @return the value value. + */ + public List value() { + return this.value; + } + + /** + * Set the value property: Array of private endpoint connections. + * + * @param value the value value to set. + * @return the PrivateEndpointConnectionListResult object itself. + */ + public PrivateEndpointConnectionListResult withValue(List value) { + this.value = value; + 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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionProvisioningState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionProvisioningState.java index 5ef042590e134..4c7a0ba7d3305 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionProvisioningState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionProvisioningState.java @@ -34,7 +34,11 @@ public static PrivateEndpointConnectionProvisioningState fromString(String name) return fromString(name, PrivateEndpointConnectionProvisioningState.class); } - /** @return known PrivateEndpointConnectionProvisioningState values. */ + /** + * Gets known PrivateEndpointConnectionProvisioningState values. + * + * @return known PrivateEndpointConnectionProvisioningState values. + */ public static Collection values() { return values(PrivateEndpointConnectionProvisioningState.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnections.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnections.java index 129b4ce0590fe..4bd6232e282ac 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnections.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnections.java @@ -4,15 +4,43 @@ package com.azure.resourcemanager.machinelearningservices.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 PrivateEndpointConnections. */ public interface PrivateEndpointConnections { + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String workspaceName); + + /** + * List all the private endpoint connections associated with the workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @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 private endpoint connection associated with the specified workspace as paginated response with + * {@link PagedIterable}. + */ + PagedIterable list(String resourceGroupName, String workspaceName, Context context); + /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -25,14 +53,14 @@ public interface PrivateEndpointConnections { /** * Gets the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @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 specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response}. */ Response getWithResponse( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, Context context); @@ -40,7 +68,7 @@ Response getWithResponse( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -52,14 +80,14 @@ Response getWithResponse( /** * Deletes the specified private endpoint connection associated with the workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param privateEndpointConnectionName The name of the private endpoint connection associated with the workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ Response deleteWithResponse( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, Context context); @@ -71,7 +99,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response}. */ PrivateEndpointConnection getById(String id); @@ -83,7 +111,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the specified private endpoint connection associated with the workspace. + * @return the specified private endpoint connection associated with the workspace along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); @@ -105,7 +133,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ Response deleteByIdWithResponse(String id, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointServiceConnectionStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointServiceConnectionStatus.java index 63de7ad21ed26..a8d6c4856a447 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointServiceConnectionStatus.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointServiceConnectionStatus.java @@ -37,7 +37,11 @@ public static PrivateEndpointServiceConnectionStatus fromString(String name) { return fromString(name, PrivateEndpointServiceConnectionStatus.class); } - /** @return known PrivateEndpointServiceConnectionStatus values. */ + /** + * Gets known PrivateEndpointServiceConnectionStatus values. + * + * @return known PrivateEndpointServiceConnectionStatus values. + */ public static Collection values() { return values(PrivateEndpointServiceConnectionStatus.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResource.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResource.java index 8effde6d19787..3ae19e356dac4 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResource.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResource.java @@ -5,44 +5,41 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; -import com.azure.core.management.Resource; +import com.azure.core.management.ProxyResource; import com.azure.core.management.SystemData; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateLinkResourceProperties; +import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; import java.util.Map; /** A private link resource. */ -@JsonFlatten @Fluent -public class PrivateLinkResource extends Resource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResource.class); - +public final class PrivateLinkResource extends ProxyResource { /* - * The private link resource group id. + * Resource properties. */ - @JsonProperty(value = "properties.groupId", access = JsonProperty.Access.WRITE_ONLY) - private String groupId; + @JsonProperty(value = "properties") + private PrivateLinkResourceProperties innerProperties; /* - * The private link resource required member names. + * The identity of the resource. */ - @JsonProperty(value = "properties.requiredMembers", access = JsonProperty.Access.WRITE_ONLY) - private List requiredMembers; + @JsonProperty(value = "identity") + private Identity identity; /* - * The private link resource Private link DNS zone name. + * Specifies the location of the resource. */ - @JsonProperty(value = "properties.requiredZoneNames") - private List requiredZoneNames; + @JsonProperty(value = "location") + private String location; /* - * The identity of the resource. + * Contains resource tags defined as key/value pairs. */ - @JsonProperty(value = "identity") - private Identity identity; + @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map tags; /* * The sku of the workspace. @@ -51,66 +48,77 @@ public class PrivateLinkResource extends Resource { private Sku sku; /* - * Read only system data + * System data */ @JsonProperty(value = "systemData", access = JsonProperty.Access.WRITE_ONLY) private SystemData systemData; /** - * Get the groupId property: The private link resource group id. + * Get the innerProperties property: Resource properties. * - * @return the groupId value. + * @return the innerProperties value. */ - public String groupId() { - return this.groupId; + private PrivateLinkResourceProperties innerProperties() { + return this.innerProperties; } /** - * Get the requiredMembers property: The private link resource required member names. + * Get the identity property: The identity of the resource. * - * @return the requiredMembers value. + * @return the identity value. */ - public List requiredMembers() { - return this.requiredMembers; + public Identity identity() { + return this.identity; } /** - * Get the requiredZoneNames property: The private link resource Private link DNS zone name. + * Set the identity property: The identity of the resource. * - * @return the requiredZoneNames value. + * @param identity the identity value to set. + * @return the PrivateLinkResource object itself. */ - public List requiredZoneNames() { - return this.requiredZoneNames; + public PrivateLinkResource withIdentity(Identity identity) { + this.identity = identity; + return this; } /** - * Set the requiredZoneNames property: The private link resource Private link DNS zone name. + * Get the location property: Specifies the location of the resource. * - * @param requiredZoneNames the requiredZoneNames value to set. + * @return the location value. + */ + public String location() { + return this.location; + } + + /** + * Set the location property: Specifies the location of the resource. + * + * @param location the location value to set. * @return the PrivateLinkResource object itself. */ - public PrivateLinkResource withRequiredZoneNames(List requiredZoneNames) { - this.requiredZoneNames = requiredZoneNames; + public PrivateLinkResource withLocation(String location) { + this.location = location; return this; } /** - * Get the identity property: The identity of the resource. + * Get the tags property: Contains resource tags defined as key/value pairs. * - * @return the identity value. + * @return the tags value. */ - public Identity identity() { - return this.identity; + public Map tags() { + return this.tags; } /** - * Set the identity property: The identity of the resource. + * Set the tags property: Contains resource tags defined as key/value pairs. * - * @param identity the identity value to set. + * @param tags the tags value to set. * @return the PrivateLinkResource object itself. */ - public PrivateLinkResource withIdentity(Identity identity) { - this.identity = identity; + public PrivateLinkResource withTags(Map tags) { + this.tags = tags; return this; } @@ -135,7 +143,7 @@ public PrivateLinkResource withSku(Sku sku) { } /** - * Get the systemData property: Read only system data. + * Get the systemData property: System data. * * @return the systemData value. */ @@ -143,17 +151,44 @@ public SystemData systemData() { return this.systemData; } - /** {@inheritDoc} */ - @Override - public PrivateLinkResource withLocation(String location) { - super.withLocation(location); - return this; + /** + * Get the groupId property: The private link resource group id. + * + * @return the groupId value. + */ + public String groupId() { + return this.innerProperties() == null ? null : this.innerProperties().groupId(); } - /** {@inheritDoc} */ - @Override - public PrivateLinkResource withTags(Map tags) { - super.withTags(tags); + /** + * Get the requiredMembers property: The private link resource required member names. + * + * @return the requiredMembers value. + */ + public List requiredMembers() { + return this.innerProperties() == null ? null : this.innerProperties().requiredMembers(); + } + + /** + * Get the requiredZoneNames property: The private link resource Private link DNS zone name. + * + * @return the requiredZoneNames value. + */ + public List requiredZoneNames() { + return this.innerProperties() == null ? null : this.innerProperties().requiredZoneNames(); + } + + /** + * Set the requiredZoneNames property: The private link resource Private link DNS zone name. + * + * @param requiredZoneNames the requiredZoneNames value to set. + * @return the PrivateLinkResource object itself. + */ + public PrivateLinkResource withRequiredZoneNames(List requiredZoneNames) { + if (this.innerProperties() == null) { + this.innerProperties = new PrivateLinkResourceProperties(); + } + this.innerProperties().withRequiredZoneNames(requiredZoneNames); return this; } @@ -163,6 +198,9 @@ public PrivateLinkResource withTags(Map tags) { * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { + if (innerProperties() != null) { + innerProperties().validate(); + } if (identity() != null) { identity().validate(); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResources.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResources.java index cad1df3087eeb..6d9a6aae2b078 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResources.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkResources.java @@ -12,26 +12,26 @@ public interface PrivateLinkResources { /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 private link resources that need to be created for a workspace. */ - PrivateLinkResourceListResult listByWorkspace(String resourceGroupName, String workspaceName); + PrivateLinkResourceListResult list(String resourceGroupName, String workspaceName); /** * Gets the private link resources that need to be created for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 private link resources that need to be created for a workspace. + * @return the private link resources that need to be created for a workspace along with {@link Response}. */ - Response listByWorkspaceWithResponse( + Response listWithResponse( String resourceGroupName, String workspaceName, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkServiceConnectionState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkServiceConnectionState.java index b5a87b9fd2d1b..20d60868de3be 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkServiceConnectionState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateLinkServiceConnectionState.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** A collection of information about the state of the connection between service consumer and provider. */ @Fluent public final class PrivateLinkServiceConnectionState { - @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkServiceConnectionState.class); - /* * Indicates whether the connection has been Approved/Rejected/Removed by * the owner of the service. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ProvisioningState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ProvisioningState.java index b809c9bf6e81b..3c5d505be20ac 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ProvisioningState.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ProvisioningState.java @@ -42,7 +42,11 @@ public static ProvisioningState fromString(String name) { return fromString(name, ProvisioningState.class); } - /** @return known ProvisioningState values. */ + /** + * Gets known ProvisioningState values. + * + * @return known ProvisioningState values. + */ public static Collection values() { return values(ProvisioningState.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.java new file mode 100644 index 0000000000000..9819a3b710db2 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.java @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.core.util.ExpandableStringEnum; +import com.fasterxml.jackson.annotation.JsonCreator; +import java.util.Collection; + +/** Defines values for PublicNetworkAccess. */ +public final class PublicNetworkAccess extends ExpandableStringEnum { + /** Static value Enabled for PublicNetworkAccess. */ + public static final PublicNetworkAccess ENABLED = fromString("Enabled"); + + /** Static value Disabled for PublicNetworkAccess. */ + public static final PublicNetworkAccess DISABLED = fromString("Disabled"); + + /** + * Creates or finds a PublicNetworkAccess from its string representation. + * + * @param name a name to look for. + * @return the corresponding PublicNetworkAccess. + */ + @JsonCreator + public static PublicNetworkAccess fromString(String name) { + return fromString(name, PublicNetworkAccess.class); + } + + /** + * Gets known PublicNetworkAccess values. + * + * @return known PublicNetworkAccess values. + */ + public static Collection values() { + return values(PublicNetworkAccess.class); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaBaseProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaBaseProperties.java index 91e1ac8adc80e..5c810925f3400 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaBaseProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaBaseProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The properties for Quota update or retrieval. */ @Fluent public final class QuotaBaseProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(QuotaBaseProperties.class); - /* * Specifies the resource ID. */ @@ -27,7 +23,7 @@ public final class QuotaBaseProperties { private String type; /* - * The maximum permitted quota of the resource. + * Limit. The maximum permitted quota of the resource. */ @JsonProperty(value = "limit") private Long limit; @@ -79,7 +75,7 @@ public QuotaBaseProperties withType(String type) { } /** - * Get the limit property: The maximum permitted quota of the resource. + * Get the limit property: Limit. The maximum permitted quota of the resource. * * @return the limit value. */ @@ -88,7 +84,7 @@ public Long limit() { } /** - * Set the limit property: The maximum permitted quota of the resource. + * Set the limit property: Limit. The maximum permitted quota of the resource. * * @param limit the limit value to set. * @return the QuotaBaseProperties object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUnit.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUnit.java index 77b07e964ee54..ed51ebe0de1e9 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUnit.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUnit.java @@ -24,7 +24,11 @@ public static QuotaUnit fromString(String name) { return fromString(name, QuotaUnit.class); } - /** @return known QuotaUnit values. */ + /** + * Gets known QuotaUnit values. + * + * @return known QuotaUnit values. + */ public static Collection values() { return values(QuotaUnit.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUpdateParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUpdateParameters.java index 2472b2667689e..e74a25f1771d1 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUpdateParameters.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/QuotaUpdateParameters.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.List; /** Quota update parameters. */ @Fluent public final class QuotaUpdateParameters { - @JsonIgnore private final ClientLogger logger = new ClientLogger(QuotaUpdateParameters.class); - /* * The list for update quota. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Quotas.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Quotas.java index 29e493f42ad8e..a630246246bd4 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Quotas.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Quotas.java @@ -31,7 +31,7 @@ public interface Quotas { * @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 result of update workspace quota. + * @return the result of update workspace quota along with {@link Response}. */ Response updateWithResponse( String location, QuotaUpdateParameters parameters, Context context); @@ -43,7 +43,8 @@ Response updateWithResponse( * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ PagedIterable list(String location); @@ -55,7 +56,8 @@ Response updateWithResponse( * @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 currently assigned Workspace Quotas based on VMFamily. + * @return the currently assigned Workspace Quotas based on VMFamily as paginated response with {@link + * PagedIterable}. */ PagedIterable list(String location, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RCranPackage.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RCranPackage.java deleted file mode 100644 index 1ad94c9709e12..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RCranPackage.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The RCranPackage model. */ -@Fluent -public final class RCranPackage { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RCranPackage.class); - - /* - * The package name. - */ - @JsonProperty(value = "name") - private String name; - - /* - * The repository name. - */ - @JsonProperty(value = "repository") - private String repository; - - /** - * Get the name property: The package name. - * - * @return the name value. - */ - public String name() { - return this.name; - } - - /** - * Set the name property: The package name. - * - * @param name the name value to set. - * @return the RCranPackage object itself. - */ - public RCranPackage withName(String name) { - this.name = name; - return this; - } - - /** - * Get the repository property: The repository name. - * - * @return the repository value. - */ - public String repository() { - return this.repository; - } - - /** - * Set the repository property: The repository name. - * - * @param repository the repository value to set. - * @return the RCranPackage object itself. - */ - public RCranPackage withRepository(String repository) { - this.repository = repository; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackage.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackage.java deleted file mode 100644 index a0f7b6ee799b8..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackage.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The RGitHubPackage model. */ -@Fluent -public final class RGitHubPackage { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RGitHubPackage.class); - - /* - * Repository address in the format username/repo[/subdir][@ref|#pull]. - */ - @JsonProperty(value = "repository") - private String repository; - - /* - * Personal access token to install from a private repo - */ - @JsonProperty(value = "authToken") - private String authToken; - - /** - * Get the repository property: Repository address in the format username/repo[/subdir][@ref|#pull]. - * - * @return the repository value. - */ - public String repository() { - return this.repository; - } - - /** - * Set the repository property: Repository address in the format username/repo[/subdir][@ref|#pull]. - * - * @param repository the repository value to set. - * @return the RGitHubPackage object itself. - */ - public RGitHubPackage withRepository(String repository) { - this.repository = repository; - return this; - } - - /** - * Get the authToken property: Personal access token to install from a private repo. - * - * @return the authToken value. - */ - public String authToken() { - return this.authToken; - } - - /** - * Set the authToken property: Personal access token to install from a private repo. - * - * @param authToken the authToken value to set. - * @return the RGitHubPackage object itself. - */ - public RGitHubPackage withAuthToken(String authToken) { - this.authToken = authToken; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackageResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackageResponse.java deleted file mode 100644 index b5c892df3a2c1..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackageResponse.java +++ /dev/null @@ -1,50 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The RGitHubPackageResponse model. */ -@Fluent -public final class RGitHubPackageResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RGitHubPackageResponse.class); - - /* - * Repository address in the format username/repo[/subdir][@ref|#pull]. - */ - @JsonProperty(value = "repository") - private String repository; - - /** - * Get the repository property: Repository address in the format username/repo[/subdir][@ref|#pull]. - * - * @return the repository value. - */ - public String repository() { - return this.repository; - } - - /** - * Set the repository property: Repository address in the format username/repo[/subdir][@ref|#pull]. - * - * @param repository the repository value to set. - * @return the RGitHubPackageResponse object itself. - */ - public RGitHubPackageResponse withRepository(String repository) { - this.repository = repository; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSection.java deleted file mode 100644 index 33723470d7d74..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSection.java +++ /dev/null @@ -1,242 +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.machinelearningservices.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.List; - -/** The RSection model. */ -@Fluent -public class RSection { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RSection.class); - - /* - * The version of R to be installed - */ - @JsonProperty(value = "rVersion") - private String rVersion; - - /* - * Indicates whether the environment is managed by user or by AzureML. - */ - @JsonProperty(value = "userManaged") - private Boolean userManaged; - - /* - * The Rscript path to use if an environment build is not required. - * The path specified gets used to call the user script. - */ - @JsonProperty(value = "rscriptPath") - private String rscriptPath; - - /* - * Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17" - */ - @JsonProperty(value = "snapshotDate") - private String snapshotDate; - - /* - * The CRAN packages to use. - */ - @JsonProperty(value = "cranPackages") - private List cranPackages; - - /* - * The packages directly from GitHub. - */ - @JsonProperty(value = "gitHubPackages") - private List gitHubPackages; - - /* - * The packages from custom urls. - */ - @JsonProperty(value = "customUrlPackages") - private List customUrlPackages; - - /* - * The packages from Bioconductor. - */ - @JsonProperty(value = "bioConductorPackages") - private List bioConductorPackages; - - /** - * Get the rVersion property: The version of R to be installed. - * - * @return the rVersion value. - */ - public String rVersion() { - return this.rVersion; - } - - /** - * Set the rVersion property: The version of R to be installed. - * - * @param rVersion the rVersion value to set. - * @return the RSection object itself. - */ - public RSection withRVersion(String rVersion) { - this.rVersion = rVersion; - return this; - } - - /** - * Get the userManaged property: Indicates whether the environment is managed by user or by AzureML. - * - * @return the userManaged value. - */ - public Boolean userManaged() { - return this.userManaged; - } - - /** - * Set the userManaged property: Indicates whether the environment is managed by user or by AzureML. - * - * @param userManaged the userManaged value to set. - * @return the RSection object itself. - */ - public RSection withUserManaged(Boolean userManaged) { - this.userManaged = userManaged; - return this; - } - - /** - * Get the rscriptPath property: The Rscript path to use if an environment build is not required. The path specified - * gets used to call the user script. - * - * @return the rscriptPath value. - */ - public String rscriptPath() { - return this.rscriptPath; - } - - /** - * Set the rscriptPath property: The Rscript path to use if an environment build is not required. The path specified - * gets used to call the user script. - * - * @param rscriptPath the rscriptPath value to set. - * @return the RSection object itself. - */ - public RSection withRscriptPath(String rscriptPath) { - this.rscriptPath = rscriptPath; - return this; - } - - /** - * Get the snapshotDate property: Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17". - * - * @return the snapshotDate value. - */ - public String snapshotDate() { - return this.snapshotDate; - } - - /** - * Set the snapshotDate property: Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17". - * - * @param snapshotDate the snapshotDate value to set. - * @return the RSection object itself. - */ - public RSection withSnapshotDate(String snapshotDate) { - this.snapshotDate = snapshotDate; - return this; - } - - /** - * Get the cranPackages property: The CRAN packages to use. - * - * @return the cranPackages value. - */ - public List cranPackages() { - return this.cranPackages; - } - - /** - * Set the cranPackages property: The CRAN packages to use. - * - * @param cranPackages the cranPackages value to set. - * @return the RSection object itself. - */ - public RSection withCranPackages(List cranPackages) { - this.cranPackages = cranPackages; - return this; - } - - /** - * Get the gitHubPackages property: The packages directly from GitHub. - * - * @return the gitHubPackages value. - */ - public List gitHubPackages() { - return this.gitHubPackages; - } - - /** - * Set the gitHubPackages property: The packages directly from GitHub. - * - * @param gitHubPackages the gitHubPackages value to set. - * @return the RSection object itself. - */ - public RSection withGitHubPackages(List gitHubPackages) { - this.gitHubPackages = gitHubPackages; - return this; - } - - /** - * Get the customUrlPackages property: The packages from custom urls. - * - * @return the customUrlPackages value. - */ - public List customUrlPackages() { - return this.customUrlPackages; - } - - /** - * Set the customUrlPackages property: The packages from custom urls. - * - * @param customUrlPackages the customUrlPackages value to set. - * @return the RSection object itself. - */ - public RSection withCustomUrlPackages(List customUrlPackages) { - this.customUrlPackages = customUrlPackages; - return this; - } - - /** - * Get the bioConductorPackages property: The packages from Bioconductor. - * - * @return the bioConductorPackages value. - */ - public List bioConductorPackages() { - return this.bioConductorPackages; - } - - /** - * Set the bioConductorPackages property: The packages from Bioconductor. - * - * @param bioConductorPackages the bioConductorPackages value to set. - * @return the RSection object itself. - */ - public RSection withBioConductorPackages(List bioConductorPackages) { - this.bioConductorPackages = bioConductorPackages; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (cranPackages() != null) { - cranPackages().forEach(e -> e.validate()); - } - if (gitHubPackages() != null) { - gitHubPackages().forEach(e -> e.validate()); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSectionResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSectionResponse.java deleted file mode 100644 index 014c39e79d700..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSectionResponse.java +++ /dev/null @@ -1,242 +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.machinelearningservices.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.List; - -/** The RSectionResponse model. */ -@Fluent -public class RSectionResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RSectionResponse.class); - - /* - * The version of R to be installed - */ - @JsonProperty(value = "rVersion") - private String rVersion; - - /* - * Indicates whether the environment is managed by user or by AzureML. - */ - @JsonProperty(value = "userManaged") - private Boolean userManaged; - - /* - * The Rscript path to use if an environment build is not required. - * The path specified gets used to call the user script. - */ - @JsonProperty(value = "rscriptPath") - private String rscriptPath; - - /* - * Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17" - */ - @JsonProperty(value = "snapshotDate") - private String snapshotDate; - - /* - * The CRAN packages to use. - */ - @JsonProperty(value = "cranPackages") - private List cranPackages; - - /* - * The packages directly from GitHub. - */ - @JsonProperty(value = "gitHubPackages") - private List gitHubPackages; - - /* - * The packages from custom urls. - */ - @JsonProperty(value = "customUrlPackages") - private List customUrlPackages; - - /* - * The packages from Bioconductor. - */ - @JsonProperty(value = "bioConductorPackages") - private List bioConductorPackages; - - /** - * Get the rVersion property: The version of R to be installed. - * - * @return the rVersion value. - */ - public String rVersion() { - return this.rVersion; - } - - /** - * Set the rVersion property: The version of R to be installed. - * - * @param rVersion the rVersion value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withRVersion(String rVersion) { - this.rVersion = rVersion; - return this; - } - - /** - * Get the userManaged property: Indicates whether the environment is managed by user or by AzureML. - * - * @return the userManaged value. - */ - public Boolean userManaged() { - return this.userManaged; - } - - /** - * Set the userManaged property: Indicates whether the environment is managed by user or by AzureML. - * - * @param userManaged the userManaged value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withUserManaged(Boolean userManaged) { - this.userManaged = userManaged; - return this; - } - - /** - * Get the rscriptPath property: The Rscript path to use if an environment build is not required. The path specified - * gets used to call the user script. - * - * @return the rscriptPath value. - */ - public String rscriptPath() { - return this.rscriptPath; - } - - /** - * Set the rscriptPath property: The Rscript path to use if an environment build is not required. The path specified - * gets used to call the user script. - * - * @param rscriptPath the rscriptPath value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withRscriptPath(String rscriptPath) { - this.rscriptPath = rscriptPath; - return this; - } - - /** - * Get the snapshotDate property: Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17". - * - * @return the snapshotDate value. - */ - public String snapshotDate() { - return this.snapshotDate; - } - - /** - * Set the snapshotDate property: Date of MRAN snapshot to use in YYYY-MM-DD format, e.g. "2019-04-17". - * - * @param snapshotDate the snapshotDate value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withSnapshotDate(String snapshotDate) { - this.snapshotDate = snapshotDate; - return this; - } - - /** - * Get the cranPackages property: The CRAN packages to use. - * - * @return the cranPackages value. - */ - public List cranPackages() { - return this.cranPackages; - } - - /** - * Set the cranPackages property: The CRAN packages to use. - * - * @param cranPackages the cranPackages value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withCranPackages(List cranPackages) { - this.cranPackages = cranPackages; - return this; - } - - /** - * Get the gitHubPackages property: The packages directly from GitHub. - * - * @return the gitHubPackages value. - */ - public List gitHubPackages() { - return this.gitHubPackages; - } - - /** - * Set the gitHubPackages property: The packages directly from GitHub. - * - * @param gitHubPackages the gitHubPackages value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withGitHubPackages(List gitHubPackages) { - this.gitHubPackages = gitHubPackages; - return this; - } - - /** - * Get the customUrlPackages property: The packages from custom urls. - * - * @return the customUrlPackages value. - */ - public List customUrlPackages() { - return this.customUrlPackages; - } - - /** - * Set the customUrlPackages property: The packages from custom urls. - * - * @param customUrlPackages the customUrlPackages value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withCustomUrlPackages(List customUrlPackages) { - this.customUrlPackages = customUrlPackages; - return this; - } - - /** - * Get the bioConductorPackages property: The packages from Bioconductor. - * - * @return the bioConductorPackages value. - */ - public List bioConductorPackages() { - return this.bioConductorPackages; - } - - /** - * Set the bioConductorPackages property: The packages from Bioconductor. - * - * @param bioConductorPackages the bioConductorPackages value to set. - * @return the RSectionResponse object itself. - */ - public RSectionResponse withBioConductorPackages(List bioConductorPackages) { - this.bioConductorPackages = bioConductorPackages; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (cranPackages() != null) { - cranPackages().forEach(e -> e.validate()); - } - if (gitHubPackages() != null) { - gitHubPackages().forEach(e -> e.validate()); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ReasonCode.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ReasonCode.java index 9931d7233a588..93ba66b5c60c8 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ReasonCode.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ReasonCode.java @@ -30,7 +30,11 @@ public static ReasonCode fromString(String name) { return fromString(name, ReasonCode.class); } - /** @return known ReasonCode values. */ + /** + * Gets known ReasonCode values. + * + * @return known ReasonCode values. + */ public static Collection values() { return values(ReasonCode.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RegistryListCredentialsResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RegistryListCredentialsResult.java index d0f5bf0e8eb07..b43905aeba155 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RegistryListCredentialsResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RegistryListCredentialsResult.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.List; /** The RegistryListCredentialsResult model. */ @Fluent public final class RegistryListCredentialsResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(RegistryListCredentialsResult.class); - /* * The location property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RemoteLoginPortPublicAccess.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RemoteLoginPortPublicAccess.java index b95cf89dd7676..a0fad01587655 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RemoteLoginPortPublicAccess.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RemoteLoginPortPublicAccess.java @@ -30,7 +30,11 @@ public static RemoteLoginPortPublicAccess fromString(String name) { return fromString(name, RemoteLoginPortPublicAccess.class); } - /** @return known RemoteLoginPortPublicAccess values. */ + /** + * Gets known RemoteLoginPortPublicAccess values. + * + * @return known RemoteLoginPortPublicAccess values. + */ public static Collection values() { return values(RemoteLoginPortPublicAccess.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceId.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceId.java index 962c5540dfb63..211313066d87b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceId.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceId.java @@ -6,14 +6,11 @@ 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; /** Represents a resource ID. For example, for a subnet, it is the resource URL for the subnet. */ @Fluent public final class ResourceId { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceId.class); - /* * The ID of the resource */ @@ -47,8 +44,10 @@ public ResourceId withId(String id) { */ public void validate() { if (id() == null) { - throw logger + throw LOGGER .logExceptionAsError(new IllegalArgumentException("Missing required property id in model ResourceId")); } } + + private static final ClientLogger LOGGER = new ClientLogger(ResourceId.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceName.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceName.java index 8f111d7329099..1e4ad9183c0a5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceName.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceName.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The Resource Name. */ @Immutable public final class ResourceName { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceName.class); - /* * The name of the resource. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceQuota.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceQuota.java index 4d49fe276b8ad..95cbd4351c961 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceQuota.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceQuota.java @@ -37,7 +37,7 @@ public interface ResourceQuota { ResourceName name(); /** - * Gets the limit property: The maximum permitted quota of the resource. + * Gets the limit property: Limit. The maximum permitted quota of the resource. * * @return the limit value. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuLocationInfo.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuLocationInfo.java index c0f8a5b2effdb..7f20d7ce7d95e 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuLocationInfo.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuLocationInfo.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The ResourceSkuLocationInfo model. */ @Immutable public final class ResourceSkuLocationInfo { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceSkuLocationInfo.class); - /* * Location of the SKU */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuZoneDetails.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuZoneDetails.java index 8b78b6175027f..f7e788f680f0a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuZoneDetails.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ResourceSkuZoneDetails.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** Describes The zonal capabilities of a SKU. */ @Immutable public final class ResourceSkuZoneDetails { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ResourceSkuZoneDetails.class); - /* * The set of zones that the SKU is available in with the specified * capabilities. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Restriction.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Restriction.java index e2352f06f8e23..df1e9f6296ae5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Restriction.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Restriction.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.List; /** The restriction because of which SKU cannot be used. */ @Fluent public final class Restriction { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Restriction.class); - /* * The type of restrictions. As of now only possible value for this is * location. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettings.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettings.java index 2a45bc1b35913..4b22752f2e905 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettings.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettings.java @@ -5,16 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.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.time.Duration; /** scale settings for AML Compute. */ @Fluent public final class ScaleSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ScaleSettings.class); - /* * Max number of nodes to use */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.java new file mode 100644 index 0000000000000..23c133029024b --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.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.machinelearningservices.models; + +import com.azure.core.annotation.Fluent; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Desired scale settings for the amlCompute. */ +@Fluent +public final class ScaleSettingsInformation { + /* + * scale settings for AML Compute + */ + @JsonProperty(value = "scaleSettings") + private ScaleSettings scaleSettings; + + /** + * Get the scaleSettings property: scale settings for AML Compute. + * + * @return the scaleSettings value. + */ + public ScaleSettings scaleSettings() { + return this.scaleSettings; + } + + /** + * Set the scaleSettings property: scale settings for AML Compute. + * + * @param scaleSettings the scaleSettings value to set. + * @return the ScaleSettingsInformation object itself. + */ + public ScaleSettingsInformation withScaleSettings(ScaleSettings scaleSettings) { + this.scaleSettings = scaleSettings; + return this; + } + + /** + * Validates the instance. + * + * @throws IllegalArgumentException thrown if the instance is not valid. + */ + public void validate() { + if (scaleSettings() != null) { + scaleSettings().validate(); + } + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptReference.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptReference.java index 74dddcc2d4023..ea761d9449a9d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptReference.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptReference.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Script reference. */ @Fluent public final class ScriptReference { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ScriptReference.class); - /* * The storage source of the script: inline, workspace. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptsToExecute.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptsToExecute.java index 6fa53fce30570..e36db76c9b0bd 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptsToExecute.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScriptsToExecute.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Customized setup scripts. */ @Fluent public final class ScriptsToExecute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ScriptsToExecute.class); - /* * Script that's run every time the machine starts. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceManagedResourcesSettings.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceManagedResourcesSettings.java index faeea6ad644c5..859cb9f205a7a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceManagedResourcesSettings.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceManagedResourcesSettings.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The ServiceManagedResourcesSettings model. */ @Fluent public final class ServiceManagedResourcesSettings { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServiceManagedResourcesSettings.class); - /* * The settings for the service managed cosmosdb account. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResource.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResource.java deleted file mode 100644 index 97657d744b9e5..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResource.java +++ /dev/null @@ -1,312 +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.machinelearningservices.models; - -import com.azure.core.management.Region; -import com.azure.core.management.SystemData; -import com.azure.core.util.Context; -import com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner; -import java.util.Map; - -/** An immutable client-side representation of ServiceResource. */ -public interface ServiceResource { - /** - * 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 location property: The geo-location where the resource lives. - * - * @return the location value. - */ - String location(); - - /** - * Gets the tags property: Resource tags. - * - * @return the tags value. - */ - Map tags(); - - /** - * Gets the properties property: Service properties. - * - * @return the properties value. - */ - ServiceResponseBase properties(); - - /** - * Gets the identity property: The identity of the resource. - * - * @return the identity value. - */ - Identity identity(); - - /** - * Gets the sku property: The sku of the workspace. - * - * @return the sku value. - */ - Sku sku(); - - /** - * Gets the systemData property: Read only system data. - * - * @return the systemData value. - */ - SystemData systemData(); - - /** - * Gets the region of the resource. - * - * @return the region of the resource. - */ - Region region(); - - /** - * Gets the name of the resource region. - * - * @return the name of the resource region. - */ - String regionName(); - - /** - * Gets the inner com.azure.resourcemanager.machinelearningservices.fluent.models.ServiceResourceInner object. - * - * @return the inner object. - */ - ServiceResourceInner innerModel(); - - /** The entirety of the ServiceResource definition. */ - interface Definition - extends DefinitionStages.Blank, DefinitionStages.WithParentResource, DefinitionStages.WithCreate { - } - /** The ServiceResource definition stages. */ - interface DefinitionStages { - /** The first stage of the ServiceResource definition. */ - interface Blank extends WithParentResource { - } - /** The stage of the ServiceResource definition allowing to specify parent resource. */ - interface WithParentResource { - /** - * Specifies resourceGroupName, workspaceName. - * - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @return the next definition stage. - */ - WithCreate withExistingWorkspace(String resourceGroupName, String workspaceName); - } - /** - * The stage of the ServiceResource 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.WithLocation, - DefinitionStages.WithDescription, - DefinitionStages.WithKvTags, - DefinitionStages.WithProperties, - DefinitionStages.WithKeys, - DefinitionStages.WithEnvironmentImageRequest { - /** - * Executes the create request. - * - * @return the created resource. - */ - ServiceResource create(); - - /** - * Executes the create request. - * - * @param context The context to associate with this operation. - * @return the created resource. - */ - ServiceResource create(Context context); - } - /** The stage of the ServiceResource definition allowing to specify location. */ - interface WithLocation { - /** - * Specifies the region for the resource. - * - * @param location The name of the Azure location/region. - * @return the next definition stage. - */ - WithCreate withRegion(Region location); - - /** - * Specifies the region for the resource. - * - * @param location The name of the Azure location/region. - * @return the next definition stage. - */ - WithCreate withRegion(String location); - } - /** The stage of the ServiceResource definition allowing to specify description. */ - interface WithDescription { - /** - * Specifies the description property: The description of the service.. - * - * @param description The description of the service. - * @return the next definition stage. - */ - WithCreate withDescription(String description); - } - /** The stage of the ServiceResource definition allowing to specify kvTags. */ - interface WithKvTags { - /** - * Specifies the kvTags property: The service tag dictionary. Tags are mutable.. - * - * @param kvTags The service tag dictionary. Tags are mutable. - * @return the next definition stage. - */ - WithCreate withKvTags(Map kvTags); - } - /** The stage of the ServiceResource definition allowing to specify properties. */ - interface WithProperties { - /** - * Specifies the properties property: The service properties dictionary. Properties are immutable.. - * - * @param properties The service properties dictionary. Properties are immutable. - * @return the next definition stage. - */ - WithCreate withProperties(Map properties); - } - /** The stage of the ServiceResource definition allowing to specify keys. */ - interface WithKeys { - /** - * Specifies the keys property: The authentication keys.. - * - * @param keys The authentication keys. - * @return the next definition stage. - */ - WithCreate withKeys(CreateServiceRequestKeys keys); - } - /** The stage of the ServiceResource definition allowing to specify environmentImageRequest. */ - interface WithEnvironmentImageRequest { - /** - * Specifies the environmentImageRequest property: The Environment, models and assets needed for - * inferencing.. - * - * @param environmentImageRequest The Environment, models and assets needed for inferencing. - * @return the next definition stage. - */ - WithCreate withEnvironmentImageRequest(CreateServiceRequestEnvironmentImageRequest environmentImageRequest); - } - } - /** - * Begins update for the ServiceResource resource. - * - * @return the stage of resource update. - */ - ServiceResource.Update update(); - - /** The template for ServiceResource update. */ - interface Update - extends UpdateStages.WithDescription, - UpdateStages.WithKvTags, - UpdateStages.WithProperties, - UpdateStages.WithKeys, - UpdateStages.WithEnvironmentImageRequest { - /** - * Executes the update request. - * - * @return the updated resource. - */ - ServiceResource apply(); - - /** - * Executes the update request. - * - * @param context The context to associate with this operation. - * @return the updated resource. - */ - ServiceResource apply(Context context); - } - /** The ServiceResource update stages. */ - interface UpdateStages { - /** The stage of the ServiceResource update allowing to specify description. */ - interface WithDescription { - /** - * Specifies the description property: The description of the service.. - * - * @param description The description of the service. - * @return the next definition stage. - */ - Update withDescription(String description); - } - /** The stage of the ServiceResource update allowing to specify kvTags. */ - interface WithKvTags { - /** - * Specifies the kvTags property: The service tag dictionary. Tags are mutable.. - * - * @param kvTags The service tag dictionary. Tags are mutable. - * @return the next definition stage. - */ - Update withKvTags(Map kvTags); - } - /** The stage of the ServiceResource update allowing to specify properties. */ - interface WithProperties { - /** - * Specifies the properties property: The service properties dictionary. Properties are immutable.. - * - * @param properties The service properties dictionary. Properties are immutable. - * @return the next definition stage. - */ - Update withProperties(Map properties); - } - /** The stage of the ServiceResource update allowing to specify keys. */ - interface WithKeys { - /** - * Specifies the keys property: The authentication keys.. - * - * @param keys The authentication keys. - * @return the next definition stage. - */ - Update withKeys(CreateServiceRequestKeys keys); - } - /** The stage of the ServiceResource update allowing to specify environmentImageRequest. */ - interface WithEnvironmentImageRequest { - /** - * Specifies the environmentImageRequest property: The Environment, models and assets needed for - * inferencing.. - * - * @param environmentImageRequest The Environment, models and assets needed for inferencing. - * @return the next definition stage. - */ - Update withEnvironmentImageRequest(CreateServiceRequestEnvironmentImageRequest environmentImageRequest); - } - } - /** - * Refreshes the resource to sync with Azure. - * - * @return the refreshed resource. - */ - ServiceResource refresh(); - - /** - * Refreshes the resource to sync with Azure. - * - * @param context The context to associate with this operation. - * @return the refreshed resource. - */ - ServiceResource refresh(Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBase.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBase.java deleted file mode 100644 index d48ae950585c2..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBase.java +++ /dev/null @@ -1,178 +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.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonSubTypes; -import com.fasterxml.jackson.annotation.JsonTypeInfo; -import com.fasterxml.jackson.annotation.JsonTypeName; -import java.util.Map; - -/** - * The base service response. The correct inherited response based on computeType will be returned (ex. - * ACIServiceResponse). - */ -@JsonTypeInfo( - use = JsonTypeInfo.Id.NAME, - include = JsonTypeInfo.As.PROPERTY, - property = "computeType", - defaultImpl = ServiceResponseBase.class) -@JsonTypeName("ServiceResponseBase") -@JsonSubTypes({ - @JsonSubTypes.Type(name = "ACI", value = AciServiceResponse.class), - @JsonSubTypes.Type(name = "Custom", value = AksVariantResponse.class) -}) -@Fluent -public class ServiceResponseBase { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServiceResponseBase.class); - - /* - * The service description. - */ - @JsonProperty(value = "description") - private String description; - - /* - * The service tag dictionary. Tags are mutable. - */ - @JsonProperty(value = "kvTags") - private Map kvTags; - - /* - * The service property dictionary. Properties are immutable. - */ - @JsonProperty(value = "properties") - private Map properties; - - /* - * The current state of the service. - */ - @JsonProperty(value = "state", access = JsonProperty.Access.WRITE_ONLY) - private WebServiceState state; - - /* - * The error details. - */ - @JsonProperty(value = "error", access = JsonProperty.Access.WRITE_ONLY) - private ServiceResponseBaseError error; - - /* - * The deployment type for the service. - */ - @JsonProperty(value = "deploymentType") - private DeploymentType deploymentType; - - /** - * Get the description property: The service description. - * - * @return the description value. - */ - public String description() { - return this.description; - } - - /** - * Set the description property: The service description. - * - * @param description the description value to set. - * @return the ServiceResponseBase object itself. - */ - public ServiceResponseBase withDescription(String description) { - this.description = description; - return this; - } - - /** - * Get the kvTags property: The service tag dictionary. Tags are mutable. - * - * @return the kvTags value. - */ - public Map kvTags() { - return this.kvTags; - } - - /** - * Set the kvTags property: The service tag dictionary. Tags are mutable. - * - * @param kvTags the kvTags value to set. - * @return the ServiceResponseBase object itself. - */ - public ServiceResponseBase withKvTags(Map kvTags) { - this.kvTags = kvTags; - return this; - } - - /** - * Get the properties property: The service property dictionary. Properties are immutable. - * - * @return the properties value. - */ - public Map properties() { - return this.properties; - } - - /** - * Set the properties property: The service property dictionary. Properties are immutable. - * - * @param properties the properties value to set. - * @return the ServiceResponseBase object itself. - */ - public ServiceResponseBase withProperties(Map properties) { - this.properties = properties; - return this; - } - - /** - * Get the state property: The current state of the service. - * - * @return the state value. - */ - public WebServiceState state() { - return this.state; - } - - /** - * Get the error property: The error details. - * - * @return the error value. - */ - public ServiceResponseBaseError error() { - return this.error; - } - - /** - * Get the deploymentType property: The deployment type for the service. - * - * @return the deploymentType value. - */ - public DeploymentType deploymentType() { - return this.deploymentType; - } - - /** - * Set the deploymentType property: The deployment type for the service. - * - * @param deploymentType the deploymentType value to set. - * @return the ServiceResponseBase object itself. - */ - public ServiceResponseBase withDeploymentType(DeploymentType deploymentType) { - this.deploymentType = deploymentType; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - if (error() != null) { - error().validate(); - } - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBaseError.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBaseError.java deleted file mode 100644 index 91b6e51e5caf0..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBaseError.java +++ /dev/null @@ -1,24 +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.machinelearningservices.models; - -import com.azure.core.annotation.Immutable; -import com.azure.core.management.exception.ManagementError; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; - -/** The error details. */ -@Immutable -public final class ServiceResponseBaseError extends ManagementError { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ServiceResponseBaseError.class); - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SetupScripts.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SetupScripts.java index c7a2d56f449d3..a6c1355de9794 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SetupScripts.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SetupScripts.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Details of customized scripts to execute for setting up the cluster. */ @Fluent public final class SetupScripts { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SetupScripts.class); - /* * Customized setup scripts */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SharedPrivateLinkResource.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SharedPrivateLinkResource.java index 7744d6de11457..57525dc0a18f6 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SharedPrivateLinkResource.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SharedPrivateLinkResource.java @@ -5,17 +5,12 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.fluent.models.SharedPrivateLinkResourceProperty; import com.fasterxml.jackson.annotation.JsonProperty; /** The SharedPrivateLinkResource model. */ -@JsonFlatten @Fluent -public class SharedPrivateLinkResource { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResource.class); - +public final class SharedPrivateLinkResource { /* * Unique name of the private link. */ @@ -23,29 +18,10 @@ public class SharedPrivateLinkResource { private String name; /* - * The resource id that private link links to. - */ - @JsonProperty(value = "properties.privateLinkResourceId") - private String privateLinkResourceId; - - /* - * The private link resource group id. + * Resource properties. */ - @JsonProperty(value = "properties.groupId") - private String groupId; - - /* - * Request message. - */ - @JsonProperty(value = "properties.requestMessage") - private String requestMessage; - - /* - * Indicates whether the connection has been Approved/Rejected/Removed by - * the owner of the service. - */ - @JsonProperty(value = "properties.status") - private PrivateEndpointServiceConnectionStatus status; + @JsonProperty(value = "properties") + private SharedPrivateLinkResourceProperty innerProperties; /** * Get the name property: Unique name of the private link. @@ -67,13 +43,22 @@ public SharedPrivateLinkResource withName(String name) { return this; } + /** + * Get the innerProperties property: Resource properties. + * + * @return the innerProperties value. + */ + private SharedPrivateLinkResourceProperty innerProperties() { + return this.innerProperties; + } + /** * Get the privateLinkResourceId property: The resource id that private link links to. * * @return the privateLinkResourceId value. */ public String privateLinkResourceId() { - return this.privateLinkResourceId; + return this.innerProperties() == null ? null : this.innerProperties().privateLinkResourceId(); } /** @@ -83,7 +68,10 @@ public String privateLinkResourceId() { * @return the SharedPrivateLinkResource object itself. */ public SharedPrivateLinkResource withPrivateLinkResourceId(String privateLinkResourceId) { - this.privateLinkResourceId = privateLinkResourceId; + if (this.innerProperties() == null) { + this.innerProperties = new SharedPrivateLinkResourceProperty(); + } + this.innerProperties().withPrivateLinkResourceId(privateLinkResourceId); return this; } @@ -93,7 +81,7 @@ public SharedPrivateLinkResource withPrivateLinkResourceId(String privateLinkRes * @return the groupId value. */ public String groupId() { - return this.groupId; + return this.innerProperties() == null ? null : this.innerProperties().groupId(); } /** @@ -103,7 +91,10 @@ public String groupId() { * @return the SharedPrivateLinkResource object itself. */ public SharedPrivateLinkResource withGroupId(String groupId) { - this.groupId = groupId; + if (this.innerProperties() == null) { + this.innerProperties = new SharedPrivateLinkResourceProperty(); + } + this.innerProperties().withGroupId(groupId); return this; } @@ -113,7 +104,7 @@ public SharedPrivateLinkResource withGroupId(String groupId) { * @return the requestMessage value. */ public String requestMessage() { - return this.requestMessage; + return this.innerProperties() == null ? null : this.innerProperties().requestMessage(); } /** @@ -123,7 +114,10 @@ public String requestMessage() { * @return the SharedPrivateLinkResource object itself. */ public SharedPrivateLinkResource withRequestMessage(String requestMessage) { - this.requestMessage = requestMessage; + if (this.innerProperties() == null) { + this.innerProperties = new SharedPrivateLinkResourceProperty(); + } + this.innerProperties().withRequestMessage(requestMessage); return this; } @@ -134,7 +128,7 @@ public SharedPrivateLinkResource withRequestMessage(String requestMessage) { * @return the status value. */ public PrivateEndpointServiceConnectionStatus status() { - return this.status; + return this.innerProperties() == null ? null : this.innerProperties().status(); } /** @@ -145,7 +139,10 @@ public PrivateEndpointServiceConnectionStatus status() { * @return the SharedPrivateLinkResource object itself. */ public SharedPrivateLinkResource withStatus(PrivateEndpointServiceConnectionStatus status) { - this.status = status; + if (this.innerProperties() == null) { + this.innerProperties = new SharedPrivateLinkResourceProperty(); + } + this.innerProperties().withStatus(status); return this; } @@ -155,5 +152,8 @@ public SharedPrivateLinkResource withStatus(PrivateEndpointServiceConnectionStat * @throws IllegalArgumentException thrown if the instance is not valid. */ public void validate() { + if (innerProperties() != null) { + innerProperties().validate(); + } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Sku.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Sku.java index 6af3d430cce58..957d37d594025 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Sku.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Sku.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Sku of the resource. */ @Fluent public final class Sku { - @JsonIgnore private final ClientLogger logger = new ClientLogger(Sku.class); - /* * Name of the sku */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuCapability.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuCapability.java index 3e458016d8590..e906229654602 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuCapability.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuCapability.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Features/user capabilities associated with the sku. */ @Fluent public final class SkuCapability { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuCapability.class); - /* * Capability/Feature ID */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuListResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuListResult.java index 234136f5d8ba1..2e6e6e1af8ca5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuListResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SkuListResult.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceSkuInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** List of skus with features. */ @Fluent public final class SkuListResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SkuListResult.class); - /* * The value property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SparkMavenPackage.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SparkMavenPackage.java deleted file mode 100644 index 2fef06f7c8b1c..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SparkMavenPackage.java +++ /dev/null @@ -1,102 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The SparkMavenPackage model. */ -@Fluent -public final class SparkMavenPackage { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SparkMavenPackage.class); - - /* - * The group property. - */ - @JsonProperty(value = "group") - private String group; - - /* - * The artifact property. - */ - @JsonProperty(value = "artifact") - private String artifact; - - /* - * The version property. - */ - @JsonProperty(value = "version") - private String version; - - /** - * Get the group property: The group property. - * - * @return the group value. - */ - public String group() { - return this.group; - } - - /** - * Set the group property: The group property. - * - * @param group the group value to set. - * @return the SparkMavenPackage object itself. - */ - public SparkMavenPackage withGroup(String group) { - this.group = group; - return this; - } - - /** - * Get the artifact property: The artifact property. - * - * @return the artifact value. - */ - public String artifact() { - return this.artifact; - } - - /** - * Set the artifact property: The artifact property. - * - * @param artifact the artifact value to set. - * @return the SparkMavenPackage object itself. - */ - public SparkMavenPackage withArtifact(String artifact) { - this.artifact = artifact; - return this; - } - - /** - * Get the version property: The version property. - * - * @return the version value. - */ - public String version() { - return this.version; - } - - /** - * Set the version property: The version property. - * - * @param version the version value to set. - * @return the SparkMavenPackage object itself. - */ - public SparkMavenPackage withVersion(String version) { - this.version = version; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SshPublicAccess.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SshPublicAccess.java index 24403e44b926e..e9aad368f347a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SshPublicAccess.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SshPublicAccess.java @@ -27,7 +27,11 @@ public static SshPublicAccess fromString(String name) { return fromString(name, SshPublicAccess.class); } - /** @return known SshPublicAccess values. */ + /** + * Gets known SshPublicAccess values. + * + * @return known SshPublicAccess values. + */ public static Collection values() { return values(SshPublicAccess.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfiguration.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfiguration.java index 013504eab4307..ade42eeb17006 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfiguration.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfiguration.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The ssl configuration for scoring. */ @Fluent public final class SslConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SslConfiguration.class); - /* * Enable or disable ssl for scoring */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfigurationStatus.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfigurationStatus.java index ae0426df88857..50f228c9c7f94 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfigurationStatus.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SslConfigurationStatus.java @@ -30,7 +30,11 @@ public static SslConfigurationStatus fromString(String name) { return fromString(name, SslConfigurationStatus.class); } - /** @return known SslConfigurationStatus values. */ + /** + * Gets known SslConfigurationStatus values. + * + * @return known SslConfigurationStatus values. + */ public static Collection values() { return values(SslConfigurationStatus.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Status.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Status.java index 76a2517b3ac1a..30e5959fb0201 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Status.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Status.java @@ -46,7 +46,11 @@ public static Status fromString(String name) { return fromString(name, Status.class); } - /** @return known Status values. */ + /** + * Gets known Status values. + * + * @return known Status values. + */ public static Collection values() { return values(Status.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/StorageAccounts.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/StorageAccounts.java deleted file mode 100644 index 9a16ff0fb526a..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/StorageAccounts.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.machinelearningservices.models; - -import com.azure.core.http.rest.Response; -import com.azure.core.util.Context; - -/** Resource collection API of StorageAccounts. */ -public interface StorageAccounts { - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - ListStorageAccountKeysResult listKeys(String resourceGroupName, String workspaceName); - - /** - * @param resourceGroupName Name of the resource group in which workspace is located. - * @param workspaceName Name of Azure Machine Learning workspace. - * @param context The context to associate with this operation. - * @throws IllegalArgumentException thrown if parameters fail the validation. - * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. - * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. - */ - Response listKeysWithResponse( - String resourceGroupName, String workspaceName, Context context); -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSpark.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSpark.java index 8e0d76206e0d0..03e983ebf199b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSpark.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSpark.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,30 +14,28 @@ @JsonTypeName("SynapseSpark") @Fluent public final class SynapseSpark extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SynapseSpark.class); - /* - * AKS properties + * The properties property. */ @JsonProperty(value = "properties") - private SynapseSparkPoolPropertiesAutoGenerated properties; + private SynapseSparkProperties properties; /** - * Get the properties property: AKS properties. + * Get the properties property: The properties property. * * @return the properties value. */ - public SynapseSparkPoolPropertiesAutoGenerated properties() { + public SynapseSparkProperties properties() { return this.properties; } /** - * Set the properties property: AKS properties. + * Set the properties property: The properties property. * * @param properties the properties value to set. * @return the SynapseSpark object itself. */ - public SynapseSpark withProperties(SynapseSparkPoolPropertiesAutoGenerated properties) { + public SynapseSpark withProperties(SynapseSparkProperties properties) { this.properties = properties; return this; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolPropertiesAutoGenerated.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkProperties.java similarity index 76% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolPropertiesAutoGenerated.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkProperties.java index 43a026eb64733..658857090e362 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkPoolPropertiesAutoGenerated.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SynapseSparkProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; -/** AKS properties. */ +/** The SynapseSparkProperties model. */ @Fluent -public final class SynapseSparkPoolPropertiesAutoGenerated { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SynapseSparkPoolPropertiesAutoGenerated.class); - +public final class SynapseSparkProperties { /* * Auto scale properties. */ @@ -87,9 +83,9 @@ public AutoScaleProperties autoScaleProperties() { * Set the autoScaleProperties property: Auto scale properties. * * @param autoScaleProperties the autoScaleProperties value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withAutoScaleProperties(AutoScaleProperties autoScaleProperties) { + public SynapseSparkProperties withAutoScaleProperties(AutoScaleProperties autoScaleProperties) { this.autoScaleProperties = autoScaleProperties; return this; } @@ -107,9 +103,9 @@ public AutoPauseProperties autoPauseProperties() { * Set the autoPauseProperties property: Auto pause properties. * * @param autoPauseProperties the autoPauseProperties value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withAutoPauseProperties(AutoPauseProperties autoPauseProperties) { + public SynapseSparkProperties withAutoPauseProperties(AutoPauseProperties autoPauseProperties) { this.autoPauseProperties = autoPauseProperties; return this; } @@ -127,9 +123,9 @@ public String sparkVersion() { * Set the sparkVersion property: Spark version. * * @param sparkVersion the sparkVersion value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withSparkVersion(String sparkVersion) { + public SynapseSparkProperties withSparkVersion(String sparkVersion) { this.sparkVersion = sparkVersion; return this; } @@ -147,9 +143,9 @@ public Integer nodeCount() { * Set the nodeCount property: The number of compute nodes currently assigned to the compute. * * @param nodeCount the nodeCount value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withNodeCount(Integer nodeCount) { + public SynapseSparkProperties withNodeCount(Integer nodeCount) { this.nodeCount = nodeCount; return this; } @@ -167,9 +163,9 @@ public String nodeSize() { * Set the nodeSize property: Node size. * * @param nodeSize the nodeSize value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withNodeSize(String nodeSize) { + public SynapseSparkProperties withNodeSize(String nodeSize) { this.nodeSize = nodeSize; return this; } @@ -187,9 +183,9 @@ public String nodeSizeFamily() { * Set the nodeSizeFamily property: Node size family. * * @param nodeSizeFamily the nodeSizeFamily value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withNodeSizeFamily(String nodeSizeFamily) { + public SynapseSparkProperties withNodeSizeFamily(String nodeSizeFamily) { this.nodeSizeFamily = nodeSizeFamily; return this; } @@ -207,9 +203,9 @@ public String subscriptionId() { * Set the subscriptionId property: Azure subscription identifier. * * @param subscriptionId the subscriptionId value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withSubscriptionId(String subscriptionId) { + public SynapseSparkProperties withSubscriptionId(String subscriptionId) { this.subscriptionId = subscriptionId; return this; } @@ -227,9 +223,9 @@ public String resourceGroup() { * Set the resourceGroup property: Name of the resource group in which workspace is located. * * @param resourceGroup the resourceGroup value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withResourceGroup(String resourceGroup) { + public SynapseSparkProperties withResourceGroup(String resourceGroup) { this.resourceGroup = resourceGroup; return this; } @@ -247,9 +243,9 @@ public String workspaceName() { * Set the workspaceName property: Name of Azure Machine Learning workspace. * * @param workspaceName the workspaceName value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withWorkspaceName(String workspaceName) { + public SynapseSparkProperties withWorkspaceName(String workspaceName) { this.workspaceName = workspaceName; return this; } @@ -267,9 +263,9 @@ public String poolName() { * Set the poolName property: Pool name. * * @param poolName the poolName value to set. - * @return the SynapseSparkPoolPropertiesAutoGenerated object itself. + * @return the SynapseSparkProperties object itself. */ - public SynapseSparkPoolPropertiesAutoGenerated withPoolName(String poolName) { + public SynapseSparkProperties withPoolName(String poolName) { this.poolName = poolName; return this; } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SystemService.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SystemService.java index c9ff23e491372..1ebabf8d804af 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SystemService.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SystemService.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** A system service running on a compute. */ @Immutable public final class SystemService { - @JsonIgnore private final ClientLogger logger = new ClientLogger(SystemService.class); - /* * The type of this system service. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnderlyingResourceAction.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnderlyingResourceAction.java index ed2a28becd3ef..b069692445276 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnderlyingResourceAction.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnderlyingResourceAction.java @@ -27,7 +27,11 @@ public static UnderlyingResourceAction fromString(String name) { return fromString(name, UnderlyingResourceAction.class); } - /** @return known UnderlyingResourceAction values. */ + /** + * Gets known UnderlyingResourceAction values. + * + * @return known UnderlyingResourceAction values. + */ public static Collection values() { return values(UnderlyingResourceAction.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnitOfMeasure.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnitOfMeasure.java index ea58f459588de..0464c9368d3c3 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnitOfMeasure.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UnitOfMeasure.java @@ -24,7 +24,11 @@ public static UnitOfMeasure fromString(String name) { return fromString(name, UnitOfMeasure.class); } - /** @return known UnitOfMeasure values. */ + /** + * Gets known UnitOfMeasure values. + * + * @return known UnitOfMeasure values. + */ public static Collection values() { return values(UnitOfMeasure.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UpdateWorkspaceQuotas.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UpdateWorkspaceQuotas.java index 7ec7492795d9b..13613a080212a 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UpdateWorkspaceQuotas.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UpdateWorkspaceQuotas.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The properties for update Quota response. */ @Fluent public final class UpdateWorkspaceQuotas { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UpdateWorkspaceQuotas.class); - /* * Specifies the resource ID. */ @@ -27,7 +23,7 @@ public final class UpdateWorkspaceQuotas { private String type; /* - * The maximum permitted quota of the resource. + * Limit. The maximum permitted quota of the resource. */ @JsonProperty(value = "limit") private Long limit; @@ -39,7 +35,7 @@ public final class UpdateWorkspaceQuotas { private QuotaUnit unit; /* - * Status of update workspace quota. + * Update Workspace Quota Status. Status of update workspace quota. */ @JsonProperty(value = "status") private Status status; @@ -63,7 +59,7 @@ public String type() { } /** - * Get the limit property: The maximum permitted quota of the resource. + * Get the limit property: Limit. The maximum permitted quota of the resource. * * @return the limit value. */ @@ -72,7 +68,7 @@ public Long limit() { } /** - * Set the limit property: The maximum permitted quota of the resource. + * Set the limit property: Limit. The maximum permitted quota of the resource. * * @param limit the limit value to set. * @return the UpdateWorkspaceQuotas object itself. @@ -92,7 +88,7 @@ public QuotaUnit unit() { } /** - * Get the status property: Status of update workspace quota. + * Get the status property: Update Workspace Quota Status. Status of update workspace quota. * * @return the status value. */ @@ -101,7 +97,7 @@ public Status status() { } /** - * Set the status property: Status of update workspace quota. + * Set the status property: Update Workspace Quota Status. Status of update workspace quota. * * @param status the status value to set. * @return the UpdateWorkspaceQuotas object itself. diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageName.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageName.java index 07a21f99a3dae..e52638b92596d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageName.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageName.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Immutable; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The Usage Names. */ @Immutable public final class UsageName { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UsageName.class); - /* * The name of the resource. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageUnit.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageUnit.java index 84603281cc8a7..dcfa95c9e2350 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageUnit.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UsageUnit.java @@ -24,7 +24,11 @@ public static UsageUnit fromString(String name) { return fromString(name, UsageUnit.class); } - /** @return known UsageUnit values. */ + /** + * Gets known UsageUnit values. + * + * @return known UsageUnit values. + */ public static Collection values() { return values(UsageUnit.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Usages.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Usages.java index 5c7ed7c6a09c0..d9dff0e84f48c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Usages.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Usages.java @@ -16,7 +16,8 @@ public interface Usages { * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ PagedIterable list(String location); @@ -28,7 +29,8 @@ public interface Usages { * @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 current usage information as well as limits for AML resources for given subscription and location. + * @return the current usage information as well as limits for AML resources for given subscription and location as + * paginated response with {@link PagedIterable}. */ PagedIterable list(String location, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAccountCredentials.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAccountCredentials.java index 20cb550c0fac4..3b845a41ee32b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAccountCredentials.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAccountCredentials.java @@ -6,35 +6,33 @@ import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** Settings for user account that gets created on each on the nodes of a compute. */ @Fluent public final class UserAccountCredentials { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UserAccountCredentials.class); - /* - * Name of the administrator user account which can be used to SSH to - * nodes. + * User name. Name of the administrator user account which can be used to + * SSH to nodes. */ @JsonProperty(value = "adminUserName", required = true) private String adminUsername; /* - * SSH public key of the administrator user account. + * SSH public key. SSH public key of the administrator user account. */ @JsonProperty(value = "adminUserSshPublicKey") private String adminUserSshPublicKey; /* - * Password of the administrator user account. + * Password. Password of the administrator user account. */ @JsonProperty(value = "adminUserPassword") private String adminUserPassword; /** - * Get the adminUsername property: Name of the administrator user account which can be used to SSH to nodes. + * Get the adminUsername property: User name. Name of the administrator user account which can be used to SSH to + * nodes. * * @return the adminUsername value. */ @@ -43,7 +41,8 @@ public String adminUsername() { } /** - * Set the adminUsername property: Name of the administrator user account which can be used to SSH to nodes. + * Set the adminUsername property: User name. Name of the administrator user account which can be used to SSH to + * nodes. * * @param adminUsername the adminUsername value to set. * @return the UserAccountCredentials object itself. @@ -54,7 +53,7 @@ public UserAccountCredentials withAdminUsername(String adminUsername) { } /** - * Get the adminUserSshPublicKey property: SSH public key of the administrator user account. + * Get the adminUserSshPublicKey property: SSH public key. SSH public key of the administrator user account. * * @return the adminUserSshPublicKey value. */ @@ -63,7 +62,7 @@ public String adminUserSshPublicKey() { } /** - * Set the adminUserSshPublicKey property: SSH public key of the administrator user account. + * Set the adminUserSshPublicKey property: SSH public key. SSH public key of the administrator user account. * * @param adminUserSshPublicKey the adminUserSshPublicKey value to set. * @return the UserAccountCredentials object itself. @@ -74,7 +73,7 @@ public UserAccountCredentials withAdminUserSshPublicKey(String adminUserSshPubli } /** - * Get the adminUserPassword property: Password of the administrator user account. + * Get the adminUserPassword property: Password. Password of the administrator user account. * * @return the adminUserPassword value. */ @@ -83,7 +82,7 @@ public String adminUserPassword() { } /** - * Set the adminUserPassword property: Password of the administrator user account. + * Set the adminUserPassword property: Password. Password of the administrator user account. * * @param adminUserPassword the adminUserPassword value to set. * @return the UserAccountCredentials object itself. @@ -100,10 +99,12 @@ public UserAccountCredentials withAdminUserPassword(String adminUserPassword) { */ public void validate() { if (adminUsername() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException( "Missing required property adminUsername in model UserAccountCredentials")); } } + + private static final ClientLogger LOGGER = new ClientLogger(UserAccountCredentials.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAssignedIdentity.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAssignedIdentity.java index 24beefcc18125..5d5efd9e9b765 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAssignedIdentity.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAssignedIdentity.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** User Assigned Identity. */ @Immutable public class UserAssignedIdentity { - @JsonIgnore private final ClientLogger logger = new ClientLogger(UserAssignedIdentity.class); - /* * The principal ID of the user assigned identity. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMPriceOSType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMPriceOSType.java index 4979b2019f71c..792a0b7d987ae 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMPriceOSType.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMPriceOSType.java @@ -27,7 +27,11 @@ public static VMPriceOSType fromString(String name) { return fromString(name, VMPriceOSType.class); } - /** @return known VMPriceOSType values. */ + /** + * Gets known VMPriceOSType values. + * + * @return known VMPriceOSType values. + */ public static Collection values() { return values(VMPriceOSType.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMTier.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMTier.java index cf57260261473..72b7a4a86ce60 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMTier.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VMTier.java @@ -30,7 +30,11 @@ public static VMTier fromString(String name) { return fromString(name, VMTier.class); } - /** @return known VMTier values. */ + /** + * Gets known VMTier values. + * + * @return known VMTier values. + */ public static Collection values() { return values(VMTier.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ValueFormat.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ValueFormat.java index 0ed4fcb436095..4c2d1252d2c0b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ValueFormat.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ValueFormat.java @@ -24,7 +24,11 @@ public static ValueFormat fromString(String name) { return fromString(name, ValueFormat.class); } - /** @return known ValueFormat values. */ + /** + * Gets known ValueFormat values. + * + * @return known ValueFormat values. + */ public static Collection values() { return values(ValueFormat.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VariantType.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VariantType.java deleted file mode 100644 index 7e03450aef11d..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VariantType.java +++ /dev/null @@ -1,34 +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.machinelearningservices.models; - -import com.azure.core.util.ExpandableStringEnum; -import com.fasterxml.jackson.annotation.JsonCreator; -import java.util.Collection; - -/** Defines values for VariantType. */ -public final class VariantType extends ExpandableStringEnum { - /** Static value Control for VariantType. */ - public static final VariantType CONTROL = fromString("Control"); - - /** Static value Treatment for VariantType. */ - public static final VariantType TREATMENT = fromString("Treatment"); - - /** - * Creates or finds a VariantType from its string representation. - * - * @param name a name to look for. - * @return the corresponding VariantType. - */ - @JsonCreator - public static VariantType fromString(String name) { - return fromString(name, VariantType.class); - } - - /** @return known VariantType values. */ - public static Collection values() { - return values(VariantType.class); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachine.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachine.java index 43b7c6cec7075..3ee696d662950 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachine.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachine.java @@ -5,8 +5,6 @@ package com.azure.resourcemanager.machinelearningservices.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 com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -16,8 +14,6 @@ @JsonTypeName("VirtualMachine") @Fluent public final class VirtualMachine extends Compute { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachine.class); - /* * The properties property. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineImage.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineImage.java index 5ce0176455852..b10cf1032b302 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineImage.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineImage.java @@ -6,14 +6,11 @@ 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; /** Virtual Machine image for Windows AML Compute. */ @Fluent public final class VirtualMachineImage { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineImage.class); - /* * Virtual Machine image path */ @@ -47,9 +44,11 @@ public VirtualMachineImage withId(String id) { */ public void validate() { if (id() == null) { - throw logger + throw LOGGER .logExceptionAsError( new IllegalArgumentException("Missing required property id in model VirtualMachineImage")); } } + + private static final ClientLogger LOGGER = new ClientLogger(VirtualMachineImage.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineProperties.java index 1d4f51c7533cb..34dc9f9bff18c 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineProperties.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineProperties.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The VirtualMachineProperties model. */ @Fluent public final class VirtualMachineProperties { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineProperties.class); - /* * Virtual Machine size */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSecrets.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSecrets.java index bb51bbc1a9502..25700c99c9c5d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSecrets.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSecrets.java @@ -5,9 +5,7 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeSecretsInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonTypeInfo; import com.fasterxml.jackson.annotation.JsonTypeName; @@ -17,8 +15,6 @@ @JsonTypeName("VirtualMachine") @Fluent public final class VirtualMachineSecrets extends ComputeSecretsInner { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineSecrets.class); - /* * Admin credentials for virtual machine. */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSize.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSize.java index f8e25bb6f8b54..084a85e1a4fc5 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSize.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSize.java @@ -5,65 +5,68 @@ package com.azure.resourcemanager.machinelearningservices.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.List; /** Describes the properties of a VM size. */ @Fluent public final class VirtualMachineSize { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineSize.class); - /* - * The name of the virtual machine size. + * Virtual Machine size name The name of the virtual machine size. */ @JsonProperty(value = "name", access = JsonProperty.Access.WRITE_ONLY) private String name; /* - * The family name of the virtual machine size. + * Virtual Machine family name The family name of the virtual machine size. */ @JsonProperty(value = "family", access = JsonProperty.Access.WRITE_ONLY) private String family; /* - * The number of vCPUs supported by the virtual machine size. + * Number of vPUs The number of vCPUs supported by the virtual machine + * size. */ @JsonProperty(value = "vCPUs", access = JsonProperty.Access.WRITE_ONLY) private Integer vCPUs; /* - * The number of gPUs supported by the virtual machine size. + * Number of gPUs The number of gPUs supported by the virtual machine size. */ @JsonProperty(value = "gpus", access = JsonProperty.Access.WRITE_ONLY) private Integer gpus; /* - * The OS VHD disk size, in MB, allowed by the virtual machine size. + * OS VHD Disk size The OS VHD disk size, in MB, allowed by the virtual + * machine size. */ @JsonProperty(value = "osVhdSizeMB", access = JsonProperty.Access.WRITE_ONLY) private Integer osVhdSizeMB; /* - * The resource volume size, in MB, allowed by the virtual machine size. + * Resource volume size The resource volume size, in MB, allowed by the + * virtual machine size. */ @JsonProperty(value = "maxResourceVolumeMB", access = JsonProperty.Access.WRITE_ONLY) private Integer maxResourceVolumeMB; /* - * The amount of memory, in GB, supported by the virtual machine size. + * Memory size The amount of memory, in GB, supported by the virtual + * machine size. */ @JsonProperty(value = "memoryGB", access = JsonProperty.Access.WRITE_ONLY) private Double memoryGB; /* - * Specifies if the virtual machine size supports low priority VMs. + * Low priority capable Specifies if the virtual machine size supports low + * priority VMs. */ @JsonProperty(value = "lowPriorityCapable", access = JsonProperty.Access.WRITE_ONLY) private Boolean lowPriorityCapable; /* - * Specifies if the virtual machine size supports premium IO. + * Premium IO supported Specifies if the virtual machine size supports + * premium IO. */ @JsonProperty(value = "premiumIO", access = JsonProperty.Access.WRITE_ONLY) private Boolean premiumIO; @@ -74,8 +77,15 @@ public final class VirtualMachineSize { @JsonProperty(value = "estimatedVMPrices") private EstimatedVMPrices estimatedVMPrices; + /* + * Supported Compute Types Specifies the compute types supported by the + * virtual machine size. + */ + @JsonProperty(value = "supportedComputeTypes") + private List supportedComputeTypes; + /** - * Get the name property: The name of the virtual machine size. + * Get the name property: Virtual Machine size name The name of the virtual machine size. * * @return the name value. */ @@ -84,7 +94,7 @@ public String name() { } /** - * Get the family property: The family name of the virtual machine size. + * Get the family property: Virtual Machine family name The family name of the virtual machine size. * * @return the family value. */ @@ -93,7 +103,7 @@ public String family() { } /** - * Get the vCPUs property: The number of vCPUs supported by the virtual machine size. + * Get the vCPUs property: Number of vPUs The number of vCPUs supported by the virtual machine size. * * @return the vCPUs value. */ @@ -102,7 +112,7 @@ public Integer vCPUs() { } /** - * Get the gpus property: The number of gPUs supported by the virtual machine size. + * Get the gpus property: Number of gPUs The number of gPUs supported by the virtual machine size. * * @return the gpus value. */ @@ -111,7 +121,7 @@ public Integer gpus() { } /** - * Get the osVhdSizeMB property: The OS VHD disk size, in MB, allowed by the virtual machine size. + * Get the osVhdSizeMB property: OS VHD Disk size The OS VHD disk size, in MB, allowed by the virtual machine size. * * @return the osVhdSizeMB value. */ @@ -120,7 +130,8 @@ public Integer osVhdSizeMB() { } /** - * Get the maxResourceVolumeMB property: The resource volume size, in MB, allowed by the virtual machine size. + * Get the maxResourceVolumeMB property: Resource volume size The resource volume size, in MB, allowed by the + * virtual machine size. * * @return the maxResourceVolumeMB value. */ @@ -129,7 +140,7 @@ public Integer maxResourceVolumeMB() { } /** - * Get the memoryGB property: The amount of memory, in GB, supported by the virtual machine size. + * Get the memoryGB property: Memory size The amount of memory, in GB, supported by the virtual machine size. * * @return the memoryGB value. */ @@ -138,7 +149,8 @@ public Double memoryGB() { } /** - * Get the lowPriorityCapable property: Specifies if the virtual machine size supports low priority VMs. + * Get the lowPriorityCapable property: Low priority capable Specifies if the virtual machine size supports low + * priority VMs. * * @return the lowPriorityCapable value. */ @@ -147,7 +159,7 @@ public Boolean lowPriorityCapable() { } /** - * Get the premiumIO property: Specifies if the virtual machine size supports premium IO. + * Get the premiumIO property: Premium IO supported Specifies if the virtual machine size supports premium IO. * * @return the premiumIO value. */ @@ -175,6 +187,28 @@ public VirtualMachineSize withEstimatedVMPrices(EstimatedVMPrices estimatedVMPri return this; } + /** + * Get the supportedComputeTypes property: Supported Compute Types Specifies the compute types supported by the + * virtual machine size. + * + * @return the supportedComputeTypes value. + */ + public List supportedComputeTypes() { + return this.supportedComputeTypes; + } + + /** + * Set the supportedComputeTypes property: Supported Compute Types Specifies the compute types supported by the + * virtual machine size. + * + * @param supportedComputeTypes the supportedComputeTypes value to set. + * @return the VirtualMachineSize object itself. + */ + public VirtualMachineSize withSupportedComputeTypes(List supportedComputeTypes) { + this.supportedComputeTypes = supportedComputeTypes; + return this; + } + /** * Validates the instance. * diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizeListResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizeListResult.java index 12e9a041a0e0e..0463c91130ca1 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizeListResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizeListResult.java @@ -10,11 +10,11 @@ /** An immutable client-side representation of VirtualMachineSizeListResult. */ public interface VirtualMachineSizeListResult { /** - * Gets the amlCompute property: The list of virtual machine sizes supported by AmlCompute. + * Gets the value property: The list of virtual machine sizes supported by AmlCompute. * - * @return the amlCompute value. + * @return the value value. */ - List amlCompute(); + List value(); /** * Gets the inner com.azure.resourcemanager.machinelearningservices.fluent.models.VirtualMachineSizeListResultInner diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizes.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizes.java index e91502cc5ac61..82e110d4882fc 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizes.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSizes.java @@ -28,7 +28,7 @@ public interface VirtualMachineSizes { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Virtual Machine size operation response. + * @return the List Virtual Machine size operation response along with {@link Response}. */ Response listWithResponse(String location, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSshCredentials.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSshCredentials.java index ff9d8600e57f2..19536cbd45b42 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSshCredentials.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSshCredentials.java @@ -5,15 +5,11 @@ package com.azure.resourcemanager.machinelearningservices.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; /** Admin credentials for virtual machine. */ @Fluent public final class VirtualMachineSshCredentials { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VirtualMachineSshCredentials.class); - /* * Username of admin account */ diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VmPriority.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VmPriority.java index 3b068ed422dc5..91ff0cb0e9a5e 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VmPriority.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VmPriority.java @@ -27,7 +27,11 @@ public static VmPriority fromString(String name) { return fromString(name, VmPriority.class); } - /** @return known VmPriority values. */ + /** + * Gets known VmPriority values. + * + * @return known VmPriority values. + */ public static Collection values() { return values(VmPriority.class); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VnetConfiguration.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VnetConfiguration.java deleted file mode 100644 index 568854c417afc..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VnetConfiguration.java +++ /dev/null @@ -1,76 +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.machinelearningservices.models; - -import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; -import com.fasterxml.jackson.annotation.JsonProperty; - -/** The VnetConfiguration model. */ -@Fluent -public class VnetConfiguration { - @JsonIgnore private final ClientLogger logger = new ClientLogger(VnetConfiguration.class); - - /* - * The name of the virtual network. - */ - @JsonProperty(value = "vnetName") - private String vnetName; - - /* - * The name of the virtual network subnet. - */ - @JsonProperty(value = "subnetName") - private String subnetName; - - /** - * Get the vnetName property: The name of the virtual network. - * - * @return the vnetName value. - */ - public String vnetName() { - return this.vnetName; - } - - /** - * Set the vnetName property: The name of the virtual network. - * - * @param vnetName the vnetName value to set. - * @return the VnetConfiguration object itself. - */ - public VnetConfiguration withVnetName(String vnetName) { - this.vnetName = vnetName; - return this; - } - - /** - * Get the subnetName property: The name of the virtual network subnet. - * - * @return the subnetName value. - */ - public String subnetName() { - return this.subnetName; - } - - /** - * Set the subnetName property: The name of the virtual network subnet. - * - * @param subnetName the subnetName value to set. - * @return the VnetConfiguration object itself. - */ - public VnetConfiguration withSubnetName(String subnetName) { - this.subnetName = subnetName; - return this; - } - - /** - * Validates the instance. - * - * @throws IllegalArgumentException thrown if the instance is not valid. - */ - public void validate() { - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WebServiceState.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WebServiceState.java deleted file mode 100644 index 59b9ccccc2a50..0000000000000 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WebServiceState.java +++ /dev/null @@ -1,43 +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.machinelearningservices.models; - -import com.azure.core.util.ExpandableStringEnum; -import com.fasterxml.jackson.annotation.JsonCreator; -import java.util.Collection; - -/** Defines values for WebServiceState. */ -public final class WebServiceState extends ExpandableStringEnum { - /** Static value Transitioning for WebServiceState. */ - public static final WebServiceState TRANSITIONING = fromString("Transitioning"); - - /** Static value Healthy for WebServiceState. */ - public static final WebServiceState HEALTHY = fromString("Healthy"); - - /** Static value Unhealthy for WebServiceState. */ - public static final WebServiceState UNHEALTHY = fromString("Unhealthy"); - - /** Static value Failed for WebServiceState. */ - public static final WebServiceState FAILED = fromString("Failed"); - - /** Static value Unschedulable for WebServiceState. */ - public static final WebServiceState UNSCHEDULABLE = fromString("Unschedulable"); - - /** - * Creates or finds a WebServiceState from its string representation. - * - * @param name a name to look for. - * @return the corresponding WebServiceState. - */ - @JsonCreator - public static WebServiceState fromString(String name) { - return fromString(name, WebServiceState.class); - } - - /** @return known WebServiceState values. */ - public static Collection values() { - return values(WebServiceState.class); - } -} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspace.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspace.java index 9ce76bf264353..14fe311315ebd 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspace.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspace.java @@ -36,19 +36,40 @@ public interface Workspace { String type(); /** - * Gets the location property: The geo-location where the resource lives. + * Gets the identity property: The identity of the resource. + * + * @return the identity value. + */ + Identity identity(); + + /** + * Gets the location property: Specifies the location of the resource. * * @return the location value. */ String location(); /** - * Gets the tags property: Resource tags. + * Gets the tags property: Contains resource tags defined as key/value pairs. * * @return the tags value. */ Map tags(); + /** + * Gets the sku property: The sku of the workspace. + * + * @return the sku value. + */ + Sku sku(); + + /** + * Gets the systemData property: System data. + * + * @return the systemData value. + */ + SystemData systemData(); + /** * Gets the workspaceId property: The immutable id associated with this workspace. * @@ -163,6 +184,13 @@ public interface Workspace { */ Boolean allowPublicAccessWhenBehindVnet(); + /** + * Gets the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + PublicNetworkAccess publicNetworkAccess(); + /** * Gets the privateEndpointConnections property: The list of private endpoint connections in the workspace. * @@ -207,25 +235,20 @@ public interface Workspace { String tenantId(); /** - * Gets the identity property: The identity of the resource. - * - * @return the identity value. - */ - Identity identity(); - - /** - * Gets the sku property: The sku of the workspace. + * Gets the storageHnsEnabled property: If the storage associated with the workspace has hierarchical namespace(HNS) + * enabled. * - * @return the sku value. + * @return the storageHnsEnabled value. */ - Sku sku(); + Boolean storageHnsEnabled(); /** - * Gets the systemData property: Read only system data. + * Gets the mlFlowTrackingUri property: The URI associated with this workspace that machine learning flow must point + * at to set up tracking. * - * @return the systemData value. + * @return the mlFlowTrackingUri value. */ - SystemData systemData(); + String mlFlowTrackingUri(); /** * Gets the region of the resource. @@ -250,40 +273,19 @@ public interface Workspace { /** The entirety of the Workspace definition. */ interface Definition - extends DefinitionStages.Blank, - DefinitionStages.WithLocation, - DefinitionStages.WithResourceGroup, - DefinitionStages.WithCreate { + extends DefinitionStages.Blank, DefinitionStages.WithResourceGroup, DefinitionStages.WithCreate { } /** The Workspace definition stages. */ interface DefinitionStages { /** The first stage of the Workspace definition. */ - interface Blank extends WithLocation { - } - /** The stage of the Workspace definition allowing to specify location. */ - interface WithLocation { - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithResourceGroup withRegion(Region location); - - /** - * Specifies the region for the resource. - * - * @param location The geo-location where the resource lives. - * @return the next definition stage. - */ - WithResourceGroup withRegion(String location); + interface Blank extends WithResourceGroup { } /** The stage of the Workspace definition allowing to specify parent resource. */ interface WithResourceGroup { /** * Specifies resourceGroupName. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @return the next definition stage. */ WithCreate withExistingResourceGroup(String resourceGroupName); @@ -293,7 +295,10 @@ interface WithResourceGroup { * be created, but also allows for any other optional properties to be specified. */ interface WithCreate - extends DefinitionStages.WithTags, + extends DefinitionStages.WithLocation, + DefinitionStages.WithTags, + DefinitionStages.WithIdentity, + DefinitionStages.WithSku, DefinitionStages.WithDescription, DefinitionStages.WithFriendlyName, DefinitionStages.WithKeyVault, @@ -305,11 +310,10 @@ interface WithCreate DefinitionStages.WithHbiWorkspace, DefinitionStages.WithImageBuildCompute, DefinitionStages.WithAllowPublicAccessWhenBehindVnet, + DefinitionStages.WithPublicNetworkAccess, DefinitionStages.WithSharedPrivateLinkResources, DefinitionStages.WithServiceManagedResourcesSettings, - DefinitionStages.WithPrimaryUserAssignedIdentity, - DefinitionStages.WithIdentity, - DefinitionStages.WithSku { + DefinitionStages.WithPrimaryUserAssignedIdentity { /** * Executes the create request. * @@ -325,16 +329,54 @@ interface WithCreate */ Workspace create(Context context); } + /** The stage of the Workspace definition allowing to specify location. */ + interface WithLocation { + /** + * Specifies the region for the resource. + * + * @param location Specifies the location of the resource. + * @return the next definition stage. + */ + WithCreate withRegion(Region location); + + /** + * Specifies the region for the resource. + * + * @param location Specifies the location of the resource. + * @return the next definition stage. + */ + WithCreate withRegion(String location); + } /** The stage of the Workspace definition allowing to specify tags. */ interface WithTags { /** - * Specifies the tags property: Resource tags.. + * Specifies the tags property: Contains resource tags defined as key/value pairs.. * - * @param tags Resource tags. + * @param tags Contains resource tags defined as key/value pairs. * @return the next definition stage. */ WithCreate withTags(Map tags); } + /** The stage of the Workspace definition allowing to specify identity. */ + interface WithIdentity { + /** + * Specifies the identity property: The identity of the resource.. + * + * @param identity The identity of the resource. + * @return the next definition stage. + */ + WithCreate withIdentity(Identity identity); + } + /** The stage of the Workspace definition allowing to specify sku. */ + interface WithSku { + /** + * Specifies the sku property: The sku of the workspace.. + * + * @param sku The sku of the workspace. + * @return the next definition stage. + */ + WithCreate withSku(Sku sku); + } /** The stage of the Workspace definition allowing to specify description. */ interface WithDescription { /** @@ -459,6 +501,16 @@ interface WithAllowPublicAccessWhenBehindVnet { */ WithCreate withAllowPublicAccessWhenBehindVnet(Boolean allowPublicAccessWhenBehindVnet); } + /** The stage of the Workspace definition allowing to specify publicNetworkAccess. */ + interface WithPublicNetworkAccess { + /** + * Specifies the publicNetworkAccess property: Whether requests from Public Network are allowed.. + * + * @param publicNetworkAccess Whether requests from Public Network are allowed. + * @return the next definition stage. + */ + WithCreate withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess); + } /** The stage of the Workspace definition allowing to specify sharedPrivateLinkResources. */ interface WithSharedPrivateLinkResources { /** @@ -493,26 +545,6 @@ interface WithPrimaryUserAssignedIdentity { */ WithCreate withPrimaryUserAssignedIdentity(String primaryUserAssignedIdentity); } - /** The stage of the Workspace definition allowing to specify identity. */ - interface WithIdentity { - /** - * Specifies the identity property: The identity of the resource.. - * - * @param identity The identity of the resource. - * @return the next definition stage. - */ - WithCreate withIdentity(Identity identity); - } - /** The stage of the Workspace definition allowing to specify sku. */ - interface WithSku { - /** - * Specifies the sku property: The sku of the workspace.. - * - * @param sku The sku of the workspace. - * @return the next definition stage. - */ - WithCreate withSku(Sku sku); - } } /** * Begins update for the Workspace resource. @@ -530,7 +562,8 @@ interface Update UpdateStages.WithFriendlyName, UpdateStages.WithImageBuildCompute, UpdateStages.WithServiceManagedResourcesSettings, - UpdateStages.WithPrimaryUserAssignedIdentity { + UpdateStages.WithPrimaryUserAssignedIdentity, + UpdateStages.WithPublicNetworkAccess { /** * Executes the update request. * @@ -630,6 +663,16 @@ interface WithPrimaryUserAssignedIdentity { */ Update withPrimaryUserAssignedIdentity(String primaryUserAssignedIdentity); } + /** The stage of the Workspace update allowing to specify publicNetworkAccess. */ + interface WithPublicNetworkAccess { + /** + * Specifies the publicNetworkAccess property: Whether requests from Public Network are allowed.. + * + * @param publicNetworkAccess Whether requests from Public Network are allowed. + * @return the next definition stage. + */ + Update withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess); + } } /** * Refreshes the resource to sync with Azure. @@ -646,6 +689,38 @@ interface WithPrimaryUserAssignedIdentity { */ Workspace refresh(Context context); + /** + * Diagnose workspace setup issue. + * + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose(DiagnoseWorkspaceParameters parameters); + + /** + * Diagnose workspace setup issue. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose(); + + /** + * Diagnose workspace setup issue. + * + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose(DiagnoseWorkspaceParameters parameters, Context context); + /** * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. @@ -664,7 +739,7 @@ interface WithPrimaryUserAssignedIdentity { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ Response listKeysWithResponse(Context context); @@ -704,7 +779,67 @@ interface WithPrimaryUserAssignedIdentity { * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ Response listNotebookAccessTokenWithResponse(Context context); + + /** + * Prepare a notebook. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + NotebookResourceInfo prepareNotebook(); + + /** + * Prepare a notebook. + * + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + NotebookResourceInfo prepareNotebook(Context context); + + /** + * List storage account keys of a workspace. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + ListStorageAccountKeysResult listStorageAccountKeys(); + + /** + * List storage account keys of a workspace. + * + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + Response listStorageAccountKeysWithResponse(Context context); + + /** + * List keys of a notebook. + * + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + ListNotebookKeysResult listNotebookKeys(); + + /** + * List keys of a notebook. + * + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + Response listNotebookKeysWithResponse(Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnection.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnection.java index 0c10207f88628..c219adcff6ca2 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnection.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnection.java @@ -86,7 +86,7 @@ interface WithParentResource { /** * Specifies resourceGroupName, workspaceName. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @return the next definition stage. */ @@ -97,8 +97,7 @@ interface WithParentResource { * resource to be created, but also allows for any other optional properties to be specified. */ interface WithCreate - extends DefinitionStages.WithName, - DefinitionStages.WithCategory, + extends DefinitionStages.WithCategory, DefinitionStages.WithTarget, DefinitionStages.WithAuthType, DefinitionStages.WithValue, @@ -118,16 +117,6 @@ interface WithCreate */ WorkspaceConnection create(Context context); } - /** The stage of the WorkspaceConnection definition allowing to specify name. */ - interface WithName { - /** - * Specifies the name property: Friendly name of the workspace connection. - * - * @param name Friendly name of the workspace connection. - * @return the next definition stage. - */ - WithCreate withName(String name); - } /** The stage of the WorkspaceConnection definition allowing to specify category. */ interface WithCategory { /** diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnections.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnections.java index 78c85f2433be4..a1d9fdd7fa936 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnections.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceConnections.java @@ -13,19 +13,19 @@ public interface WorkspaceConnections { /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String workspaceName); /** * List all connections under a AML workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -33,7 +33,7 @@ public interface WorkspaceConnections { * @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 paginated list of Workspace connection objects. + * @return paginated list of Workspace connection objects as paginated response with {@link PagedIterable}. */ PagedIterable list( String resourceGroupName, String workspaceName, String target, String category, Context context); @@ -41,7 +41,7 @@ PagedIterable list( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -54,14 +54,14 @@ PagedIterable list( /** * Get the detail of a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @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 detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response}. */ Response getWithResponse( String resourceGroupName, String workspaceName, String connectionName, Context context); @@ -69,7 +69,7 @@ Response getWithResponse( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -81,14 +81,14 @@ Response getWithResponse( /** * Delete a workspace connection. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param connectionName Friendly name of the workspace connection. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ Response deleteWithResponse( String resourceGroupName, String workspaceName, String connectionName, Context context); @@ -100,7 +100,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response}. */ WorkspaceConnection getById(String id); @@ -112,7 +112,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the detail of a workspace connection. + * @return the detail of a workspace connection along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); @@ -134,7 +134,7 @@ Response deleteWithResponse( * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the {@link Response}. */ Response deleteByIdWithResponse(String id, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceFeatures.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceFeatures.java index 8ddcb302fee7c..ea297bc14f8db 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceFeatures.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceFeatures.java @@ -12,25 +12,25 @@ public interface WorkspaceFeatures { /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String workspaceName); /** * Lists all enabled features for a workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the List Aml user feature operation response. + * @return the List Aml user feature operation response as paginated response with {@link PagedIterable}. */ PagedIterable list(String resourceGroupName, String workspaceName, Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceListResult.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceListResult.java index 9aa65b3b40a14..db136f60dbdcc 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceListResult.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceListResult.java @@ -5,17 +5,13 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspaceInner; -import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.List; /** The result of a request to list machine learning workspaces. */ @Fluent public final class WorkspaceListResult { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceListResult.class); - /* * The list of machine learning workspaces. Since this list may be * incomplete, the nextLink field should be used to request the next list diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceProperties.java new file mode 100644 index 0000000000000..b60cf6da94edf --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceProperties.java @@ -0,0 +1,198 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.models; + +import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspacePropertiesInner; +import java.util.List; + +/** An immutable client-side representation of WorkspaceProperties. */ +public interface WorkspaceProperties { + /** + * Gets the workspaceId property: The immutable id associated with this workspace. + * + * @return the workspaceId value. + */ + String workspaceId(); + + /** + * Gets the description property: The description of this workspace. + * + * @return the description value. + */ + String description(); + + /** + * Gets the friendlyName property: The friendly name for this workspace. This name in mutable. + * + * @return the friendlyName value. + */ + String friendlyName(); + + /** + * Gets the keyVault property: ARM id of the key vault associated with this workspace. This cannot be changed once + * the workspace has been created. + * + * @return the keyVault value. + */ + String keyVault(); + + /** + * Gets the applicationInsights property: ARM id of the application insights associated with this workspace. This + * cannot be changed once the workspace has been created. + * + * @return the applicationInsights value. + */ + String applicationInsights(); + + /** + * Gets the containerRegistry property: ARM id of the container registry associated with this workspace. This cannot + * be changed once the workspace has been created. + * + * @return the containerRegistry value. + */ + String containerRegistry(); + + /** + * Gets the storageAccount property: ARM id of the storage account associated with this workspace. This cannot be + * changed once the workspace has been created. + * + * @return the storageAccount value. + */ + String storageAccount(); + + /** + * Gets the discoveryUrl property: Url for the discovery service to identify regional endpoints for machine learning + * experimentation services. + * + * @return the discoveryUrl value. + */ + String discoveryUrl(); + + /** + * Gets the provisioningState property: The current deployment state of workspace resource. The provisioningState is + * to indicate states for resource provisioning. + * + * @return the provisioningState value. + */ + ProvisioningState provisioningState(); + + /** + * Gets the encryption property: The encryption settings of Azure ML workspace. + * + * @return the encryption value. + */ + EncryptionProperty encryption(); + + /** + * Gets the hbiWorkspace property: The flag to signal HBI data in the workspace and reduce diagnostic data collected + * by the service. + * + * @return the hbiWorkspace value. + */ + Boolean hbiWorkspace(); + + /** + * Gets the serviceProvisionedResourceGroup property: The name of the managed resource group created by workspace RP + * in customer subscription if the workspace is CMK workspace. + * + * @return the serviceProvisionedResourceGroup value. + */ + String serviceProvisionedResourceGroup(); + + /** + * Gets the privateLinkCount property: Count of private connections in the workspace. + * + * @return the privateLinkCount value. + */ + Integer privateLinkCount(); + + /** + * Gets the imageBuildCompute property: The compute name for image build. + * + * @return the imageBuildCompute value. + */ + String imageBuildCompute(); + + /** + * Gets the allowPublicAccessWhenBehindVnet property: The flag to indicate whether to allow public access when + * behind VNet. + * + * @return the allowPublicAccessWhenBehindVnet value. + */ + Boolean allowPublicAccessWhenBehindVnet(); + + /** + * Gets the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + PublicNetworkAccess publicNetworkAccess(); + + /** + * Gets the privateEndpointConnections property: The list of private endpoint connections in the workspace. + * + * @return the privateEndpointConnections value. + */ + List privateEndpointConnections(); + + /** + * Gets the sharedPrivateLinkResources property: The list of shared private link resources in this workspace. + * + * @return the sharedPrivateLinkResources value. + */ + List sharedPrivateLinkResources(); + + /** + * Gets the notebookInfo property: The notebook info of Azure ML workspace. + * + * @return the notebookInfo value. + */ + NotebookResourceInfo notebookInfo(); + + /** + * Gets the serviceManagedResourcesSettings property: The service managed resource settings. + * + * @return the serviceManagedResourcesSettings value. + */ + ServiceManagedResourcesSettings serviceManagedResourcesSettings(); + + /** + * Gets the primaryUserAssignedIdentity property: The user assigned identity resource id that represents the + * workspace identity. + * + * @return the primaryUserAssignedIdentity value. + */ + String primaryUserAssignedIdentity(); + + /** + * Gets the tenantId property: The tenant id associated with this workspace. + * + * @return the tenantId value. + */ + String tenantId(); + + /** + * Gets the storageHnsEnabled property: If the storage associated with the workspace has hierarchical namespace(HNS) + * enabled. + * + * @return the storageHnsEnabled value. + */ + Boolean storageHnsEnabled(); + + /** + * Gets the mlFlowTrackingUri property: The URI associated with this workspace that machine learning flow must point + * at to set up tracking. + * + * @return the mlFlowTrackingUri value. + */ + String mlFlowTrackingUri(); + + /** + * Gets the inner com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspacePropertiesInner object. + * + * @return the inner object. + */ + WorkspacePropertiesInner innerModel(); +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceOperations.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceSkus.java similarity index 74% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceOperations.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceSkus.java index 6dbc7ddb14c79..796a2c501fb7d 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceOperations.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceSkus.java @@ -7,16 +7,16 @@ import com.azure.core.http.rest.PagedIterable; import com.azure.core.util.Context; -/** Resource collection API of WorkspaceOperations. */ -public interface WorkspaceOperations { +/** Resource collection API of WorkspaceSkus. */ +public interface WorkspaceSkus { /** * Lists all skus with associated features. * * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ - PagedIterable listSkus(); + PagedIterable list(); /** * Lists all skus with associated features. @@ -25,7 +25,7 @@ public interface WorkspaceOperations { * @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 skus with features. + * @return list of skus with features as paginated response with {@link PagedIterable}. */ - PagedIterable listSkus(Context context); + PagedIterable list(Context context); } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceUpdateParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceUpdateParameters.java index 476d64375dcaa..6645cdfaa29ca 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceUpdateParameters.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceUpdateParameters.java @@ -5,22 +5,19 @@ package com.azure.resourcemanager.machinelearningservices.models; import com.azure.core.annotation.Fluent; -import com.azure.core.annotation.JsonFlatten; -import com.azure.core.util.logging.ClientLogger; -import com.fasterxml.jackson.annotation.JsonIgnore; +import com.azure.resourcemanager.machinelearningservices.fluent.models.WorkspacePropertiesUpdateParameters; +import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import java.util.Map; /** The parameters for updating a machine learning workspace. */ -@JsonFlatten @Fluent -public class WorkspaceUpdateParameters { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceUpdateParameters.class); - +public final class WorkspaceUpdateParameters { /* * The resource tags for the machine learning workspace. */ @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) private Map tags; /* @@ -36,35 +33,10 @@ public class WorkspaceUpdateParameters { private Identity identity; /* - * The description of this workspace. - */ - @JsonProperty(value = "properties.description") - private String description; - - /* - * The friendly name for this workspace. - */ - @JsonProperty(value = "properties.friendlyName") - private String friendlyName; - - /* - * The compute name for image build - */ - @JsonProperty(value = "properties.imageBuildCompute") - private String imageBuildCompute; - - /* - * The service managed resource settings. + * The properties that the machine learning workspace will be updated with. */ - @JsonProperty(value = "properties.serviceManagedResourcesSettings") - private ServiceManagedResourcesSettings serviceManagedResourcesSettings; - - /* - * The user assigned identity resource id that represents the workspace - * identity. - */ - @JsonProperty(value = "properties.primaryUserAssignedIdentity") - private String primaryUserAssignedIdentity; + @JsonProperty(value = "properties") + private WorkspacePropertiesUpdateParameters innerProperties; /** * Get the tags property: The resource tags for the machine learning workspace. @@ -126,13 +98,22 @@ public WorkspaceUpdateParameters withIdentity(Identity identity) { return this; } + /** + * Get the innerProperties property: The properties that the machine learning workspace will be updated with. + * + * @return the innerProperties value. + */ + private WorkspacePropertiesUpdateParameters innerProperties() { + return this.innerProperties; + } + /** * Get the description property: The description of this workspace. * * @return the description value. */ public String description() { - return this.description; + return this.innerProperties() == null ? null : this.innerProperties().description(); } /** @@ -142,7 +123,10 @@ public String description() { * @return the WorkspaceUpdateParameters object itself. */ public WorkspaceUpdateParameters withDescription(String description) { - this.description = description; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withDescription(description); return this; } @@ -152,7 +136,7 @@ public WorkspaceUpdateParameters withDescription(String description) { * @return the friendlyName value. */ public String friendlyName() { - return this.friendlyName; + return this.innerProperties() == null ? null : this.innerProperties().friendlyName(); } /** @@ -162,7 +146,10 @@ public String friendlyName() { * @return the WorkspaceUpdateParameters object itself. */ public WorkspaceUpdateParameters withFriendlyName(String friendlyName) { - this.friendlyName = friendlyName; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withFriendlyName(friendlyName); return this; } @@ -172,7 +159,7 @@ public WorkspaceUpdateParameters withFriendlyName(String friendlyName) { * @return the imageBuildCompute value. */ public String imageBuildCompute() { - return this.imageBuildCompute; + return this.innerProperties() == null ? null : this.innerProperties().imageBuildCompute(); } /** @@ -182,7 +169,10 @@ public String imageBuildCompute() { * @return the WorkspaceUpdateParameters object itself. */ public WorkspaceUpdateParameters withImageBuildCompute(String imageBuildCompute) { - this.imageBuildCompute = imageBuildCompute; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withImageBuildCompute(imageBuildCompute); return this; } @@ -192,7 +182,7 @@ public WorkspaceUpdateParameters withImageBuildCompute(String imageBuildCompute) * @return the serviceManagedResourcesSettings value. */ public ServiceManagedResourcesSettings serviceManagedResourcesSettings() { - return this.serviceManagedResourcesSettings; + return this.innerProperties() == null ? null : this.innerProperties().serviceManagedResourcesSettings(); } /** @@ -203,7 +193,10 @@ public ServiceManagedResourcesSettings serviceManagedResourcesSettings() { */ public WorkspaceUpdateParameters withServiceManagedResourcesSettings( ServiceManagedResourcesSettings serviceManagedResourcesSettings) { - this.serviceManagedResourcesSettings = serviceManagedResourcesSettings; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withServiceManagedResourcesSettings(serviceManagedResourcesSettings); return this; } @@ -214,7 +207,7 @@ public WorkspaceUpdateParameters withServiceManagedResourcesSettings( * @return the primaryUserAssignedIdentity value. */ public String primaryUserAssignedIdentity() { - return this.primaryUserAssignedIdentity; + return this.innerProperties() == null ? null : this.innerProperties().primaryUserAssignedIdentity(); } /** @@ -225,7 +218,33 @@ public String primaryUserAssignedIdentity() { * @return the WorkspaceUpdateParameters object itself. */ public WorkspaceUpdateParameters withPrimaryUserAssignedIdentity(String primaryUserAssignedIdentity) { - this.primaryUserAssignedIdentity = primaryUserAssignedIdentity; + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withPrimaryUserAssignedIdentity(primaryUserAssignedIdentity); + return this; + } + + /** + * Get the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @return the publicNetworkAccess value. + */ + public PublicNetworkAccess publicNetworkAccess() { + return this.innerProperties() == null ? null : this.innerProperties().publicNetworkAccess(); + } + + /** + * Set the publicNetworkAccess property: Whether requests from Public Network are allowed. + * + * @param publicNetworkAccess the publicNetworkAccess value to set. + * @return the WorkspaceUpdateParameters object itself. + */ + public WorkspaceUpdateParameters withPublicNetworkAccess(PublicNetworkAccess publicNetworkAccess) { + if (this.innerProperties() == null) { + this.innerProperties = new WorkspacePropertiesUpdateParameters(); + } + this.innerProperties().withPublicNetworkAccess(publicNetworkAccess); return this; } @@ -241,8 +260,8 @@ public void validate() { if (identity() != null) { identity().validate(); } - if (serviceManagedResourcesSettings() != null) { - serviceManagedResourcesSettings().validate(); + if (innerProperties() != null) { + innerProperties().validate(); } } } diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspaces.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspaces.java index b926e16439e82..e7966613d5a8b 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspaces.java +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Workspaces.java @@ -13,7 +13,7 @@ public interface Workspaces { /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -25,20 +25,20 @@ public interface Workspaces { /** * Gets the properties of the specified machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response}. */ Response getByResourceGroupWithResponse(String resourceGroupName, String workspaceName, Context context); /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -49,7 +49,7 @@ public interface Workspaces { /** * Deletes a machine learning workspace. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -61,32 +61,75 @@ public interface Workspaces { /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ PagedIterable listByResourceGroup(String resourceGroupName); /** * Lists all the available machine learning workspaces under the specified resource group. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param skip Continuation token for pagination. * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ PagedIterable listByResourceGroup(String resourceGroupName, String skip, Context context); + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose(String resourceGroupName, String workspaceName); + + /** + * Diagnose workspace setup issue. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param parameters The parameter of diagnosing workspace health. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + DiagnoseResponseResult diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context); + /** * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -99,13 +142,13 @@ public interface Workspaces { * Lists all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ Response listKeysWithResponse( String resourceGroupName, String workspaceName, Context context); @@ -114,7 +157,7 @@ Response listKeysWithResponse( * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -126,7 +169,7 @@ Response listKeysWithResponse( * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and * password for container registry. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -140,7 +183,8 @@ Response listKeysWithResponse( * * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ PagedIterable list(); @@ -152,14 +196,15 @@ Response listKeysWithResponse( * @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 result of a request to list machine learning workspaces. + * @return the result of a request to list machine learning workspaces as paginated response with {@link + * PagedIterable}. */ PagedIterable list(String skip, Context context); /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. @@ -171,17 +216,120 @@ Response listKeysWithResponse( /** * return notebook access token and refresh token. * - * @param resourceGroupName Name of the resource group in which workspace is located. + * @param resourceGroupName The name of the resource group. The name is case insensitive. * @param workspaceName Name of Azure Machine Learning workspace. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. - * @return the response. + * @return the response body along with {@link Response}. */ Response listNotebookAccessTokenWithResponse( String resourceGroupName, String workspaceName, Context context); + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + NotebookResourceInfo prepareNotebook(String resourceGroupName, String workspaceName); + + /** + * Prepare a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + NotebookResourceInfo prepareNotebook(String resourceGroupName, String workspaceName, Context context); + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + ListStorageAccountKeysResult listStorageAccountKeys(String resourceGroupName, String workspaceName); + + /** + * List storage account keys of a workspace. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + Response listStorageAccountKeysWithResponse( + String resourceGroupName, String workspaceName, Context context); + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + ListNotebookKeysResult listNotebookKeys(String resourceGroupName, String workspaceName); + + /** + * List keys of a notebook. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + Response listNotebookKeysWithResponse( + String resourceGroupName, String workspaceName, Context context); + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response. + */ + ExternalFqdnResponse listOutboundNetworkDependenciesEndpoints(String resourceGroupName, String workspaceName); + + /** + * Called by Client (Portal, CLI, etc) to get a list of all external outbound dependencies (FQDNs) programmatically. + * + * @param resourceGroupName The name of the resource group. The name is case insensitive. + * @param workspaceName Name of Azure Machine Learning workspace. + * @param context The context to associate with this operation. + * @throws IllegalArgumentException thrown if parameters fail the validation. + * @throws com.azure.core.management.exception.ManagementException thrown if the request is rejected by server. + * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. + * @return the response body along with {@link Response}. + */ + Response listOutboundNetworkDependenciesEndpointsWithResponse( + String resourceGroupName, String workspaceName, Context context); + /** * Gets the properties of the specified machine learning workspace. * @@ -189,7 +337,7 @@ Response listNotebookAccessTokenWithResponse( * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response}. */ Workspace getById(String id); @@ -201,7 +349,7 @@ Response listNotebookAccessTokenWithResponse( * @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 properties of the specified machine learning workspace. + * @return the properties of the specified machine learning workspace along with {@link Response}. */ Response getByIdWithResponse(String id, Context context); diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeCreateOrUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeCreateOrUpdateSamples.java new file mode 100644 index 0000000000000..43977da281d9a --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeCreateOrUpdateSamples.java @@ -0,0 +1,264 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.resourcemanager.machinelearningservices.models.Aks; +import com.azure.resourcemanager.machinelearningservices.models.AksProperties; +import com.azure.resourcemanager.machinelearningservices.models.AmlCompute; +import com.azure.resourcemanager.machinelearningservices.models.AmlComputeProperties; +import com.azure.resourcemanager.machinelearningservices.models.ApplicationSharingPolicy; +import com.azure.resourcemanager.machinelearningservices.models.AssignedUser; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstance; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceAuthorizationType; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceProperties; +import com.azure.resourcemanager.machinelearningservices.models.ComputeInstanceSshSettings; +import com.azure.resourcemanager.machinelearningservices.models.DataFactory; +import com.azure.resourcemanager.machinelearningservices.models.InstanceTypeSchema; +import com.azure.resourcemanager.machinelearningservices.models.InstanceTypeSchemaResources; +import com.azure.resourcemanager.machinelearningservices.models.Kubernetes; +import com.azure.resourcemanager.machinelearningservices.models.KubernetesProperties; +import com.azure.resourcemanager.machinelearningservices.models.OsType; +import com.azure.resourcemanager.machinelearningservices.models.PersonalComputeInstanceSettings; +import com.azure.resourcemanager.machinelearningservices.models.RemoteLoginPortPublicAccess; +import com.azure.resourcemanager.machinelearningservices.models.ResourceId; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettings; +import com.azure.resourcemanager.machinelearningservices.models.SshPublicAccess; +import com.azure.resourcemanager.machinelearningservices.models.VirtualMachineImage; +import com.azure.resourcemanager.machinelearningservices.models.VmPriority; +import java.time.Duration; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Compute CreateOrUpdate. */ +public final class ComputeCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicAKSCompute.json + */ + /** + * Sample code: Create an AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties(new Aks()) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/AKSCompute.json + */ + /** + * Sample code: Update an AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAnAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new Aks() + .withDescription("some compute") + .withResourceId( + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/testrg123/providers/Microsoft.ContainerService/managedClusters/compute123-56826-c9b00420020b2") + .withProperties(new AksProperties().withAgentCount(4))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/KubernetesCompute.json + */ + /** + * Sample code: Attach a Kubernetes Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void attachAKubernetesCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new Kubernetes() + .withDescription("some compute") + .withResourceId( + "/subscriptions/34adfa4f-cedf-4dc0-ba29-b6d1a69ab345/resourcegroups/testrg123/providers/Microsoft.ContainerService/managedClusters/compute123-56826-c9b00420020b2") + .withProperties( + new KubernetesProperties() + .withNamespace("default") + .withDefaultInstanceType("defaultInstanceType") + .withInstanceTypes( + mapOf( + "defaultInstanceType", + new InstanceTypeSchema() + .withResources( + new InstanceTypeSchemaResources() + .withRequests( + mapOf("cpu", "1", "memory", "4Gi", "nvidia.com/gpu", null)) + .withLimits( + mapOf("cpu", "1", "memory", "4Gi", "nvidia.com/gpu", null))))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicAmlCompute.json + */ + /** + * Sample code: Create a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new AmlCompute() + .withProperties( + new AmlComputeProperties() + .withOsType(OsType.WINDOWS) + .withVmSize("STANDARD_NC6") + .withVmPriority(VmPriority.DEDICATED) + .withVirtualMachineImage( + new VirtualMachineImage() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/myResourceGroup/providers/Microsoft.Compute/galleries/myImageGallery/images/myImageDefinition/versions/0.0.1")) + .withIsolatedNetwork(false) + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(1) + .withMinNodeCount(0) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M"))) + .withRemoteLoginPortPublicAccess(RemoteLoginPortPublicAccess.NOT_SPECIFIED) + .withEnableNodePublicIp(true))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/ComputeInstance.json + */ + /** + * Sample code: Create an ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new ComputeInstance() + .withProperties( + new ComputeInstanceProperties() + .withVmSize("STANDARD_NC6") + .withSubnet(new ResourceId()) + .withApplicationSharingPolicy(ApplicationSharingPolicy.PERSONAL) + .withSshSettings( + new ComputeInstanceSshSettings().withSshPublicAccess(SshPublicAccess.DISABLED)) + .withComputeInstanceAuthorizationType(ComputeInstanceAuthorizationType.PERSONAL) + .withPersonalComputeInstanceSettings( + new PersonalComputeInstanceSettings() + .withAssignedUser( + new AssignedUser() + .withObjectId("00000000-0000-0000-0000-000000000000") + .withTenantId("00000000-0000-0000-0000-000000000000"))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/ComputeInstanceMinimal.json + */ + /** + * Sample code: Create an ComputeInstance Compute with minimal inputs. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createAnComputeInstanceComputeWithMinimalInputs( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new ComputeInstance().withProperties(new ComputeInstanceProperties().withVmSize("STANDARD_NC6"))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/AmlCompute.json + */ + /** + * Sample code: Update a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties( + new AmlCompute() + .withDescription("some compute") + .withProperties( + new AmlComputeProperties() + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(4) + .withMinNodeCount(4) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M"))))) + .create(); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/createOrUpdate/BasicDataFactoryCompute.json + */ + /** + * Sample code: Create a DataFactory Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createADataFactoryCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .define("compute123") + .withExistingWorkspace("testrg123", "workspaces123") + .withRegion("eastus") + .withProperties(new DataFactory()) + .create(); + } + + @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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeDeleteSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeDeleteSamples.java new file mode 100644 index 0000000000000..faaba161b9979 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeDeleteSamples.java @@ -0,0 +1,26 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.UnderlyingResourceAction; + +/** Samples for Compute Delete. */ +public final class ComputeDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/delete.json + */ + /** + * Sample code: Delete Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .computes() + .delete("testrg123", "workspaces123", "compute123", UnderlyingResourceAction.DELETE, Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeGetSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeGetSamples.java new file mode 100644 index 0000000000000..b55de44a8ef1e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeGetSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute Get. */ +public final class ComputeGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/AKSCompute.json + */ + /** + * Sample code: Get a AKS Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAAKSCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/KubernetesCompute.json + */ + /** + * Sample code: Get a Kubernetes Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAKubernetesCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/ComputeInstance.json + */ + /** + * Sample code: Get an ComputeInstance. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAnComputeInstance( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } + + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/get/AmlCompute.json + */ + /** + * Sample code: Get a AML Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getAAMLCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListKeysSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListKeysSamples.java new file mode 100644 index 0000000000000..c516fe5eb3df0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListKeysSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute ListKeys. */ +public final class ComputeListKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/listKeys.json + */ + /** + * Sample code: List AKS Compute Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listAKSComputeKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().listKeysWithResponse("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListNodesSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListNodesSamples.java new file mode 100644 index 0000000000000..16b7d7fdefb3e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListNodesSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute ListNodes. */ +public final class ComputeListNodesSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/listNodes.json + */ + /** + * Sample code: Get compute nodes information for a compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getComputeNodesInformationForACompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().listNodes("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListSamples.java new file mode 100644 index 0000000000000..43910489dd09b --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute List. */ +public final class ComputeListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/list.json + */ + /** + * Sample code: Get Computes. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getComputes( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().list("testrg123", "workspaces123", null, Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeRestartSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeRestartSamples.java new file mode 100644 index 0000000000000..eec6590454525 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeRestartSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute Restart. */ +public final class ComputeRestartSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/restart.json + */ + /** + * Sample code: Restart ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void restartComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().restart("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStartSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStartSamples.java new file mode 100644 index 0000000000000..565f11bcc59a8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStartSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute Start. */ +public final class ComputeStartSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/start.json + */ + /** + * Sample code: Start ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void startComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().start("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStopSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStopSamples.java new file mode 100644 index 0000000000000..8a9e2f0d52efc --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStopSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Compute Stop. */ +public final class ComputeStopSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/stop.json + */ + /** + * Sample code: Stop ComputeInstance Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void stopComputeInstanceCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.computes().stop("testrg123", "workspaces123", "compute123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeUpdateSamples.java new file mode 100644 index 0000000000000..d08a4d688a49b --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeUpdateSamples.java @@ -0,0 +1,38 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.ComputeResource; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettings; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettingsInformation; +import java.time.Duration; + +/** Samples for Compute Update. */ +public final class ComputeUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Compute/patch.json + */ + /** + * Sample code: Update a AmlCompute Compute. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateAAmlComputeCompute( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + ComputeResource resource = + manager.computes().getWithResponse("testrg123", "workspaces123", "compute123", Context.NONE).getValue(); + resource + .update() + .withProperties( + new ScaleSettingsInformation() + .withScaleSettings( + new ScaleSettings() + .withMaxNodeCount(4) + .withMinNodeCount(4) + .withNodeIdleTimeBeforeScaleDown(Duration.parse("PT5M")))) + .apply(); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsCreateOrUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsCreateOrUpdateSamples.java new file mode 100644 index 0000000000000..d9870082fd49e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsCreateOrUpdateSamples.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.machinelearningservices.generated; + +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.azure.resourcemanager.machinelearningservices.models.PrivateLinkServiceConnectionState; + +/** Samples for PrivateEndpointConnections CreateOrUpdate. */ +public final class PrivateEndpointConnectionsCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/createOrUpdate.json + */ + /** + * Sample code: WorkspacePutPrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspacePutPrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .define("{privateEndpointConnectionName}") + .withExistingWorkspace("rg-1234", "testworkspace") + .withPrivateLinkServiceConnectionState( + new PrivateLinkServiceConnectionState() + .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED) + .withDescription("Auto-Approved")) + .create(); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsDeleteSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsDeleteSamples.java new file mode 100644 index 0000000000000..f6e85f05c4f4d --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsDeleteSamples.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections Delete. */ +public final class PrivateEndpointConnectionsDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/delete.json + */ + /** + * Sample code: WorkspaceDeletePrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceDeletePrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .deleteWithResponse("rg-1234", "testworkspace", "{privateEndpointConnectionName}", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsGetSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsGetSamples.java new file mode 100644 index 0000000000000..f919618b0ec00 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsGetSamples.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections Get. */ +public final class PrivateEndpointConnectionsGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/get.json + */ + /** + * Sample code: WorkspaceGetPrivateEndpointConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceGetPrivateEndpointConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .privateEndpointConnections() + .getWithResponse("rg-1234", "testworkspace", "{privateEndpointConnectionName}", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsListSamples.java new file mode 100644 index 0000000000000..8ccf5798ad35d --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for PrivateEndpointConnections List. */ +public final class PrivateEndpointConnectionsListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateEndpointConnection/list.json + */ + /** + * Sample code: StorageAccountListPrivateEndpointConnections. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void storageAccountListPrivateEndpointConnections( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.privateEndpointConnections().list("rg-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateLinkResourcesListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateLinkResourcesListSamples.java new file mode 100644 index 0000000000000..bd7ca85f24ad2 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateLinkResourcesListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for PrivateLinkResources List. */ +public final class PrivateLinkResourcesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/PrivateLinkResource/list.json + */ + /** + * Sample code: WorkspaceListPrivateLinkResources. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void workspaceListPrivateLinkResources( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.privateLinkResources().listWithResponse("rg-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasListSamples.java new file mode 100644 index 0000000000000..858c7544b2dac --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Quotas List. */ +public final class QuotasListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Quota/list.json + */ + /** + * Sample code: List workspace quotas by VMFamily. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceQuotasByVMFamily( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.quotas().list("eastus", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasUpdateSamples.java new file mode 100644 index 0000000000000..efa15617dbd06 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasUpdateSamples.java @@ -0,0 +1,47 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.QuotaBaseProperties; +import com.azure.resourcemanager.machinelearningservices.models.QuotaUnit; +import com.azure.resourcemanager.machinelearningservices.models.QuotaUpdateParameters; +import java.util.Arrays; + +/** Samples for Quotas Update. */ +public final class QuotasUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Quota/update.json + */ + /** + * Sample code: update quotas. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateQuotas( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .quotas() + .updateWithResponse( + "eastus", + new QuotaUpdateParameters() + .withValue( + Arrays + .asList( + new QuotaBaseProperties() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace1/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs") + .withType("Microsoft.MachineLearningServices/workspaces/quotas") + .withLimit(100L) + .withUnit(QuotaUnit.COUNT), + new QuotaBaseProperties() + .withId( + "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg/providers/Microsoft.MachineLearningServices/workspaces/demo_workspace2/quotas/Standard_DSv2_Family_Cluster_Dedicated_vCPUs") + .withType("Microsoft.MachineLearningServices/workspaces/quotas") + .withLimit(200L) + .withUnit(QuotaUnit.COUNT))), + Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/UsagesListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/UsagesListSamples.java new file mode 100644 index 0000000000000..43f3e20adecc9 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/UsagesListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Usages List. */ +public final class UsagesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Usage/list.json + */ + /** + * Sample code: List Usages. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listUsages( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.usages().list("eastus", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/VirtualMachineSizesListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/VirtualMachineSizesListSamples.java new file mode 100644 index 0000000000000..6dd02bb50c72d --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/VirtualMachineSizesListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for VirtualMachineSizes List. */ +public final class VirtualMachineSizesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/VirtualMachineSize/list.json + */ + /** + * Sample code: List VM Sizes. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listVMSizes( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.virtualMachineSizes().listWithResponse("eastus", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsCreateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsCreateSamples.java new file mode 100644 index 0000000000000..abd325eae4c16 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsCreateSamples.java @@ -0,0 +1,29 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +/** Samples for WorkspaceConnections Create. */ +public final class WorkspaceConnectionsCreateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/create.json + */ + /** + * Sample code: CreateWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaceConnections() + .define("connection-1") + .withExistingWorkspace("resourceGroup-1", "workspace-1") + .withCategory("ACR") + .withTarget("www.facebook.com") + .withAuthType("PAT") + .withValue("secrets") + .create(); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsDeleteSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsDeleteSamples.java new file mode 100644 index 0000000000000..09a111587decc --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsDeleteSamples.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections Delete. */ +public final class WorkspaceConnectionsDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/delete.json + */ + /** + * Sample code: DeleteWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaceConnections() + .deleteWithResponse("resourceGroup-1", "workspace-1", "connection-1", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsGetSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsGetSamples.java new file mode 100644 index 0000000000000..7f4d1a31bdfa2 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsGetSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections Get. */ +public final class WorkspaceConnectionsGetSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/get.json + */ + /** + * Sample code: GetWorkspaceConnection. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspaceConnection( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceConnections().getWithResponse("resourceGroup-1", "workspace-1", "connection-1", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsListSamples.java new file mode 100644 index 0000000000000..a66e7bf68b26b --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for WorkspaceConnections List. */ +public final class WorkspaceConnectionsListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceConnection/list.json + */ + /** + * Sample code: ListWorkspaceConnections. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceConnections( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceConnections().list("resourceGroup-1", "workspace-1", "www.facebook.com", "ACR", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceFeaturesListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceFeaturesListSamples.java new file mode 100644 index 0000000000000..bf9aa6c8d28f3 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceFeaturesListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for WorkspaceFeatures List. */ +public final class WorkspaceFeaturesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceFeature/list.json + */ + /** + * Sample code: List Workspace features. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceFeatures( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceFeatures().list("myResourceGroup", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceSkusListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceSkusListSamples.java new file mode 100644 index 0000000000000..dd2067a0739b7 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceSkusListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for WorkspaceSkus List. */ +public final class WorkspaceSkusListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/WorkspaceSku/list.json + */ + /** + * Sample code: List Skus. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listSkus( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaceSkus().list(Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesCreateOrUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesCreateOrUpdateSamples.java new file mode 100644 index 0000000000000..73c0e2a8aaa13 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesCreateOrUpdateSamples.java @@ -0,0 +1,92 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.resourcemanager.machinelearningservices.models.EncryptionProperty; +import com.azure.resourcemanager.machinelearningservices.models.EncryptionStatus; +import com.azure.resourcemanager.machinelearningservices.models.Identity; +import com.azure.resourcemanager.machinelearningservices.models.IdentityForCmk; +import com.azure.resourcemanager.machinelearningservices.models.KeyVaultProperties; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.azure.resourcemanager.machinelearningservices.models.ResourceIdentityType; +import com.azure.resourcemanager.machinelearningservices.models.SharedPrivateLinkResource; +import com.azure.resourcemanager.machinelearningservices.models.UserAssignedIdentity; +import java.util.Arrays; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Workspaces CreateOrUpdate. */ +public final class WorkspacesCreateOrUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/create.json + */ + /** + * Sample code: Create Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void createWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .define("testworkspace") + .withExistingResourceGroup("workspace-1234") + .withRegion("eastus2euap") + .withIdentity( + new Identity() + .withType(ResourceIdentityType.SYSTEM_ASSIGNED_USER_ASSIGNED) + .withUserAssignedIdentities( + mapOf( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai", + new UserAssignedIdentity()))) + .withDescription("test description") + .withFriendlyName("HelloName") + .withKeyVault( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv") + .withApplicationInsights( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/microsoft.insights/components/testinsights") + .withContainerRegistry( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ContainerRegistry/registries/testRegistry") + .withStorageAccount( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/accountcrud-1234/providers/Microsoft.Storage/storageAccounts/testStorageAccount") + .withEncryption( + new EncryptionProperty() + .withStatus(EncryptionStatus.ENABLED) + .withIdentity( + new IdentityForCmk() + .withUserAssignedIdentity( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.ManagedIdentity/userAssignedIdentities/testuai")) + .withKeyVaultProperties( + new KeyVaultProperties() + .withKeyVaultArmId( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.KeyVault/vaults/testkv") + .withKeyIdentifier( + "https://testkv.vault.azure.net/keys/testkey/aabbccddee112233445566778899aabb") + .withIdentityClientId(""))) + .withHbiWorkspace(false) + .withSharedPrivateLinkResources( + Arrays + .asList( + new SharedPrivateLinkResource() + .withName("testdbresource") + .withPrivateLinkResourceId( + "/subscriptions/00000000-1111-2222-3333-444444444444/resourceGroups/workspace-1234/providers/Microsoft.DocumentDB/databaseAccounts/testdbresource/privateLinkResources/Sql") + .withGroupId("Sql") + .withRequestMessage("Please approve") + .withStatus(PrivateEndpointServiceConnectionStatus.APPROVED))) + .create(); + } + + @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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDeleteSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDeleteSamples.java new file mode 100644 index 0000000000000..5533e7b226cbc --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDeleteSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces Delete. */ +public final class WorkspacesDeleteSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/delete.json + */ + /** + * Sample code: Delete Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void deleteWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().delete("workspace-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDiagnoseSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDiagnoseSamples.java new file mode 100644 index 0000000000000..de98da83191b0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDiagnoseSamples.java @@ -0,0 +1,55 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseRequestProperties; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseWorkspaceParameters; +import java.util.HashMap; +import java.util.Map; + +/** Samples for Workspaces Diagnose. */ +public final class WorkspacesDiagnoseSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/diagnose.json + */ + /** + * Sample code: Diagnose Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void diagnoseWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .diagnose( + "workspace-1234", + "testworkspace", + new DiagnoseWorkspaceParameters() + .withValue( + new DiagnoseRequestProperties() + .withUdr(mapOf()) + .withNsg(mapOf()) + .withResourceLock(mapOf()) + .withDnsResolution(mapOf()) + .withStorageAccount(mapOf()) + .withKeyVault(mapOf()) + .withContainerRegistry(mapOf()) + .withApplicationInsights(mapOf()) + .withOthers(mapOf())), + Context.NONE); + } + + @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/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesGetByResourceGroupSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesGetByResourceGroupSamples.java new file mode 100644 index 0000000000000..cc1b28183a3c4 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesGetByResourceGroupSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces GetByResourceGroup. */ +public final class WorkspacesGetByResourceGroupSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/get.json + */ + /** + * Sample code: Get Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().getByResourceGroupWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListByResourceGroupSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListByResourceGroupSamples.java new file mode 100644 index 0000000000000..96cb2be798288 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListByResourceGroupSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListByResourceGroup. */ +public final class WorkspacesListByResourceGroupSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listByResourceGroup.json + */ + /** + * Sample code: Get Workspaces by Resource Group. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspacesByResourceGroup( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listByResourceGroup("workspace-1234", null, Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListKeysSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListKeysSamples.java new file mode 100644 index 0000000000000..2507668793336 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListKeysSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListKeys. */ +public final class WorkspacesListKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookAccessTokenSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookAccessTokenSamples.java new file mode 100644 index 0000000000000..c47300575163c --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookAccessTokenSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListNotebookAccessToken. */ +public final class WorkspacesListNotebookAccessTokenSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listNotebookAccessToken.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listNotebookAccessTokenWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookKeysSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookKeysSamples.java new file mode 100644 index 0000000000000..786b333022860 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookKeysSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListNotebookKeys. */ +public final class WorkspacesListNotebookKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Notebook/listKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listNotebookKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListOutboundNetworkDependenciesEndpointsSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListOutboundNetworkDependenciesEndpointsSamples.java new file mode 100644 index 0000000000000..be4b66f6006d8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListOutboundNetworkDependenciesEndpointsSamples.java @@ -0,0 +1,25 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListOutboundNetworkDependenciesEndpoints. */ +public final class WorkspacesListOutboundNetworkDependenciesEndpointsSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/ExternalFQDN/get.json + */ + /** + * Sample code: ListOutboundNetworkDependenciesEndpoints. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listOutboundNetworkDependenciesEndpoints( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager + .workspaces() + .listOutboundNetworkDependenciesEndpointsWithResponse("workspace-1234", "testworkspace", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListSamples.java new file mode 100644 index 0000000000000..9ec54e6e900ad --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces List. */ +public final class WorkspacesListSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listBySubscription.json + */ + /** + * Sample code: Get Workspaces by subscription. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void getWorkspacesBySubscription( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().list(null, Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListStorageAccountKeysSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListStorageAccountKeysSamples.java new file mode 100644 index 0000000000000..68ed4de1c29e5 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListStorageAccountKeysSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ListStorageAccountKeys. */ +public final class WorkspacesListStorageAccountKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/listStorageAccountKeys.json + */ + /** + * Sample code: List Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void listWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().listStorageAccountKeysWithResponse("testrg123", "workspaces123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesPrepareNotebookSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesPrepareNotebookSamples.java new file mode 100644 index 0000000000000..7c67a0a8a40d7 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesPrepareNotebookSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces PrepareNotebook. */ +public final class WorkspacesPrepareNotebookSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Notebook/prepare.json + */ + /** + * Sample code: Prepare Notebook. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void prepareNotebook( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().prepareNotebook("testrg123", "workspaces123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesResyncKeysSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesResyncKeysSamples.java new file mode 100644 index 0000000000000..b27463ed449a5 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesResyncKeysSamples.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.machinelearningservices.generated; + +import com.azure.core.util.Context; + +/** Samples for Workspaces ResyncKeys. */ +public final class WorkspacesResyncKeysSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/resyncKeys.json + */ + /** + * Sample code: Resync Workspace Keys. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void resyncWorkspaceKeys( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + manager.workspaces().resyncKeys("testrg123", "workspaces123", Context.NONE); + } +} diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesUpdateSamples.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesUpdateSamples.java new file mode 100644 index 0000000000000..06e0cb62bf51c --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesUpdateSamples.java @@ -0,0 +1,35 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.generated; + +import com.azure.core.util.Context; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.Workspace; + +/** Samples for Workspaces Update. */ +public final class WorkspacesUpdateSamples { + /* + * x-ms-original-file: specification/machinelearningservices/resource-manager/Microsoft.MachineLearningServices/stable/2021-07-01/examples/Workspace/update.json + */ + /** + * Sample code: Update Workspace. + * + * @param manager Entry point to MachineLearningServicesManager. + */ + public static void updateWorkspace( + com.azure.resourcemanager.machinelearningservices.MachineLearningServicesManager manager) { + Workspace resource = + manager + .workspaces() + .getByResourceGroupWithResponse("workspace-1234", "testworkspace", Context.NONE) + .getValue(); + resource + .update() + .withDescription("new description") + .withFriendlyName("New friendly name") + .withPublicNetworkAccess(PublicNetworkAccess.DISABLED) + .apply(); + } +}