79705427

Date: 2025-07-17 21:31:40
Score: 0.5
Natty:
Report link

Regarding the timeout after 300 seconds aka 5 minutes:
The default timeout for Lambdas is 3 seconds, so I guess you already adjusted this.

Without any knowledge about the container image you're building/using, I strongly suspect that the container image hits some kind of cold start situation, which exceed the 5 minutes timeout.

Found answers/explanations for similar cases here and here, although they don't match exactly.

So what's happening on AWS side when you update the image can be described like this:

This process takes time - and is generally described as "cold start". See this for a more detailed description in which situations cold starts can be especially annoying. TL;DR: All invocations until the first Lambda instance is running will all be delayed by cold start behavior.

AWS docs around this topic can be found here. It even describes your exact error messages.

There are different ways to approach this. You can increase timeout, reduce image size, reduce image startup dependencies, change language, and more. Probably all of them are worth a separate question...
But hopefully, I was able to explain what you are seeing and get you on the right track.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: thetillhoff