Top best practices you should follow when building with AWS Lambda

George Mao
4 min readMar 10, 2023
Photo by Ales Krivec on Unsplash

Set CloudWatch log retention policies

Lambda creates a log group that matches the name of your function in this format: /aws/lambda/[lambda name]. All log streams in this group persist forever by default. You pay for every byte written to the log group. These costs pile up forever (at $0.53/GB) unless you set a retention…

--

--

George Mao

Distinguished Engineer @ Capital One leading all things Serverless | Ex -AWS WW Serverless Tech Lead.