The pros and cons of Lambdalith
“Lambdalith” refers to deploying monolithic applications using AWS Lambda. This is typically associated with (but not limited to) building serverless APIs.
With a Lambdalith, a single Lambda function handles all the routes in an API. You can use Lambda Function URLs [1] or put the function behind a greedy path in API Gateway.
This contrasts with the “function per endpoint” approach, where a different Lambda function handles each API route.
Lambdaliths has been the source of intense debate in the serverless community. While I generally prefer the “function per endpoint” approach, I have adopted Lambdaliths where it makes sense.
In this post, let’s discuss the pros and cons of Lambdaliths and the nuances that are often overlooked.