PipelineDefinition class

Provides a DataPipeline Pipeline Definition resource.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const _default = new aws.datapipeline.Pipeline("default", {name: "tf-pipeline-default"});
const example = new aws.datapipeline.PipelineDefinition("example", {
    pipelineObjects: [
        {
            fields: [{
                key: "workerGroup",
                stringValue: "workerGroup",
            }],
            id: "Default",
            name: "Default",
        },
        {
            fields: [
                {
                    key: "startDateTime",
                    stringValue: "2012-12-12T00:00:00",
                },
                {
                    key: "type",
                    stringValue: "Schedule",
                },
                {
                    key: "period",
                    stringValue: "1 hour",
                },
                {
                    key: "endDateTime",
                    stringValue: "2012-12-21T18:00:00",
                },
            ],
            id: "Schedule",
            name: "Schedule",
        },
        {
            fields: [
                {
                    key: "type",
                    stringValue: "ShellCommandActivity",
                },
                {
                    key: "command",
                    stringValue: "echo hello",
                },
                {
                    key: "parent",
                    stringValue: "Default",
                },
                {
                    key: "schedule",
                    stringValue: "Schedule",
                },
            ],
            id: "SayHello",
            name: "SayHello",
        },
    ],
    pipelineId: _default.id,
});
import pulumi
import pulumi_aws as aws

default = aws.datapipeline.Pipeline("default", name="tf-pipeline-default")
example = aws.datapipeline.PipelineDefinition("example",
    pipeline_objects=[
        {
            "fields": [{
                "key": "workerGroup",
                "string_value": "workerGroup",
            }],
            "id": "Default",
            "name": "Default",
        },
        {
            "fields": [
                {
                    "key": "startDateTime",
                    "string_value": "2012-12-12T00:00:00",
                },
                {
                    "key": "type",
                    "string_value": "Schedule",
                },
                {
                    "key": "period",
                    "string_value": "1 hour",
                },
                {
                    "key": "endDateTime",
                    "string_value": "2012-12-21T18:00:00",
                },
            ],
            "id": "Schedule",
            "name": "Schedule",
        },
        {
            "fields": [
                {
                    "key": "type",
                    "string_value": "ShellCommandActivity",
                },
                {
                    "key": "command",
                    "string_value": "echo hello",
                },
                {
                    "key": "parent",
                    "string_value": "Default",
                },
                {
                    "key": "schedule",
                    "string_value": "Schedule",
                },
            ],
            "id": "SayHello",
            "name": "SayHello",
        },
    ],
    pipeline_id=default.id)
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Aws = Pulumi.Aws;

return await Deployment.RunAsync(() =>
{
    var @default = new Aws.DataPipeline.Pipeline("default", new()
    {
        Name = "tf-pipeline-default",
    });

    var example = new Aws.DataPipeline.PipelineDefinition("example", new()
    {
        PipelineObjects = new[]
        {
            new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectArgs
            {
                Fields = new[]
                {
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "workerGroup",
                        StringValue = "workerGroup",
                    },
                },
                Id = "Default",
                Name = "Default",
            },
            new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectArgs
            {
                Fields = new[]
                {
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "startDateTime",
                        StringValue = "2012-12-12T00:00:00",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "type",
                        StringValue = "Schedule",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "period",
                        StringValue = "1 hour",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "endDateTime",
                        StringValue = "2012-12-21T18:00:00",
                    },
                },
                Id = "Schedule",
                Name = "Schedule",
            },
            new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectArgs
            {
                Fields = new[]
                {
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "type",
                        StringValue = "ShellCommandActivity",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "command",
                        StringValue = "echo hello",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "parent",
                        StringValue = "Default",
                    },
                    new Aws.DataPipeline.Inputs.PipelineDefinitionPipelineObjectFieldArgs
                    {
                        Key = "schedule",
                        StringValue = "Schedule",
                    },
                },
                Id = "SayHello",
                Name = "SayHello",
            },
        },
        PipelineId = @default.Id,
    });

});
package main

import (
	"github.com/pulumi/pulumi-aws/sdk/v7/go/aws/datapipeline"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_default, err := datapipeline.NewPipeline(ctx, "default", &datapipeline.PipelineArgs{
			Name: pulumi.String("tf-pipeline-default"),
		})
		if err != nil {
			return err
		}
		_, err = datapipeline.NewPipelineDefinition(ctx, "example", &datapipeline.PipelineDefinitionArgs{
			PipelineObjects: datapipeline.PipelineDefinitionPipelineObjectArray{
				&datapipeline.PipelineDefinitionPipelineObjectArgs{
					Fields: datapipeline.PipelineDefinitionPipelineObjectFieldArray{
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("workerGroup"),
							StringValue: pulumi.String("workerGroup"),
						},
					},
					Id:   pulumi.String("Default"),
					Name: pulumi.String("Default"),
				},
				&datapipeline.PipelineDefinitionPipelineObjectArgs{
					Fields: datapipeline.PipelineDefinitionPipelineObjectFieldArray{
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("startDateTime"),
							StringValue: pulumi.String("2012-12-12T00:00:00"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("type"),
							StringValue: pulumi.String("Schedule"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("period"),
							StringValue: pulumi.String("1 hour"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("endDateTime"),
							StringValue: pulumi.String("2012-12-21T18:00:00"),
						},
					},
					Id:   pulumi.String("Schedule"),
					Name: pulumi.String("Schedule"),
				},
				&datapipeline.PipelineDefinitionPipelineObjectArgs{
					Fields: datapipeline.PipelineDefinitionPipelineObjectFieldArray{
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("type"),
							StringValue: pulumi.String("ShellCommandActivity"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("command"),
							StringValue: pulumi.String("echo hello"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("parent"),
							StringValue: pulumi.String("Default"),
						},
						&datapipeline.PipelineDefinitionPipelineObjectFieldArgs{
							Key:         pulumi.String("schedule"),
							StringValue: pulumi.String("Schedule"),
						},
					},
					Id:   pulumi.String("SayHello"),
					Name: pulumi.String("SayHello"),
				},
			},
			PipelineId: _default.ID().ToIDOutput().ToStringOutput(),
		})
		if err != nil {
			return err
		}
		return nil
	})
}
pulumi {
  required_providers {
    aws = {
      source = "pulumi/aws"
    }
  }
}

resource "aws_datapipeline_pipeline" "default" {
  name = "tf-pipeline-default"
}
resource "aws_datapipeline_pipelinedefinition" "example" {
  pipeline_objects {
    fields {
      key          = "workerGroup"
      string_value = "workerGroup"
    }
    id   = "Default"
    name = "Default"
  }
  pipeline_objects {
    fields {
      key          = "startDateTime"
      string_value = "2012-12-12T00:00:00"
    }
    fields {
      key          = "type"
      string_value = "Schedule"
    }
    fields {
      key          = "period"
      string_value = "1 hour"
    }
    fields {
      key          = "endDateTime"
      string_value = "2012-12-21T18:00:00"
    }
    id   = "Schedule"
    name = "Schedule"
  }
  pipeline_objects {
    fields {
      key          = "type"
      string_value = "ShellCommandActivity"
    }
    fields {
      key          = "command"
      string_value = "echo hello"
    }
    fields {
      key          = "parent"
      string_value = "Default"
    }
    fields {
      key          = "schedule"
      string_value = "Schedule"
    }
    id   = "SayHello"
    name = "SayHello"
  }
  pipeline_id = aws_datapipeline_pipeline.default.id
}
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.aws.datapipeline.Pipeline;
import com.pulumi.aws.datapipeline.PipelineArgs;
import com.pulumi.aws.datapipeline.PipelineDefinition;
import com.pulumi.aws.datapipeline.PipelineDefinitionArgs;
import com.pulumi.aws.datapipeline.inputs.PipelineDefinitionPipelineObjectArgs;
import com.pulumi.aws.datapipeline.inputs.PipelineDefinitionPipelineObjectFieldArgs;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        var default_ = new Pipeline("default", PipelineArgs.builder()
            .name("tf-pipeline-default")
            .build());

        var example = new PipelineDefinition("example", PipelineDefinitionArgs.builder()
            .pipelineObjects(
                PipelineDefinitionPipelineObjectArgs.builder()
                    .fields(PipelineDefinitionPipelineObjectFieldArgs.builder()
                        .key("workerGroup")
                        .stringValue("workerGroup")
                        .build())
                    .id("Default")
                    .name("Default")
                    .build(),
                PipelineDefinitionPipelineObjectArgs.builder()
                    .fields(
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("startDateTime")
                            .stringValue("2012-12-12T00:00:00")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("type")
                            .stringValue("Schedule")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("period")
                            .stringValue("1 hour")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("endDateTime")
                            .stringValue("2012-12-21T18:00:00")
                            .build())
                    .id("Schedule")
                    .name("Schedule")
                    .build(),
                PipelineDefinitionPipelineObjectArgs.builder()
                    .fields(
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("type")
                            .stringValue("ShellCommandActivity")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("command")
                            .stringValue("echo hello")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("parent")
                            .stringValue("Default")
                            .build(),
                        PipelineDefinitionPipelineObjectFieldArgs.builder()
                            .key("schedule")
                            .stringValue("Schedule")
                            .build())
                    .id("SayHello")
                    .name("SayHello")
                    .build())
            .pipelineId(default_.id())
            .build());

    }
}
resources:
  default:
    type: aws:datapipeline:Pipeline
    properties:
      name: tf-pipeline-default
  example:
    type: aws:datapipeline:PipelineDefinition
    properties:
      pipelineObjects:
        - fields:
            - key: workerGroup
              stringValue: workerGroup
          id: Default
          name: Default
        - fields:
            - key: startDateTime
              stringValue: 2012-12-12T00:00:00
            - key: type
              stringValue: Schedule
            - key: period
              stringValue: 1 hour
            - key: endDateTime
              stringValue: 2012-12-21T18:00:00
          id: Schedule
          name: Schedule
        - fields:
            - key: type
              stringValue: ShellCommandActivity
            - key: command
              stringValue: echo hello
            - key: parent
              stringValue: Default
            - key: schedule
              stringValue: Schedule
          id: SayHello
          name: SayHello
      pipelineId: ${default.id}

Import

Using pulumi import, import aws.datapipeline.PipelineDefinition using the id. For example:

$ pulumi import aws:datapipeline/pipelineDefinition:PipelineDefinition example df-1234567890

Constructors

PipelineDefinition(String name, {PipelineDefinitionArgs? args, CustomResourceOptions? options})
Creates a new PipelineDefinition. name The Pulumi resource name. args Arguments used to configure this PipelineDefinition. The set of arguments for PipelineDefinition. options Resource options controlling this resource's behavior.
PipelineDefinition.reference(String urn)
Creates a typed reference to an existing PipelineDefinition resource.

Properties

childResources → Set<Resource>
finalinherited
completionSources ↔ Map<String, IOutputCompletionSource>
latefinalinherited
hashCode → int
The hash code for this object.
no setterinherited
id ↔ Output<String>
getter/setter pairinherited
isCustom → bool
Returns whether this resource is provider-managed.
no setterinherited
isProtected → bool
Returns whether this resource is protected from deletion.
no setterinherited
isRemote → bool
Whether this resource is registered as remote.
no setterinherited
isResourceReference → bool
Whether this instance represents a resource value returned over RPC.
finalinherited
parameterObjects ↔ Output<List<PipelineDefinitionParameterObject>?>
Configuration block for the parameter objects used in the pipeline definition. See below
latefinal
parameterValues ↔ Output<List<PipelineDefinitionParameterValue>?>
Configuration block for the parameter values used in the pipeline definition. See below
latefinal
pipelineId ↔ Output<String>
ID of the pipeline.
latefinal
pipelineObjects ↔ Output<List<PipelineDefinitionPipelineObject>>
Configuration block for the objects that define the pipeline. See below
latefinal
region ↔ Output<String>
Region where this resource will be managed. Defaults to the Region set in the provider configuration.
latefinal
resourceTransforms → List<ResourceTransform>
Inherited/explicit async transforms.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
transformations → List<ResourceTransformation>
Inherited/explicit legacy transformations.
no setterinherited
urn ↔ Output<String>
latefinalinherited

Methods

failId(Object error) → void
Completes this resource ID with an error when registration fails.
inherited
failOutputs(Object error) → void
Completes all output properties with error.
inherited
failUrn(Object error) → void
Completes this resource URN with an error when registration fails.
inherited
getProvider(String moduleMember) → ProviderResource?
Returns provider for moduleMember's package, if configured.
inherited
getResourceName() → String
Returns this resource's logical name.
inherited
getResourceType() → String
Returns this resource's Pulumi type token.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
registerOutput<T>(String propertyName, {Object? decoder(Object?)?, bool isSecret = false}) → Output<T>
Registers a dynamic output property for this resource.
inherited
resolveId(String? value, {required bool isKnown}) → void
Resolves the provider-assigned ID for this resource.
inherited
resolveOutputs(Struct outputs) → void
Resolves all output properties from a monitor response payload.
inherited
resolveUrn(String value) → void
Resolves this resource's URN once assigned by the engine.
inherited
serializeProperties(Map<String, dynamic> properties) → Future<Struct>
Serializes resource properties for RPC transmission.
inherited
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited

Static Methods

get(String name, Input<String> id, {PipelineDefinitionState? state, CustomResourceOptions? options}) → PipelineDefinition
Gets an existing PipelineDefinition resource's state with the given name and id.