AWS DMS Event Subscription
This page shows how to write Terraform and CloudFormation for AWS DMS Event Subscription and write them securely.
aws_dms_event_subscription (Terraform)
The Event Subscription in AWS DMS can be configured in Terraform with the resource name aws_dms_event_subscription
. The following sections describe 3 examples of how to use the resource and its parameters.
Example Usage from GitHub
resource "aws_dms_event_subscription" "this" {
enabled = var.enabled
event_categories = var.event_categories
name = var.name
sns_topic_arn = var.sns_topic_arn
source_ids = var.source_ids
resource "aws_dms_event_subscription" "this" {
count = var.create ? 1 : 0
name = var.name
event_categories = var.event_categories
sns_topic_arn = var.sns_topic_arn
resource "aws_dms_event_subscription" "example" {
enabled = true
event_categories = ["creation", "failure"]
name = "my-favorite-event-subscription"
sns_topic_arn = aws_sns_topic.example.arn
source_ids = [aws_dms_replication_task.example.replication_task_id]
Parameters
-
arn
optional computed - string -
enabled
optional - bool -
event_categories
required - set of string -
id
optional computed - string -
name
required - string -
sns_topic_arn
required - string -
source_ids
optional - set of string -
source_type
optional - string -
tags
optional - map from string to string -
timeouts
single block
Explanation in Terraform Registry
Provides a DMS (Data Migration Service) event subscription resource.
AWS::DMS::EventSubscription (CloudFormation)
The EventSubscription in DMS can be configured in CloudFormation with the resource name AWS::DMS::EventSubscription
. The following sections describe 10 examples of how to use the resource and its parameters.
Example Usage from GitHub
Type: AWS::DMS::EventSubscription
Description: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html
Properties:
SnsTopicArn: !Ref 'SnsTopicArn'
Type: AWS::DMS::EventSubscription
Description: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html
Properties:
SnsTopicArn: !Ref 'SnsTopicArn'
Type: AWS::DMS::EventSubscription
Description: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html
Properties:
SnsTopicArn: !Ref 'SnsTopicArn'
Type: AWS::DMS::EventSubscription
Description: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html
Properties:
SnsTopicArn: !Ref 'SnsTopicArn'
Type: AWS::DMS::EventSubscription
Description: http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html
Properties:
SnsTopicArn: !Ref 'SnsTopicArn'
"AWS::DMS::EventSubscription": {
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html",
"Properties": {
"SourceType": {
"Required": false,
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html#cfn-dms-eventsubscription-sourcetype",
"AWS::DMS::EventSubscription": {
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html",
"Properties": {
"SourceType": {
"Required": false,
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html#cfn-dms-eventsubscription-sourcetype",
"AWS::DMS::EventSubscription": {
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html",
"Properties": {
"SourceType": {
"Required": false,
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html#cfn-dms-eventsubscription-sourcetype",
"AWS::DMS::EventSubscription": {
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html",
"Properties": {
"SourceType": {
"Required": false,
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html#cfn-dms-eventsubscription-sourcetype",
"AWS::DMS::EventSubscription": {
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html",
"Properties": {
"SourceType": {
"Required": false,
"Documentation": "http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dms-eventsubscription.html#cfn-dms-eventsubscription-sourcetype",
Parameters
-
SourceType
optional - String -
EventCategories
optional - List -
Enabled
optional - Boolean -
SubscriptionName
optional - String -
SnsTopicArn
required - String -
SourceIds
optional - List -
Tags
optional - List of Tag
Explanation in CloudFormation Registry
Use the
AWS::DMS::EventSubscription
resource to get notifications for AWS Database Migration Service events through the Amazon Simple Notification Service. For more information, see Using AWS DMS Event Notification in the *AWS Database Migration Service User Guide.
Frequently asked questions
What is AWS DMS Event Subscription?
AWS DMS Event Subscription is a resource for DMS of Amazon Web Service. Settings can be wrote in Terraform and CloudFormation.
Where can I find the example code for the AWS DMS Event Subscription?
For Terraform, the niveklabs/aws, kleytonhsantos/terraform-aws-dms and afonsoaugusto/terraform-aws-s3-webapp source code examples are useful. See the Terraform Example section for further details.
For CloudFormation, the awslabs/aws-service-catalog-products, awslabs/aws-service-catalog-products and awslabs/aws-service-catalog-products source code examples are useful. See the CloudFormation Example section for further details.