Serverless computing has revolutionized modern software architectures by offering scalability, agility, and cost-efficiency. AWS Lambda, in particular, enables developers to execute code without provisioning or managing servers, while MongoDB Atlas offers a fully managed NoSQL database service in the cloud. However, realizing high throughput from such architectures requires deliberate tuning. This paper presents a comprehensive analysis of performance optimization strategies specifically tailored for AWS Lambda functions interfacing with MongoDB Cloud. By identifying typical performance bottlenecks such as cold starts, connection limitations, and VPC overheads, we demonstrate practical solutions including provisioned concurrency, persistent connections via Lambda layers, and usage of VPC endpoints. The methodology focuses on balancing execution time, latency, and cost-effectiveness, ensuring the infrastructure supports both burst and steady-state loads. Our real-world case study from the fuel retail industry validates the success of these tuning strategies through metrics such as request latency, transaction per second (TPS), and connection stability. Furthermore, we investigate the synergy between event-driven triggers like Amazon SQS and data-intensive operations in MongoDB to achieve sustained throughput at scale. The findings from this research can guide engineers and architects in building robust, responsive, and scalable serverless applications using AWS and MongoDB Cloud, ultimately aligning business outcomes with technical performance.
Sasikanth Mamidi - (Mon,) studied this question.