Lambda from docker container instead of zip: what is faster?

Viewed 3623

AWS Lambda recently added the option to create functions from docker containers (small warning: the ECR needs to be in the same account for now). I was wondering: except for all the advantages of docker over random ZIPs, is this also quicker to start, or quicker to call?

2 Answers

I have just used a Lambda container for a big API project in my company and I haven't personally seen slow downs in start time. I would believe that it may take a few more milliseconds to boot, but I think is negligible.

You could test it printing the times in CloudWatch, but I would avoid going to the Docker route if it's not needed because of all the pain that it is setting it up and getting a nice testing environment.

In relation to other pros and cons, I could write a whole essay here. Each has its perks, but as of a rule of thumb, only use the Dockerized Lambda if you really need it.

They'll take the same amount of time to call.

Related