Restarting AWS lambda function to clear cache

后端 未结 7 1723
你的背包
你的背包 2021-01-08 00:38

I have a AWS Lambda function that creates an object from a s3 call in cold start. I then hold the object in the cache while the function is warm to keep load times down. W

7条回答
  •  無奈伤痛
    2021-01-08 00:50

    I made an Answer based on my comment and verification from @DejanVasic

    aws lambda update-function-configuration --function-name "myLambda" --description "foo"
    

    This will force the next invokation of the lambda to "cold start".

    To verify:

    @timestamp, @message | sort @timestamp desc | limit 1000 | filter @message like "cold_start:true"
    

提交回复
热议问题