diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/__init__.py b/azure-mgmt-automation/azure/mgmt/automation/models/__init__.py index dffa31034a14..afe9e2fe1914 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/__init__.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/__init__.py @@ -129,6 +129,7 @@ from .source_control_sync_job_by_id import SourceControlSyncJobById from .dsc_node import DscNode from .dsc_node_configuration import DscNodeConfiguration +from .dsc_node_configuration_create_or_update_parameters_properties import DscNodeConfigurationCreateOrUpdateParametersProperties from .automation_account_paged import AutomationAccountPaged from .operation_paged import OperationPaged from .statistics_paged import StatisticsPaged @@ -303,6 +304,7 @@ 'SourceControlSyncJobById', 'DscNode', 'DscNodeConfiguration', + 'DscNodeConfigurationCreateOrUpdateParametersProperties', 'AutomationAccountPaged', 'OperationPaged', 'StatisticsPaged', diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_configuration.py b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_configuration.py index 4a2672ec3067..a546052ed1d9 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_configuration.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_configuration.py @@ -48,6 +48,9 @@ class DscConfiguration(TrackedResource): :type creation_time: datetime :param last_modified_time: Gets or sets the last modified time. :type last_modified_time: datetime + :param node_configuration_count: Gets the number of compiled node + configurations. + :type node_configuration_count: int :param description: Gets or sets the description. :type description: str :param etag: Gets or sets the etag of the resource. @@ -74,11 +77,12 @@ class DscConfiguration(TrackedResource): 'log_verbose': {'key': 'properties.logVerbose', 'type': 'bool'}, 'creation_time': {'key': 'properties.creationTime', 'type': 'iso-8601'}, 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, + 'node_configuration_count': {'key': 'properties.nodeConfigurationCount', 'type': 'int'}, 'description': {'key': 'properties.description', 'type': 'str'}, 'etag': {'key': 'etag', 'type': 'str'}, } - def __init__(self, tags=None, location=None, provisioning_state=None, job_count=None, parameters=None, source=None, state=None, log_verbose=None, creation_time=None, last_modified_time=None, description=None, etag=None): + def __init__(self, tags=None, location=None, provisioning_state=None, job_count=None, parameters=None, source=None, state=None, log_verbose=None, creation_time=None, last_modified_time=None, node_configuration_count=None, description=None, etag=None): super(DscConfiguration, self).__init__(tags=tags, location=location) self.provisioning_state = provisioning_state self.job_count = job_count @@ -88,5 +92,6 @@ def __init__(self, tags=None, location=None, provisioning_state=None, job_count= self.log_verbose = log_verbose self.creation_time = creation_time self.last_modified_time = last_modified_time + self.node_configuration_count = node_configuration_count self.description = description self.etag = etag diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node.py b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node.py index a9b4ab486fb7..8a46001f3af1 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node.py @@ -40,6 +40,9 @@ class DscNode(ProxyResource): :type node_id: str :param etag: Gets or sets the etag of the resource. :type etag: str + :param total_count: Gets the total number of records matching filter + criteria. + :type total_count: int :param extension_handler: Gets or sets the list of extensionHandler properties for a Node. :type extension_handler: @@ -64,10 +67,11 @@ class DscNode(ProxyResource): 'status': {'key': 'properties.status', 'type': 'str'}, 'node_id': {'key': 'properties.nodeId', 'type': 'str'}, 'etag': {'key': 'properties.etag', 'type': 'str'}, + 'total_count': {'key': 'properties.totalCount', 'type': 'int'}, 'extension_handler': {'key': 'properties.extensionHandler', 'type': '[DscNodeExtensionHandlerAssociationProperty]'}, } - def __init__(self, last_seen=None, registration_time=None, ip=None, account_id=None, dsc_node_name=None, status=None, node_id=None, etag=None, extension_handler=None): + def __init__(self, last_seen=None, registration_time=None, ip=None, account_id=None, dsc_node_name=None, status=None, node_id=None, etag=None, total_count=None, extension_handler=None): super(DscNode, self).__init__() self.last_seen = last_seen self.registration_time = registration_time @@ -77,4 +81,5 @@ def __init__(self, last_seen=None, registration_time=None, ip=None, account_id=N self.status = status self.node_id = node_id self.etag = etag + self.total_count = total_count self.extension_handler = extension_handler diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters.py b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters.py index 99e5af654b6f..87665da540e5 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters.py @@ -18,7 +18,7 @@ class DscNodeConfigurationCreateOrUpdateParameters(Model): :param source: Gets or sets the source. :type source: ~azure.mgmt.automation.models.ContentSource - :param name: Name of the node configuration. + :param name: Gets or sets the type of the parameter. :type name: str :param configuration: Gets or sets the configuration of the node. :type configuration: @@ -26,27 +26,12 @@ class DscNodeConfigurationCreateOrUpdateParameters(Model): :param new_node_configuration_build_version_required: If a new build version of NodeConfiguration is required. :type new_node_configuration_build_version_required: bool - :param source1: Gets or sets the source. - :type source1: ~azure.mgmt.automation.models.ContentSource - :param name1: Gets or sets the type of the parameter. - :type name1: str - :param configuration1: Gets or sets the configuration of the node. - :type configuration1: - ~azure.mgmt.automation.models.DscConfigurationAssociationProperty - :param increment_node_configuration_build: If a new build version of - NodeConfiguration is required. - :type increment_node_configuration_build: bool - :param tags: Gets or sets the tags attached to the resource. - :type tags: dict[str, str] """ _validation = { 'source': {'required': True}, 'name': {'required': True}, 'configuration': {'required': True}, - 'source1': {'required': True}, - 'name1': {'required': True}, - 'configuration1': {'required': True}, } _attribute_map = { @@ -54,21 +39,11 @@ class DscNodeConfigurationCreateOrUpdateParameters(Model): 'name': {'key': 'name', 'type': 'str'}, 'configuration': {'key': 'configuration', 'type': 'DscConfigurationAssociationProperty'}, 'new_node_configuration_build_version_required': {'key': 'newNodeConfigurationBuildVersionRequired', 'type': 'bool'}, - 'source1': {'key': 'properties.source', 'type': 'ContentSource'}, - 'name1': {'key': 'properties.name', 'type': 'str'}, - 'configuration1': {'key': 'properties.configuration', 'type': 'DscConfigurationAssociationProperty'}, - 'increment_node_configuration_build': {'key': 'properties.incrementNodeConfigurationBuild', 'type': 'bool'}, - 'tags': {'key': 'tags', 'type': '{str}'}, } - def __init__(self, source, name, configuration, source1, name1, configuration1, new_node_configuration_build_version_required=None, increment_node_configuration_build=None, tags=None): + def __init__(self, source, name, configuration, new_node_configuration_build_version_required=None): super(DscNodeConfigurationCreateOrUpdateParameters, self).__init__() self.source = source self.name = name self.configuration = configuration self.new_node_configuration_build_version_required = new_node_configuration_build_version_required - self.source1 = source1 - self.name1 = name1 - self.configuration1 = configuration1 - self.increment_node_configuration_build = increment_node_configuration_build - self.tags = tags diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters_properties.py b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters_properties.py new file mode 100644 index 000000000000..d1a7116d3cef --- /dev/null +++ b/azure-mgmt-automation/azure/mgmt/automation/models/dsc_node_configuration_create_or_update_parameters_properties.py @@ -0,0 +1,49 @@ +# 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 DscNodeConfigurationCreateOrUpdateParametersProperties(Model): + """The parameters supplied to the create or update node configuration + operation. + + :param source: Gets or sets the source. + :type source: ~azure.mgmt.automation.models.ContentSource + :param name: Gets or sets the type of the parameter. + :type name: str + :param configuration: Gets or sets the configuration of the node. + :type configuration: + ~azure.mgmt.automation.models.DscConfigurationAssociationProperty + :param increment_node_configuration_build: If a new build version of + NodeConfiguration is required. + :type increment_node_configuration_build: bool + """ + + _validation = { + 'source': {'required': True}, + 'name': {'required': True}, + 'configuration': {'required': True}, + } + + _attribute_map = { + 'source': {'key': 'source', 'type': 'ContentSource'}, + 'name': {'key': 'name', 'type': 'str'}, + 'configuration': {'key': 'configuration', 'type': 'DscConfigurationAssociationProperty'}, + 'increment_node_configuration_build': {'key': 'incrementNodeConfigurationBuild', 'type': 'bool'}, + } + + def __init__(self, source, name, configuration, increment_node_configuration_build=None): + super(DscNodeConfigurationCreateOrUpdateParametersProperties, self).__init__() + self.source = source + self.name = name + self.configuration = configuration + self.increment_node_configuration_build = increment_node_configuration_build diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/job.py b/azure-mgmt-automation/azure/mgmt/automation/models/job.py index 50df77aa7a4f..2170947ffa3c 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/job.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/job.py @@ -55,8 +55,8 @@ class Job(ProxyResource): :type last_status_modified_time: datetime :param parameters: Gets or sets the parameters of the job. :type parameters: dict[str, str] - :ivar provisioning_state: The provisioning state of a resource. - :vartype provisioning_state: + :param provisioning_state: The provisioning state of a resource. + :type provisioning_state: ~azure.mgmt.automation.models.JobProvisioningStateProperty """ @@ -64,7 +64,6 @@ class Job(ProxyResource): 'id': {'readonly': True}, 'name': {'readonly': True}, 'type': {'readonly': True}, - 'provisioning_state': {'readonly': True}, } _attribute_map = { @@ -87,7 +86,7 @@ class Job(ProxyResource): 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'JobProvisioningStateProperty'}, } - def __init__(self, runbook=None, started_by=None, run_on=None, job_id=None, creation_time=None, status=None, status_details=None, start_time=None, end_time=None, exception=None, last_modified_time=None, last_status_modified_time=None, parameters=None): + def __init__(self, runbook=None, started_by=None, run_on=None, job_id=None, creation_time=None, status=None, status_details=None, start_time=None, end_time=None, exception=None, last_modified_time=None, last_status_modified_time=None, parameters=None, provisioning_state=None): super(Job, self).__init__() self.runbook = runbook self.started_by = started_by @@ -102,4 +101,4 @@ def __init__(self, runbook=None, started_by=None, run_on=None, job_id=None, crea self.last_modified_time = last_modified_time self.last_status_modified_time = last_status_modified_time self.parameters = parameters - self.provisioning_state = None + self.provisioning_state = provisioning_state diff --git a/azure-mgmt-automation/azure/mgmt/automation/models/job_collection_item.py b/azure-mgmt-automation/azure/mgmt/automation/models/job_collection_item.py index 15e44eb07892..a1ac49c010bc 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/models/job_collection_item.py +++ b/azure-mgmt-automation/azure/mgmt/automation/models/job_collection_item.py @@ -41,8 +41,9 @@ class JobCollectionItem(ProxyResource): :vartype end_time: datetime :ivar last_modified_time: The last modified time of the job. :vartype last_modified_time: datetime - :ivar provisioning_state: The provisioning state of a resource. - :vartype provisioning_state: str + :param provisioning_state: The current provisioning state of the job. + :type provisioning_state: + ~azure.mgmt.automation.models.JobProvisioningStateProperty """ _validation = { @@ -56,7 +57,6 @@ class JobCollectionItem(ProxyResource): 'start_time': {'readonly': True}, 'end_time': {'readonly': True}, 'last_modified_time': {'readonly': True}, - 'provisioning_state': {'readonly': True}, } _attribute_map = { @@ -70,10 +70,10 @@ class JobCollectionItem(ProxyResource): 'start_time': {'key': 'properties.startTime', 'type': 'iso-8601'}, 'end_time': {'key': 'properties.endTime', 'type': 'iso-8601'}, 'last_modified_time': {'key': 'properties.lastModifiedTime', 'type': 'iso-8601'}, - 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'str'}, + 'provisioning_state': {'key': 'properties.provisioningState', 'type': 'JobProvisioningStateProperty'}, } - def __init__(self): + def __init__(self, provisioning_state=None): super(JobCollectionItem, self).__init__() self.runbook = None self.job_id = None @@ -82,4 +82,4 @@ def __init__(self): self.start_time = None self.end_time = None self.last_modified_time = None - self.provisioning_state = None + self.provisioning_state = provisioning_state diff --git a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_configuration_operations.py b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_configuration_operations.py index 9154a8c5a916..24c64fe59537 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_configuration_operations.py +++ b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_configuration_operations.py @@ -369,13 +369,21 @@ def get_content( get_content.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/configurations/{configurationName}/content'} def list_by_automation_account( - self, resource_group_name, automation_account_name, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, automation_account_name, filter=None, skip=None, top=None, inlinecount=None, custom_headers=None, raw=False, **operation_config): """Retrieve a list of configurations. :param resource_group_name: Name of an Azure Resource group. :type resource_group_name: str :param automation_account_name: The automation account name. :type automation_account_name: str + :param filter: The filter to apply on the operation. + :type filter: str + :param skip: The number of rows to skip. + :type skip: int + :param top: The the number of rows to take. + :type top: int + :param inlinecount: Return total rows. + :type inlinecount: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -402,6 +410,14 @@ def internal_paging(next_link=None, raw=False): # Construct parameters query_parameters = {} query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') + if filter is not None: + query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int') + if inlinecount is not None: + query_parameters['$inlinecount'] = self._serialize.query("inlinecount", inlinecount, 'str') else: url = next_link diff --git a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_configuration_operations.py b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_configuration_operations.py index c4beae5b0047..81baf3911f48 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_configuration_operations.py +++ b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_configuration_operations.py @@ -186,7 +186,7 @@ def _create_or_update_initial( header_parameters['accept-language'] = self._serialize.header("self.config.accept_language", self.config.accept_language, 'str') # Construct body - body_content = self._serialize.body(parameters, 'DscNodeConfigurationCreateOrUpdateParameters') + body_content = self._serialize.body(parameters, 'DscNodeConfigurationCreateOrUpdateParametersProperties') # Construct and send request request = self._client.put(url, query_parameters) @@ -219,7 +219,7 @@ def create_or_update( :type node_configuration_name: str :param parameters: The create or update parameters for configuration. :type parameters: - ~azure.mgmt.automation.models.DscNodeConfigurationCreateOrUpdateParameters + ~azure.mgmt.automation.models.DscNodeConfigurationCreateOrUpdateParametersProperties :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -279,7 +279,7 @@ def get_long_running_output(response): create_or_update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/nodeConfigurations/{nodeConfigurationName}'} def list_by_automation_account( - self, resource_group_name, automation_account_name, filter=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, automation_account_name, filter=None, skip=None, top=None, inlinecount=None, custom_headers=None, raw=False, **operation_config): """Retrieve a list of dsc node configurations. :param resource_group_name: Name of an Azure Resource group. @@ -288,6 +288,12 @@ def list_by_automation_account( :type automation_account_name: str :param filter: The filter to apply on the operation. :type filter: str + :param skip: The number of rows to skip. + :type skip: int + :param top: The the number of rows to take. + :type top: int + :param inlinecount: Return total rows. + :type inlinecount: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -316,6 +322,12 @@ def internal_paging(next_link=None, raw=False): query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') if filter is not None: query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int') + if inlinecount is not None: + query_parameters['$inlinecount'] = self._serialize.query("inlinecount", inlinecount, 'str') else: url = next_link diff --git a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_operations.py b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_operations.py index aa1e6c97f9b6..570e0aa765f2 100644 --- a/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_operations.py +++ b/azure-mgmt-automation/azure/mgmt/automation/operations/dsc_node_operations.py @@ -237,7 +237,7 @@ def update( update.metadata = {'url': '/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.Automation/automationAccounts/{automationAccountName}/nodes/{nodeId}'} def list_by_automation_account( - self, resource_group_name, automation_account_name, filter=None, custom_headers=None, raw=False, **operation_config): + self, resource_group_name, automation_account_name, filter=None, skip=None, top=None, inlinecount=None, custom_headers=None, raw=False, **operation_config): """Retrieve a list of dsc nodes. :param resource_group_name: Name of an Azure Resource group. @@ -246,6 +246,12 @@ def list_by_automation_account( :type automation_account_name: str :param filter: The filter to apply on the operation. :type filter: str + :param skip: The number of rows to skip. + :type skip: int + :param top: The the number of rows to take. + :type top: int + :param inlinecount: Return total rows. + :type inlinecount: str :param dict custom_headers: headers that will be added to the request :param bool raw: returns the direct response alongside the deserialized response @@ -273,6 +279,12 @@ def internal_paging(next_link=None, raw=False): query_parameters = {} if filter is not None: query_parameters['$filter'] = self._serialize.query("filter", filter, 'str') + if skip is not None: + query_parameters['$skip'] = self._serialize.query("skip", skip, 'int') + if top is not None: + query_parameters['$top'] = self._serialize.query("top", top, 'int') + if inlinecount is not None: + query_parameters['$inlinecount'] = self._serialize.query("inlinecount", inlinecount, 'str') query_parameters['api-version'] = self._serialize.query("self.api_version", self.api_version, 'str') else: