AWS CloudFormation
User Guide (Version )

AWS::DMS::ReplicationTask

The AWS::DMS::ReplicationTask resource creates an AWS DMS replication task.

Syntax

To declare this entity in your AWS CloudFormation template, use the following syntax:

JSON

{ "Type" : "AWS::DMS::ReplicationTask", "Properties" : { "CdcStartTime" : Double, "MigrationType" : String, "ReplicationInstanceArn" : String, "ReplicationTaskIdentifier" : String, "ReplicationTaskSettings" : String, "SourceEndpointArn" : String, "TableMappings" : String, "Tags" : [ Tag, ... ], "TargetEndpointArn" : String } }

YAML

Type: AWS::DMS::ReplicationTask Properties: CdcStartTime: Double MigrationType: String ReplicationInstanceArn: String ReplicationTaskIdentifier: String ReplicationTaskSettings: String SourceEndpointArn: String TableMappings: String Tags: - Tag TargetEndpointArn: String

Properties

CdcStartTime

Indicates the start time for a change data capture (CDC) operation.

Required: No

Type: Double

Update requires: No interruption

MigrationType

The migration type.

Required: Yes

Type: String

Allowed Values: cdc | full-load | full-load-and-cdc

Update requires: No interruption

ReplicationInstanceArn

The Amazon Resource Name (ARN) of the replication instance.

Required: Yes

Type: String

Update requires: Replacement

ReplicationTaskIdentifier

The replication task identifier.

Constraints:

  • Must contain from 1 to 255 alphanumeric characters or hyphens.

  • First character must be a letter.

  • Cannot end with a hyphen or contain two consecutive hyphens.

Required: No

Type: String

Update requires: No interruption

ReplicationTaskSettings

Settings for the task, such as target metadata settings. For a complete list of task settings, see Task Settings for AWS Database Migration Service Tasks in the AWS Database Migration User Guide.

Required: No

Type: String

Update requires: No interruption

SourceEndpointArn

The Amazon Resource Name (ARN) string that uniquely identifies the endpoint.

Required: Yes

Type: String

Update requires: Replacement

TableMappings

When using the AWS CLI or boto3, provide the path of the JSON file that contains the table mappings. Precede the path with "file://". When working with the DMS API, provide the JSON as the parameter value.

For example, --table-mappings file://mappingfile.json

Required: Yes

Type: String

Update requires: No interruption

Tags

Tags to be added to the replication instance.

Required: No

Type: List of Tag

Update requires: Replacement

TargetEndpointArn

The Amazon Resource Name (ARN) string that uniquely identifies the endpoint.

Required: Yes

Type: String

Update requires: Replacement

Return Values

Ref

When you pass the logical ID of this resource to the intrinsic Ref function, Ref returns the replication task ARN.

For more information about using the Ref function, see Ref.

Examples

JSON

{ "AWSTemplateFormatVersion": "2010-09-09", "Resources": { "myReplicationTask": { "Type": "AWS::DMS::ReplicationTask", "Properties": { "SourceEndpointArn": 11, "TargetEndpointArn": "12ff", "ReplicationInstanceArn": "ert1", "MigrationType": "full-load", "TableMappings": "{ \"rules\": [ { \"rule-type\": \"selection\", \"rule-id\": \"1\", \"rule-name\": \"1\", \"object-locator\": { \"schema-name\": \"%\", \"table-name\": \"%\" }, \"rule-action\": \"include\" } ] }" } } } }

YAML

AWSTemplateFormatVersion: 2010-09-09 Resources: myReplicationTask: Properties: MigrationType: full-load ReplicationInstanceArn: ReplicationInstance SourceEndpointArn: SourceEndpoint TableMappings: "{ \"rules\": [ { \"rule-type\": \"selection\", \"rule-id\": \"1\", \"rule-name\": \"1\", \"object-locator\": { \"schema-name\": \"%\", \"table-name\": \"%\" }, \"rule-action\": \"include\" } ] }" TargetEndpointArn: TargetEndpoint Type: "AWS::DMS::ReplicationTask"

See Also