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

feat: Accept new arguments function_response_types in aws_lambda_event_source_mapping #255

Conversation

keng000
Copy link
Contributor

@keng000 keng000 commented Jan 21, 2022

Description

I added an optional argument in aws_lambda_event_source_mapping definition.

Motivation and Context

#254

Breaking Changes

No breaking changes that the new line I added in this PR is optional argument.

How Has This Been Tested?

  • I have tested and validated these changes using one or more of the provided examples/* projects

I used examples/event-source-mapping/main.tf for testing.
First I applied it before this change, and then I added a new configuration in the example such as below.

event_source_mapping = {
    sqs = {
      event_source_arn = aws_sqs_queue.this.arn
      function_response_types = ["ReportBatchItemFailures"] # added this line
    }
    dynamodb = {
  ...

After that, I applied again and got as below.

Terraform will perform the following actions:

  # module.lambda_function.aws_lambda_event_source_mapping.this["sqs"] will be updated in-place
  ~ resource "aws_lambda_event_source_mapping" "this" {
      ~ function_response_types            = [
          + "ReportBatchItemFailures",
        ]
        id                                 = "e535db8a-1f87-4c5c-a0c7-611b6eaea024"
        # (17 unchanged attributes hidden)
    }

  # module.lambda_function.null_resource.archive[0] must be replaced
-/+ resource "null_resource" "archive" {
      ~ id       = "5022921647598251107" -> (known after apply)
      ~ triggers = { # forces replacement
          ~ "timestamp" = "1642698462516710000" -> "1642759069961922000"
            # (1 unchanged element hidden)
        }
    }

Plan: 1 to add, 1 to change, 1 to destroy.

@keng000 keng000 changed the title accept new arguments function_response_types in aws_lambda_event_source_mapping feat: accept new arguments function_response_types in aws_lambda_event_source_mapping Jan 21, 2022
@keng000 keng000 changed the title feat: accept new arguments function_response_types in aws_lambda_event_source_mapping feat: Accept new arguments function_response_types in aws_lambda_event_source_mapping Jan 21, 2022
@keng000 keng000 closed this Jan 21, 2022
@keng000 keng000 reopened this Jan 21, 2022
@antonbabenko antonbabenko merged commit 1fda108 into terraform-aws-modules:master Jan 21, 2022
antonbabenko pushed a commit that referenced this pull request Jan 21, 2022
## [2.33.0](v2.32.0...v2.33.0) (2022-01-21)

### Features

* Accept new arguments `function_response_types` in `aws_lambda_event_source_mapping` ([#255](#255)) ([1fda108](1fda108))
@antonbabenko
Copy link
Member

This PR is included in version 2.33.0 🎉

@github-actions
Copy link

github-actions bot commented Nov 8, 2022

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Nov 8, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants