Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Modernize aws_sns_topic_subscription #14923

Merged

Conversation

nikhil-goenka
Copy link
Contributor

@nikhil-goenka nikhil-goenka commented Aug 31, 2020

Community Note

  • Please vote on this pull request by adding a 👍 reaction to the original pull request comment to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for pull request followers and do not help prioritize the request

Closes #12286, closes #17303, closes #17307

Release note for CHANGELOG:


Output from acceptance testing:

$ make testacc TESTARGS='-run=TestAccXXX'

...

@nikhil-goenka nikhil-goenka requested a review from a team August 31, 2020 15:33
@ghost ghost added size/XS Managed by automation to categorize the size of a PR. needs-triage Waiting for first response or review from a maintainer. documentation Introduces or discusses updates to documentation. service/sns Issues and PRs that pertain to the sns service. labels Aug 31, 2020
@nikhil-goenka
Copy link
Contributor Author

@bflad : Just an approach for email support on SNS, what are your thoughts ?

@nikhil-goenka nikhil-goenka changed the title Email support for sns subscription f/Email support for sns subscription Sep 12, 2020
@nikhil-goenka nikhil-goenka marked this pull request as draft September 16, 2020 15:24
@nikhil-goenka nikhil-goenka marked this pull request as ready for review September 18, 2020 17:35
Comment on lines 259 to 261
These are unsupported because the endpoint needs to be authorized and does not
generate an ARN until the target email address has been validated. This breaks
the Terraform model and as a result are not currently supported.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this paragraph also be removed as part of this PR?

Base automatically changed from master to main January 23, 2021 00:58
@breathingdust breathingdust requested a review from a team as a code owner January 23, 2021 00:58
@okgolove
Copy link

okgolove commented Feb 2, 2021

Any chances this one will be merged?

@YakDriver YakDriver self-assigned this Feb 18, 2021
@YakDriver
Copy link
Member

@nikhil-goenka Thank you for your work on this PR! I will be working on this before long. In order to expedite the process, I will likely make some changes. Make sure that you have checked the box "Allow edits from maintainers." (Don't worry though, you will receive all credit for your contribution and code!) Also, please coordinate with us before making any commits to this branch. Again, thank you for your help and we look forward to this popular addition to the AWS provider!

@nikhil-goenka
Copy link
Contributor Author

@nikhil-goenka Thank you for your work on this PR! I will be working on this before long. In order to expedite the process, I will likely make some changes. Make sure that you have checked the box "Allow edits from maintainers." (Don't worry though, you will receive all credit for your contribution and code!) Also, please coordinate with us before making any commits to this branch. Again, thank you for your help and we look forward to this popular addition to the AWS provider!

Thank you and will be great to see this branch getting merged, the box has been ticked.

@YakDriver YakDriver force-pushed the sns_topic_subscription-email-support branch from fa9a4aa to 7404ab2 Compare February 18, 2021 23:57
@YakDriver YakDriver removed the needs-triage Waiting for first response or review from a maintainer. label Feb 18, 2021
@ghost ghost added size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure. and removed size/XS Managed by automation to categorize the size of a PR. labels Feb 19, 2021
@YakDriver
Copy link
Member

YakDriver commented Feb 20, 2021

The biggest problem with email support is that unconfirmed subscriptions cannot be deleted / unsubscribed. My workaround is to remove the aws_sns_topic_subscription from the state, log a warning, and provide plenty of documentation for this issue. I'd love to get feedback on this approach.

NOTE: It's not a big issue for testing purposes since once the test topic is removed, SNS kills the associated subscriptions.

@YakDriver YakDriver changed the title f/Email support for sns subscription Modernize aws_sns_topic_subscription Feb 20, 2021
@YakDriver YakDriver force-pushed the sns_topic_subscription-email-support branch from 50da880 to 0171179 Compare February 25, 2021 15:06
@YakDriver YakDriver added this to the v3.30.0 milestone Feb 25, 2021
Copy link
Member

@YakDriver YakDriver left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great! Thanks for your work @nikhil-goenka and @chammock! 🎉

Acceptance tests in GovCloud:

--- SKIP: TestAccAWSSNSTopicSubscription_autoConfirmingSecuredEndpoint (1.28s)
--- SKIP: TestAccAWSSNSTopicSubscription_autoConfirmingEndpoint (1.28s)
--- PASS: TestAccAWSSNSTopicSubscription_email (18.14s)
--- PASS: TestAccAWSSNSTopicSubscription_basic (21.83s)
--- PASS: TestAccAWSSNSTopicSubscription_rawMessageDelivery (47.23s)
--- PASS: TestAccAWSSNSTopicSubscription_filterPolicy (48.52s)
--- PASS: TestAccAWSSNSTopicSubscription_deliveryPolicy (48.52s)
--- PASS: TestAccAWSSNSTopicSubscription_redrivePolicy (52.97s)
--- SKIP: TestAccAWSSNSTopicSubscription_firehose (53.93s)

On us-west-2:

--- PASS: TestAccAWSSNSTopicSubscription_email (14.93s)
--- PASS: TestAccAWSSNSTopicSubscription_basic (18.18s)
--- PASS: TestAccAWSSNSTopicSubscription_rawMessageDelivery (37.10s)
--- PASS: TestAccAWSSNSTopicSubscription_filterPolicy (37.97s)
--- PASS: TestAccAWSSNSTopicSubscription_deliveryPolicy (38.05s)
--- PASS: TestAccAWSSNSTopicSubscription_redrivePolicy (40.86s)
--- PASS: TestAccAWSSNSTopicSubscription_autoConfirmingEndpoint (41.26s)
--- PASS: TestAccAWSSNSTopicSubscription_autoConfirmingSecuredEndpoint (81.65s)
--- PASS: TestAccAWSSNSTopicSubscription_firehose (100.05s)

@ghost
Copy link

ghost commented Feb 26, 2021

This has been released in version 3.30.0 of the Terraform AWS provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template for triage. Thanks!

@ghost
Copy link

ghost commented Mar 28, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thanks!

@ghost ghost locked as resolved and limited conversation to collaborators Mar 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
documentation Introduces or discusses updates to documentation. service/sns Issues and PRs that pertain to the sns service. size/XL Managed by automation to categorize the size of a PR. tests PRs: expanded test coverage. Issues: expanded coverage, enhancements to test infrastructure.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sns_topic_subscription support firehose protocol Support email sns_topic_subscription
5 participants