Thanks for looking at this question!
So I am trying to figure out how long is the cold start phase for a lambda function. But when I searched Init Duration in the lambda CloudWatch log group, I can only find logs in 2020 that contained this field. The lambda function has been changed several times this year, so there must be some executions contains cold start.
I wonder why this field is missing and how can I get it back?
Thank you!
The Init Duration field should be there on the Report entry for every cold start execution. This also means that in a Lambda log group, each log stream should have an Init Duration exactly once and it should be on the Report entry of the oldest/first execution.
As far as I know, they have not changed the way they log this information, and I can still find it in lambda logs on my account. You could check manually for a log stream if the first entry contains it, otherwise, the only hint I can give is to check whether or not your filter is syntactically correct and your time window is big enough.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With