Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
Generated from 5271be59e1385aa17e3cc8b4e0ee8e1a1c9d7415
update examples
  • Loading branch information
AutorestCI committed Sep 13, 2018
commit 3971a8815e6e550795a6d233ef88d25c513ff147
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@
from .virtual_machine_ssh_credentials_py3 import VirtualMachineSshCredentials
from .virtual_machine_properties_py3 import VirtualMachineProperties
from .virtual_machine_py3 import VirtualMachine
from .hd_insight_properties_py3 import HDInsightProperties
from .hd_insight_py3 import HDInsight
from .data_factory_py3 import DataFactory
from .service_principal_credentials_py3 import ServicePrincipalCredentials
from .compute_secrets_py3 import ComputeSecrets
Expand Down Expand Up @@ -64,6 +66,8 @@
from .virtual_machine_ssh_credentials import VirtualMachineSshCredentials
from .virtual_machine_properties import VirtualMachineProperties
from .virtual_machine import VirtualMachine
from .hd_insight_properties import HDInsightProperties
from .hd_insight import HDInsight
from .data_factory import DataFactory
from .service_principal_credentials import ServicePrincipalCredentials
from .compute_secrets import ComputeSecrets
Expand Down Expand Up @@ -103,6 +107,8 @@
'VirtualMachineSshCredentials',
'VirtualMachineProperties',
'VirtualMachine',
'HDInsightProperties',
'HDInsight',
'DataFactory',
'ServicePrincipalCredentials',
'ComputeSecrets',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class AKS(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -52,6 +54,7 @@ class AKS(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class AKS(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -52,6 +54,7 @@ class AKS(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand All @@ -62,7 +65,7 @@ class AKS(Compute):
'properties': {'key': 'properties', 'type': 'AKSProperties'},
}

def __init__(self, *, description: str=None, resource_id: str=None, properties=None, **kwargs) -> None:
super(AKS, self).__init__(description=description, resource_id=resource_id, **kwargs)
def __init__(self, *, compute_location: str=None, description: str=None, resource_id: str=None, properties=None, **kwargs) -> None:
super(AKS, self).__init__(compute_location=compute_location, description=description, resource_id=resource_id, **kwargs)
self.properties = properties
self.compute_type = 'AKS'
Original file line number Diff line number Diff line change
Expand Up @@ -34,3 +34,4 @@ class ComputeType(str, Enum):
batch_ai = "BatchAI"
data_factory = "DataFactory"
virtual_machine = "VirtualMachine"
hd_insight = "HDInsight"
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class BatchAI(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -53,6 +55,7 @@ class BatchAI(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class BatchAI(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -53,6 +55,7 @@ class BatchAI(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand All @@ -63,7 +66,7 @@ class BatchAI(Compute):
'properties': {'key': 'properties', 'type': 'BatchAIProperties'},
}

def __init__(self, *, description: str=None, resource_id: str=None, properties=None, **kwargs) -> None:
super(BatchAI, self).__init__(description=description, resource_id=resource_id, **kwargs)
def __init__(self, *, compute_location: str=None, description: str=None, resource_id: str=None, properties=None, **kwargs) -> None:
super(BatchAI, self).__init__(compute_location=compute_location, description=description, resource_id=resource_id, **kwargs)
self.properties = properties
self.compute_type = 'BatchAI'
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@ class Compute(Model):
"""Machine Learning compute object.

You probably want to use the sub-classes and not this class directly. Known
sub-classes are: AKS, BatchAI, VirtualMachine, DataFactory
sub-classes are: AKS, BatchAI, VirtualMachine, HDInsight, DataFactory

Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -53,6 +55,7 @@ class Compute(Model):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand All @@ -63,11 +66,12 @@ class Compute(Model):
}

_subtype_map = {
'compute_type': {'AKS': 'AKS', 'BatchAI': 'BatchAI', 'VirtualMachine': 'VirtualMachine', 'DataFactory': 'DataFactory'}
'compute_type': {'AKS': 'AKS', 'BatchAI': 'BatchAI', 'VirtualMachine': 'VirtualMachine', 'HDInsight': 'HDInsight', 'DataFactory': 'DataFactory'}
}

def __init__(self, **kwargs):
super(Compute, self).__init__(**kwargs)
self.compute_location = kwargs.get('compute_location', None)
self.provisioning_state = None
self.description = kwargs.get('description', None)
self.created_on = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,15 @@ class Compute(Model):
"""Machine Learning compute object.

You probably want to use the sub-classes and not this class directly. Known
sub-classes are: AKS, BatchAI, VirtualMachine, DataFactory
sub-classes are: AKS, BatchAI, VirtualMachine, HDInsight, DataFactory

Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -53,6 +55,7 @@ class Compute(Model):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand All @@ -63,11 +66,12 @@ class Compute(Model):
}

_subtype_map = {
'compute_type': {'AKS': 'AKS', 'BatchAI': 'BatchAI', 'VirtualMachine': 'VirtualMachine', 'DataFactory': 'DataFactory'}
'compute_type': {'AKS': 'AKS', 'BatchAI': 'BatchAI', 'VirtualMachine': 'VirtualMachine', 'HDInsight': 'HDInsight', 'DataFactory': 'DataFactory'}
}

def __init__(self, *, description: str=None, resource_id: str=None, **kwargs) -> None:
def __init__(self, *, compute_location: str=None, description: str=None, resource_id: str=None, **kwargs) -> None:
super(Compute, self).__init__(**kwargs)
self.compute_location = compute_location
self.provisioning_state = None
self.description = description
self.created_on = None
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class DataFactory(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -50,6 +52,7 @@ class DataFactory(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ class DataFactory(Compute):

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
Expand Down Expand Up @@ -50,6 +52,7 @@ class DataFactory(Compute):
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
Expand All @@ -59,6 +62,6 @@ class DataFactory(Compute):
'compute_type': {'key': 'computeType', 'type': 'str'},
}

def __init__(self, *, description: str=None, resource_id: str=None, **kwargs) -> None:
super(DataFactory, self).__init__(description=description, resource_id=resource_id, **kwargs)
def __init__(self, *, compute_location: str=None, description: str=None, resource_id: str=None, **kwargs) -> None:
super(DataFactory, self).__init__(compute_location=compute_location, description=description, resource_id=resource_id, **kwargs)
self.compute_type = 'DataFactory'
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
# 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 .compute import Compute


class HDInsight(Compute):
"""A HDInsight compute.

Variables are only populated by the server, and will be ignored when
sending a request.

All required parameters must be populated in order to send to Azure.

:param compute_location: Location for the underlying compute
:type compute_location: str
:ivar provisioning_state: The provision state of the cluster. Valid values
are Unknown, Updating, Provisioning, Succeeded, and Failed. Possible
values include: 'Unknown', 'Updating', 'Creating', 'Deleting',
'Succeeded', 'Failed', 'Canceled'
:vartype provisioning_state: str or
~azure.mgmt.machinelearningservices.models.ProvisioningState
:param description: The description of the Machine Learning compute.
:type description: str
:ivar created_on: The date and time when the compute was created.
:vartype created_on: datetime
:ivar modified_on: The date and time when the compute was last modified.
:vartype modified_on: datetime
:param resource_id: ARM resource id of the compute
:type resource_id: str
:ivar provisioning_errors: Errors during provisioning
:vartype provisioning_errors:
list[~azure.mgmt.machinelearningservices.models.MachineLearningServiceError]
:param compute_type: Required. Constant filled by server.
:type compute_type: str
:param properties:
:type properties:
~azure.mgmt.machinelearningservices.models.HDInsightProperties
"""

_validation = {
'provisioning_state': {'readonly': True},
'created_on': {'readonly': True},
'modified_on': {'readonly': True},
'provisioning_errors': {'readonly': True},
'compute_type': {'required': True},
}

_attribute_map = {
'compute_location': {'key': 'computeLocation', 'type': 'str'},
'provisioning_state': {'key': 'provisioningState', 'type': 'str'},
'description': {'key': 'description', 'type': 'str'},
'created_on': {'key': 'createdOn', 'type': 'iso-8601'},
'modified_on': {'key': 'modifiedOn', 'type': 'iso-8601'},
'resource_id': {'key': 'resourceId', 'type': 'str'},
'provisioning_errors': {'key': 'provisioningErrors', 'type': '[MachineLearningServiceError]'},
'compute_type': {'key': 'computeType', 'type': 'str'},
'properties': {'key': 'properties', 'type': 'HDInsightProperties'},
}

def __init__(self, **kwargs):
super(HDInsight, self).__init__(**kwargs)
self.properties = kwargs.get('properties', None)
self.compute_type = 'HDInsight'
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
# 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 HDInsightProperties(Model):
"""HDInsightProperties.

Variables are only populated by the server, and will be ignored when
sending a request.

:param ssh_port: Port open for ssh connections on the master node of the
cluster.
:type ssh_port: int
:ivar address: Public IP address of the master node of the cluster.
:vartype address: str
:param administrator_account: Admin credentials for master node of the
cluster
:type administrator_account:
~azure.mgmt.machinelearningservices.models.VirtualMachineSshCredentials
"""

_validation = {
'address': {'readonly': True},
}

_attribute_map = {
'ssh_port': {'key': 'sshPort', 'type': 'int'},
'address': {'key': 'address', 'type': 'str'},
'administrator_account': {'key': 'administratorAccount', 'type': 'VirtualMachineSshCredentials'},
}

def __init__(self, **kwargs):
super(HDInsightProperties, self).__init__(**kwargs)
self.ssh_port = kwargs.get('ssh_port', None)
self.address = None
self.administrator_account = kwargs.get('administrator_account', None)
Loading