Skip to content

Resource: awsDmsEventSubscription

Provides a DMS (Data Migration Service) event subscription resource.

Example Usage

/*Provider bindings are generated by running cdktf get.
See https://cdk.tf/provider-generation for more details.*/
import * as aws from "./.gen/providers/aws";
new aws.dmsEventSubscription.DmsEventSubscription(this, "example", {
  enabled: true,
  eventCategories: ["creation", "failure"],
  name: "my-favorite-event-subscription",
  snsTopicArn: "${aws_sns_topic.example.arn}",
  sourceIds: ["${aws_dms_replication_task.example.replication_task_id}"],
  sourceType: "replication-task",
  tags: {
    Name: "example",
  },
});

Argument Reference

The following arguments are supported:

  • name - (Required) Name of event subscription.
  • enabled - (Optional, Default: true) Whether the event subscription should be enabled.
  • eventCategories - (Optional) List of event categories to listen for, see describeEventCategories for a canonical list.
  • sourceType - (Optional, Default: all events) Type of source for events. Valid values: replicationInstance or replicationTask
  • sourceIds - (Required) Ids of sources to listen to.
  • snsTopicArn - (Required) SNS topic arn to send events on.
  • tags - (Optional) Map of resource tags to assign to the resource. If configured with a provider defaultTags configuration block present, tags with matching keys will overwrite those defined at the provider-level.

Attributes Reference

In addition to all arguments above, the following attributes are exported:

  • arn - Amazon Resource Name (ARN) of the DMS Event Subscription.
  • tagsAll - A map of tags assigned to the resource, including those inherited from the provider defaultTags configuration block.

Timeouts

Configuration options:

  • create - (Default 10M)
  • update - (Default 10M)
  • delete - (Default 10M)

Import

Event subscriptions can be imported using the name, e.g.,

$ terraform import aws_dms_event_subscription.test my-awesome-event-subscription