Skip to content

feat: Add response_streaming_invoke_arn to outputs#756

Open
joaquingatica wants to merge 3 commits into
terraform-aws-modules:masterfrom
joaquingatica:master
Open

feat: Add response_streaming_invoke_arn to outputs#756
joaquingatica wants to merge 3 commits into
terraform-aws-modules:masterfrom
joaquingatica:master

Conversation

@joaquingatica

@joaquingatica joaquingatica commented Jun 3, 2026

Copy link
Copy Markdown

Description

Add lambda_function_response_streaming_invoke_arn output which is a direct forward of the existing aws_lambda_function.response_streaming_invoke_arn output.

Motivation and Context

As of now, if the Response Streaming Invoke ARN is needed outside of this module, it has to be derived from the invoke_arn when it should be able use the native output of the aws_lambda_function resource instead.

One example is when streaming responses from API Gateway, something similar to the following is needed to use as uri in an aws_api_gateway_integration when response_transfer_mode = "STREAM" is used:

resource "aws_api_gateway_integration" "myapi_resource_post" {
  # other attributes...
  response_transfer_mode  = "STREAM"
  uri = replace(
    replace(
      module.mylambda.lambda_function_invoke_arn,
      "2015-03-31", "2021-11-15"
    ),
    "/invocations", "/response-streaming-invocations"
  )
}

Instead, the following could be done when using the output added through this PR:

resource "aws_api_gateway_integration" "myapi_resource_post" {
  # other attributes...
  response_transfer_mode  = "STREAM"
  uri = module.mylambda.lambda_function_response_streaming_invoke_arn
}

The workaround is inspired by the suggestion in hashicorp/terraform-provider-aws#45649

Breaking Changes

How Has This Been Tested?

  • I have updated at least one of the examples/* to demonstrate and validate my change(s)
    • I updated examples/complete by adding a new output to it which forwards the module's output
    • Its README.md was updated accordingly via terraform-docs
  • I have tested and validated these changes using one or more of the provided examples/* projects
    • After performing terraform apply, the new output was printed to the CLI.
    • This is the relevant line (I replaced my AWS account number with XXXXXXXXXXXX):
      lambda_function_response_streaming_invoke_arn = "arn:aws:apigateway:eu-west-1:lambda:path/2021-11-15/functions/arn:aws:lambda:eu-west-1:XXXXXXXXXXXX:function:capable-crayfish-lambda1/response-streaming-invocations"
  • I have executed pre-commit run -a on my pull request

@joaquingatica joaquingatica changed the title feat: Add response_streaming_invoke_arn to outputs feat: Add response_streaming_invoke_arn to outputs Jun 3, 2026
@joaquingatica
joaquingatica marked this pull request as ready for review June 3, 2026 20:20
@joaquingatica

Copy link
Copy Markdown
Author

Do let me know if this qualifies as "significant work" as per the CONTRIBUTING.md guidelines and I'll happily open an Issue to track discussions.

I feel like it's small enough to not be considered significant, but could be wrong.

Thank you!

@github-actions

github-actions Bot commented Jul 5, 2026

Copy link
Copy Markdown

This PR has been automatically marked as stale because it has been open 30 days
with no activity. Remove stale label or comment or this PR will be closed in 10 days

@github-actions github-actions Bot added the stale label Jul 5, 2026
@joaquingatica

Copy link
Copy Markdown
Author

Still a relevant change, commenting to remove stale status.

@github-actions github-actions Bot removed the stale label Jul 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant