1 個回答
- 最新
- 最多得票
- 最多評論
1
When your function returns to the caller, the Lambda service freezes the execution environment and nothing happens there until there is another invocation, or until the execution environment is shutdown.
If you look at your trace you see that the last log message is printed after the END message. My assumption is that because you are using Node.js, the event loop is not empty when you return. This external blog explains it very well. The following documentation explains how to use callbackWaitsForEmptyEventLoop
to resolve this.
相關內容
- AWS 官方已更新 1 年前
- AWS 官方已更新 3 年前
Thank you for this, an experiment seems to indicate this is the cause, though it will take me a few days to get into the live system to prove, so accepting now.
Appreciate you taking time to answer my question, all the best.