From d268beaa1a0f595572d7cbaf628bd29258f5c6d1 Mon Sep 17 00:00:00 2001 From: Azure SDK for Python bot Date: Thu, 29 Aug 2019 23:00:35 +0000 Subject: [PATCH] Generated from 5e1bb35d5c3314d8f4fead76c3d69a2522be026b Update review comments --- .../azure/mgmt/datafactory/models/__init__.py | 3 + .../azure/mgmt/datafactory/models/_models.py | 89 +++++++++++++++++- .../mgmt/datafactory/models/_models_py3.py | 91 ++++++++++++++++++- 3 files changed, 176 insertions(+), 7 deletions(-) diff --git a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/__init__.py b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/__init__.py index 298f059389b8..f45fba3e8bbf 100644 --- a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/__init__.py +++ b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/__init__.py @@ -105,6 +105,7 @@ from ._models_py3 import CassandraLinkedService from ._models_py3 import CassandraSource from ._models_py3 import CassandraTableDataset + from ._models_py3 import ChainingTrigger from ._models_py3 import CommonDataServiceForAppsEntityDataset from ._models_py3 import CommonDataServiceForAppsLinkedService from ._models_py3 import CommonDataServiceForAppsSink @@ -621,6 +622,7 @@ from ._models import CassandraLinkedService from ._models import CassandraSource from ._models import CassandraTableDataset + from ._models import ChainingTrigger from ._models import CommonDataServiceForAppsEntityDataset from ._models import CommonDataServiceForAppsLinkedService from ._models import CommonDataServiceForAppsSink @@ -1220,6 +1222,7 @@ 'CassandraLinkedService', 'CassandraSource', 'CassandraTableDataset', + 'ChainingTrigger', 'CommonDataServiceForAppsEntityDataset', 'CommonDataServiceForAppsLinkedService', 'CommonDataServiceForAppsSink', diff --git a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models.py b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models.py index a056f9732314..aeb32319f20a 100644 --- a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models.py +++ b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models.py @@ -5961,8 +5961,8 @@ class Trigger(Model): pipeline run. You probably want to use the sub-classes and not this class directly. Known - sub-classes are: RerunTumblingWindowTrigger, TumblingWindowTrigger, - MultiplePipelineTrigger + sub-classes are: RerunTumblingWindowTrigger, ChainingTrigger, + TumblingWindowTrigger, MultiplePipelineTrigger Variables are only populated by the server, and will be ignored when sending a request. @@ -6000,7 +6000,7 @@ class Trigger(Model): } _subtype_map = { - 'type': {'RerunTumblingWindowTrigger': 'RerunTumblingWindowTrigger', 'TumblingWindowTrigger': 'TumblingWindowTrigger', 'MultiplePipelineTrigger': 'MultiplePipelineTrigger'} + 'type': {'RerunTumblingWindowTrigger': 'RerunTumblingWindowTrigger', 'ChainingTrigger': 'ChainingTrigger', 'TumblingWindowTrigger': 'TumblingWindowTrigger', 'MultiplePipelineTrigger': 'MultiplePipelineTrigger'} } def __init__(self, **kwargs): @@ -6526,6 +6526,70 @@ def __init__(self, **kwargs): self.type = 'CassandraTable' +class ChainingTrigger(Trigger): + """Trigger that allows the referenced pipeline to depend on other pipeline + runs based on runDimension Name/Value pairs. Upstream pipelines should + declare the same runDimension Name and their runs should have the values + for those runDimensions. The referenced pipeline run would be triggered if + the values for the runDimension match for all upstream pipeline runs. + + 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 additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param description: Trigger description. + :type description: str + :ivar runtime_state: Indicates if trigger is running or not. Updated when + Start/Stop APIs are called on the Trigger. Possible values include: + 'Started', 'Stopped', 'Disabled' + :vartype runtime_state: str or + ~azure.mgmt.datafactory.models.TriggerRuntimeState + :param annotations: List of tags that can be used for describing the + trigger. + :type annotations: list[object] + :param type: Required. Constant filled by server. + :type type: str + :param pipeline: Required. Pipeline for which runs are created when all + upstream pipelines complete successfully. + :type pipeline: ~azure.mgmt.datafactory.models.TriggerPipelineReference + :param depends_on: Required. Upstream Pipelines. + :type depends_on: list[~azure.mgmt.datafactory.models.PipelineReference] + :param run_dimension: Required. Run Dimension property that needs to be + emitted by upstream pipelines. + :type run_dimension: str + """ + + _validation = { + 'runtime_state': {'readonly': True}, + 'type': {'required': True}, + 'pipeline': {'required': True}, + 'depends_on': {'required': True}, + 'run_dimension': {'required': True}, + } + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'description': {'key': 'description', 'type': 'str'}, + 'runtime_state': {'key': 'runtimeState', 'type': 'str'}, + 'annotations': {'key': 'annotations', 'type': '[object]'}, + 'type': {'key': 'type', 'type': 'str'}, + 'pipeline': {'key': 'pipeline', 'type': 'TriggerPipelineReference'}, + 'depends_on': {'key': 'typeProperties.dependsOn', 'type': '[PipelineReference]'}, + 'run_dimension': {'key': 'typeProperties.runDimension', 'type': 'str'}, + } + + def __init__(self, **kwargs): + super(ChainingTrigger, self).__init__(**kwargs) + self.pipeline = kwargs.get('pipeline', None) + self.depends_on = kwargs.get('depends_on', None) + self.run_dimension = kwargs.get('run_dimension', None) + self.type = 'ChainingTrigger' + + class CloudError(Model): """The object that defines the structure of an Azure Data Factory error response. @@ -20081,6 +20145,8 @@ class PipelineResource(SubResource): :param annotations: List of tags that can be used for describing the Pipeline. :type annotations: list[object] + :param run_dimensions: Dimensions emitted by Pipeline. + :type run_dimensions: dict[str, object] :param folder: The folder that this Pipeline is in. If not specified, Pipeline will appear at the root level. :type folder: ~azure.mgmt.datafactory.models.PipelineFolder @@ -20106,6 +20172,7 @@ class PipelineResource(SubResource): 'variables': {'key': 'properties.variables', 'type': '{VariableSpecification}'}, 'concurrency': {'key': 'properties.concurrency', 'type': 'int'}, 'annotations': {'key': 'properties.annotations', 'type': '[object]'}, + 'run_dimensions': {'key': 'properties.runDimensions', 'type': '{object}'}, 'folder': {'key': 'properties.folder', 'type': 'PipelineFolder'}, } @@ -20118,6 +20185,7 @@ def __init__(self, **kwargs): self.variables = kwargs.get('variables', None) self.concurrency = kwargs.get('concurrency', None) self.annotations = kwargs.get('annotations', None) + self.run_dimensions = kwargs.get('run_dimensions', None) self.folder = kwargs.get('folder', None) @@ -20143,6 +20211,8 @@ class PipelineRun(Model): :ivar parameters: The full or partial list of parameter name, value pair used in the pipeline run. :vartype parameters: dict[str, str] + :ivar run_dimensions: Run dimensions emitted by Pipeline run. + :vartype run_dimensions: dict[str, str] :ivar invoked_by: Entity that started the pipeline run. :vartype invoked_by: ~azure.mgmt.datafactory.models.PipelineRunInvokedBy :ivar last_updated: The last updated timestamp for the pipeline run event @@ -20166,6 +20236,7 @@ class PipelineRun(Model): 'is_latest': {'readonly': True}, 'pipeline_name': {'readonly': True}, 'parameters': {'readonly': True}, + 'run_dimensions': {'readonly': True}, 'invoked_by': {'readonly': True}, 'last_updated': {'readonly': True}, 'run_start': {'readonly': True}, @@ -20182,6 +20253,7 @@ class PipelineRun(Model): 'is_latest': {'key': 'isLatest', 'type': 'bool'}, 'pipeline_name': {'key': 'pipelineName', 'type': 'str'}, 'parameters': {'key': 'parameters', 'type': '{str}'}, + 'run_dimensions': {'key': 'runDimensions', 'type': '{str}'}, 'invoked_by': {'key': 'invokedBy', 'type': 'PipelineRunInvokedBy'}, 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, 'run_start': {'key': 'runStart', 'type': 'iso-8601'}, @@ -20199,6 +20271,7 @@ def __init__(self, **kwargs): self.is_latest = None self.pipeline_name = None self.parameters = None + self.run_dimensions = None self.invoked_by = None self.last_updated = None self.run_start = None @@ -27428,6 +27501,10 @@ class TriggerRun(Model): :ivar triggered_pipelines: List of pipeline name and run Id triggered by the trigger run. :vartype triggered_pipelines: dict[str, str] + :ivar run_dimension: Run dimension for which trigger was fired. + :vartype run_dimension: dict[str, str] + :ivar dependency_status: Status of the upstream pipelines. + :vartype dependency_status: dict[str, object] """ _validation = { @@ -27439,6 +27516,8 @@ class TriggerRun(Model): 'message': {'readonly': True}, 'properties': {'readonly': True}, 'triggered_pipelines': {'readonly': True}, + 'run_dimension': {'readonly': True}, + 'dependency_status': {'readonly': True}, } _attribute_map = { @@ -27451,6 +27530,8 @@ class TriggerRun(Model): 'message': {'key': 'message', 'type': 'str'}, 'properties': {'key': 'properties', 'type': '{str}'}, 'triggered_pipelines': {'key': 'triggeredPipelines', 'type': '{str}'}, + 'run_dimension': {'key': 'runDimension', 'type': '{str}'}, + 'dependency_status': {'key': 'dependencyStatus', 'type': '{object}'}, } def __init__(self, **kwargs): @@ -27464,6 +27545,8 @@ def __init__(self, **kwargs): self.message = None self.properties = None self.triggered_pipelines = None + self.run_dimension = None + self.dependency_status = None class TriggerRunsQueryResponse(Model): diff --git a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models_py3.py b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models_py3.py index 6449023a7260..7d89d02a63b8 100644 --- a/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models_py3.py +++ b/sdk/datafactory/azure-mgmt-datafactory/azure/mgmt/datafactory/models/_models_py3.py @@ -5961,8 +5961,8 @@ class Trigger(Model): pipeline run. You probably want to use the sub-classes and not this class directly. Known - sub-classes are: RerunTumblingWindowTrigger, TumblingWindowTrigger, - MultiplePipelineTrigger + sub-classes are: RerunTumblingWindowTrigger, ChainingTrigger, + TumblingWindowTrigger, MultiplePipelineTrigger Variables are only populated by the server, and will be ignored when sending a request. @@ -6000,7 +6000,7 @@ class Trigger(Model): } _subtype_map = { - 'type': {'RerunTumblingWindowTrigger': 'RerunTumblingWindowTrigger', 'TumblingWindowTrigger': 'TumblingWindowTrigger', 'MultiplePipelineTrigger': 'MultiplePipelineTrigger'} + 'type': {'RerunTumblingWindowTrigger': 'RerunTumblingWindowTrigger', 'ChainingTrigger': 'ChainingTrigger', 'TumblingWindowTrigger': 'TumblingWindowTrigger', 'MultiplePipelineTrigger': 'MultiplePipelineTrigger'} } def __init__(self, *, additional_properties=None, description: str=None, annotations=None, **kwargs) -> None: @@ -6526,6 +6526,70 @@ def __init__(self, *, linked_service_name, additional_properties=None, descripti self.type = 'CassandraTable' +class ChainingTrigger(Trigger): + """Trigger that allows the referenced pipeline to depend on other pipeline + runs based on runDimension Name/Value pairs. Upstream pipelines should + declare the same runDimension Name and their runs should have the values + for those runDimensions. The referenced pipeline run would be triggered if + the values for the runDimension match for all upstream pipeline runs. + + 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 additional_properties: Unmatched properties from the message are + deserialized this collection + :type additional_properties: dict[str, object] + :param description: Trigger description. + :type description: str + :ivar runtime_state: Indicates if trigger is running or not. Updated when + Start/Stop APIs are called on the Trigger. Possible values include: + 'Started', 'Stopped', 'Disabled' + :vartype runtime_state: str or + ~azure.mgmt.datafactory.models.TriggerRuntimeState + :param annotations: List of tags that can be used for describing the + trigger. + :type annotations: list[object] + :param type: Required. Constant filled by server. + :type type: str + :param pipeline: Required. Pipeline for which runs are created when all + upstream pipelines complete successfully. + :type pipeline: ~azure.mgmt.datafactory.models.TriggerPipelineReference + :param depends_on: Required. Upstream Pipelines. + :type depends_on: list[~azure.mgmt.datafactory.models.PipelineReference] + :param run_dimension: Required. Run Dimension property that needs to be + emitted by upstream pipelines. + :type run_dimension: str + """ + + _validation = { + 'runtime_state': {'readonly': True}, + 'type': {'required': True}, + 'pipeline': {'required': True}, + 'depends_on': {'required': True}, + 'run_dimension': {'required': True}, + } + + _attribute_map = { + 'additional_properties': {'key': '', 'type': '{object}'}, + 'description': {'key': 'description', 'type': 'str'}, + 'runtime_state': {'key': 'runtimeState', 'type': 'str'}, + 'annotations': {'key': 'annotations', 'type': '[object]'}, + 'type': {'key': 'type', 'type': 'str'}, + 'pipeline': {'key': 'pipeline', 'type': 'TriggerPipelineReference'}, + 'depends_on': {'key': 'typeProperties.dependsOn', 'type': '[PipelineReference]'}, + 'run_dimension': {'key': 'typeProperties.runDimension', 'type': 'str'}, + } + + def __init__(self, *, pipeline, depends_on, run_dimension: str, additional_properties=None, description: str=None, annotations=None, **kwargs) -> None: + super(ChainingTrigger, self).__init__(additional_properties=additional_properties, description=description, annotations=annotations, **kwargs) + self.pipeline = pipeline + self.depends_on = depends_on + self.run_dimension = run_dimension + self.type = 'ChainingTrigger' + + class CloudError(Model): """The object that defines the structure of an Azure Data Factory error response. @@ -20081,6 +20145,8 @@ class PipelineResource(SubResource): :param annotations: List of tags that can be used for describing the Pipeline. :type annotations: list[object] + :param run_dimensions: Dimensions emitted by Pipeline. + :type run_dimensions: dict[str, object] :param folder: The folder that this Pipeline is in. If not specified, Pipeline will appear at the root level. :type folder: ~azure.mgmt.datafactory.models.PipelineFolder @@ -20106,10 +20172,11 @@ class PipelineResource(SubResource): 'variables': {'key': 'properties.variables', 'type': '{VariableSpecification}'}, 'concurrency': {'key': 'properties.concurrency', 'type': 'int'}, 'annotations': {'key': 'properties.annotations', 'type': '[object]'}, + 'run_dimensions': {'key': 'properties.runDimensions', 'type': '{object}'}, 'folder': {'key': 'properties.folder', 'type': 'PipelineFolder'}, } - def __init__(self, *, additional_properties=None, description: str=None, activities=None, parameters=None, variables=None, concurrency: int=None, annotations=None, folder=None, **kwargs) -> None: + def __init__(self, *, additional_properties=None, description: str=None, activities=None, parameters=None, variables=None, concurrency: int=None, annotations=None, run_dimensions=None, folder=None, **kwargs) -> None: super(PipelineResource, self).__init__(**kwargs) self.additional_properties = additional_properties self.description = description @@ -20118,6 +20185,7 @@ def __init__(self, *, additional_properties=None, description: str=None, activit self.variables = variables self.concurrency = concurrency self.annotations = annotations + self.run_dimensions = run_dimensions self.folder = folder @@ -20143,6 +20211,8 @@ class PipelineRun(Model): :ivar parameters: The full or partial list of parameter name, value pair used in the pipeline run. :vartype parameters: dict[str, str] + :ivar run_dimensions: Run dimensions emitted by Pipeline run. + :vartype run_dimensions: dict[str, str] :ivar invoked_by: Entity that started the pipeline run. :vartype invoked_by: ~azure.mgmt.datafactory.models.PipelineRunInvokedBy :ivar last_updated: The last updated timestamp for the pipeline run event @@ -20166,6 +20236,7 @@ class PipelineRun(Model): 'is_latest': {'readonly': True}, 'pipeline_name': {'readonly': True}, 'parameters': {'readonly': True}, + 'run_dimensions': {'readonly': True}, 'invoked_by': {'readonly': True}, 'last_updated': {'readonly': True}, 'run_start': {'readonly': True}, @@ -20182,6 +20253,7 @@ class PipelineRun(Model): 'is_latest': {'key': 'isLatest', 'type': 'bool'}, 'pipeline_name': {'key': 'pipelineName', 'type': 'str'}, 'parameters': {'key': 'parameters', 'type': '{str}'}, + 'run_dimensions': {'key': 'runDimensions', 'type': '{str}'}, 'invoked_by': {'key': 'invokedBy', 'type': 'PipelineRunInvokedBy'}, 'last_updated': {'key': 'lastUpdated', 'type': 'iso-8601'}, 'run_start': {'key': 'runStart', 'type': 'iso-8601'}, @@ -20199,6 +20271,7 @@ def __init__(self, *, additional_properties=None, **kwargs) -> None: self.is_latest = None self.pipeline_name = None self.parameters = None + self.run_dimensions = None self.invoked_by = None self.last_updated = None self.run_start = None @@ -27428,6 +27501,10 @@ class TriggerRun(Model): :ivar triggered_pipelines: List of pipeline name and run Id triggered by the trigger run. :vartype triggered_pipelines: dict[str, str] + :ivar run_dimension: Run dimension for which trigger was fired. + :vartype run_dimension: dict[str, str] + :ivar dependency_status: Status of the upstream pipelines. + :vartype dependency_status: dict[str, object] """ _validation = { @@ -27439,6 +27516,8 @@ class TriggerRun(Model): 'message': {'readonly': True}, 'properties': {'readonly': True}, 'triggered_pipelines': {'readonly': True}, + 'run_dimension': {'readonly': True}, + 'dependency_status': {'readonly': True}, } _attribute_map = { @@ -27451,6 +27530,8 @@ class TriggerRun(Model): 'message': {'key': 'message', 'type': 'str'}, 'properties': {'key': 'properties', 'type': '{str}'}, 'triggered_pipelines': {'key': 'triggeredPipelines', 'type': '{str}'}, + 'run_dimension': {'key': 'runDimension', 'type': '{str}'}, + 'dependency_status': {'key': 'dependencyStatus', 'type': '{object}'}, } def __init__(self, *, additional_properties=None, **kwargs) -> None: @@ -27464,6 +27545,8 @@ def __init__(self, *, additional_properties=None, **kwargs) -> None: self.message = None self.properties = None self.triggered_pipelines = None + self.run_dimension = None + self.dependency_status = None class TriggerRunsQueryResponse(Model):