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: add lambda configuration #427

Merged
merged 2 commits into from
Apr 26, 2023
Merged

feat: add lambda configuration #427

merged 2 commits into from
Apr 26, 2023

Conversation

malandis
Copy link
Contributor

@malandis malandis commented Apr 26, 2023

Adds a configuration optimized for Lambda environments. This is the
same as the InRegion.Default config but also eagerly connects the
client. This avoids the cold start penalty from before where we
established the connection on the first request, leading to
first-request timeouts.

Adds a configuration optimized for Lambda environments. This is the
same as the `InRegion.LowLatency` config but also eagerly connects the
client. This avoids the cold start penalty from before where we
established the connection on the first request, leading to
first-request timeouts.
@malandis malandis requested a review from cprice404 April 26, 2023 18:23
/// <returns></returns>
public static IConfiguration Latest(ILoggerFactory? loggerFactory = null)
{
var config = LowLatency.V1(loggerFactory);
Copy link
Contributor

Choose a reason for hiding this comment

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

I think maybe you should go with InRegion.Default rather than InRegion.LowLatency. I don't think lambdas are guaranteed to have great networking traits so making the timeout a tiny bit more lenient is probably the way to go.

Sorry for not mentioning sooner.

@eaddingtonwhite can you weigh in on this?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I changed this to InRegion.Default here

Copy link
Member

Choose a reason for hiding this comment

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

Agree w/ this. Start more conservative w/ default timeouts we can always make more agressive down line.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

OK. In that case b164b6a implements this.

@malandis malandis requested a review from cprice404 April 26, 2023 18:39
@malandis malandis merged commit 1751cd5 into main Apr 26, 2023
@malandis malandis deleted the feat/lambda-configuration branch April 26, 2023 18:40
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.

3 participants