How AWS is billing Lambda Service
Lambda is a compute service that lets you run your code without provisioning or managing any server. Lambda is one of the most used services in AWS stack.The only thing you need to do is that develop and run your code
Lambda is also very cheap service but before using Lambda, it would be better to understand how AWS is billing this service
Code Storage
In case you deploy your code, the code is going to be stored in S3. So, this storage cost is billing in S3
Request
Lambda service is counting how many times you request the service. The first 1 million request is free for each month and it charges after 1M request
Duration
Lambda also charges how long you run the Lambda service and the amount of memory you have used.The first 400.000 GB-seconds is free
400 GB ram used * 1000 seconds = 400,000 GB-seconds
The important thing to note is that lambda is working only 5 minutes. That is the reason why should use EMR for batch processing
Final Words
Using lambda is really make sense when you need micro-batch applications. You don’t need to manage any server