Skip to content

aws_sns_topic subscription is getting deleted abruptly  #64

Description

@hariprasath91

Describe the Bug

When we are trying to delete a identity in amazon , we are deleting the notification relation as well .
So when we does it , the sns subscription is also getting deleted.

resource "aws_sns_topic_subscription" "user_updates_email_target" {
topic_arn = aws_sns_topic.test_topic.arn
protocol  = "email"
endpoint  = "example@gmail.com"
}

resource "aws_sesv2_email_identity" "_example_com" {
 identity = "example.com"
}

resource "aws_ses_identity_notification_topic" "_example_com" {
 topic_arn = aws_sns_topic.test_topic.arn
 notification_type = "Bounce"
 identity = aws_sesv2_email_identity._example_com.identity
 include_original_headers = true
}

Expected Behavior

WE dont want the sns topic subscription to be deleted when we delete the sns for the specific domain.

Steps to Reproduce

Delete the resource - resource "aws_ses_identity_notification_topic" "_example_com
where the relevant subscription gets deleted.

Screenshots

No response

Environment

  • OS: Linux
    -Terraform version- v1.2.3

Additional Context

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    bug🐛 An issue with the system

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions