Skip to content
This repository has been archived by the owner on May 7, 2024. It is now read-only.

Telephonic signature PoC #96

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

skrisyuk
Copy link

@skrisyuk skrisyuk commented Feb 7, 2023

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.

@@ -65,14 +73,32 @@ private boolean processData(String data) {
return false;
}

AmazonDynamoDBClientBuilder builder = AmazonDynamoDBClientBuilder.standard();
Copy link
Contributor

Choose a reason for hiding this comment

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

Recommendation generated by Amazon CodeGuru Reviewer. Leave feedback on this recommendation by replying to the comment or by reacting to the comment using emoji.

If you don’t explicitly set an AWS region, the SDK consults the default region provider chain to try and determine the region to use. However, the resulting delay might lead to a poor cold-start. If code portability is not an issue, consider explicitly setting the AWS region using the withRegion() method.

Learn more

@@ -65,14 +73,32 @@ private boolean processData(String data) {
return false;
}

AmazonDynamoDBClientBuilder builder = AmazonDynamoDBClientBuilder.standard();
Copy link
Contributor

Choose a reason for hiding this comment

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

Recommendation generated by Amazon CodeGuru Reviewer. Leave feedback on this recommendation by replying to the comment or by reacting to the comment using emoji.

This code is written so that the client cannot be reused across invocations of the Lambda function.
To improve the performance of the Lambda function, consider using static initialization/constructor, global/static variables and singletons. It allows to keep alive and reuse HTTP connections that were established during a previous invocation.
Learn more about best practices for working with AWS Lambda functions.

@davelemons
Copy link
Contributor

Can you please provide more context/reasoning behind this change?

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.

3 participants