diff --git a/unreleased/azure-mgmt-machinelearning/HISTORY.rst b/unreleased/azure-mgmt-machinelearning/HISTORY.rst deleted file mode 100644 index 9622126fde19..000000000000 --- a/unreleased/azure-mgmt-machinelearning/HISTORY.rst +++ /dev/null @@ -1,9 +0,0 @@ -.. :changelog: - -Release History -=============== - -0.1.0 (2016-09-12) -++++++++++++++++++ - -* Initial preview release diff --git a/unreleased/azure-mgmt-machinelearning/MANIFEST.in b/unreleased/azure-mgmt-machinelearning/MANIFEST.in deleted file mode 100644 index b7fafdffbc07..000000000000 --- a/unreleased/azure-mgmt-machinelearning/MANIFEST.in +++ /dev/null @@ -1,3 +0,0 @@ -include *.rst -exclude azure/__init__.py -exclude azure/mgmt/__init__.py diff --git a/unreleased/azure-mgmt-machinelearning/README.rst b/unreleased/azure-mgmt-machinelearning/README.rst deleted file mode 100644 index 2a23565025d0..000000000000 --- a/unreleased/azure-mgmt-machinelearning/README.rst +++ /dev/null @@ -1,49 +0,0 @@ -Microsoft Azure SDK for Python -============================== - -This is the Microsoft Azure Machine Learning Management Client Library. - -Azure Resource Manager (ARM) is the next generation of management APIs that -replace the old Azure Service Management (ASM). - -This package has been tested with Python 2.7, 3.3, 3.4 and 3.5. - -For the older Azure Service Management (ASM) libraries, see -`azure-servicemanagement-legacy `__ library. - -For a more complete set of Azure libraries, see the `azure `__ bundle package. - - -Compatibility -============= - -**IMPORTANT**: If you have an earlier version of the azure package -(version < 1.0), you should uninstall it before installing this package. - -You can check the version using pip: - -.. code:: shell - - pip freeze - -If you see azure==0.11.0 (or any version below 1.0), uninstall it first: - -.. code:: shell - - pip uninstall azure - - -Usage -===== - -For code examples, see `Machine Learning Management -`__ -on readthedocs.org. - - -Provide Feedback -================ - -If you encounter any bugs or have suggestions, please file an issue in the -`Issues `__ -section of the project. diff --git a/unreleased/azure-mgmt-machinelearning/azure/__init__.py b/unreleased/azure-mgmt-machinelearning/azure/__init__.py deleted file mode 100644 index 849489fca33c..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/__init__.py +++ /dev/null @@ -1 +0,0 @@ -__import__('pkg_resources').declare_namespace(__name__) diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/__init__.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/__init__.py deleted file mode 100644 index 849489fca33c..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/__init__.py +++ /dev/null @@ -1 +0,0 @@ -__import__('pkg_resources').declare_namespace(__name__) diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/__init__.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/__init__.py deleted file mode 100644 index d03284502330..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/__init__.py +++ /dev/null @@ -1,18 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from .azure_ml_web_services_management_client import AzureMLWebServicesManagementClient -from .version import VERSION - -__all__ = ['AzureMLWebServicesManagementClient'] - -__version__ = VERSION - diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/azure_ml_web_services_management_client.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/azure_ml_web_services_management_client.py deleted file mode 100644 index 9c9adef7c498..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/azure_ml_web_services_management_client.py +++ /dev/null @@ -1,118 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.service_client import ServiceClient -from msrest import Serializer, Deserializer -from msrestazure import AzureConfiguration -from .version import VERSION -from .operations.web_services_operations import WebServicesOperations -from . import models - - -class AzureMLWebServicesManagementClientConfiguration(AzureConfiguration): - """Configuration for AzureMLWebServicesManagementClient - Note that all parameters used to create this instance are saved as instance - attributes. - - :param credentials: Credentials needed for the client to connect to Azure. - :type credentials: :mod:`A msrestazure Credentials - object` - :param subscription_id: The Azure subscription ID. - :type subscription_id: str - :param api_version: The version of the Microsoft.MachineLearning resource - provider API to use. - :type api_version: str - :param accept_language: Gets or sets the preferred language for the - response. - :type accept_language: str - :param long_running_operation_retry_timeout: Gets or sets the retry - timeout in seconds for Long Running Operations. Default value is 30. - :type long_running_operation_retry_timeout: int - :param generate_client_request_id: When set to true a unique - x-ms-client-request-id value is generated and included in each request. - Default is true. - :type generate_client_request_id: bool - :param str base_url: Service URL - :param str filepath: Existing config - """ - - def __init__( - self, credentials, subscription_id, api_version='2016-05-01-preview', accept_language='en-US', long_running_operation_retry_timeout=30, generate_client_request_id=True, base_url=None, filepath=None): - - if credentials is None: - raise ValueError("Parameter 'credentials' must not be None.") - if subscription_id is None: - raise ValueError("Parameter 'subscription_id' must not be None.") - if not isinstance(subscription_id, str): - raise TypeError("Parameter 'subscription_id' must be str.") - if api_version is not None and not isinstance(api_version, str): - raise TypeError("Optional parameter 'api_version' must be str.") - if accept_language is not None and not isinstance(accept_language, str): - raise TypeError("Optional parameter 'accept_language' must be str.") - if not base_url: - base_url = 'https://management.azure.com' - - super(AzureMLWebServicesManagementClientConfiguration, self).__init__(base_url, filepath) - - self.add_user_agent('azuremlwebservicesmanagementclient/{}'.format(VERSION)) - self.add_user_agent('Azure-SDK-For-Python') - - self.credentials = credentials - self.subscription_id = subscription_id - self.api_version = api_version - self.accept_language = accept_language - self.long_running_operation_retry_timeout = long_running_operation_retry_timeout - self.generate_client_request_id = generate_client_request_id - - -class AzureMLWebServicesManagementClient(object): - """These APIs allow end users to operate on Azure Machine Learning Web Services resources. They support the following operations:<ul><li>Create or update a web service</li><li>Get a web service</li><li>Patch a web service</li><li>Delete a web service</li><li>Get All Web Services in a Resource Group </li><li>Get All Web Services in a Subscription</li><li>Get Web Services Keys</li></ul> - - :ivar config: Configuration for client. - :vartype config: AzureMLWebServicesManagementClientConfiguration - - :ivar web_services: WebServices operations - :vartype web_services: .operations.WebServicesOperations - - :param credentials: Credentials needed for the client to connect to Azure. - :type credentials: :mod:`A msrestazure Credentials - object` - :param subscription_id: The Azure subscription ID. - :type subscription_id: str - :param api_version: The version of the Microsoft.MachineLearning resource - provider API to use. - :type api_version: str - :param accept_language: Gets or sets the preferred language for the - response. - :type accept_language: str - :param long_running_operation_retry_timeout: Gets or sets the retry - timeout in seconds for Long Running Operations. Default value is 30. - :type long_running_operation_retry_timeout: int - :param generate_client_request_id: When set to true a unique - x-ms-client-request-id value is generated and included in each request. - Default is true. - :type generate_client_request_id: bool - :param str base_url: Service URL - :param str filepath: Existing config - """ - - def __init__( - self, credentials, subscription_id, api_version='2016-05-01-preview', accept_language='en-US', long_running_operation_retry_timeout=30, generate_client_request_id=True, base_url=None, filepath=None): - - self.config = AzureMLWebServicesManagementClientConfiguration(credentials, subscription_id, api_version, accept_language, long_running_operation_retry_timeout, generate_client_request_id, base_url, filepath) - self._client = ServiceClient(self.config.credentials, self.config) - - client_models = {k: v for k, v in models.__dict__.items() if isinstance(v, type)} - self._serialize = Serializer(client_models) - self._deserialize = Deserializer(client_models) - - self.web_services = WebServicesOperations( - self._client, self.config, self._serialize, self._deserialize) diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/__init__.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/__init__.py deleted file mode 100644 index 2b1bac4c9688..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/__init__.py +++ /dev/null @@ -1,84 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from .resource import Resource -from .web_service_keys import WebServiceKeys -from .realtime_configuration import RealtimeConfiguration -from .diagnostics_configuration import DiagnosticsConfiguration -from .storage_account import StorageAccount -from .machine_learning_workspace import MachineLearningWorkspace -from .commitment_plan import CommitmentPlan -from .column_specification import ColumnSpecification -from .table_specification import TableSpecification -from .service_input_output_specification import ServiceInputOutputSpecification -from .example_request import ExampleRequest -from .asset_location import AssetLocation -from .input_port import InputPort -from .output_port import OutputPort -from .mode_value_info import ModeValueInfo -from .module_asset_parameter import ModuleAssetParameter -from .asset_item import AssetItem -from .web_service_properties import WebServiceProperties -from .web_service import WebService -from .graph_node import GraphNode -from .graph_edge import GraphEdge -from .graph_parameter_link import GraphParameterLink -from .graph_parameter import GraphParameter -from .graph_package import GraphPackage -from .web_service_properties_for_graph import WebServicePropertiesForGraph -from .web_service_paged import WebServicePaged -from .azure_ml_web_services_management_client_enums import ( - ProvisioningState, - DiagnosticsLevel, - ColumnType, - ColumnFormat, - AssetType, - InputPortType, - OutputPortType, - ParameterType, -) - -__all__ = [ - 'Resource', - 'WebServiceKeys', - 'RealtimeConfiguration', - 'DiagnosticsConfiguration', - 'StorageAccount', - 'MachineLearningWorkspace', - 'CommitmentPlan', - 'ColumnSpecification', - 'TableSpecification', - 'ServiceInputOutputSpecification', - 'ExampleRequest', - 'AssetLocation', - 'InputPort', - 'OutputPort', - 'ModeValueInfo', - 'ModuleAssetParameter', - 'AssetItem', - 'WebServiceProperties', - 'WebService', - 'GraphNode', - 'GraphEdge', - 'GraphParameterLink', - 'GraphParameter', - 'GraphPackage', - 'WebServicePropertiesForGraph', - 'WebServicePaged', - 'ProvisioningState', - 'DiagnosticsLevel', - 'ColumnType', - 'ColumnFormat', - 'AssetType', - 'InputPortType', - 'OutputPortType', - 'ParameterType', -] diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_item.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_item.py deleted file mode 100644 index 1677f483ca47..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_item.py +++ /dev/null @@ -1,66 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class AssetItem(Model): - """Information about an asset associated with the web service. - - :param name: Asset's friendly name. - :type name: str - :param id: Asset's Id. - :type id: str - :param type: Asset's type. Possible values include: 'Module', 'Resource' - :type type: str or :class:`AssetType - ` - :param location_info: Access information for the asset. - :type location_info: :class:`AssetLocation - ` - :param input_ports: Information about the asset's input ports. - :type input_ports: dict - :param output_ports: Information about the asset's output ports. - :type output_ports: dict - :param metadata: If the asset is a custom module, this holds the module's - metadata. - :type metadata: dict - :param parameters: If the asset is a custom module, this holds the - module's parameters. - :type parameters: list of :class:`ModuleAssetParameter - ` - """ - - _validation = { - 'name': {'required': True}, - 'type': {'required': True}, - 'location_info': {'required': True}, - } - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'id': {'key': 'id', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'location_info': {'key': 'locationInfo', 'type': 'AssetLocation'}, - 'input_ports': {'key': 'inputPorts', 'type': '{InputPort}'}, - 'output_ports': {'key': 'outputPorts', 'type': '{OutputPort}'}, - 'metadata': {'key': 'metadata', 'type': '{str}'}, - 'parameters': {'key': 'parameters', 'type': '[ModuleAssetParameter]'}, - } - - def __init__(self, name, type, location_info, id=None, input_ports=None, output_ports=None, metadata=None, parameters=None): - self.name = name - self.id = id - self.type = type - self.location_info = location_info - self.input_ports = input_ports - self.output_ports = output_ports - self.metadata = metadata - self.parameters = parameters diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_location.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_location.py deleted file mode 100644 index 2ceaf93ff09e..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/asset_location.py +++ /dev/null @@ -1,37 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class AssetLocation(Model): - """Describes the access location for a web service asset. - - :param uri: The URI where the asset is accessible from, (e.g. aml://abc - for system assets or https://xyz for user asets - :type uri: str - :param credentials: Access credentials for the asset, if applicable (e.g. - asset specified by storage account connection string + blob URI) - :type credentials: str - """ - - _validation = { - 'uri': {'required': True}, - } - - _attribute_map = { - 'uri': {'key': 'uri', 'type': 'str'}, - 'credentials': {'key': 'credentials', 'type': 'str'}, - } - - def __init__(self, uri, credentials=None): - self.uri = uri - self.credentials = credentials diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/azure_ml_web_services_management_client_enums.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/azure_ml_web_services_management_client_enums.py deleted file mode 100644 index 15dc4d1ec28c..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/azure_ml_web_services_management_client_enums.py +++ /dev/null @@ -1,88 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from enum import Enum - - -class ProvisioningState(Enum): - - unknown = "Unknown" - provisioning = "Provisioning" - succeeded = "Succeeded" - failed = "Failed" - - -class DiagnosticsLevel(Enum): - - none = "None" - error = "Error" - all = "All" - - -class ColumnType(Enum): - - boolean = "Boolean" - integer = "Integer" - number = "Number" - string = "String" - - -class ColumnFormat(Enum): - - byte = "Byte" - char = "Char" - complex64 = "Complex64" - complex128 = "Complex128" - date_time = "Date-time" - date_time_offset = "Date-timeOffset" - double = "Double" - duration = "Duration" - float_enum = "Float" - int8 = "Int8" - int16 = "Int16" - int32 = "Int32" - int64 = "Int64" - uint8 = "Uint8" - uint16 = "Uint16" - uint32 = "Uint32" - uint64 = "Uint64" - - -class AssetType(Enum): - - module = "Module" - resource = "Resource" - - -class InputPortType(Enum): - - dataset = "Dataset" - - -class OutputPortType(Enum): - - dataset = "Dataset" - - -class ParameterType(Enum): - - string = "String" - int_enum = "Int" - float_enum = "Float" - enumerated = "Enumerated" - script = "Script" - mode = "Mode" - credential = "Credential" - boolean = "Boolean" - double = "Double" - column_picker = "ColumnPicker" - parameter_range = "ParameterRange" - data_gateway_name = "DataGatewayName" diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/column_specification.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/column_specification.py deleted file mode 100644 index 6c3d372cb226..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/column_specification.py +++ /dev/null @@ -1,58 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class ColumnSpecification(Model): - """Swagger 2.0 schema for a column within the data table representing a web - service input or output. See Swagger specification: - http://swagger.io/specification/. - - :param type: Data type of the column. Possible values include: 'Boolean', - 'Integer', 'Number', 'String' - :type type: str or :class:`ColumnType - ` - :param format: Additional format information for the data type. Possible - values include: 'Byte', 'Char', 'Complex64', 'Complex128', 'Date-time', - 'Date-timeOffset', 'Double', 'Duration', 'Float', 'Int8', 'Int16', - 'Int32', 'Int64', 'Uint8', 'Uint16', 'Uint32', 'Uint64' - :type format: str or :class:`ColumnFormat - ` - :param enum: If the data type is categorical, this provides the list of - accepted categories. - :type enum: list of object - :param x_ms_isnullable: Flag indicating if the type supports null values - or not. - :type x_ms_isnullable: bool - :param x_ms_isordered: Flag indicating whether the categories are treated - as an ordered set or not, if this is a categorical column. - :type x_ms_isordered: bool - """ - - _validation = { - 'type': {'required': True}, - } - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - 'format': {'key': 'format', 'type': 'str'}, - 'enum': {'key': 'enum', 'type': '[object]'}, - 'x_ms_isnullable': {'key': 'x-ms-isnullable', 'type': 'bool'}, - 'x_ms_isordered': {'key': 'x-ms-isordered', 'type': 'bool'}, - } - - def __init__(self, type, format=None, enum=None, x_ms_isnullable=None, x_ms_isordered=None): - self.type = type - self.format = format - self.enum = enum - self.x_ms_isnullable = x_ms_isnullable - self.x_ms_isordered = x_ms_isordered diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/commitment_plan.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/commitment_plan.py deleted file mode 100644 index 7f5777d5a879..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/commitment_plan.py +++ /dev/null @@ -1,33 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class CommitmentPlan(Model): - """Information about the machine learning commitment plan associated with the - web service. - - :param id: Specifies the Azure Resource Manager ID of the commitment plan - associated with the web service. - :type id: str - """ - - _validation = { - 'id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - } - - def __init__(self, id): - self.id = id diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/diagnostics_configuration.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/diagnostics_configuration.py deleted file mode 100644 index e504e69b1125..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/diagnostics_configuration.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class DiagnosticsConfiguration(Model): - """Diagnostics settings for an Azure ML web service. - - :param level: Specifies the verbosity of the diagnostic output. Valid - values are: None - disables tracing; Error - collects only error (stderr) - traces; All - collects all traces (stdout and stderr). Possible values - include: 'None', 'Error', 'All' - :type level: str or :class:`DiagnosticsLevel - ` - :param expiry: Specifies the date and time when the logging will cease. If - null, diagnostic collection is not time limited. - :type expiry: datetime - """ - - _validation = { - 'level': {'required': True}, - } - - _attribute_map = { - 'level': {'key': 'level', 'type': 'str'}, - 'expiry': {'key': 'expiry', 'type': 'iso-8601'}, - } - - def __init__(self, level, expiry=None): - self.level = level - self.expiry = expiry diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/example_request.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/example_request.py deleted file mode 100644 index a7f4544f4bbd..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/example_request.py +++ /dev/null @@ -1,33 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class ExampleRequest(Model): - """Sample input data for the service's input(s). - - :param inputs: Sample input data for the web service's input(s) given as - an input name to sample input values matrix map. - :type inputs: dict - :param global_parameters: Sample input data for the web service's global - parameters - :type global_parameters: dict - """ - - _attribute_map = { - 'inputs': {'key': 'inputs', 'type': '{list}'}, - 'global_parameters': {'key': 'globalParameters', 'type': '{object}'}, - } - - def __init__(self, inputs=None, global_parameters=None): - self.inputs = inputs - self.global_parameters = global_parameters diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_edge.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_edge.py deleted file mode 100644 index 96dbd4389197..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_edge.py +++ /dev/null @@ -1,41 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class GraphEdge(Model): - """Defines an edge within the web service's graph. - - :param source_node_id: The source graph node's identifier. - :type source_node_id: str - :param source_port_id: The identifier of the source node's port that the - edge connects from. - :type source_port_id: str - :param target_node_id: The destination graph node's identifier. - :type target_node_id: str - :param target_port_id: The identifier of the destination node's port that - the edge connects into. - :type target_port_id: str - """ - - _attribute_map = { - 'source_node_id': {'key': 'sourceNodeId', 'type': 'str'}, - 'source_port_id': {'key': 'sourcePortId', 'type': 'str'}, - 'target_node_id': {'key': 'targetNodeId', 'type': 'str'}, - 'target_port_id': {'key': 'targetPortId', 'type': 'str'}, - } - - def __init__(self, source_node_id=None, source_port_id=None, target_node_id=None, target_port_id=None): - self.source_node_id = source_node_id - self.source_port_id = source_port_id - self.target_node_id = target_node_id - self.target_port_id = target_port_id diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_node.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_node.py deleted file mode 100644 index bd14a8f4d660..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_node.py +++ /dev/null @@ -1,42 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class GraphNode(Model): - """Specifies a node in the web service graph. The node can either be an input, - output or asset node, so only one of the corresponding id properties is - populated at any given time. - - :param asset_id: The id of the asset represented by this node. - :type asset_id: str - :param input_id: The id of the input element represented by this node. - :type input_id: str - :param output_id: The id of the output element represented by this node. - :type output_id: str - :param parameters: If applicable, parameters of the node. Global graph - parameters map into these, with values set at runtime. - :type parameters: dict - """ - - _attribute_map = { - 'asset_id': {'key': 'assetId', 'type': 'str'}, - 'input_id': {'key': 'inputId', 'type': 'str'}, - 'output_id': {'key': 'outputId', 'type': 'str'}, - 'parameters': {'key': 'parameters', 'type': '{str}'}, - } - - def __init__(self, asset_id=None, input_id=None, output_id=None, parameters=None): - self.asset_id = asset_id - self.input_id = input_id - self.output_id = output_id - self.parameters = parameters diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_package.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_package.py deleted file mode 100644 index bbd8d3815d67..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_package.py +++ /dev/null @@ -1,40 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class GraphPackage(Model): - """Defines the graph of modules making up the machine learning solution. - - :param nodes: The set of nodes making up the graph, provided as a nodeId - to GraphNode map - :type nodes: dict - :param edges: The list of edges making up the graph. - :type edges: list of :class:`GraphEdge - ` - :param graph_parameters: The collection of global parameters for the - graph, given as a global parameter name to GraphParameter map. Each - parameter here has a 1:1 match with the global parameters values map - declared at the WebServiceProperties level. - :type graph_parameters: dict - """ - - _attribute_map = { - 'nodes': {'key': 'nodes', 'type': '{GraphNode}'}, - 'edges': {'key': 'edges', 'type': '[GraphEdge]'}, - 'graph_parameters': {'key': 'graphParameters', 'type': '{GraphParameter}'}, - } - - def __init__(self, nodes=None, edges=None, graph_parameters=None): - self.nodes = nodes - self.edges = edges - self.graph_parameters = graph_parameters diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter.py deleted file mode 100644 index c266a27daea4..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter.py +++ /dev/null @@ -1,44 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class GraphParameter(Model): - """Defines a global parameter in the graph. - - :param description: Description of this graph parameter. - :type description: str - :param type: Graph parameter's type. Possible values include: 'String', - 'Int', 'Float', 'Enumerated', 'Script', 'Mode', 'Credential', 'Boolean', - 'Double', 'ColumnPicker', 'ParameterRange', 'DataGatewayName' - :type type: str or :class:`ParameterType - ` - :param links: Association links for this parameter to nodes in the graph. - :type links: list of :class:`GraphParameterLink - ` - """ - - _validation = { - 'type': {'required': True}, - 'links': {'required': True}, - } - - _attribute_map = { - 'description': {'key': 'description', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'links': {'key': 'links', 'type': '[GraphParameterLink]'}, - } - - def __init__(self, type, links, description=None): - self.description = description - self.type = type - self.links = links diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter_link.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter_link.py deleted file mode 100644 index 6722cd3be988..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/graph_parameter_link.py +++ /dev/null @@ -1,37 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class GraphParameterLink(Model): - """Association link for a graph global parameter to a node in the graph. - - :param node_id: The graph node's identifier - :type node_id: str - :param parameter_key: The identifier of the node parameter that the global - parameter maps to. - :type parameter_key: str - """ - - _validation = { - 'node_id': {'required': True}, - 'parameter_key': {'required': True}, - } - - _attribute_map = { - 'node_id': {'key': 'nodeId', 'type': 'str'}, - 'parameter_key': {'key': 'parameterKey', 'type': 'str'}, - } - - def __init__(self, node_id, parameter_key): - self.node_id = node_id - self.parameter_key = parameter_key diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/input_port.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/input_port.py deleted file mode 100644 index ec3373af31e3..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/input_port.py +++ /dev/null @@ -1,29 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class InputPort(Model): - """Asset input port. - - :param type: Port data type. Possible values include: 'Dataset'. Default - value: "Dataset" . - :type type: str or :class:`InputPortType - ` - """ - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__(self, type="Dataset"): - self.type = type diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/machine_learning_workspace.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/machine_learning_workspace.py deleted file mode 100644 index 8e47b24e02a6..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/machine_learning_workspace.py +++ /dev/null @@ -1,33 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class MachineLearningWorkspace(Model): - """Information about the machine learning workspace containing the experiment - that is source for the web service. - - :param id: Specifies the workspace ID of the machine learning workspace - associated with the web service - :type id: str - """ - - _validation = { - 'id': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - } - - def __init__(self, id): - self.id = id diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/mode_value_info.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/mode_value_info.py deleted file mode 100644 index a942c03cbecd..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/mode_value_info.py +++ /dev/null @@ -1,33 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class ModeValueInfo(Model): - """Nested parameter definition. - - :param interface_string: The interface string name for the nested - parameter. - :type interface_string: str - :param parameters: The definition of the parameter. - :type parameters: list of :class:`ModuleAssetParameter - ` - """ - - _attribute_map = { - 'interface_string': {'key': 'interfaceString', 'type': 'str'}, - 'parameters': {'key': 'parameters', 'type': '[ModuleAssetParameter]'}, - } - - def __init__(self, interface_string=None, parameters=None): - self.interface_string = interface_string - self.parameters = parameters diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/module_asset_parameter.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/module_asset_parameter.py deleted file mode 100644 index bb96bbbca16a..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/module_asset_parameter.py +++ /dev/null @@ -1,36 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class ModuleAssetParameter(Model): - """Parameter definition for a module asset. - - :param name: Parameter name. - :type name: str - :param parameter_type: Parameter type. - :type parameter_type: str - :param mode_values_info: Definitions for nested interface parameters if - this is a complex module parameter. - :type mode_values_info: dict - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'parameter_type': {'key': 'parameterType', 'type': 'str'}, - 'mode_values_info': {'key': 'modeValuesInfo', 'type': '{ModeValueInfo}'}, - } - - def __init__(self, name=None, parameter_type=None, mode_values_info=None): - self.name = name - self.parameter_type = parameter_type - self.mode_values_info = mode_values_info diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/output_port.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/output_port.py deleted file mode 100644 index a00eee30f5c9..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/output_port.py +++ /dev/null @@ -1,29 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class OutputPort(Model): - """Asset output port. - - :param type: Port data type. Possible values include: 'Dataset'. Default - value: "Dataset" . - :type type: str or :class:`OutputPortType - ` - """ - - _attribute_map = { - 'type': {'key': 'type', 'type': 'str'}, - } - - def __init__(self, type="Dataset"): - self.type = type diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/realtime_configuration.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/realtime_configuration.py deleted file mode 100644 index c6dc574f4684..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/realtime_configuration.py +++ /dev/null @@ -1,33 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class RealtimeConfiguration(Model): - """Holds the available configuration options for an Azure ML web service - endpoint. - - :param max_concurrent_calls: Specifies the maximum concurrent calls that - can be made to the web service. Minimum value: 4, Maximum value: 200. - :type max_concurrent_calls: int - """ - - _validation = { - 'max_concurrent_calls': {'maximum': 200, 'minimum': 4}, - } - - _attribute_map = { - 'max_concurrent_calls': {'key': 'maxConcurrentCalls', 'type': 'int'}, - } - - def __init__(self, max_concurrent_calls=None): - self.max_concurrent_calls = max_concurrent_calls diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/resource.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/resource.py deleted file mode 100644 index 8528b117ca6f..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/resource.py +++ /dev/null @@ -1,52 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class Resource(Model): - """Resource. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Specifies the resource ID. - :vartype id: str - :param name: Specifies the name of the resource. - :type name: str - :param location: Specifies the location of the resource. - :type location: str - :ivar type: Specifies the type of the resource. - :vartype type: str - :param tags: Contains resource tags defined as key/value pairs. - :type tags: dict - """ - - _validation = { - 'id': {'readonly': True}, - 'location': {'required': True}, - 'type': {'readonly': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'location': {'key': 'location', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - } - - def __init__(self, location, name=None, tags=None): - self.id = None - self.name = name - self.location = location - self.type = None - self.tags = tags diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/service_input_output_specification.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/service_input_output_specification.py deleted file mode 100644 index db26720a8ae6..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/service_input_output_specification.py +++ /dev/null @@ -1,48 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class ServiceInputOutputSpecification(Model): - """The swagger 2.0 schema describing the service's inputs or outputs. See - Swagger specification: http://swagger.io/specification/. - - :param title: The title of your Swagger schema. - :type title: str - :param description: The description of the Swagger schema. - :type description: str - :param type: The type of the entity described in swagger. Always 'object'. - Default value: "object" . - :type type: str - :param properties: Specifies a collection that contains the column schema - for each input or output of the web service. For more information, see the - Swagger specification. - :type properties: dict - """ - - _validation = { - 'type': {'required': True}, - 'properties': {'required': True}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': '{TableSpecification}'}, - } - - def __init__(self, properties, title=None, description=None, type="object"): - self.title = title - self.description = description - self.type = type - self.properties = properties diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/storage_account.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/storage_account.py deleted file mode 100644 index 75bc64fbf634..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/storage_account.py +++ /dev/null @@ -1,31 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class StorageAccount(Model): - """Access information for a storage account. - - :param name: Specifies the name of the storage account. - :type name: str - :param key: Specifies the key used to access the storage account. - :type key: str - """ - - _attribute_map = { - 'name': {'key': 'name', 'type': 'str'}, - 'key': {'key': 'key', 'type': 'str'}, - } - - def __init__(self, name=None, key=None): - self.name = name - self.key = key diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/table_specification.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/table_specification.py deleted file mode 100644 index fa1e80e472d2..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/table_specification.py +++ /dev/null @@ -1,49 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class TableSpecification(Model): - """The swagger 2.0 schema describing a single service input or output. See - Swagger specification: http://swagger.io/specification/. - - :param title: Swagger schema title. - :type title: str - :param description: Swagger schema description. - :type description: str - :param type: The type of the entity described in swagger. Default value: - "object" . - :type type: str - :param format: The format, if 'type' is not 'object' - :type format: str - :param properties: The set of columns within the data table. - :type properties: dict - """ - - _validation = { - 'type': {'required': True}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'format': {'key': 'format', 'type': 'str'}, - 'properties': {'key': 'properties', 'type': '{ColumnSpecification}'}, - } - - def __init__(self, title=None, description=None, type="object", format=None, properties=None): - self.title = title - self.description = description - self.type = type - self.format = format - self.properties = properties diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service.py deleted file mode 100644 index 622ef235476a..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service.py +++ /dev/null @@ -1,55 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from .resource import Resource - - -class WebService(Resource): - """Instance of an Azure ML web service resource. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :ivar id: Specifies the resource ID. - :vartype id: str - :param name: Specifies the name of the resource. - :type name: str - :param location: Specifies the location of the resource. - :type location: str - :ivar type: Specifies the type of the resource. - :vartype type: str - :param tags: Contains resource tags defined as key/value pairs. - :type tags: dict - :param properties: Contains the property payload that describes the web - service. - :type properties: :class:`WebServiceProperties - ` - """ - - _validation = { - 'id': {'readonly': True}, - 'location': {'required': True}, - 'type': {'readonly': True}, - 'properties': {'required': True}, - } - - _attribute_map = { - 'id': {'key': 'id', 'type': 'str'}, - 'name': {'key': 'name', 'type': 'str'}, - 'location': {'key': 'location', 'type': 'str'}, - 'type': {'key': 'type', 'type': 'str'}, - 'tags': {'key': 'tags', 'type': '{str}'}, - 'properties': {'key': 'properties', 'type': 'WebServiceProperties'}, - } - - def __init__(self, location, properties, name=None, tags=None): - super(WebService, self).__init__(name=name, location=location, tags=tags) - self.properties = properties diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_keys.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_keys.py deleted file mode 100644 index 664abd3df1d2..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_keys.py +++ /dev/null @@ -1,31 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class WebServiceKeys(Model): - """Access keys for the web service calls. - - :param primary: The primary access key. - :type primary: str - :param secondary: The secondary access key. - :type secondary: str - """ - - _attribute_map = { - 'primary': {'key': 'primary', 'type': 'str'}, - 'secondary': {'key': 'secondary', 'type': 'str'}, - } - - def __init__(self, primary=None, secondary=None): - self.primary = primary - self.secondary = secondary diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_paged.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_paged.py deleted file mode 100644 index ce4cf6d6e08b..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_paged.py +++ /dev/null @@ -1,27 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.paging import Paged - - -class WebServicePaged(Paged): - """ - A paging container for iterating over a list of WebService object - """ - - _attribute_map = { - 'next_link': {'key': 'nextLink', 'type': 'str'}, - 'current_page': {'key': 'value', 'type': '[WebService]'} - } - - def __init__(self, *args, **kwargs): - - super(WebServicePaged, self).__init__(*args, **kwargs) diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties.py deleted file mode 100644 index 347b2883f26b..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties.py +++ /dev/null @@ -1,157 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.serialization import Model - - -class WebServiceProperties(Model): - """The set of properties specific to the Azure ML web service resource. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param title: The title of the web service. - :type title: str - :param description: The description of the web service. - :type description: str - :ivar created_on: Read Only: The date and time when the web service was - created. - :vartype created_on: datetime - :ivar modified_on: Read Only: The date and time when the web service was - last modified. - :vartype modified_on: datetime - :ivar provisioning_state: Read Only: The provision state of the web - service. Valid values are Unknown, Provisioning, Succeeded, and Failed. - Possible values include: 'Unknown', 'Provisioning', 'Succeeded', 'Failed' - :vartype provisioning_state: str or :class:`ProvisioningState - ` - :param keys: Contains the web service provisioning keys. If you do not - specify provisioning keys, the Azure Machine Learning system generates - them for you. Note: The keys are not returned from calls to GET - operations. - :type keys: :class:`WebServiceKeys - ` - :param read_only: When set to true, indicates that the web service is - read-only and can no longer be updated or patched, only removed. Default, - is false. Note: Once set to true, you cannot change its value. - :type read_only: bool - :ivar swagger_location: Read Only: Contains the URI of the swagger spec - associated with this web service. - :vartype swagger_location: str - :param expose_sample_data: When set to true, sample data is included in - the web service's swagger definition. The default value is true. - :type expose_sample_data: bool - :param realtime_configuration: Contains the configuration settings for the - web service endpoint. - :type realtime_configuration: :class:`RealtimeConfiguration - ` - :param diagnostics: Settings controlling the diagnostics traces collection - for the web service. - :type diagnostics: :class:`DiagnosticsConfiguration - ` - :param storage_account: Specifies the storage account that Azure Machine - Learning uses to store information about the web service. Only the name of - the storage account is returned from calls to GET operations. When - updating the storage account information, you must ensure that all - necessary assets are available in the new storage account or calls to your - web service will fail. - :type storage_account: :class:`StorageAccount - ` - :param machine_learning_workspace: Specifies the Machine Learning - workspace containing the experiment that is source for the web service. - :type machine_learning_workspace: :class:`MachineLearningWorkspace - ` - :param commitment_plan: Contains the commitment plan associated with this - web service. Set at creation time. Once set, this value cannot be changed. - Note: The commitment plan is not returned from calls to GET operations. - :type commitment_plan: :class:`CommitmentPlan - ` - :param input: Contains the Swagger 2.0 schema describing one or more of - the web service's inputs. For more information, see the Swagger - specification. - :type input: :class:`ServiceInputOutputSpecification - ` - :param output: Contains the Swagger 2.0 schema describing one or more of - the web service's outputs. For more information, see the Swagger - specification. - :type output: :class:`ServiceInputOutputSpecification - ` - :param example_request: Defines sample input data for one or more of the - service's inputs. - :type example_request: :class:`ExampleRequest - ` - :param assets: Contains user defined properties describing web service - assets. Properties are expressed as Key/Value pairs. - :type assets: dict - :param parameters: The set of global parameters values defined for the web - service, given as a global parameter name to default value map. If no - default value is specified, the parameter is considered to be required. - :type parameters: dict - :param package_type: Polymorphic Discriminator - :type package_type: str - """ - - _validation = { - 'created_on': {'readonly': True}, - 'modified_on': {'readonly': True}, - 'provisioning_state': {'readonly': True}, - 'swagger_location': {'readonly': True}, - 'package_type': {'required': True}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'created_on': {'key': 'createdOn', 'type': 'iso-8601'}, - 'modified_on': {'key': 'modifiedOn', 'type': 'iso-8601'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'keys': {'key': 'keys', 'type': 'WebServiceKeys'}, - 'read_only': {'key': 'readOnly', 'type': 'bool'}, - 'swagger_location': {'key': 'swaggerLocation', 'type': 'str'}, - 'expose_sample_data': {'key': 'exposeSampleData', 'type': 'bool'}, - 'realtime_configuration': {'key': 'realtimeConfiguration', 'type': 'RealtimeConfiguration'}, - 'diagnostics': {'key': 'diagnostics', 'type': 'DiagnosticsConfiguration'}, - 'storage_account': {'key': 'storageAccount', 'type': 'StorageAccount'}, - 'machine_learning_workspace': {'key': 'machineLearningWorkspace', 'type': 'MachineLearningWorkspace'}, - 'commitment_plan': {'key': 'commitmentPlan', 'type': 'CommitmentPlan'}, - 'input': {'key': 'input', 'type': 'ServiceInputOutputSpecification'}, - 'output': {'key': 'output', 'type': 'ServiceInputOutputSpecification'}, - 'example_request': {'key': 'exampleRequest', 'type': 'ExampleRequest'}, - 'assets': {'key': 'assets', 'type': '{AssetItem}'}, - 'parameters': {'key': 'parameters', 'type': '{str}'}, - 'package_type': {'key': 'packageType', 'type': 'str'}, - } - - _subtype_map = { - 'package_type': {'Graph': 'WebServicePropertiesForGraph'} - } - - def __init__(self, title=None, description=None, keys=None, read_only=None, expose_sample_data=None, realtime_configuration=None, diagnostics=None, storage_account=None, machine_learning_workspace=None, commitment_plan=None, input=None, output=None, example_request=None, assets=None, parameters=None): - self.title = title - self.description = description - self.created_on = None - self.modified_on = None - self.provisioning_state = None - self.keys = keys - self.read_only = read_only - self.swagger_location = None - self.expose_sample_data = expose_sample_data - self.realtime_configuration = realtime_configuration - self.diagnostics = diagnostics - self.storage_account = storage_account - self.machine_learning_workspace = machine_learning_workspace - self.commitment_plan = commitment_plan - self.input = input - self.output = output - self.example_request = example_request - self.assets = assets - self.parameters = parameters - self.package_type = None diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties_for_graph.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties_for_graph.py deleted file mode 100644 index 0c368b936682..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/models/web_service_properties_for_graph.py +++ /dev/null @@ -1,141 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from .web_service_properties import WebServiceProperties - - -class WebServicePropertiesForGraph(WebServiceProperties): - """Properties specific to a Graph based web service. - - Variables are only populated by the server, and will be ignored when - sending a request. - - :param title: The title of the web service. - :type title: str - :param description: The description of the web service. - :type description: str - :ivar created_on: Read Only: The date and time when the web service was - created. - :vartype created_on: datetime - :ivar modified_on: Read Only: The date and time when the web service was - last modified. - :vartype modified_on: datetime - :ivar provisioning_state: Read Only: The provision state of the web - service. Valid values are Unknown, Provisioning, Succeeded, and Failed. - Possible values include: 'Unknown', 'Provisioning', 'Succeeded', 'Failed' - :vartype provisioning_state: str or :class:`ProvisioningState - ` - :param keys: Contains the web service provisioning keys. If you do not - specify provisioning keys, the Azure Machine Learning system generates - them for you. Note: The keys are not returned from calls to GET - operations. - :type keys: :class:`WebServiceKeys - ` - :param read_only: When set to true, indicates that the web service is - read-only and can no longer be updated or patched, only removed. Default, - is false. Note: Once set to true, you cannot change its value. - :type read_only: bool - :ivar swagger_location: Read Only: Contains the URI of the swagger spec - associated with this web service. - :vartype swagger_location: str - :param expose_sample_data: When set to true, sample data is included in - the web service's swagger definition. The default value is true. - :type expose_sample_data: bool - :param realtime_configuration: Contains the configuration settings for the - web service endpoint. - :type realtime_configuration: :class:`RealtimeConfiguration - ` - :param diagnostics: Settings controlling the diagnostics traces collection - for the web service. - :type diagnostics: :class:`DiagnosticsConfiguration - ` - :param storage_account: Specifies the storage account that Azure Machine - Learning uses to store information about the web service. Only the name of - the storage account is returned from calls to GET operations. When - updating the storage account information, you must ensure that all - necessary assets are available in the new storage account or calls to your - web service will fail. - :type storage_account: :class:`StorageAccount - ` - :param machine_learning_workspace: Specifies the Machine Learning - workspace containing the experiment that is source for the web service. - :type machine_learning_workspace: :class:`MachineLearningWorkspace - ` - :param commitment_plan: Contains the commitment plan associated with this - web service. Set at creation time. Once set, this value cannot be changed. - Note: The commitment plan is not returned from calls to GET operations. - :type commitment_plan: :class:`CommitmentPlan - ` - :param input: Contains the Swagger 2.0 schema describing one or more of - the web service's inputs. For more information, see the Swagger - specification. - :type input: :class:`ServiceInputOutputSpecification - ` - :param output: Contains the Swagger 2.0 schema describing one or more of - the web service's outputs. For more information, see the Swagger - specification. - :type output: :class:`ServiceInputOutputSpecification - ` - :param example_request: Defines sample input data for one or more of the - service's inputs. - :type example_request: :class:`ExampleRequest - ` - :param assets: Contains user defined properties describing web service - assets. Properties are expressed as Key/Value pairs. - :type assets: dict - :param parameters: The set of global parameters values defined for the web - service, given as a global parameter name to default value map. If no - default value is specified, the parameter is considered to be required. - :type parameters: dict - :param package_type: Polymorphic Discriminator - :type package_type: str - :param package: The definition of the graph package making up this web - service. - :type package: :class:`GraphPackage - ` - """ - - _validation = { - 'created_on': {'readonly': True}, - 'modified_on': {'readonly': True}, - 'provisioning_state': {'readonly': True}, - 'swagger_location': {'readonly': True}, - 'package_type': {'required': True}, - } - - _attribute_map = { - 'title': {'key': 'title', 'type': 'str'}, - 'description': {'key': 'description', 'type': 'str'}, - 'created_on': {'key': 'createdOn', 'type': 'iso-8601'}, - 'modified_on': {'key': 'modifiedOn', 'type': 'iso-8601'}, - 'provisioning_state': {'key': 'provisioningState', 'type': 'str'}, - 'keys': {'key': 'keys', 'type': 'WebServiceKeys'}, - 'read_only': {'key': 'readOnly', 'type': 'bool'}, - 'swagger_location': {'key': 'swaggerLocation', 'type': 'str'}, - 'expose_sample_data': {'key': 'exposeSampleData', 'type': 'bool'}, - 'realtime_configuration': {'key': 'realtimeConfiguration', 'type': 'RealtimeConfiguration'}, - 'diagnostics': {'key': 'diagnostics', 'type': 'DiagnosticsConfiguration'}, - 'storage_account': {'key': 'storageAccount', 'type': 'StorageAccount'}, - 'machine_learning_workspace': {'key': 'machineLearningWorkspace', 'type': 'MachineLearningWorkspace'}, - 'commitment_plan': {'key': 'commitmentPlan', 'type': 'CommitmentPlan'}, - 'input': {'key': 'input', 'type': 'ServiceInputOutputSpecification'}, - 'output': {'key': 'output', 'type': 'ServiceInputOutputSpecification'}, - 'example_request': {'key': 'exampleRequest', 'type': 'ExampleRequest'}, - 'assets': {'key': 'assets', 'type': '{AssetItem}'}, - 'parameters': {'key': 'parameters', 'type': '{str}'}, - 'package_type': {'key': 'packageType', 'type': 'str'}, - 'package': {'key': 'package', 'type': 'GraphPackage'}, - } - - def __init__(self, title=None, description=None, keys=None, read_only=None, expose_sample_data=None, realtime_configuration=None, diagnostics=None, storage_account=None, machine_learning_workspace=None, commitment_plan=None, input=None, output=None, example_request=None, assets=None, parameters=None, package=None): - super(WebServicePropertiesForGraph, self).__init__(title=title, description=description, keys=keys, read_only=read_only, expose_sample_data=expose_sample_data, realtime_configuration=realtime_configuration, diagnostics=diagnostics, storage_account=storage_account, machine_learning_workspace=machine_learning_workspace, commitment_plan=commitment_plan, input=input, output=output, example_request=example_request, assets=assets, parameters=parameters) - self.package = package - self.package_type = 'Graph' diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/__init__.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/__init__.py deleted file mode 100644 index 80cf79fe5299..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/__init__.py +++ /dev/null @@ -1,16 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from .web_services_operations import WebServicesOperations - -__all__ = [ - 'WebServicesOperations', -] diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/web_services_operations.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/web_services_operations.py deleted file mode 100644 index 1497c6d94488..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/operations/web_services_operations.py +++ /dev/null @@ -1,574 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -from msrest.pipeline import ClientRawResponse -from msrestazure.azure_exceptions import CloudError -from msrestazure.azure_operation import AzureOperationPoller -import uuid - -from .. import models - - -class WebServicesOperations(object): - """WebServicesOperations operations. - - :param client: Client for service requests. - :param config: Configuration of service client. - :param serializer: An object model serializer. - :param deserializer: An objec model deserializer. - """ - - def __init__(self, client, config, serializer, deserializer): - - self._client = client - self._serialize = serializer - self._deserialize = deserializer - - self.config = config - - def create_or_update( - self, resource_group_name, web_service_name, create_or_update_payload, custom_headers=None, raw=False, **operation_config): - """Create or update a web service. This call will overwrite an existing - web service. Note that there is no warning or confirmation. This is a - nonrecoverable operation. If your intent is to create a new web - service, call the Get operation first to verify that it does not exist. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param web_service_name: The name of the web service. - :type web_service_name: str - :param create_or_update_payload: The payload that is used to create or - update the web service. - :type create_or_update_payload: :class:`WebService - ` - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :rtype: - :class:`AzureOperationPoller` - instance that returns :class:`WebService - ` - :rtype: :class:`ClientRawResponse` - if raw=true - :raises: :class:`CloudError` - """ - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices/{webServiceName}' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'webServiceName': self._serialize.url("web_service_name", web_service_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct body - body_content = self._serialize.body(create_or_update_payload, 'WebService') - - # Construct and send request - def long_running_send(): - - request = self._client.put(url, query_parameters) - return self._client.send( - request, header_parameters, body_content, **operation_config) - - def get_long_running_status(status_link, headers=None): - - request = self._client.get(status_link) - if headers: - request.headers.update(headers) - return self._client.send( - request, header_parameters, **operation_config) - - def get_long_running_output(response): - - if response.status_code not in [200, 201]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('WebService', response) - if response.status_code == 201: - deserialized = self._deserialize('WebService', response) - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response - - return deserialized - - if raw: - response = long_running_send() - return get_long_running_output(response) - - long_running_operation_timeout = operation_config.get( - 'long_running_operation_timeout', - self.config.long_running_operation_timeout) - return AzureOperationPoller( - long_running_send, get_long_running_output, - get_long_running_status, long_running_operation_timeout) - - def get( - self, resource_group_name, web_service_name, custom_headers=None, raw=False, **operation_config): - """Gets the Web Service Definiton as specified by a subscription, resource - group, and name. Note that the storage credentials and web service keys - are not returned by this call. To get the web service access keys, call - List Keys. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param web_service_name: The name of the web service. - :type web_service_name: str - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :rtype: :class:`WebService - ` - :rtype: :class:`ClientRawResponse` - if raw=true - :raises: :class:`CloudError` - """ - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices/{webServiceName}' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'webServiceName': self._serialize.url("web_service_name", web_service_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) - - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('WebService', response) - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response - - return deserialized - - def patch( - self, resource_group_name, web_service_name, patch_payload, custom_headers=None, raw=False, **operation_config): - """Modifies an existing web service resource. The PATCH API call is an - asynchronous operation. To determine whether it has completed - successfully, you must perform a Get operation. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param web_service_name: The name of the web service. - :type web_service_name: str - :param patch_payload: The payload to use to patch the web service. - :type patch_payload: :class:`WebService - ` - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :rtype: - :class:`AzureOperationPoller` - instance that returns :class:`WebService - ` - :rtype: :class:`ClientRawResponse` - if raw=true - :raises: :class:`CloudError` - """ - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices/{webServiceName}' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'webServiceName': self._serialize.url("web_service_name", web_service_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct body - body_content = self._serialize.body(patch_payload, 'WebService') - - # Construct and send request - def long_running_send(): - - request = self._client.patch(url, query_parameters) - return self._client.send( - request, header_parameters, body_content, **operation_config) - - def get_long_running_status(status_link, headers=None): - - request = self._client.get(status_link) - if headers: - request.headers.update(headers) - return self._client.send( - request, header_parameters, **operation_config) - - def get_long_running_output(response): - - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('WebService', response) - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response - - return deserialized - - if raw: - response = long_running_send() - return get_long_running_output(response) - - long_running_operation_timeout = operation_config.get( - 'long_running_operation_timeout', - self.config.long_running_operation_timeout) - return AzureOperationPoller( - long_running_send, get_long_running_output, - get_long_running_status, long_running_operation_timeout) - - def remove( - self, resource_group_name, web_service_name, custom_headers=None, raw=False, **operation_config): - """Deletes the specified web service. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param web_service_name: The name of the web service. - :type web_service_name: str - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :rtype: - :class:`AzureOperationPoller` - instance that returns None - :rtype: :class:`ClientRawResponse` - if raw=true - :raises: :class:`CloudError` - """ - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices/{webServiceName}' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'webServiceName': self._serialize.url("web_service_name", web_service_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct and send request - def long_running_send(): - - request = self._client.delete(url, query_parameters) - return self._client.send(request, header_parameters, **operation_config) - - def get_long_running_status(status_link, headers=None): - - request = self._client.get(status_link) - if headers: - request.headers.update(headers) - return self._client.send( - request, header_parameters, **operation_config) - - def get_long_running_output(response): - - if response.status_code not in [202, 204]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - if raw: - client_raw_response = ClientRawResponse(None, response) - return client_raw_response - - if raw: - response = long_running_send() - return get_long_running_output(response) - - long_running_operation_timeout = operation_config.get( - 'long_running_operation_timeout', - self.config.long_running_operation_timeout) - return AzureOperationPoller( - long_running_send, get_long_running_output, - get_long_running_status, long_running_operation_timeout) - - def list_keys( - self, resource_group_name, web_service_name, custom_headers=None, raw=False, **operation_config): - """Gets the access keys for the specified web service. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param web_service_name: The name of the web service. - :type web_service_name: str - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :rtype: :class:`WebServiceKeys - ` - :rtype: :class:`ClientRawResponse` - if raw=true - :raises: :class:`CloudError` - """ - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices/{webServiceName}/listKeys' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'webServiceName': self._serialize.url("web_service_name", web_service_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send(request, header_parameters, **operation_config) - - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - deserialized = None - - if response.status_code == 200: - deserialized = self._deserialize('WebServiceKeys', response) - - if raw: - client_raw_response = ClientRawResponse(deserialized, response) - return client_raw_response - - return deserialized - - def list_by_resource_group( - self, resource_group_name, skiptoken=None, custom_headers=None, raw=False, **operation_config): - """Gets the web services in the specified resource group. - - :param resource_group_name: Name of the resource group in which the - web service is located. - :type resource_group_name: str - :param skiptoken: Continuation token for pagination. - :type skiptoken: str - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :rtype: :class:`WebServicePaged - ` - :raises: :class:`CloudError` - """ - def internal_paging(next_link=None, raw=False): - - if not next_link: - # Construct URL - url = '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.MachineLearning/webServices' - path_format_arguments = { - 'resourceGroupName': self._serialize.url("resource_group_name", resource_group_name, 'str'), - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - if skiptoken is not None: - query_parameters['$skiptoken'] = self._serialize.query("skiptoken", skiptoken, 'str') - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - else: - url = next_link - query_parameters = {} - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, **operation_config) - - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - return response - - # Deserialize response - deserialized = models.WebServicePaged(internal_paging, self._deserialize.dependencies) - - if raw: - header_dict = {} - client_raw_response = models.WebServicePaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response - - return deserialized - - def list( - self, skiptoken=None, custom_headers=None, raw=False, **operation_config): - """Gets the web services in the specified subscription. - - :param skiptoken: Continuation token for pagination. - :type skiptoken: str - :param dict custom_headers: headers that will be added to the request - :param bool raw: returns the direct response alongside the - deserialized response - :param operation_config: :ref:`Operation configuration - overrides`. - :rtype: :class:`WebServicePaged - ` - :raises: :class:`CloudError` - """ - def internal_paging(next_link=None, raw=False): - - if not next_link: - # Construct URL - url = '/subscriptions/{subscriptionId}/providers/Microsoft.MachineLearning/webServices' - path_format_arguments = { - 'subscriptionId': self._serialize.url("self.config.subscription_id", self.config.subscription_id, 'str') - } - url = self._client.format_url(url, **path_format_arguments) - - # Construct parameters - query_parameters = {} - if skiptoken is not None: - query_parameters['$skiptoken'] = self._serialize.query("skiptoken", skiptoken, 'str') - query_parameters['api-version'] = self._serialize.query("self.config.api_version", self.config.api_version, 'str') - - else: - url = next_link - query_parameters = {} - - # Construct headers - header_parameters = {} - header_parameters['Content-Type'] = 'application/json; charset=utf-8' - if self.config.generate_client_request_id: - header_parameters['x-ms-client-request-id'] = str(uuid.uuid1()) - if custom_headers: - header_parameters.update(custom_headers) - if self.config.accept_language is not None: - header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') - - # Construct and send request - request = self._client.get(url, query_parameters) - response = self._client.send( - request, header_parameters, **operation_config) - - if response.status_code not in [200]: - exp = CloudError(response) - exp.request_id = response.headers.get('x-ms-request-id') - raise exp - - return response - - # Deserialize response - deserialized = models.WebServicePaged(internal_paging, self._deserialize.dependencies) - - if raw: - header_dict = {} - client_raw_response = models.WebServicePaged(internal_paging, self._deserialize.dependencies, header_dict) - return client_raw_response - - return deserialized diff --git a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/version.py b/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/version.py deleted file mode 100644 index e0ec669828cb..000000000000 --- a/unreleased/azure-mgmt-machinelearning/azure/mgmt/machinelearning/version.py +++ /dev/null @@ -1,13 +0,0 @@ -# coding=utf-8 -# -------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -# -# Code generated by Microsoft (R) AutoRest Code Generator. -# Changes may cause incorrect behavior and will be lost if the code is -# regenerated. -# -------------------------------------------------------------------------- - -VERSION = "0.1.0" - diff --git a/unreleased/azure-mgmt-machinelearning/setup.cfg b/unreleased/azure-mgmt-machinelearning/setup.cfg deleted file mode 100644 index 7c1852ce7f41..000000000000 --- a/unreleased/azure-mgmt-machinelearning/setup.cfg +++ /dev/null @@ -1,6 +0,0 @@ -[bdist_wheel] -universal=1 - -[install] -single-version-externally-managed=1 -record=RECORD.txt diff --git a/unreleased/azure-mgmt-machinelearning/setup.py b/unreleased/azure-mgmt-machinelearning/setup.py deleted file mode 100644 index 95d44c32baa6..000000000000 --- a/unreleased/azure-mgmt-machinelearning/setup.py +++ /dev/null @@ -1,77 +0,0 @@ -#!/usr/bin/env python - -#------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -#-------------------------------------------------------------------------- - -from setuptools import find_packages, setup -from io import open -import re -import os.path - -# Change the PACKAGE_NAME only to change folder and different name -PACKAGE_NAME = "azure-mgmt-machinelearning" -PACKAGE_PPRINT_NAME = "Machine Learning Management" - -# a-b-c => a/b/c -package_folder_path = PACKAGE_NAME.replace('-', '/') -# a-b-c => a.b.c -namespace_name = PACKAGE_NAME.replace('-', '.') - -# azure v0.x is not compatible with this package -# azure v0.x used to have a __version__ attribute (newer versions don't) -try: - import azure - try: - ver = azure.__version__ - raise Exception( - 'This package is incompatible with azure=={}. '.format(ver) + - 'Uninstall it with "pip uninstall azure".' - ) - except AttributeError: - pass -except ImportError: - pass - -# Version extraction inspired from 'requests' -with open(os.path.join(package_folder_path, 'version.py'), 'r') as fd: - version = re.search(r'^VERSION\s*=\s*[\'"]([^\'"]*)[\'"]', - fd.read(), re.MULTILINE).group(1) - -if not version: - raise RuntimeError('Cannot find version information') - -with open('README.rst', encoding='utf-8') as f: - readme = f.read() -with open('HISTORY.rst', encoding='utf-8') as f: - history = f.read() - -setup( - name=PACKAGE_NAME, - version=version, - description='Microsoft Azure {} Client Library for Python'.format(PACKAGE_PPRINT_NAME), - long_description=readme + '\n\n' + history, - license='MIT License', - author='Microsoft Corporation', - author_email='ptvshelp@microsoft.com', - url='https://github.com/Azure/azure-sdk-for-python', - classifiers=[ - 'Development Status :: 4 - Beta', - 'Programming Language :: Python', - 'Programming Language :: Python :: 2', - 'Programming Language :: Python :: 2.7', - 'Programming Language :: Python :: 3', - 'Programming Language :: Python :: 3.3', - 'Programming Language :: Python :: 3.4', - 'Programming Language :: Python :: 3.5', - 'License :: OSI Approved :: MIT License', - ], - zip_safe=False, - packages=find_packages(), - install_requires=[ - 'azure-mgmt-nspkg', - 'azure-common[autorest]==1.1.4', - ], -) diff --git a/unreleased/azure-mgmt-machinelearning/tests/test_mgmt_machinelearning.py b/unreleased/azure-mgmt-machinelearning/tests/test_mgmt_machinelearning.py deleted file mode 100644 index 0c12b1c8d0e7..000000000000 --- a/unreleased/azure-mgmt-machinelearning/tests/test_mgmt_machinelearning.py +++ /dev/null @@ -1,95 +0,0 @@ -# coding: utf-8 - -#------------------------------------------------------------------------- -# Copyright (c) Microsoft Corporation. All rights reserved. -# Licensed under the MIT License. See License.txt in the project root for -# license information. -#-------------------------------------------------------------------------- -import unittest -raise unittest.SkipTest("Skipping all tests") - -import azure.mgmt.machinelearning -from azure.mgmt.storage import StorageManagementClient -from azure.mgmt.storage.models import ( - StorageAccountCreateParameters, - StorageAccountUpdateParameters, - Sku, - SkuName, - Kind -) -from devtools_testutils import AzureMgmtTestCase, ResourceGroupPreparer - -class MgmtMachineLearningTest(AzureMgmtTestCase): - - def setUp(self): - super(MgmtMachineLearningTest, self).setUp() - self.client = self.create_mgmt_client( - azure.mgmt.machinelearning.AzureMLWebServicesManagementClient - ) - - @ResourceGroupPreparer() - def test_ml(self, resource_group, location): - region = 'southcentralus' - - # Create a storage account and get keys - storage_name = self.get_resource_name('pystorage') - storage_client = azure.mgmt.storage.StorageManagementClient( - credentials=self.settings.get_credentials(), - subscription_id=self.settings.SUBSCRIPTION_ID - ) - storage_async_operation = storage_client.storage_accounts.create( - resource_group.name, - storage_name, - StorageAccountCreateParameters( - sku=Sku(SkuName.standard_ragrs), - kind=Kind.storage, - location=region - ) - ) - storage_async_operation.wait() - storage_key = storage_client.storage_accounts.list_keys( - resource_group.name, - storage_name - ).keys[0].value - - # Create Commitment plan - commitplan_name = self.get_resource_name('pycommit') - commitplan = self.resource_client.resources.create_or_update( - resource_group_name=resource_group.name, - resource_provider_namespace="Microsoft.MachineLearning", - parent_resource_path="", - resource_type="commitmentPlans", - resource_name=commitplan_name, - api_version="2016-05-01-preview", - parameters={ - 'location': region, - 'sku': { - 'name': "DevTest", - 'tier': 'Standard', - 'capacity': '1' - } - } - ) - - # Create WebService - ws_name = self.get_resource_name('pyws') - self.client.web_services.create_or_update({ - 'location': region, - 'properties': { - 'storage_account': { - 'name': storage_name, - 'key': storage_key - }, - 'machine_learning_workspace': { - 'id': commitplan.id - }, - 'packageType': 'Graph' - } - }, - resource_group.name, - ws_name - ) - -#------------------------------------------------------------------------------ -if __name__ == '__main__': - unittest.main()