From 1bd964088bc20eefdc6fa080da215d27107e64d6 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Thu, 6 Jan 2022 03:31:49 +0000 Subject: [PATCH] CodeGen from PR 17182 in Azure/azure-rest-api-specs update-typescript.md (#17182) --- .../CHANGELOG.md | 3 +- .../README.md | 7 +- .../SAMPLE.md | 1387 +++++++++++++++++ .../pom.xml | 121 +- .../MachineLearningServicesManager.java | 131 +- .../AzureMachineLearningWorkspaces.java | 47 +- ...omputesClient.java => ComputesClient.java} | 126 +- .../fluent/MachineLearningServicesClient.java | 207 --- .../fluent/NotebooksClient.java | 89 -- .../PrivateEndpointConnectionsClient.java | 44 +- .../fluent/PrivateLinkResourcesClient.java | 8 +- .../fluent/StorageAccountsClient.java | 38 - .../fluent/WorkspaceConnectionsClient.java | 21 +- .../fluent/WorkspaceFeaturesClient.java | 4 +- ...nsClient.java => WorkspaceSkusClient.java} | 8 +- .../fluent/WorkspacesClient.java | 277 +++- .../models/ClusterUpdateProperties.java | 54 + .../fluent/models/ComputeResourceInner.java | 116 +- .../models/DiagnoseResponseResultInner.java | 54 + .../models/ExternalFqdnResponseInner.java | 55 + .../PrivateEndpointConnectionInner.java | 171 +- .../PrivateEndpointConnectionProperties.java | 110 ++ .../models/PrivateLinkResourceProperties.java | 81 + .../fluent/models/ResourceQuotaInner.java | 4 +- .../fluent/models/ServiceResourceInner.java | 146 -- .../SharedPrivateLinkResourceProperty.java | 132 ++ .../VirtualMachineSizeListResultInner.java | 24 +- .../models/WorkspaceConnectionInner.java | 77 +- .../models/WorkspaceConnectionProps.java} | 67 +- .../fluent/models/WorkspaceInner.java | 434 +++--- .../models/WorkspacePropertiesInner.java | 603 +++++++ .../WorkspacePropertiesUpdateParameters.java | 189 +++ ...AzureMachineLearningWorkspacesBuilder.java | 4 +- .../AzureMachineLearningWorkspacesImpl.java | 108 +- .../implementation/ComputeResourceImpl.java | 72 +- ...lientImpl.java => ComputesClientImpl.java} | 415 +++-- ...ingComputesImpl.java => ComputesImpl.java} | 30 +- .../DiagnoseResponseResultImpl.java | 34 + .../ExternalFqdnResponseImpl.java | 41 + .../MachineLearningServicesClientImpl.java | 1298 --------------- .../MachineLearningServicesImpl.java | 222 --- .../implementation/NotebooksClientImpl.java | 455 ------ .../implementation/NotebooksImpl.java | 82 - .../PrivateEndpointConnectionImpl.java | 50 +- .../PrivateEndpointConnectionsClientImpl.java | 239 ++- .../PrivateEndpointConnectionsImpl.java | 18 +- .../PrivateLinkResourcesClientImpl.java | 33 +- .../PrivateLinkResourcesImpl.java | 9 +- .../implementation/ServiceResourceImpl.java | 244 --- .../StorageAccountsClientImpl.java | 211 --- .../implementation/StorageAccountsImpl.java | 62 - .../VirtualMachineSizeListResultImpl.java | 4 +- .../WorkspaceConnectionImpl.java | 23 +- .../WorkspaceConnectionsClientImpl.java | 57 +- .../WorkspaceConnectionsImpl.java | 2 +- .../WorkspaceFeaturesClientImpl.java | 12 +- .../implementation/WorkspaceImpl.java | 121 +- .../WorkspacePropertiesImpl.java | 157 ++ ...Impl.java => WorkspaceSkusClientImpl.java} | 58 +- ...ationsImpl.java => WorkspaceSkusImpl.java} | 24 +- .../implementation/WorkspacesClientImpl.java | 1342 ++++++++++++++-- .../implementation/WorkspacesImpl.java | 137 ++ .../models/AciServiceCreateRequest.java | 374 ----- ...AciServiceCreateRequestDataCollection.java | 39 - ...viceCreateRequestEncryptionProperties.java | 46 - ...ServiceCreateRequestVnetConfiguration.java | 39 - .../models/AciServiceResponse.java | 515 ------ .../AciServiceResponseDataCollection.java | 39 - ...ciServiceResponseEncryptionProperties.java | 46 - ...erviceResponseEnvironmentImageRequest.java | 69 - .../AciServiceResponseVnetConfiguration.java | 39 - .../models/AksComputeSecretsProperties.java | 108 ++ .../models/AksReplicaStatus.java | 131 -- .../models/AksReplicaStatusError.java | 24 - .../models/AksServiceCreateRequest.java | 450 ------ .../AksServiceCreateRequestAutoScaler.java | 60 - ...AksServiceCreateRequestDataCollection.java | 39 - ...reateRequestLivenessProbeRequirements.java | 61 - .../models/AksServiceResponse.java | 558 ------- .../models/AksServiceResponseAutoScaler.java | 60 - .../AksServiceResponseDataCollection.java | 39 - .../AksServiceResponseDeploymentStatus.java | 53 - ...erviceResponseEnvironmentImageRequest.java | 69 - ...viceResponseLivenessProbeRequirements.java | 60 - .../models/AksVariantResponse.java | 143 -- .../models/AmlCompute.java | 8 +- .../models/AmlComputeNodeInformation.java | 20 +- .../models/AmlComputeNodesInformation.java | 25 +- .../models/AmlComputeProperties.java | 115 +- .../models/AuthKeys.java | 76 - .../models/AutoScaler.java | 157 -- ...operties.java => BaseComputeResource.java} | 20 +- .../models/ClusterUpdateParameters.java | 43 +- .../models/Compute.java | 1 + .../models/ComputeEnvironmentType.java | 34 - .../models/ComputeInstance.java | 8 +- .../models/ComputeInstanceProperties.java | 37 +- .../models/ComputeInstanceSshSettings.java | 20 +- .../models/ComputeNodesInformation.java | 49 - .../models/ComputeResource.java | 125 +- .../models/ComputeType.java | 3 + ...ineLearningComputes.java => Computes.java} | 49 +- ...ava => ComputesCreateOrUpdateHeaders.java} | 11 +- ...va => ComputesCreateOrUpdateResponse.java} | 12 +- ...eaders.java => ComputesDeleteHeaders.java} | 14 +- ...ponse.java => ComputesDeleteResponse.java} | 15 +- .../models/ContainerRegistry.java | 102 -- .../models/ContainerResourceRequirements.java | 196 --- .../models/CreateEndpointVariantRequest.java | 158 -- .../models/CreateServiceRequest.java | 201 --- ...ServiceRequestEnvironmentImageRequest.java | 69 - .../models/CreateServiceRequestKeys.java | 39 - .../models/DataFactory.java | 4 +- .../models/Databricks.java | 6 +- .../DatabricksComputeSecretsProperties.java | 50 + .../models/DatabricksProperties.java | 2 +- .../models/DatasetReference.java | 76 - .../models/DeploymentType.java | 37 - .../models/DiagnoseRequestProperties.java | 269 ++++ .../models/DiagnoseResponseResult.java | 25 + .../models/DiagnoseResponseResultValue.java | 286 ++++ .../models/DiagnoseResult.java | 69 + .../models/DiagnoseResultLevel.java | 37 + .../models/DiagnoseWorkspaceParameters.java | 53 + .../models/EncryptionProperties.java | 118 -- .../models/EnvironmentImageRequest.java | 194 --- .../EnvironmentImageRequestEnvironment.java | 82 - ...nmentImageRequestEnvironmentReference.java | 39 - .../models/EnvironmentImageResponse.java | 194 --- .../EnvironmentImageResponseEnvironment.java | 82 - ...mentImageResponseEnvironmentReference.java | 40 - .../models/EnvironmentReference.java | 76 - .../models/EstimatedVMPrice.java | 18 +- .../models/EstimatedVMPrices.java | 30 +- .../models/ExternalFqdnResponse.java | 25 + .../models/FqdnEndpoint.java | 80 + ...yResponse.java => FqdnEndpointDetail.java} | 30 +- .../models/FqdnEndpoints.java | 53 + .../models/FqdnEndpointsProperties.java | 80 + .../models/HDInsight.java | 6 +- .../models/HDInsightProperties.java | 2 +- .../models/Identity.java | 2 + .../models/ImageAsset.java | 128 -- .../models/InstanceTypeSchema.java | 82 + .../models/InstanceTypeSchemaResources.java | 80 + .../models/Kubernetes.java | 87 ++ .../models/KubernetesProperties.java | 245 +++ .../models/KubernetesSchema.java | 53 + .../models/LivenessProbeRequirements.java | 154 -- ...LearningComputesCreateOrUpdateHeaders.java | 51 - .../models/MachineLearningServices.java | 170 -- .../machinelearningservices/models/Model.java | 601 ------- .../models/ModelDataCollection.java | 76 - .../models/ModelDockerSection.java | 107 -- .../ModelDockerSectionBaseImageRegistry.java | 46 - .../models/ModelDockerSectionResponse.java | 108 -- ...ockerSectionResponseBaseImageRegistry.java | 32 - .../models/ModelEnvironmentDefinition.java | 248 --- .../ModelEnvironmentDefinitionDocker.java | 47 - .../ModelEnvironmentDefinitionPython.java | 53 - .../models/ModelEnvironmentDefinitionR.java | 82 - .../ModelEnvironmentDefinitionResponse.java | 248 --- ...elEnvironmentDefinitionResponseDocker.java | 47 - ...elEnvironmentDefinitionResponsePython.java | 53 - .../ModelEnvironmentDefinitionResponseR.java | 82 - ...delEnvironmentDefinitionResponseSpark.java | 47 - .../ModelEnvironmentDefinitionSpark.java | 47 - .../models/ModelPythonSection.java | 135 -- .../models/ModelSparkSection.java | 106 -- .../models/NodeStateCounts.java | 27 +- .../models/Notebooks.java | 54 - .../models/OrderString.java | 40 - .../models/PaginatedServiceList.java | 61 - .../models/PrivateEndpointConnection.java | 192 ++- .../PrivateEndpointConnectionListResult.java | 55 + .../models/PrivateEndpointConnections.java | 34 +- .../models/PrivateLinkResource.java | 144 +- .../models/PrivateLinkResources.java | 8 +- .../models/PublicNetworkAccess.java | 34 + .../models/QuotaBaseProperties.java | 6 +- .../models/RCranPackage.java | 76 - .../models/RGitHubPackage.java | 76 - .../models/RGitHubPackageResponse.java | 50 - .../models/RSection.java | 242 --- .../models/RSectionResponse.java | 242 --- .../models/ResourceQuota.java | 2 +- .../models/ScaleSettingsInformation.java | 53 + .../models/ServiceResource.java | 312 ---- .../models/ServiceResponseBase.java | 178 --- .../models/ServiceResponseBaseError.java | 24 - .../models/SharedPrivateLinkResource.java | 70 +- .../models/SparkMavenPackage.java | 102 -- .../models/StorageAccounts.java | 33 - .../models/SynapseSpark.java | 12 +- ...rated.java => SynapseSparkProperties.java} | 46 +- .../models/UpdateWorkspaceQuotas.java | 12 +- .../models/UserAccountCredentials.java | 22 +- .../models/VariantType.java | 34 - .../models/VirtualMachineSize.java | 74 +- .../models/VirtualMachineSizeListResult.java | 6 +- .../models/VnetConfiguration.java | 76 - .../models/WebServiceState.java | 43 - .../models/Workspace.java | 267 +++- .../models/WorkspaceConnection.java | 15 +- .../models/WorkspaceConnections.java | 12 +- .../models/WorkspaceFeatures.java | 4 +- .../models/WorkspaceProperties.java | 198 +++ ...paceOperations.java => WorkspaceSkus.java} | 8 +- .../models/WorkspaceUpdateParameters.java | 109 +- .../models/Workspaces.java | 168 +- .../models/WorkspacesDiagnoseHeaders.java | 76 + ...e.java => WorkspacesDiagnoseResponse.java} | 20 +- .../ComputeCreateOrUpdateSamples.java | 264 ++++ .../generated/ComputeDeleteSamples.java | 26 + .../generated/ComputeGetSamples.java | 62 + .../generated/ComputeListKeysSamples.java | 23 + .../generated/ComputeListNodesSamples.java | 23 + .../generated/ComputeListSamples.java | 23 + .../generated/ComputeRestartSamples.java | 23 + .../generated/ComputeStartSamples.java | 23 + .../generated/ComputeStopSamples.java | 23 + .../generated/ComputeUpdateSamples.java | 38 + ...pointConnectionsCreateOrUpdateSamples.java | 32 + ...ivateEndpointConnectionsDeleteSamples.java | 25 + .../PrivateEndpointConnectionsGetSamples.java | 25 + ...PrivateEndpointConnectionsListSamples.java | 23 + .../PrivateLinkResourcesListSamples.java | 23 + .../generated/QuotasListSamples.java | 23 + .../generated/QuotasUpdateSamples.java | 47 + .../generated/UsagesListSamples.java | 23 + .../VirtualMachineSizesListSamples.java | 23 + .../WorkspaceConnectionsCreateSamples.java | 29 + .../WorkspaceConnectionsDeleteSamples.java | 25 + .../WorkspaceConnectionsGetSamples.java | 23 + .../WorkspaceConnectionsListSamples.java | 23 + .../WorkspaceFeaturesListSamples.java | 23 + .../generated/WorkspaceSkusListSamples.java | 23 + .../WorkspacesCreateOrUpdateSamples.java | 92 ++ .../generated/WorkspacesDeleteSamples.java | 23 + .../generated/WorkspacesDiagnoseSamples.java | 55 + .../WorkspacesGetByResourceGroupSamples.java | 23 + .../WorkspacesListByResourceGroupSamples.java | 23 + .../generated/WorkspacesListKeysSamples.java | 23 + ...kspacesListNotebookAccessTokenSamples.java | 23 + .../WorkspacesListNotebookKeysSamples.java | 23 + ...ndNetworkDependenciesEndpointsSamples.java | 25 + .../generated/WorkspacesListSamples.java | 23 + ...rkspacesListStorageAccountKeysSamples.java | 23 + .../WorkspacesPrepareNotebookSamples.java | 23 + .../WorkspacesResyncKeysSamples.java | 23 + .../generated/WorkspacesUpdateSamples.java | 35 + 251 files changed, 10649 insertions(+), 14370 deletions(-) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/SAMPLE.md rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/{MachineLearningComputesClient.java => ComputesClient.java} (82%) delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/MachineLearningServicesClient.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/NotebooksClient.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/StorageAccountsClient.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/{WorkspaceOperationsClient.java => WorkspaceSkusClient.java} (87%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ClusterUpdateProperties.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/DiagnoseResponseResultInner.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ExternalFqdnResponseInner.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionProperties.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ServiceResourceInner.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/SharedPrivateLinkResourceProperty.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/{models/WorkspaceConnectionDto.java => fluent/models/WorkspaceConnectionProps.java} (64%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesInner.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesUpdateParameters.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/{MachineLearningComputesClientImpl.java => ComputesClientImpl.java} (87%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/{MachineLearningComputesImpl.java => ComputesImpl.java} (89%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/DiagnoseResponseResultImpl.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ExternalFqdnResponseImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesClientImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/MachineLearningServicesImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksClientImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/NotebooksImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/ServiceResourceImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsClientImpl.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/StorageAccountsImpl.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/WorkspacePropertiesImpl.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/{WorkspaceOperationsClientImpl.java => WorkspaceSkusClientImpl.java} (84%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/{WorkspaceOperationsImpl.java => WorkspaceSkusImpl.java} (75%) delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestDataCollection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestEncryptionProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceCreateRequestVnetConfiguration.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseDataCollection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEncryptionProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseEnvironmentImageRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AciServiceResponseVnetConfiguration.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatus.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksReplicaStatusError.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestAutoScaler.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestDataCollection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceCreateRequestLivenessProbeRequirements.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseAutoScaler.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDataCollection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseDeploymentStatus.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseEnvironmentImageRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksServiceResponseLivenessProbeRequirements.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksVariantResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AuthKeys.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AutoScaler.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{SynapseSparkPoolProperties.java => BaseComputeResource.java} (65%) delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeEnvironmentType.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeNodesInformation.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningComputes.java => Computes.java} (86%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningServicesCreateOrUpdateHeaders.java => ComputesCreateOrUpdateHeaders.java} (73%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningComputesCreateOrUpdateResponse.java => ComputesCreateOrUpdateResponse.java} (71%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningComputesDeleteHeaders.java => ComputesDeleteHeaders.java} (78%) rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningComputesDeleteResponse.java => ComputesDeleteResponse.java} (60%) delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistry.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerResourceRequirements.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateEndpointVariantRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestEnvironmentImageRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/CreateServiceRequestKeys.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatasetReference.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DeploymentType.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseRequestProperties.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResult.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResultValue.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResult.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResultLevel.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseWorkspaceParameters.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EncryptionProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequest.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironment.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageRequestEnvironmentReference.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironment.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentImageResponseEnvironmentReference.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/EnvironmentReference.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ExternalFqdnResponse.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoint.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{ContainerRegistryResponse.java => FqdnEndpointDetail.java} (54%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoints.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointsProperties.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ImageAsset.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchema.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchemaResources.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesProperties.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesSchema.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/LivenessProbeRequirements.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateHeaders.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServices.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Model.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDataCollection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionBaseImageRegistry.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelDockerSectionResponseBaseImageRegistry.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinition.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionDocker.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionPython.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionR.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseDocker.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponsePython.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseR.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionResponseSpark.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelEnvironmentDefinitionSpark.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelPythonSection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ModelSparkSection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Notebooks.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/OrderString.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PaginatedServiceList.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionListResult.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RCranPackage.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackage.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RGitHubPackageResponse.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSection.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/RSectionResponse.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResource.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBase.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ServiceResponseBaseError.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SparkMavenPackage.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/StorageAccounts.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{SynapseSparkPoolPropertiesAutoGenerated.java => SynapseSparkProperties.java} (78%) delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VariantType.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VnetConfiguration.java delete mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WebServiceState.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspaceProperties.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{WorkspaceOperations.java => WorkspaceSkus.java} (85%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseHeaders.java rename sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/{MachineLearningServicesCreateOrUpdateResponse.java => WorkspacesDiagnoseResponse.java} (59%) create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeCreateOrUpdateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeDeleteSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeGetSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListKeysSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListNodesSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeRestartSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStartSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeStopSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/ComputeUpdateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsCreateOrUpdateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsDeleteSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsGetSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateEndpointConnectionsListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/PrivateLinkResourcesListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/QuotasUpdateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/UsagesListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/VirtualMachineSizesListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsCreateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsDeleteSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsGetSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceConnectionsListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceFeaturesListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspaceSkusListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesCreateOrUpdateSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDeleteSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesDiagnoseSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesGetByResourceGroupSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListByResourceGroupSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListKeysSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookAccessTokenSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListNotebookKeysSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListOutboundNetworkDependenciesEndpointsSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesListStorageAccountKeysSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesPrepareNotebookSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesResyncKeysSamples.java create mode 100644 sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/samples/java/com/azure/resourcemanager/machinelearningservices/generated/WorkspacesUpdateSamples.java diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/CHANGELOG.md index 41c62a9ca98f6..841f07f88fb78 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-01-06) +- 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 1c4486fd3298e..1ab0b7b407180 100644 --- a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/pom.xml @@ -1,58 +1,81 @@ - 4.0.0 - - com.azure - azure-client-sdk-parent - 1.7.0 - ../../parents/azure-client-sdk-parent - + 4.0.0 + + com.azure + azure-client-sdk-parent + 1.7.0 + ../../parents/azure-client-sdk-parent + - com.azure.resourcemanager - azure-resourcemanager-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 + + https://github.com/Azure/azure-sdk-for-java + scm:git:git@github.com:Azure/azure-sdk-for-java.git + scm:git:git@github.com:Azure/azure-sdk-for-java.git + HEAD + + + + microsoft + Microsoft + + + + UTF-8 + true false - - - - com.azure - azure-core - 1.23.1 - - - com.azure - azure-core-management - 1.4.4 - - + + + + com.azure + azure-core + 1.23.1 + + + com.azure + azure-core-management + 1.4.4 + + + + + + org.revapi + revapi-maven-plugin + 0.11.2 + + + + + java.method.addedToInterface + + + true + .* + com\.azure\.resourcemanager(\.[^.]+)+\.fluent(\.[^.]+)* + + + + + + + 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..7264cff2ea127 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,8 +8,8 @@ import com.azure.core.http.HttpClient; import com.azure.core.http.HttpPipeline; import com.azure.core.http.HttpPipelineBuilder; +import com.azure.core.http.HttpPipelinePosition; import com.azure.core.http.policy.AddDatePolicy; -import com.azure.core.http.policy.BearerTokenAuthenticationPolicy; import com.azure.core.http.policy.HttpLogOptions; import com.azure.core.http.policy.HttpLoggingPolicy; import com.azure.core.http.policy.HttpPipelinePolicy; @@ -17,44 +17,40 @@ import com.azure.core.http.policy.RequestIdPolicy; import com.azure.core.http.policy.RetryPolicy; import com.azure.core.http.policy.UserAgentPolicy; +import com.azure.core.management.http.policy.ArmChallengeAuthenticationPolicy; import com.azure.core.management.profile.AzureProfile; import com.azure.core.util.Configuration; import com.azure.core.util.logging.ClientLogger; import com.azure.resourcemanager.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 +61,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; @@ -134,6 +124,7 @@ public static final class Configurable { private HttpClient httpClient; private HttpLogOptions httpLogOptions; private final List policies = new ArrayList<>(); + private final List scopes = new ArrayList<>(); private RetryPolicy retryPolicy; private Duration defaultPollInterval; @@ -173,6 +164,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. * @@ -229,20 +231,33 @@ 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); } List policies = new ArrayList<>(); policies.add(new UserAgentPolicy(userAgentBuilder.toString())); policies.add(new RequestIdPolicy()); + policies + .addAll( + this + .policies + .stream() + .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_CALL) + .collect(Collectors.toList())); HttpPolicyProviders.addBeforeRetryPolicies(policies); policies.add(retryPolicy); policies.add(new AddDatePolicy()); + policies.add(new ArmChallengeAuthenticationPolicy(credential, scopes.toArray(new String[0]))); policies - .add( - new BearerTokenAuthenticationPolicy( - credential, profile.getEnvironment().getManagementEndpoint() + "/.default")); - policies.addAll(this.policies); + .addAll( + this + .policies + .stream() + .filter(p -> p.getPipelinePosition() == HttpPipelinePosition.PER_RETRY) + .collect(Collectors.toList())); HttpPolicyProviders.addAfterRetryPolicies(policies); policies.add(new HttpLoggingPolicy(httpLogOptions)); HttpPipeline httpPipeline = @@ -270,14 +285,6 @@ 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. */ public Usages usages() { if (this.usages == null) { @@ -302,21 +309,12 @@ 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); + /** @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. */ @@ -336,37 +334,28 @@ 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); + /** @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); + /** @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); + /** @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 82% 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..45df75a6f44a6 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,12 +17,12 @@ 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. @@ -30,12 +30,12 @@ public interface MachineLearningComputesClient { * @return computes in specified workspace. */ @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. @@ -45,14 +45,14 @@ public interface MachineLearningComputesClient { * @return computes in specified workspace. */ @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,7 +67,7 @@ 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. @@ -84,7 +84,7 @@ 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. @@ -93,7 +93,7 @@ Response getWithResponse( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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. @@ -111,7 +111,7 @@ SyncPoller, ComputeResourceInner> beginCreateOr * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +162,7 @@ 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. @@ -171,7 +171,7 @@ ComputeResourceInner createOrUpdate( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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. @@ -189,7 +189,7 @@ SyncPoller, ComputeResourceInner> beginUpdate( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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 @@ -249,7 +249,7 @@ ComputeResourceInner update( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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 @@ -270,7 +270,7 @@ SyncPoller, Void> beginDelete( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,13 @@ 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. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listNodes( @@ -336,14 +336,14 @@ 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. */ @ServiceMethod(returns = ReturnType.COLLECTION) PagedIterable listNodes( @@ -352,7 +352,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,7 +366,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. * @param context The context to associate with this operation. @@ -382,7 +382,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. @@ -390,13 +390,13 @@ Response listKeysWithResponse( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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. @@ -405,14 +405,14 @@ Response listKeysWithResponse( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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 +425,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,7 +439,7 @@ 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. @@ -447,13 +447,13 @@ SyncPoller, Void> beginStart( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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. @@ -462,14 +462,14 @@ SyncPoller, Void> beginStart( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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 +482,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 +496,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 completion. + */ + @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 completion. + */ + @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 +539,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/PrivateEndpointConnectionsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/PrivateEndpointConnectionsClient.java index 28c1ae7879899..921469a967752 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,44 @@ 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. + */ + @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. + */ + @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,7 +58,7 @@ 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. @@ -46,7 +74,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 +84,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 +93,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. @@ -76,7 +104,7 @@ PrivateEndpointConnectionInner put( * @return the Private Endpoint Connection resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - Response putWithResponse( + Response createOrUpdateWithResponse( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -86,7 +114,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,7 +127,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. * @param context The context to associate with this operation. 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..c433852e73ee3 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,12 +23,12 @@ 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. @@ -37,6 +37,6 @@ public interface PrivateLinkResourcesClient { * @return the private link resources that need to be created for a workspace. */ @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/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/WorkspaceConnectionsClient.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/WorkspaceConnectionsClient.java index e595d0c2001b1..e64714d48c2f1 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,14 +10,13 @@ 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. @@ -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. @@ -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. @@ -78,13 +77,13 @@ 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,7 +97,7 @@ 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. @@ -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,7 +126,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. * @param context The context to associate with this operation. 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..e93a4142606b1 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,7 +15,7 @@ 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. @@ -28,7 +28,7 @@ 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. 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 87% 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..e1182d56a0fa5 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,8 +10,8 @@ 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. * @@ -20,7 +20,7 @@ public interface WorkspaceOperationsClient { * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.COLLECTION) - PagedIterable listSkus(); + PagedIterable list(); /** * Lists all skus with associated features. @@ -32,5 +32,5 @@ public interface WorkspaceOperationsClient { * @return list of skus with features. */ @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..4a0c38956bebb 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,7 +40,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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -49,7 +55,7 @@ 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. @@ -57,14 +63,14 @@ Response getByResourceGroupWithResponse( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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. @@ -73,14 +79,14 @@ SyncPoller, WorkspaceInner> beginCreateOrUpdate( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,20 +116,20 @@ 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. */ - @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. @@ -131,13 +137,13 @@ WorkspaceInner createOrUpdate( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +182,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. * @param context The context to associate with this operation. @@ -192,7 +198,7 @@ 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. @@ -204,7 +210,7 @@ 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. @@ -215,11 +221,86 @@ Response updateWithResponse( @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 response. + */ + @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 response. + */ + @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,7 +314,7 @@ 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. @@ -249,21 +330,21 @@ 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. */ - @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. @@ -271,14 +352,14 @@ Response listKeysWithResponse( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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 +372,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. @@ -327,7 +408,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,7 +421,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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -351,4 +432,144 @@ Response listKeysWithResponse( @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 response. + */ + @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 response. + */ + @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. + */ + @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. + */ + @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. + */ + @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/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..df9b64962c8d0 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ClusterUpdateProperties.java @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.ScaleSettingsInformation; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The properties of a amlCompute that need to be updated. */ +@Fluent +public final class ClusterUpdateProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterUpdateProperties.class); + + /* + * 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..e40237f420114 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,33 +5,41 @@ 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 { +public final class ComputeResourceInner extends ProxyResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputeResourceInner.class); - /* - * Compute properties - */ - @JsonProperty(value = "properties") - private Compute properties; - /* * The identity of the resource. */ @JsonProperty(value = "identity") private Identity identity; + /* + * Specifies the location of the resource. + */ + @JsonProperty(value = "location") + private String location; + + /* + * Contains resource tags defined as key/value pairs. + */ + @JsonProperty(value = "tags") + @JsonInclude(value = JsonInclude.Include.NON_NULL, content = JsonInclude.Include.ALWAYS) + private Map tags; + /* * The sku of the workspace. */ @@ -39,48 +47,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 +139,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 +147,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 +173,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/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..edcb636935eb3 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/DiagnoseResponseResultInner.java @@ -0,0 +1,54 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.DiagnoseResponseResultValue; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The DiagnoseResponseResult model. */ +@Fluent +public final class DiagnoseResponseResultInner { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseResponseResultInner.class); + + /* + * 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..f842179a65e3f --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/ExternalFqdnResponseInner.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.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.FqdnEndpoints; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The ExternalFqdnResponse model. */ +@Fluent +public final class ExternalFqdnResponseInner { + @JsonIgnore private final ClientLogger logger = new ClientLogger(ExternalFqdnResponseInner.class); + + /* + * 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/PrivateEndpointConnectionInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionInner.java index 3334cc9a86e15..991183bfb00e5 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,8 +5,7 @@ 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; @@ -15,39 +14,39 @@ 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 { +public final class PrivateEndpointConnectionInner extends ProxyResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionInner.class); /* - * 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 +55,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 +150,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 +158,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..9ca69b79a6f5d --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateEndpointConnectionProperties.java @@ -0,0 +1,110 @@ +// 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.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of the PrivateEndpointConnectProperties. */ +@Fluent +public final class PrivateEndpointConnectionProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionProperties.class); + + /* + * 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(); + } + } +} 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..d60ce164617dc --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/PrivateLinkResourceProperties.java @@ -0,0 +1,81 @@ +// 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.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** Properties of a private link resource. */ +@Fluent +public final class PrivateLinkResourceProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResourceProperties.class); + + /* + * 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..ba4a04a0620a2 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 @@ -41,7 +41,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 +89,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..ec24334debad9 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/SharedPrivateLinkResourceProperty.java @@ -0,0 +1,132 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.PrivateEndpointServiceConnectionStatus; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** Properties of a shared private link resource. */ +@Fluent +public final class SharedPrivateLinkResourceProperty { + @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResourceProperty.class); + + /* + * 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/VirtualMachineSizeListResultInner.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/VirtualMachineSizeListResultInner.java index d7b7bc81d032e..f30bdec893693 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 @@ -19,26 +19,26 @@ public final class VirtualMachineSizeListResultInner { /* * 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 +48,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..74a654255d987 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,7 +5,6 @@ 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; @@ -13,40 +12,24 @@ import com.fasterxml.jackson.annotation.JsonProperty; /** Workspace connection. */ -@JsonFlatten @Fluent -public class WorkspaceConnectionInner extends ProxyResource { +public final class WorkspaceConnectionInner extends ProxyResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceConnectionInner.class); /* - * Category of the workspace connection. + * Properties of workspace connection. */ - @JsonProperty(value = "properties.category") - private String category; + @JsonProperty(value = "properties") + private WorkspaceConnectionProps innerProperties; - /* - * Target of the workspace connection. - */ - @JsonProperty(value = "properties.target") - private String target; - - /* - * Authorization type of the workspace connection. - */ - @JsonProperty(value = "properties.authType") - private String authType; - - /* - * 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 +37,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 +47,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 +60,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 +70,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 +83,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 +93,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 +106,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 +116,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 +129,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 +139,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 +152,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 64% 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..1c50dc857c25d 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,49 @@ // 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.azure.resourcemanager.machinelearningservices.models.ValueFormat; import com.fasterxml.jackson.annotation.JsonIgnore; 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 { + @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceConnectionProps.class); /* * 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 +58,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 +78,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 +98,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 +118,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 +138,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..5aea47667baf0 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,161 @@ 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 { +public final class WorkspaceInner extends ProxyResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceInner.class); /* - * The immutable id associated with this workspace. + * The properties of the machine learning workspace. */ - @JsonProperty(value = "properties.workspaceId", access = JsonProperty.Access.WRITE_ONLY) - private String workspaceId; + @JsonProperty(value = "properties") + private WorkspacePropertiesInner innerProperties; /* - * 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; - - /* - * Url for the discovery service to identify regional endpoints for machine - * learning experimentation services - */ - @JsonProperty(value = "properties.discoveryUrl") - private String discoveryUrl; - - /* - * 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 +167,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 +176,7 @@ public String workspaceId() { * @return the description value. */ public String description() { - return this.description; + return this.innerProperties() == null ? null : this.innerProperties().description(); } /** @@ -204,7 +186,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 +199,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 +209,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 +223,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 +234,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 +248,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 +259,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 +273,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 +284,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 +298,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 +309,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 +323,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 +334,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 +348,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 +357,7 @@ public ProvisioningState provisioningState() { * @return the encryption value. */ public EncryptionProperty encryption() { - return this.encryption; + return this.innerProperties() == null ? null : this.innerProperties().encryption(); } /** @@ -364,7 +367,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 +381,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 +392,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 +406,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 +415,7 @@ public String serviceProvisionedResourceGroup() { * @return the privateLinkCount value. */ public Integer privateLinkCount() { - return this.privateLinkCount; + return this.innerProperties() == null ? null : this.innerProperties().privateLinkCount(); } /** @@ -415,7 +424,7 @@ public Integer privateLinkCount() { * @return the imageBuildCompute value. */ public String imageBuildCompute() { - return this.imageBuildCompute; + return this.innerProperties() == null ? null : this.innerProperties().imageBuildCompute(); } /** @@ -425,7 +434,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 +448,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 +459,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 +495,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 +504,7 @@ public List privateEndpointConnections() { * @return the sharedPrivateLinkResources value. */ public List sharedPrivateLinkResources() { - return this.sharedPrivateLinkResources; + return this.innerProperties() == null ? null : this.innerProperties().sharedPrivateLinkResources(); } /** @@ -476,7 +514,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 +527,7 @@ public WorkspaceInner withSharedPrivateLinkResources(List tags) { - super.withTags(tags); - return this; + public String mlFlowTrackingUri() { + return this.innerProperties() == null ? null : this.innerProperties().mlFlowTrackingUri(); } /** @@ -610,20 +614,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..ea04f4391aa5f --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesInner.java @@ -0,0 +1,603 @@ +// 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.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.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.List; + +/** The properties of a machine learning workspace. */ +@Fluent +public final class WorkspacePropertiesInner { + @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspacePropertiesInner.class); + + /* + * 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..653589bcb7c80 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/fluent/models/WorkspacePropertiesUpdateParameters.java @@ -0,0 +1,189 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.machinelearningservices.fluent.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.models.PublicNetworkAccess; +import com.azure.resourcemanager.machinelearningservices.models.ServiceManagedResourcesSettings; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The parameters for updating the properties of a machine learning workspace. */ +@Fluent +public final class WorkspacePropertiesUpdateParameters { + @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspacePropertiesUpdateParameters.class); + + /* + * 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/implementation/AzureMachineLearningWorkspacesBuilder.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/implementation/AzureMachineLearningWorkspacesBuilder.java index eea90921315f0..1af366c8dd9f8 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 @@ -19,12 +19,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. 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..8bd0eda479556 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; @@ -51,11 +48,11 @@ 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 +144,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 +180,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 +216,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 +259,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 +274,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); } /** 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 87% 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..4ac1c4482de6f 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 @@ -34,7 +34,7 @@ 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 +46,40 @@ 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 { + private final ClientLogger logger = new ClientLogger(ComputesClientImpl.class); /** 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 +224,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 +240,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,7 +260,7 @@ 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. @@ -271,7 +269,7 @@ Mono> listNodesNext( * @return computes in specified workspace. */ @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 +295,7 @@ private Mono> listByWorkspaceSinglePageAsync .withContext( context -> service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -321,7 +319,7 @@ 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. @@ -331,7 +329,7 @@ private Mono> listByWorkspaceSinglePageAsync * @return computes in specified workspace. */ @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 +353,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,7 +376,7 @@ 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. @@ -387,17 +385,16 @@ private Mono> listByWorkspaceSinglePageAsync * @return computes in specified workspace. */ @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. @@ -405,17 +402,17 @@ private PagedFlux listByWorkspaceAsync( * @return computes in specified workspace. */ @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. @@ -425,17 +422,17 @@ private PagedFlux listByWorkspaceAsync(String resourceGrou * @return computes in specified workspace. */ @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. @@ -443,15 +440,15 @@ private PagedFlux listByWorkspaceAsync( * @return computes in specified workspace. */ @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. @@ -461,16 +458,16 @@ public PagedIterable listByWorkspace(String resourceGroupN * @return computes in specified workspace. */ @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. @@ -524,7 +521,7 @@ 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. @@ -576,7 +573,7 @@ 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. @@ -601,7 +598,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,7 +615,7 @@ 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. @@ -637,7 +634,7 @@ 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. @@ -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. @@ -761,7 +758,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. @@ -770,7 +767,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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 +779,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. @@ -799,7 +796,7 @@ private PollerFlux, ComputeResourceInner> begin * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +816,7 @@ 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. @@ -828,7 +825,7 @@ private PollerFlux, ComputeResourceInner> begin * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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 +835,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. @@ -848,7 +845,7 @@ public SyncPoller, ComputeResourceInner> beginC * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +860,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. @@ -884,7 +881,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. @@ -910,7 +907,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 +926,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,7 +950,7 @@ 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. @@ -1014,7 +1011,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. @@ -1077,7 +1074,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. @@ -1086,7 +1083,7 @@ private Mono>> updateWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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 +1095,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. @@ -1115,7 +1112,7 @@ private PollerFlux, ComputeResourceInner> begin * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +1132,7 @@ 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. @@ -1144,7 +1141,7 @@ private PollerFlux, ComputeResourceInner> begin * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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 +1151,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. @@ -1164,7 +1161,7 @@ public SyncPoller, ComputeResourceInner> beginU * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +1175,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. @@ -1199,7 +1196,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. @@ -1225,7 +1222,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 +1241,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 +1264,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 @@ -1331,7 +1328,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 @@ -1394,7 +1391,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 @@ -1404,7 +1401,7 @@ private Mono>> deleteWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String workspaceName, @@ -1414,13 +1411,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 @@ -1431,7 +1429,7 @@ private PollerFlux, Void> beginDeleteAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) private PollerFlux, Void> beginDeleteAsync( String resourceGroupName, String workspaceName, @@ -1449,7 +1447,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 @@ -1459,7 +1457,7 @@ private PollerFlux, Void> beginDeleteAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -1472,7 +1470,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 @@ -1483,7 +1481,7 @@ public SyncPoller, Void> beginDelete( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete( String resourceGroupName, String workspaceName, @@ -1497,7 +1495,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 @@ -1521,7 +1519,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 @@ -1547,7 +1545,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 +1566,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 +1589,13 @@ 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. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesSinglePageAsync( @@ -1653,14 +1651,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. * @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. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesSinglePageAsync( @@ -1713,13 +1711,13 @@ 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. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listNodesAsync( @@ -1732,14 +1730,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. * @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. */ @ServiceMethod(returns = ReturnType.COLLECTION) private PagedFlux listNodesAsync( @@ -1752,13 +1750,13 @@ 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. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listNodes( @@ -1769,14 +1767,14 @@ 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. */ @ServiceMethod(returns = ReturnType.COLLECTION) public PagedIterable listNodes( @@ -1787,7 +1785,7 @@ 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. @@ -1840,7 +1838,7 @@ 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. @@ -1891,7 +1889,7 @@ 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. @@ -1916,7 +1914,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,7 +1930,7 @@ 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. @@ -1950,7 +1948,7 @@ 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. @@ -2003,7 +2001,7 @@ 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. @@ -2054,7 +2052,7 @@ 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. @@ -2062,19 +2060,20 @@ private Mono>> startWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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. @@ -2083,7 +2082,7 @@ private PollerFlux, Void> beginStartAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2096,7 @@ 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. @@ -2105,7 +2104,7 @@ private PollerFlux, Void> beginStartAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2113,7 @@ 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. @@ -2123,7 +2122,7 @@ public SyncPoller, Void> beginStart( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2131,7 @@ 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. @@ -2150,7 +2149,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. * @param context The context to associate with this operation. @@ -2169,7 +2168,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 +2183,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,7 +2199,7 @@ 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. @@ -2253,7 +2252,7 @@ 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. @@ -2304,7 +2303,7 @@ 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. @@ -2312,19 +2311,20 @@ private Mono>> stopWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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. @@ -2333,7 +2333,7 @@ private PollerFlux, Void> beginStopAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2347,7 @@ 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. @@ -2355,7 +2355,7 @@ private PollerFlux, Void> beginStopAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2364,7 @@ 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. @@ -2373,7 +2373,7 @@ public SyncPoller, Void> beginStop( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +2382,7 @@ 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. @@ -2400,7 +2400,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. * @param context The context to associate with this operation. @@ -2419,7 +2419,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 +2434,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,7 +2450,7 @@ 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. @@ -2459,7 +2459,7 @@ public void stop(String resourceGroupName, String workspaceName, String computeN * @return the completion. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> restartWithResponseAsync( + private Mono>> restartWithResponseAsync( String resourceGroupName, String workspaceName, String computeName) { if (this.client.getEndpoint() == null) { return Mono @@ -2503,7 +2503,7 @@ 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. @@ -2513,7 +2513,7 @@ private Mono> restartWithResponseAsync( * @return the completion. */ @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,7 +2554,86 @@ 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. + */ + @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 completion. + */ + @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 completion. + */ + @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 completion. + */ + @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. @@ -2564,14 +2643,35 @@ private Mono> restartWithResponseAsync( */ @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 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. + */ + @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 Name of the resource group in which 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. @@ -2586,19 +2686,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(); } /** @@ -2611,7 +2709,7 @@ public Response restartWithResponse( * @return paginated list of Machine Learning compute objects wrapped in ARM resource envelope. */ @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 +2721,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<>( @@ -2647,8 +2745,7 @@ private Mono> listByWorkspaceNextSinglePageA * @return paginated list of Machine Learning compute objects wrapped in ARM resource envelope. */ @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 +2758,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 +2777,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. */ @ServiceMethod(returns = ReturnType.SINGLE) private Mono> listNodesNextSinglePageAsync(String nextLink) { @@ -2716,7 +2813,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. */ @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 89% 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..9602489ece073 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,39 @@ 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 { + @JsonIgnore private 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,9 +140,8 @@ 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) { @@ -198,7 +196,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/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..19ca21ba229e5 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,6 +19,10 @@ 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; @@ -27,6 +31,7 @@ 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. */ @@ -59,6 +64,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 +103,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,10 +132,176 @@ 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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. @@ -171,7 +357,7 @@ 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. @@ -225,7 +411,7 @@ 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. @@ -250,7 +436,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,7 +453,7 @@ 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. @@ -285,7 +471,7 @@ 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. @@ -295,7 +481,7 @@ public Response getWithResponse( * @return the Private Endpoint Connection resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> putWithResponseAsync( + private Mono> createOrUpdateWithResponseAsync( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -335,7 +521,7 @@ private Mono> putWithResponseAsync( .withContext( context -> service - .put( + .createOrUpdate( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -351,7 +537,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. @@ -362,7 +548,7 @@ private Mono> putWithResponseAsync( * @return the Private Endpoint Connection resource. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> putWithResponseAsync( + private Mono> createOrUpdateWithResponseAsync( String resourceGroupName, String workspaceName, String privateEndpointConnectionName, @@ -401,7 +587,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,7 +602,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. @@ -426,12 +612,13 @@ private Mono> putWithResponseAsync( * @return the Private Endpoint Connection resource. */ @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 +632,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 +642,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. @@ -477,13 +664,13 @@ public PrivateEndpointConnectionInner put( * @return the Private Endpoint Connection resource. */ @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,7 +678,7 @@ 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. @@ -547,7 +734,7 @@ 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. @@ -601,7 +788,7 @@ 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. @@ -619,7 +806,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,7 +821,7 @@ 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. 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..f141e867bc400 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; @@ -28,6 +29,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 = @@ -153,9 +167,7 @@ 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) { 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..713ade17f3bfd 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 @@ -61,7 +61,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,7 +74,7 @@ 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. @@ -82,7 +82,7 @@ Mono> listByWorkspace( * @return the private link resources that need to be created for a workspace. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listByWorkspaceWithResponseAsync( + private Mono> listWithResponseAsync( String resourceGroupName, String workspaceName) { if (this.client.getEndpoint() == null) { return Mono @@ -108,7 +108,7 @@ private Mono> listByWorkspaceWithRe .withContext( context -> service - .listByWorkspace( + .list( this.client.getEndpoint(), this.client.getSubscriptionId(), resourceGroupName, @@ -122,7 +122,7 @@ 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. @@ -131,7 +131,7 @@ private Mono> listByWorkspaceWithRe * @return the private link resources that need to be created for a workspace. */ @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 +155,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,7 +168,7 @@ 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. @@ -176,9 +176,8 @@ private Mono> listByWorkspaceWithRe * @return the private link resources that need to be created for a workspace. */ @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,14 +199,14 @@ 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. @@ -216,8 +215,8 @@ public PrivateLinkResourceListResultInner listByWorkspace(String resourceGroupNa * @return the private link resources that need to be created for a workspace. */ @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..5d49242c1da2c 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 @@ -28,9 +28,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 +37,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/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/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/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..1f248c2b9e359 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 @@ -32,7 +32,6 @@ 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. */ @@ -94,7 +93,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,7 +133,7 @@ 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. @@ -190,7 +189,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. @@ -244,7 +243,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. @@ -262,7 +261,7 @@ 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. @@ -279,7 +278,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. @@ -298,7 +297,7 @@ 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. @@ -315,7 +314,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. @@ -334,7 +333,7 @@ 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. @@ -345,7 +344,7 @@ public PagedIterable list( */ @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 +393,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. @@ -409,7 +408,7 @@ private Mono> createWithResponseAsync( String resourceGroupName, String workspaceName, String connectionName, - WorkspaceConnectionDto parameters, + WorkspaceConnectionInner parameters, Context context) { if (this.client.getEndpoint() == null) { return Mono @@ -456,7 +455,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. @@ -467,7 +466,7 @@ private Mono> createWithResponseAsync( */ @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 +481,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 +492,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. @@ -515,7 +514,7 @@ public Response createWithResponse( String resourceGroupName, String workspaceName, String connectionName, - WorkspaceConnectionDto parameters, + WorkspaceConnectionInner parameters, Context context) { return createWithResponseAsync(resourceGroupName, workspaceName, connectionName, parameters, context).block(); } @@ -523,7 +522,7 @@ 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. @@ -576,7 +575,7 @@ 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. @@ -627,7 +626,7 @@ 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. @@ -652,7 +651,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,7 +667,7 @@ 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. @@ -686,7 +685,7 @@ 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. @@ -739,7 +738,7 @@ 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. @@ -790,7 +789,7 @@ 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. @@ -807,7 +806,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,7 +821,7 @@ 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. 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..5c7b1f8cd2f9a 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 @@ -149,7 +149,7 @@ public void deleteById(String id) { 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) { 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..9173d3513a610 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 @@ -88,7 +88,7 @@ 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. @@ -145,7 +145,7 @@ 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. @@ -200,7 +200,7 @@ 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. @@ -216,7 +216,7 @@ 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. @@ -234,7 +234,7 @@ 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. @@ -249,7 +249,7 @@ 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. 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 84% 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..70f705fcc1c23 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 @@ -26,44 +26,44 @@ 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 { + private final ClientLogger logger = new ClientLogger(WorkspaceSkusClientImpl.class); /** 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 +74,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, @@ -89,7 +89,7 @@ Mono> listSkusNext( * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusSinglePageAsync() { + private Mono> listSinglePageAsync() { if (this.client.getEndpoint() == null) { return Mono .error( @@ -107,7 +107,7 @@ private Mono> listSkusSinglePageAsync() { .withContext( context -> service - .listSkus( + .list( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -135,7 +135,7 @@ private Mono> listSkusSinglePageAsync() { * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono> listSkusSinglePageAsync(Context context) { + private Mono> listSinglePageAsync(Context context) { if (this.client.getEndpoint() == null) { return Mono .error( @@ -151,7 +151,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(), @@ -176,8 +176,8 @@ private Mono> listSkusSinglePageAsync(Context c * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.COLLECTION) - private PagedFlux listSkusAsync() { - return new PagedFlux<>(() -> listSkusSinglePageAsync(), nextLink -> listSkusNextSinglePageAsync(nextLink)); + private PagedFlux listAsync() { + return new PagedFlux<>(() -> listSinglePageAsync(), nextLink -> listNextSinglePageAsync(nextLink)); } /** @@ -190,9 +190,9 @@ private PagedFlux listSkusAsync() { * @return list of skus with features. */ @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)); } /** @@ -203,8 +203,8 @@ private PagedFlux listSkusAsync(Context context) { * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listSkus() { - return new PagedIterable<>(listSkusAsync()); + public PagedIterable list() { + return new PagedIterable<>(listAsync()); } /** @@ -217,8 +217,8 @@ public PagedIterable listSkus() { * @return list of skus with features. */ @ServiceMethod(returns = ReturnType.COLLECTION) - public PagedIterable listSkus(Context context) { - return new PagedIterable<>(listSkusAsync(context)); + public PagedIterable list(Context context) { + return new PagedIterable<>(listAsync(context)); } /** @@ -231,7 +231,7 @@ public PagedIterable listSkus(Context context) { * @return list of skus with features. */ @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 +243,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<>( @@ -267,7 +267,7 @@ private Mono> listSkusNextSinglePageAsync(Strin * @return list of skus with features. */ @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 +280,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 75% 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..aecb55dcb9205 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,37 @@ 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.azure.resourcemanager.machinelearningservices.models.WorkspaceSkus; import com.fasterxml.jackson.annotation.JsonIgnore; -public final class WorkspaceOperationsImpl implements WorkspaceOperations { - @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceOperationsImpl.class); +public final class WorkspaceSkusImpl implements WorkspaceSkus { + @JsonIgnore private 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..7b7948278e011 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 @@ -35,9 +35,15 @@ 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; @@ -91,7 +97,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 +155,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 +228,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,7 +312,7 @@ 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. @@ -278,7 +360,7 @@ 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. @@ -324,7 +406,7 @@ 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. @@ -347,7 +429,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,7 +444,7 @@ 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. @@ -379,7 +461,7 @@ 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. @@ -434,7 +516,7 @@ 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. @@ -487,7 +569,7 @@ 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. @@ -495,7 +577,7 @@ private Mono>> createOrUpdateWithResponseAsync( * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,13 +585,17 @@ 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. @@ -518,7 +604,7 @@ private PollerFlux, WorkspaceInner> beginCreateOrUpda * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +619,7 @@ 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. @@ -541,7 +627,7 @@ private PollerFlux, WorkspaceInner> beginCreateOrUpda * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +636,7 @@ 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. @@ -559,7 +645,7 @@ public SyncPoller, WorkspaceInner> beginCreateOrUpdat * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return 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,7 +654,7 @@ 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. @@ -587,7 +673,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. * @param context The context to associate with this operation. @@ -607,7 +693,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 +709,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,7 +727,7 @@ 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. @@ -688,7 +774,7 @@ 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. @@ -734,25 +820,26 @@ 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. */ - @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. @@ -760,7 +847,7 @@ private PollerFlux, Void> beginDeleteAsync(String resourceGroup * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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 +860,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. */ - @ServiceMethod(returns = ReturnType.SINGLE) + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginDelete(String resourceGroupName, String workspaceName) { return beginDeleteAsync(resourceGroupName, workspaceName).getSyncPoller(); } @@ -788,7 +875,7 @@ 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. @@ -796,7 +883,7 @@ public SyncPoller, Void> beginDelete(String resourceGroupName, * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +892,7 @@ 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. @@ -820,7 +907,7 @@ 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. @@ -838,7 +925,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 +939,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,7 +954,7 @@ 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. @@ -922,7 +1009,7 @@ 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. @@ -975,7 +1062,7 @@ 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. @@ -1000,7 +1087,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,7 +1103,7 @@ 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. @@ -1034,7 +1121,7 @@ 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. @@ -1088,7 +1175,7 @@ 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. @@ -1140,7 +1227,7 @@ 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. @@ -1157,7 +1244,7 @@ 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. @@ -1174,7 +1261,7 @@ 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. @@ -1192,7 +1279,7 @@ 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. @@ -1207,7 +1294,7 @@ 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. @@ -1221,19 +1308,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. */ @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,28 +1340,32 @@ 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. @@ -1282,8 +1373,8 @@ private Mono> listKeysWithResponseAsync( * @return the response. */ @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 +1394,134 @@ 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 response. + */ + @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 response. + */ + @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 response. + */ + @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 response. + */ + @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 Name of the resource group in which 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(); - } - }); + private Mono diagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); } /** - * 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 +1529,19 @@ private Mono listKeysAsync(String resourceGroupNam * @return the response. */ @ServiceMethod(returns = ReturnType.SINGLE) - public ListWorkspaceKeysResultInner listKeys(String resourceGroupName, String workspaceName) { - return listKeysAsync(resourceGroupName, workspaceName).block(); + private Mono diagnoseAsync(String resourceGroupName, String workspaceName) { + final DiagnoseWorkspaceParameters parameters = null; + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters) + .last() + .flatMap(this.client::getLroFinalResultOrError); } /** - * 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 +1549,77 @@ 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(); + private Mono diagnoseAsync( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + return beginDiagnoseAsync(resourceGroupName, workspaceName, parameters, context) + .last() + .flatMap(this.client::getLroFinalResultOrError); } /** - * Resync all the keys associated with this workspace. This includes keys for the storage account, app insights and + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters) { + return diagnoseAsync(resourceGroupName, workspaceName, parameters).block(); + } + + /** + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public DiagnoseResponseResultInner diagnose(String resourceGroupName, String workspaceName) { + final DiagnoseWorkspaceParameters parameters = null; + return diagnoseAsync(resourceGroupName, workspaceName, parameters).block(); + } + + /** + * 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. + */ + @ServiceMethod(returns = ReturnType.SINGLE) + public DiagnoseResponseResultInner diagnose( + String resourceGroupName, String workspaceName, DiagnoseWorkspaceParameters parameters, Context context) { + return diagnoseAsync(resourceGroupName, workspaceName, parameters, context).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 Name of the resource group in which 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. */ @ServiceMethod(returns = ReturnType.SINGLE) - private Mono>> resyncKeysWithResponseAsync( + private Mono> listKeysWithResponseAsync( String resourceGroupName, String workspaceName) { if (this.client.getEndpoint() == null) { return Mono @@ -1412,7 +1645,7 @@ private Mono>> resyncKeysWithResponseAsync( .withContext( context -> service - .resyncKeys( + .listKeys( this.client.getEndpoint(), this.client.getApiVersion(), this.client.getSubscriptionId(), @@ -1424,19 +1657,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. */ @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 +1693,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 +1704,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. */ @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(); } /** - * 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) + 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 completion. + */ + @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 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. */ @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 completion. + */ + @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 completion. + */ + @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 completion. + */ + @ServiceMethod(returns = ReturnType.LONG_RUNNING_OPERATION) public SyncPoller, Void> beginResyncKeys(String resourceGroupName, String workspaceName) { return beginResyncKeysAsync(resourceGroupName, workspaceName).getSyncPoller(); } @@ -1531,7 +1919,7 @@ 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. @@ -1539,7 +1927,7 @@ public SyncPoller, Void> beginResyncKeys(String resourceGroupNa * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return the completion. */ - @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,7 +1937,7 @@ 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. @@ -1567,7 +1955,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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -1586,7 +1974,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 +1989,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. @@ -1782,7 +2170,7 @@ 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. @@ -1830,7 +2218,7 @@ 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. @@ -1876,7 +2264,7 @@ 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. @@ -1900,7 +2288,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,7 +2303,7 @@ 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. @@ -1929,6 +2317,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. + */ + @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. + */ + @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 response. + */ + @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 response. + */ + @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 response. + */ + @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 response. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. + */ + @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. * 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..6961d76588103 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,11 +10,22 @@ 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; @@ -76,6 +87,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,6 +184,102 @@ 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) { 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/AksComputeSecretsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java new file mode 100644 index 0000000000000..13307d653dd6a --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AksComputeSecretsProperties.java @@ -0,0 +1,108 @@ +// 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; + +/** Properties of AksComputeSecrets. */ +@Fluent +public class AksComputeSecretsProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(AksComputeSecretsProperties.class); + + /* + * 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/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/AmlCompute.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/AmlCompute.java index 131e844f80818..7e70fd874514f 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 @@ -11,7 +11,7 @@ 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 @@ -19,13 +19,13 @@ 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 +34,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..560f9189a7476 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 @@ -15,25 +15,25 @@ 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 +46,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 +61,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 +70,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 +79,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 +98,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..55e63bc6561a6 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 @@ -8,15 +8,11 @@ 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 { +public final class AmlComputeNodesInformation { @JsonIgnore private final ClientLogger logger = new ClientLogger(AmlComputeNodesInformation.class); /* @@ -25,6 +21,12 @@ public final class AmlComputeNodesInformation extends ComputeNodesInformation { @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 +36,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..445ea11b96065 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 @@ -67,54 +67,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 +129,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 +301,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 +314,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 +330,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 +343,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 +353,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 +362,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 +372,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 +392,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 +403,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/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/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 65% 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..0b05be553b92b 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 @@ -9,33 +9,33 @@ 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 { + @JsonIgnore private final ClientLogger logger = new ClientLogger(BaseComputeResource.class); /* - * 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/ClusterUpdateParameters.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ClusterUpdateParameters.java index 0b2907843aec9..1226ed9613252 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,51 @@ 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.azure.resourcemanager.machinelearningservices.fluent.models.ClusterUpdateProperties; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** AmlCompute update parameters. */ -@JsonFlatten @Fluent -public class ClusterUpdateParameters { +public final class ClusterUpdateParameters { @JsonIgnore private final ClientLogger logger = new ClientLogger(ClusterUpdateParameters.class); /* - * 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 +59,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..b21d7742b1769 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 @@ -24,6 +24,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), 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..da67ae2980401 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 @@ -11,7 +11,7 @@ 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 @@ -19,13 +19,13 @@ 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 +34,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/ComputeInstanceProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputeInstanceProperties.java index 9e76ddfdb8f33..08391b8aa4cc9 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 @@ -29,9 +29,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 +64,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 +76,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 +141,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 +153,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 +214,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 +232,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 +242,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..3759acbbd3fa4 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 @@ -15,10 +15,10 @@ 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 +43,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 +54,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/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..300d0400aabd0 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,7 @@ 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. */ PagedIterable listNodes(); @@ -272,7 +270,7 @@ 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. */ PagedIterable listNodes(Context context); @@ -347,7 +345,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..909666bb3eacc 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"); 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 86% 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..649259e845e29 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,24 +8,24 @@ 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. */ - 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. @@ -34,14 +34,13 @@ public interface MachineLearningComputes { * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return computes in specified workspace. */ - 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,7 +54,7 @@ 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. @@ -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,13 @@ 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. */ PagedIterable listNodes( String resourceGroupName, String workspaceName, String computeName); @@ -122,14 +121,14 @@ 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. */ PagedIterable listNodes( String resourceGroupName, String workspaceName, String computeName, Context context); @@ -137,7 +136,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,7 +149,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. * @param context The context to associate with this operation. @@ -165,7 +164,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 +176,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 +189,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 +201,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 +214,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 +226,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 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/ComputesCreateOrUpdateHeaders.java similarity index 73% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateHeaders.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputesCreateOrUpdateHeaders.java index b29ece78b30bb..3560acea36def 100644 --- 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/ComputesCreateOrUpdateHeaders.java @@ -9,11 +9,10 @@ import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** The MachineLearningServicesCreateOrUpdateHeaders model. */ +/** The ComputesCreateOrUpdateHeaders model. */ @Fluent -public final class MachineLearningServicesCreateOrUpdateHeaders { - @JsonIgnore - private final ClientLogger logger = new ClientLogger(MachineLearningServicesCreateOrUpdateHeaders.class); +public final class ComputesCreateOrUpdateHeaders { + @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputesCreateOrUpdateHeaders.class); /* * The Azure-AsyncOperation property. @@ -34,9 +33,9 @@ public String azureAsyncOperation() { * Set the azureAsyncOperation property: The Azure-AsyncOperation property. * * @param azureAsyncOperation the azureAsyncOperation value to set. - * @return the MachineLearningServicesCreateOrUpdateHeaders object itself. + * @return the ComputesCreateOrUpdateHeaders object itself. */ - public MachineLearningServicesCreateOrUpdateHeaders withAzureAsyncOperation(String azureAsyncOperation) { + public ComputesCreateOrUpdateHeaders withAzureAsyncOperation(String azureAsyncOperation) { this.azureAsyncOperation = azureAsyncOperation; return this; } 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/ComputesCreateOrUpdateResponse.java similarity index 71% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesCreateOrUpdateResponse.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputesCreateOrUpdateResponse.java index a30e727835bd4..4aec9227ff15c 100644 --- 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/ComputesCreateOrUpdateResponse.java @@ -10,23 +10,23 @@ import com.azure.resourcemanager.machinelearningservices.fluent.models.ComputeResourceInner; /** Contains all response data for the createOrUpdate operation. */ -public final class MachineLearningComputesCreateOrUpdateResponse - extends ResponseBase { +public final class ComputesCreateOrUpdateResponse + extends ResponseBase { /** - * Creates an instance of MachineLearningComputesCreateOrUpdateResponse. + * Creates an instance of ComputesCreateOrUpdateResponse. * - * @param request the request which resulted in this MachineLearningComputesCreateOrUpdateResponse. + * @param request the request which resulted in this ComputesCreateOrUpdateResponse. * @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( + public ComputesCreateOrUpdateResponse( HttpRequest request, int statusCode, HttpHeaders rawHeaders, ComputeResourceInner value, - MachineLearningComputesCreateOrUpdateHeaders headers) { + ComputesCreateOrUpdateHeaders headers) { super(request, statusCode, rawHeaders, value, headers); } 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/ComputesDeleteHeaders.java similarity index 78% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteHeaders.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputesDeleteHeaders.java index b8600ac86e2f8..7f894c82b3a1f 100644 --- 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/ComputesDeleteHeaders.java @@ -9,10 +9,10 @@ import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** The MachineLearningComputesDeleteHeaders model. */ +/** The ComputesDeleteHeaders model. */ @Fluent -public final class MachineLearningComputesDeleteHeaders { - @JsonIgnore private final ClientLogger logger = new ClientLogger(MachineLearningComputesDeleteHeaders.class); +public final class ComputesDeleteHeaders { + @JsonIgnore private final ClientLogger logger = new ClientLogger(ComputesDeleteHeaders.class); /* * The Azure-AsyncOperation property. @@ -39,9 +39,9 @@ public String azureAsyncOperation() { * Set the azureAsyncOperation property: The Azure-AsyncOperation property. * * @param azureAsyncOperation the azureAsyncOperation value to set. - * @return the MachineLearningComputesDeleteHeaders object itself. + * @return the ComputesDeleteHeaders object itself. */ - public MachineLearningComputesDeleteHeaders withAzureAsyncOperation(String azureAsyncOperation) { + public ComputesDeleteHeaders withAzureAsyncOperation(String azureAsyncOperation) { this.azureAsyncOperation = azureAsyncOperation; return this; } @@ -59,9 +59,9 @@ public String location() { * Set the location property: The Location property. * * @param location the location value to set. - * @return the MachineLearningComputesDeleteHeaders object itself. + * @return the ComputesDeleteHeaders object itself. */ - public MachineLearningComputesDeleteHeaders withLocation(String location) { + public ComputesDeleteHeaders withLocation(String location) { this.location = location; return this; } 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/ComputesDeleteResponse.java similarity index 60% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningComputesDeleteResponse.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ComputesDeleteResponse.java index b9eec18c74966..00c26b9caebca 100644 --- 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/ComputesDeleteResponse.java @@ -9,23 +9,18 @@ import com.azure.core.http.rest.ResponseBase; /** Contains all response data for the delete operation. */ -public final class MachineLearningComputesDeleteResponse - extends ResponseBase { +public final class ComputesDeleteResponse extends ResponseBase { /** - * Creates an instance of MachineLearningComputesDeleteResponse. + * Creates an instance of ComputesDeleteResponse. * - * @param request the request which resulted in this MachineLearningComputesDeleteResponse. + * @param request the request which resulted in this ComputesDeleteResponse. * @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) { + public ComputesDeleteResponse( + HttpRequest request, int statusCode, HttpHeaders rawHeaders, Void value, ComputesDeleteHeaders headers) { super(request, statusCode, rawHeaders, value, headers); } } 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/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/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..c26cd3e50e009 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,7 +4,7 @@ package com.azure.resourcemanager.machinelearningservices.models; -import com.azure.core.annotation.Immutable; +import com.azure.core.annotation.Fluent; import com.azure.core.util.logging.ClientLogger; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonTypeInfo; @@ -13,7 +13,7 @@ /** 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); 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..75600e0ba7223 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 @@ -19,13 +19,13 @@ 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 +34,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/DatabricksComputeSecretsProperties.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.java new file mode 100644 index 0000000000000..38c6c15fbac4a --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DatabricksComputeSecretsProperties.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.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 of Databricks Compute Secrets. */ +@Fluent +public class DatabricksComputeSecretsProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DatabricksComputeSecretsProperties.class); + + /* + * 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..a15ff43cdd6d9 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 @@ -9,7 +9,7 @@ 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); 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..f4322d75cff54 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseRequestProperties.java @@ -0,0 +1,269 @@ +// 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.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** The DiagnoseRequestProperties model. */ +@Fluent +public final class DiagnoseRequestProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseRequestProperties.class); + + /* + * 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..1d2929fc675c8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResponseResultValue.java @@ -0,0 +1,286 @@ +// 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 DiagnoseResponseResultValue model. */ +@Fluent +public final class DiagnoseResponseResultValue { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseResponseResultValue.class); + + /* + * 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..1c17e4bf9a251 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResult.java @@ -0,0 +1,69 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.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; + +/** Result of Diagnose. */ +@Immutable +public final class DiagnoseResult { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseResult.class); + + /* + * 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..ec44eeaad93cc --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseResultLevel.java @@ -0,0 +1,37 @@ +// Copyright (c) Microsoft Corporation. All rights reserved. +// Licensed under the MIT License. +// Code generated by Microsoft (R) AutoRest Code Generator. + +package com.azure.resourcemanager.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); + } + + /** @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..9d1356b1c868e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/DiagnoseWorkspaceParameters.java @@ -0,0 +1,53 @@ +// 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; + +/** Parameters to diagnose a workspace. */ +@Fluent +public final class DiagnoseWorkspaceParameters { + @JsonIgnore private final ClientLogger logger = new ClientLogger(DiagnoseWorkspaceParameters.class); + + /* + * 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/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..683aaa6df06df 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 @@ -15,25 +15,25 @@ 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 +42,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 +53,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 +62,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 +73,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 +82,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. 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..225ce12f78130 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 @@ -16,28 +16,29 @@ 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 +47,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 +59,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 +69,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 +81,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 +91,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. 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..a8c3bb93f45d4 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoint.java @@ -0,0 +1,80 @@ +// 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 FqdnEndpoint model. */ +@Fluent +public final class FqdnEndpoint { + @JsonIgnore private final ClientLogger logger = new ClientLogger(FqdnEndpoint.class); + + /* + * 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/ContainerRegistryResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointDetail.java similarity index 54% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ContainerRegistryResponse.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointDetail.java index 61727e355949b..8d59b13df1308 100644 --- 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/FqdnEndpointDetail.java @@ -9,34 +9,34 @@ import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; -/** The ContainerRegistryResponse model. */ +/** The FqdnEndpointDetail model. */ @Fluent -public class ContainerRegistryResponse { - @JsonIgnore private final ClientLogger logger = new ClientLogger(ContainerRegistryResponse.class); +public final class FqdnEndpointDetail { + @JsonIgnore private final ClientLogger logger = new ClientLogger(FqdnEndpointDetail.class); /* - * The address property. + * The port property. */ - @JsonProperty(value = "address") - private String address; + @JsonProperty(value = "port") + private Integer port; /** - * Get the address property: The address property. + * Get the port property: The port property. * - * @return the address value. + * @return the port value. */ - public String address() { - return this.address; + public Integer port() { + return this.port; } /** - * Set the address property: The address property. + * Set the port property: The port property. * - * @param address the address value to set. - * @return the ContainerRegistryResponse object itself. + * @param port the port value to set. + * @return the FqdnEndpointDetail object itself. */ - public ContainerRegistryResponse withAddress(String address) { - this.address = address; + public FqdnEndpointDetail withPort(Integer port) { + this.port = port; return this; } 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..a1f33b989af48 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpoints.java @@ -0,0 +1,53 @@ +// 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 FqdnEndpoints model. */ +@Fluent +public final class FqdnEndpoints { + @JsonIgnore private final ClientLogger logger = new ClientLogger(FqdnEndpoints.class); + + /* + * 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..ef4d4829b4ff8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/FqdnEndpointsProperties.java @@ -0,0 +1,80 @@ +// 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 FqdnEndpointsProperties model. */ +@Fluent +public final class FqdnEndpointsProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(FqdnEndpointsProperties.class); + + /* + * 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..61f21fdd1ff22 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 @@ -19,13 +19,13 @@ 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 +34,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..a2b9ace509710 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 @@ -9,7 +9,7 @@ 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); 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..559163c0cf4ff 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 @@ -7,6 +7,7 @@ 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; @@ -37,6 +38,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/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..38c55e287410e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchema.java @@ -0,0 +1,82 @@ +// 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.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Instance type schema. */ +@Fluent +public final class InstanceTypeSchema { + @JsonIgnore private final ClientLogger logger = new ClientLogger(InstanceTypeSchema.class); + + /* + * 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..f6f71c1536e8e --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/InstanceTypeSchemaResources.java @@ -0,0 +1,80 @@ +// 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.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Resource requests/limits for this instance type. */ +@Fluent +public final class InstanceTypeSchemaResources { + @JsonIgnore private final ClientLogger logger = new ClientLogger(InstanceTypeSchemaResources.class); + + /* + * 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/Kubernetes.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java new file mode 100644 index 0000000000000..be2ff458327fa --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/Kubernetes.java @@ -0,0 +1,87 @@ +// 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; + +/** 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 { + @JsonIgnore private final ClientLogger logger = new ClientLogger(Kubernetes.class); + + /* + * 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..7af574c251fdb --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesProperties.java @@ -0,0 +1,245 @@ +// 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.JsonInclude; +import com.fasterxml.jackson.annotation.JsonProperty; +import java.util.Map; + +/** Kubernetes properties. */ +@Fluent +public final class KubernetesProperties { + @JsonIgnore private final ClientLogger logger = new ClientLogger(KubernetesProperties.class); + + /* + * 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..a99e9c4a086d1 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/KubernetesSchema.java @@ -0,0 +1,53 @@ +// 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; + +/** Kubernetes Compute Schema. */ +@Fluent +public class KubernetesSchema { + @JsonIgnore private final ClientLogger logger = new ClientLogger(KubernetesSchema.class); + + /* + * 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/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/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/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/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/NodeStateCounts.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/NodeStateCounts.java index 257b3e76fb3ae..fd3fc9c9e2371 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 @@ -15,43 +15,46 @@ 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 +63,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 +72,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 +81,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 +90,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 +99,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/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/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/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/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..8b290135c70b8 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnectionListResult.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.models; + +import com.azure.core.annotation.Fluent; +import com.azure.core.util.logging.ClientLogger; +import com.azure.resourcemanager.machinelearningservices.fluent.models.PrivateEndpointConnectionInner; +import com.fasterxml.jackson.annotation.JsonIgnore; +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 { + @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateEndpointConnectionListResult.class); + + /* + * 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/PrivateEndpointConnections.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PrivateEndpointConnections.java index 129b4ce0590fe..1ba973c33a856 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,41 @@ 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. + */ + 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. + */ + 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,7 +51,7 @@ 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. @@ -40,7 +66,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,7 +78,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. * @param context The context to associate with this operation. 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..195810f7ddafb 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,45 @@ 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.azure.resourcemanager.machinelearningservices.fluent.models.PrivateLinkResourceProperties; 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; /** A private link resource. */ -@JsonFlatten @Fluent -public class PrivateLinkResource extends Resource { +public final class PrivateLinkResource extends ProxyResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(PrivateLinkResource.class); /* - * 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 +52,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 +147,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 +155,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 +202,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..9f3c0de1a4a59 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,19 +12,19 @@ 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. @@ -32,6 +32,6 @@ public interface PrivateLinkResources { * @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. */ - 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/PublicNetworkAccess.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.java new file mode 100644 index 0000000000000..d9cd75d055132 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/PublicNetworkAccess.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.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); + } + + /** @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..23e0b72d439cd 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 @@ -27,7 +27,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 +79,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 +88,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/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/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/ScaleSettingsInformation.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.java new file mode 100644 index 0000000000000..9926850f9ff25 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/ScaleSettingsInformation.java @@ -0,0 +1,53 @@ +// 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; + +/** Desired scale settings for the amlCompute. */ +@Fluent +public final class ScaleSettingsInformation { + @JsonIgnore private final ClientLogger logger = new ClientLogger(ScaleSettingsInformation.class); + + /* + * 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/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/SharedPrivateLinkResource.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/SharedPrivateLinkResource.java index 7744d6de11457..5baccfee0d11c 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,15 +5,14 @@ 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.azure.resourcemanager.machinelearningservices.fluent.models.SharedPrivateLinkResourceProperty; import com.fasterxml.jackson.annotation.JsonIgnore; import com.fasterxml.jackson.annotation.JsonProperty; /** The SharedPrivateLinkResource model. */ -@JsonFlatten @Fluent -public class SharedPrivateLinkResource { +public final class SharedPrivateLinkResource { @JsonIgnore private final ClientLogger logger = new ClientLogger(SharedPrivateLinkResource.class); /* @@ -23,29 +22,10 @@ public class SharedPrivateLinkResource { private String name; /* - * The resource id that private link links to. + * Resource properties. */ - @JsonProperty(value = "properties.privateLinkResourceId") - private String privateLinkResourceId; - - /* - * The private link resource group id. - */ - @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 +47,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 +72,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 +85,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 +95,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 +108,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 +118,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 +132,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 +143,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 +156,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/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/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..3ed904d9453ab 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 @@ -19,27 +19,27 @@ 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 78% 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..84925dddcc9a8 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 @@ -9,10 +9,10 @@ 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 { + @JsonIgnore private final ClientLogger logger = new ClientLogger(SynapseSparkProperties.class); /* * Auto scale properties. @@ -87,9 +87,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 +107,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 +127,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 +147,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 +167,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 +187,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 +207,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 +227,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 +247,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 +267,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/UpdateWorkspaceQuotas.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UpdateWorkspaceQuotas.java index 7ec7492795d9b..67334d69efe5d 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 @@ -27,7 +27,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 +39,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 +63,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 +72,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 +92,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 +101,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/UserAccountCredentials.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/UserAccountCredentials.java index 20cb550c0fac4..40722d4dfd1aa 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 @@ -15,26 +15,27 @@ 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 +44,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 +56,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 +65,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 +76,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 +85,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. 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/VirtualMachineSize.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/VirtualMachineSize.java index f8e25bb6f8b54..0a366a104f9ff 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 @@ -8,6 +8,7 @@ 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 @@ -15,55 +16,61 @@ 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 +81,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 +98,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 +107,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 +116,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 +125,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 +134,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 +144,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 +153,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 +163,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 +191,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/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..576b5d5090a0b 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. @@ -707,4 +782,64 @@ interface WithPrimaryUserAssignedIdentity { * @return the 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. + */ + 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. + */ + 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..aa07c458434a3 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,7 +13,7 @@ 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. @@ -25,7 +25,7 @@ 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. * @param target Target of the workspace connection. * @param category Category of the workspace connection. @@ -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,7 +54,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. * @param context The context to associate with this operation. @@ -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,7 +81,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. * @param context The context to associate with this operation. 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..b1c74a4f7d36c 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,7 +12,7 @@ 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. @@ -24,7 +24,7 @@ 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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. 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 85% 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..d549d0ff954e6 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,8 +7,8 @@ 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. * @@ -16,7 +16,7 @@ public interface WorkspaceOperations { * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return list of skus with features. */ - PagedIterable listSkus(); + PagedIterable list(); /** * Lists all skus with associated features. @@ -27,5 +27,5 @@ public interface WorkspaceOperations { * @throws RuntimeException all other wrapped checked exceptions if the request fails to be sent. * @return list of skus with features. */ - 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..c623857dad796 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,23 @@ 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.azure.resourcemanager.machinelearningservices.fluent.models.WorkspacePropertiesUpdateParameters; import com.fasterxml.jackson.annotation.JsonIgnore; +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 { +public final class WorkspaceUpdateParameters { @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspaceUpdateParameters.class); /* * 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 +37,10 @@ public class WorkspaceUpdateParameters { private Identity identity; /* - * The description of this workspace. + * The properties that the machine learning workspace will be updated with. */ - @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. - */ - @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 +102,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 +127,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 +140,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 +150,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 +163,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 +173,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 +186,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 +197,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 +211,7 @@ public WorkspaceUpdateParameters withServiceManagedResourcesSettings( * @return the primaryUserAssignedIdentity value. */ public String primaryUserAssignedIdentity() { - return this.primaryUserAssignedIdentity; + return this.innerProperties() == null ? null : this.innerProperties().primaryUserAssignedIdentity(); } /** @@ -225,7 +222,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 +264,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..5db6e7b9ed819 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,7 +25,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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -38,7 +38,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. * @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,7 +61,7 @@ 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. @@ -72,7 +72,7 @@ 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. * @param skip Continuation token for pagination. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -82,11 +82,52 @@ public interface Workspaces { */ 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,7 +140,7 @@ 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. @@ -114,7 +155,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 +167,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. @@ -159,7 +200,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. @@ -171,7 +212,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. * @param context The context to associate with this operation. * @throws IllegalArgumentException thrown if parameters fail the validation. @@ -182,6 +223,109 @@ Response listKeysWithResponse( 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. + */ + 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. + */ + 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. + */ + Response listOutboundNetworkDependenciesEndpointsWithResponse( + String resourceGroupName, String workspaceName, Context context); + /** * Gets the properties of the specified machine learning workspace. * diff --git a/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseHeaders.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseHeaders.java new file mode 100644 index 0000000000000..e08fab1c510c6 --- /dev/null +++ b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseHeaders.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.azure.core.util.logging.ClientLogger; +import com.fasterxml.jackson.annotation.JsonIgnore; +import com.fasterxml.jackson.annotation.JsonProperty; + +/** The WorkspacesDiagnoseHeaders model. */ +@Fluent +public final class WorkspacesDiagnoseHeaders { + @JsonIgnore private final ClientLogger logger = new ClientLogger(WorkspacesDiagnoseHeaders.class); + + /* + * The Retry-After property. + */ + @JsonProperty(value = "Retry-After") + private Integer retryAfter; + + /* + * The Location property. + */ + @JsonProperty(value = "Location") + private String location; + + /** + * Get the retryAfter property: The Retry-After property. + * + * @return the retryAfter value. + */ + public Integer retryAfter() { + return this.retryAfter; + } + + /** + * Set the retryAfter property: The Retry-After property. + * + * @param retryAfter the retryAfter value to set. + * @return the WorkspacesDiagnoseHeaders object itself. + */ + public WorkspacesDiagnoseHeaders withRetryAfter(Integer retryAfter) { + this.retryAfter = retryAfter; + return this; + } + + /** + * Get the location property: The Location property. + * + * @return the location value. + */ + public String location() { + return this.location; + } + + /** + * Set the location property: The Location property. + * + * @param location the location value to set. + * @return the WorkspacesDiagnoseHeaders object itself. + */ + public WorkspacesDiagnoseHeaders 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/MachineLearningServicesCreateOrUpdateResponse.java b/sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseResponse.java similarity index 59% rename from sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/MachineLearningServicesCreateOrUpdateResponse.java rename to sdk/machinelearningservices/azure-resourcemanager-machinelearningservices/src/main/java/com/azure/resourcemanager/machinelearningservices/models/WorkspacesDiagnoseResponse.java index bb074ed812a7d..125ac85da596f 100644 --- 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/WorkspacesDiagnoseResponse.java @@ -7,32 +7,32 @@ 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; +import com.azure.resourcemanager.machinelearningservices.fluent.models.DiagnoseResponseResultInner; -/** Contains all response data for the createOrUpdate operation. */ -public final class MachineLearningServicesCreateOrUpdateResponse - extends ResponseBase { +/** Contains all response data for the diagnose operation. */ +public final class WorkspacesDiagnoseResponse + extends ResponseBase { /** - * Creates an instance of MachineLearningServicesCreateOrUpdateResponse. + * Creates an instance of WorkspacesDiagnoseResponse. * - * @param request the request which resulted in this MachineLearningServicesCreateOrUpdateResponse. + * @param request the request which resulted in this WorkspacesDiagnoseResponse. * @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( + public WorkspacesDiagnoseResponse( HttpRequest request, int statusCode, HttpHeaders rawHeaders, - ServiceResourceInner value, - MachineLearningServicesCreateOrUpdateHeaders headers) { + DiagnoseResponseResultInner value, + WorkspacesDiagnoseHeaders headers) { super(request, statusCode, rawHeaders, value, headers); } /** @return the deserialized response body. */ @Override - public ServiceResourceInner getValue() { + public DiagnoseResponseResultInner getValue() { return super.getValue(); } } 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(); + } +}