Memory size greater than 3008?


Many thanks for the framework, makes AWS Lambda development super easy! One question, noticed this one recently. So, we have one stage of a Lambda, which is erroring when we deploy it w/ memorySize: 4096:

Serverless Error ----------------------------------------

An error occurred: EventsCronLambdaFunction - Resource handler returned message: "'MemorySize' value failed to satisfy constraint: Member must have value less than or equal to 3008 (Service: Lambda, Status Code: 400, Request ID: 3d8b92e9-afd8-4c51-97f2-675283b2e8b5, Extended Request ID: null)" (RequestToken: d9435d2d-257b-37ed-af37-ff7e9570dbeb, HandlerErrorCode: InvalidRequest).

However, in other stages this Lambda deploys with memorySize: 4096 just fine, and of course this is an allowed value through Lambda Console:

Screen Shot 2022-01-27 at 11.57.58 AM

Has anyone run into this before, where we are getting the error on the old max memory usage value in some cases, even though it is working in other cases?


– Tim

Might have sorted out when this is working. Seems to work if one sets the memory value to i.e. 4096 in AWS console. Future sls deploy executions will work. But setting this value through the serverless.yml configuration is showing the error above.