naveen chary
naveen chary

Reputation: 79

How to keep lambda warm using zappa python

I have an API function in python and deployed it on aws lambda using zappa. When I am hitting my API after 15 minutes time its taking atleast 5 to 10 seconds to respond (which is too long for my API) for first request. I have came to know about cold start issue in aws lambda. How to keep lambda warm using zappa python?

Upvotes: 4

Views: 2823

Answers (1)

Ronyis
Ronyis

Reputation: 1953

Zappa has a default warmer that keeps invoking the lambda to avoid cold starts - check https://github.com/Miserlou/Zappa#advanced-usage (make sure keep_warm is set to true).

You can verify that there is a CloudWatch event rule of a scheduled event.

Upvotes: 3

Related Questions