Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[AutoPR Microsoft.Azure.Management.DataFactory] Chainingtrigger #163

Merged
Show file tree
Hide file tree
Changes from all commits
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
Original file line number Diff line number Diff line change
@@ -0,0 +1,126 @@
// <auto-generated>
// 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.
// </auto-generated>

namespace Microsoft.Azure.Management.DataFactory.Models
{
using Microsoft.Rest;
using Microsoft.Rest.Serialization;
using Newtonsoft.Json;
using System.Collections;
using System.Collections.Generic;
using System.Linq;

/// <summary>
/// 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.
/// </summary>
[Rest.Serialization.JsonTransformation]
public partial class ChainingTrigger : Trigger
{
/// <summary>
/// Initializes a new instance of the ChainingTrigger class.
/// </summary>
public ChainingTrigger()
{
Pipeline = new TriggerPipelineReference();
CustomInit();
}

/// <summary>
/// Initializes a new instance of the ChainingTrigger class.
/// </summary>
/// <param name="pipeline">Pipeline for which runs are created when all
/// upstream pipelines complete successfully.</param>
/// <param name="dependsOn">Upstream Pipelines.</param>
/// <param name="runDimension">Run Dimension property that needs to be
/// emitted by upstream pipelines.</param>
/// <param name="additionalProperties">Unmatched properties from the
/// message are deserialized this collection</param>
/// <param name="description">Trigger description.</param>
/// <param name="runtimeState">Indicates if trigger is running or not.
/// Updated when Start/Stop APIs are called on the Trigger. Possible
/// values include: 'Started', 'Stopped', 'Disabled'</param>
/// <param name="annotations">List of tags that can be used for
/// describing the trigger.</param>
public ChainingTrigger(TriggerPipelineReference pipeline, IList<PipelineReference> dependsOn, string runDimension, IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string description = default(string), string runtimeState = default(string), IList<object> annotations = default(IList<object>))
: base(additionalProperties, description, runtimeState, annotations)
{
Pipeline = pipeline;
DependsOn = dependsOn;
RunDimension = runDimension;
CustomInit();
}

/// <summary>
/// An initialization method that performs custom operations like setting defaults
/// </summary>
partial void CustomInit();

/// <summary>
/// Gets or sets pipeline for which runs are created when all upstream
/// pipelines complete successfully.
/// </summary>
[JsonProperty(PropertyName = "pipeline")]
public TriggerPipelineReference Pipeline { get; set; }

/// <summary>
/// Gets or sets upstream Pipelines.
/// </summary>
[JsonProperty(PropertyName = "typeProperties.dependsOn")]
public IList<PipelineReference> DependsOn { get; set; }

/// <summary>
/// Gets or sets run Dimension property that needs to be emitted by
/// upstream pipelines.
/// </summary>
[JsonProperty(PropertyName = "typeProperties.runDimension")]
public string RunDimension { get; set; }

/// <summary>
/// Validate the object.
/// </summary>
/// <exception cref="ValidationException">
/// Thrown if validation fails
/// </exception>
public virtual void Validate()
{
if (Pipeline == null)
{
throw new ValidationException(ValidationRules.CannotBeNull, "Pipeline");
}
if (DependsOn == null)
{
throw new ValidationException(ValidationRules.CannotBeNull, "DependsOn");
}
if (RunDimension == null)
{
throw new ValidationException(ValidationRules.CannotBeNull, "RunDimension");
}
if (Pipeline != null)
{
Pipeline.Validate();
}
if (DependsOn != null)
{
foreach (var element in DependsOn)
{
if (element != null)
{
element.Validate();
}
}
}
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,10 @@ public PipelineResource()
/// pipeline.</param>
/// <param name="annotations">List of tags that can be used for
/// describing the Pipeline.</param>
/// <param name="runDimensions">Dimensions emitted by Pipeline.</param>
/// <param name="folder">The folder that this Pipeline is in. If not
/// specified, Pipeline will appear at the root level.</param>
public PipelineResource(string id = default(string), string name = default(string), string type = default(string), string etag = default(string), IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string description = default(string), IList<Activity> activities = default(IList<Activity>), IDictionary<string, ParameterSpecification> parameters = default(IDictionary<string, ParameterSpecification>), IDictionary<string, VariableSpecification> variables = default(IDictionary<string, VariableSpecification>), int? concurrency = default(int?), IList<object> annotations = default(IList<object>), PipelineFolder folder = default(PipelineFolder))
public PipelineResource(string id = default(string), string name = default(string), string type = default(string), string etag = default(string), IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string description = default(string), IList<Activity> activities = default(IList<Activity>), IDictionary<string, ParameterSpecification> parameters = default(IDictionary<string, ParameterSpecification>), IDictionary<string, VariableSpecification> variables = default(IDictionary<string, VariableSpecification>), int? concurrency = default(int?), IList<object> annotations = default(IList<object>), IDictionary<string, object> runDimensions = default(IDictionary<string, object>), PipelineFolder folder = default(PipelineFolder))
: base(id, name, type, etag)
{
AdditionalProperties = additionalProperties;
Expand All @@ -60,6 +61,7 @@ public PipelineResource()
Variables = variables;
Concurrency = concurrency;
Annotations = annotations;
RunDimensions = runDimensions;
Folder = folder;
CustomInit();
}
Expand Down Expand Up @@ -113,6 +115,12 @@ public PipelineResource()
[JsonProperty(PropertyName = "properties.annotations")]
public IList<object> Annotations { get; set; }

/// <summary>
/// Gets or sets dimensions emitted by Pipeline.
/// </summary>
[JsonProperty(PropertyName = "properties.runDimensions")]
public IDictionary<string, object> RunDimensions { get; set; }

/// <summary>
/// Gets or sets the folder that this Pipeline is in. If not specified,
/// Pipeline will appear at the root level.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,8 @@ public PipelineRun()
/// <param name="pipelineName">The pipeline name.</param>
/// <param name="parameters">The full or partial list of parameter
/// name, value pair used in the pipeline run.</param>
/// <param name="runDimensions">Run dimensions emitted by Pipeline
/// run.</param>
/// <param name="invokedBy">Entity that started the pipeline
/// run.</param>
/// <param name="lastUpdated">The last updated timestamp for the
Expand All @@ -52,14 +54,15 @@ public PipelineRun()
/// <param name="durationInMs">The duration of a pipeline run.</param>
/// <param name="status">The status of a pipeline run.</param>
/// <param name="message">The message from a pipeline run.</param>
public PipelineRun(IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string runId = default(string), string runGroupId = default(string), bool? isLatest = default(bool?), string pipelineName = default(string), IDictionary<string, string> parameters = default(IDictionary<string, string>), PipelineRunInvokedBy invokedBy = default(PipelineRunInvokedBy), System.DateTime? lastUpdated = default(System.DateTime?), System.DateTime? runStart = default(System.DateTime?), System.DateTime? runEnd = default(System.DateTime?), int? durationInMs = default(int?), string status = default(string), string message = default(string))
public PipelineRun(IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string runId = default(string), string runGroupId = default(string), bool? isLatest = default(bool?), string pipelineName = default(string), IDictionary<string, string> parameters = default(IDictionary<string, string>), IDictionary<string, string> runDimensions = default(IDictionary<string, string>), PipelineRunInvokedBy invokedBy = default(PipelineRunInvokedBy), System.DateTime? lastUpdated = default(System.DateTime?), System.DateTime? runStart = default(System.DateTime?), System.DateTime? runEnd = default(System.DateTime?), int? durationInMs = default(int?), string status = default(string), string message = default(string))
{
AdditionalProperties = additionalProperties;
RunId = runId;
RunGroupId = runGroupId;
IsLatest = isLatest;
PipelineName = pipelineName;
Parameters = parameters;
RunDimensions = runDimensions;
InvokedBy = invokedBy;
LastUpdated = lastUpdated;
RunStart = runStart;
Expand Down Expand Up @@ -115,6 +118,12 @@ public PipelineRun()
[JsonProperty(PropertyName = "parameters")]
public IDictionary<string, string> Parameters { get; private set; }

/// <summary>
/// Gets run dimensions emitted by Pipeline run.
/// </summary>
[JsonProperty(PropertyName = "runDimensions")]
public IDictionary<string, string> RunDimensions { get; private set; }

/// <summary>
/// Gets entity that started the pipeline run.
/// </summary>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,11 @@ public TriggerRun()
/// trigger run. Name, value pair depends on type of trigger.</param>
/// <param name="triggeredPipelines">List of pipeline name and run Id
/// triggered by the trigger run.</param>
public TriggerRun(IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string triggerRunId = default(string), string triggerName = default(string), string triggerType = default(string), System.DateTime? triggerRunTimestamp = default(System.DateTime?), string status = default(string), string message = default(string), IDictionary<string, string> properties = default(IDictionary<string, string>), IDictionary<string, string> triggeredPipelines = default(IDictionary<string, string>))
/// <param name="runDimension">Run dimension for which trigger was
/// fired.</param>
/// <param name="dependencyStatus">Status of the upstream
/// pipelines.</param>
public TriggerRun(IDictionary<string, object> additionalProperties = default(IDictionary<string, object>), string triggerRunId = default(string), string triggerName = default(string), string triggerType = default(string), System.DateTime? triggerRunTimestamp = default(System.DateTime?), string status = default(string), string message = default(string), IDictionary<string, string> properties = default(IDictionary<string, string>), IDictionary<string, string> triggeredPipelines = default(IDictionary<string, string>), IDictionary<string, string> runDimension = default(IDictionary<string, string>), IDictionary<string, object> dependencyStatus = default(IDictionary<string, object>))
{
AdditionalProperties = additionalProperties;
TriggerRunId = triggerRunId;
Expand All @@ -55,6 +59,8 @@ public TriggerRun()
Message = message;
Properties = properties;
TriggeredPipelines = triggeredPipelines;
RunDimension = runDimension;
DependencyStatus = dependencyStatus;
CustomInit();
}

Expand Down Expand Up @@ -120,5 +126,17 @@ public TriggerRun()
[JsonProperty(PropertyName = "triggeredPipelines")]
public IDictionary<string, string> TriggeredPipelines { get; private set; }

/// <summary>
/// Gets run dimension for which trigger was fired.
/// </summary>
[JsonProperty(PropertyName = "runDimension")]
public IDictionary<string, string> RunDimension { get; private set; }

/// <summary>
/// Gets status of the upstream pipelines.
/// </summary>
[JsonProperty(PropertyName = "dependencyStatus")]
public IDictionary<string, object> DependencyStatus { get; private set; }

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -36,16 +36,5 @@ public static IEnumerable<Tuple<string, string, string>> ApiInfo_DataFactoryMana
}.AsEnumerable();
}
}
// BEGIN: Code Generation Metadata Section
public static readonly String AutoRestVersion = "latest";
public static readonly String AutoRestBootStrapperVersion = "[email protected]";
public static readonly String AutoRestCmdExecuted = "cmd.exe /c autorest.cmd https://github.com/Azure/azure-rest-api-specs/blob/master/specification/datafactory/resource-manager/readme.md --csharp --version=latest --reflect-api-versions --tag=package-2018-06 --csharp-sdks-folder=C:\\azure-sdk-for-net\\sdk";
public static readonly String GithubForkName = "Azure";
public static readonly String GithubBranchName = "master";
public static readonly String GithubCommidId = "fb8f078deac2367f3dbcfbd8a542c77083c28a5b";
public static readonly String CodeGenerationErrors = "";
public static readonly String GithubRepoName = "azure-rest-api-specs";
// END: Code Generation Metadata Section
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,10 @@ public partial interface IServiceTagsOperations
/// Gets a list of service tag information resources.
/// </summary>
/// <param name='location'>
/// The location.
/// The location that will be used as a reference for version (not as a
/// filter based on location, you will get the list of service tags
/// with prefix details across all regions but limited to the cloud
/// that your subscription belongs to).
/// </param>
/// <param name='customHeaders'>
/// The headers that will be added to request.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,16 +108,5 @@ public static IEnumerable<Tuple<string, string, string>> ApiInfo_NetworkManageme
}.AsEnumerable();
}
}
// BEGIN: Code Generation Metadata Section
public static readonly String AutoRestVersion = "latest";
public static readonly String AutoRestBootStrapperVersion = "[email protected]";
public static readonly String AutoRestCmdExecuted = "cmd.exe /c autorest.cmd https://github.com/Azure/azure-rest-api-specs/blob/master/specification/network/resource-manager/readme.md --csharp --version=latest --reflect-api-versions --csharp-sdks-folder=D:\\Projects\\azure-sdk-for-net\\sdk";
public static readonly String GithubForkName = "Azure";
public static readonly String GithubBranchName = "master";
public static readonly String GithubCommidId = "9dacca31bc76fc9cc1f59ee62ed1ab1c8f0d61c6";
public static readonly String CodeGenerationErrors = "";
public static readonly String GithubRepoName = "azure-rest-api-specs";
// END: Code Generation Metadata Section
}
}

Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,10 @@ internal ServiceTagsOperations(NetworkManagementClient client)
/// Gets a list of service tag information resources.
/// </summary>
/// <param name='location'>
/// The location.
/// The location that will be used as a reference for version (not as a filter
/// based on location, you will get the list of service tags with prefix
/// details across all regions but limited to the cloud that your subscription
/// belongs to).
/// </param>
/// <param name='customHeaders'>
/// Headers that will be added to request.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,10 @@ public static partial class ServiceTagsOperationsExtensions
/// The operations group for this extension method.
/// </param>
/// <param name='location'>
/// The location.
/// The location that will be used as a reference for version (not as a filter
/// based on location, you will get the list of service tags with prefix
/// details across all regions but limited to the cloud that your subscription
/// belongs to).
/// </param>
public static ServiceTagsListResult List(this IServiceTagsOperations operations, string location)
{
Expand All @@ -42,7 +45,10 @@ public static ServiceTagsListResult List(this IServiceTagsOperations operations,
/// The operations group for this extension method.
/// </param>
/// <param name='location'>
/// The location.
/// The location that will be used as a reference for version (not as a filter
/// based on location, you will get the list of service tags with prefix
/// details across all regions but limited to the cloud that your subscription
/// belongs to).
/// </param>
/// <param name='cancellationToken'>
/// The cancellation token.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// <auto-generated>
// 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.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// <auto-generated>
// 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.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// <auto-generated>
// 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.
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
// <auto-generated>
// 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.
Expand Down
Loading