Trigger a lambda function by kinesis stream events cold boot issues

Viewed 182

I have a Java producer from client app which produces location data in real time, the data is then put into kinesis stream which will trigger a lambda function to process the data. The problem is, cold start time of the lambda is relatively slow. Setting up an event to invoke the lambda every 1 minute doesn’t really helps. Is using ec2 instead of lambda is the only way if I want a faster processing time? Thanks in advance.

1 Answers

If you have cold start issues, usual solution is to setup provisioned concurrency:

By allocating provisioned concurrency before an increase in invocations, you can ensure that all requests are served by initialized instances with low latency.

Related