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

New Serverless Pattern - Lambda s3 async onfailure terraform #2551

Open
wants to merge 5 commits into
base: main
Choose a base branch
from

Conversation

Sizk
Copy link
Contributor

@Sizk Sizk commented Dec 20, 2024

Issue #, if available:

Description of changes:

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@Sizk Sizk changed the title Lambda s3 async onfailure terraform New Serverless Pattern - Lambda s3 async onfailure terraform Dec 20, 2024
@@ -0,0 +1,73 @@
# Asynchronous Lambda with S3 Destination for Failed Invocations
Copy link
Contributor

Choose a reason for hiding this comment

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

Asynchronous AWS Lambda with Amazon S3 Destination for Failed Invocations

--function-name async_function \
--invocation-type Event \
--payload '{"forceError": true}' \
response.json
Copy link
Contributor

Choose a reason for hiding this comment

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

I am getting this error on mac while testing:
Invalid base64: "{"forceError": true}"


## Testing

1. Test successful execution (will still fail due to zero concurrency):
Copy link
Contributor

Choose a reason for hiding this comment

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

What is the purpose of using forceError flag? The concurrency is set to 0 simulate invocation failure?

@@ -0,0 +1,79 @@
{
"title": "Asynchronous Lambda with S3 Destination for Failed Invocations",
Copy link
Contributor

Choose a reason for hiding this comment

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

Asynchronous AWS Lambda with Amazon S3 Destination for Failed Invocations

@@ -0,0 +1,79 @@
{
"title": "Asynchronous Lambda with S3 Destination for Failed Invocations",
"description": "This pattern demonstrates how to set up an AWS Lambda function with asynchronous invocation and S3 destination for failed executions. It includes configuration for zero concurrency to test failure handling, and uses a random UUID for unique S3 bucket naming.",
Copy link
Contributor

Choose a reason for hiding this comment

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

The description should be <=150 char long.

{
"title": "Asynchronous Lambda with S3 Destination for Failed Invocations",
"description": "This pattern demonstrates how to set up an AWS Lambda function with asynchronous invocation and S3 destination for failed executions. It includes configuration for zero concurrency to test failure handling, and uses a random UUID for unique S3 bucket naming.",
"language": "HCL",
Copy link
Contributor

Choose a reason for hiding this comment

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

Supported values:
TypeScript,Node.js,Python,Java,Go,Rust,.NET,OpenAPI,YAML

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants