Simple python code to check lambda warm time and to benchmark memory
Run the python file - lambdabenchmark.py in Cloud9 with Lambda Invoke permission.
- The warm start execution time of a lambda is significantly lesser than the cold start execution.
- As the memory is increased, the execution time decreases until a saturation memory is reached
The python code provides tests the lambda and provides data to validate the above mentioned points. Results are printed at adequate levels to provide the Lambda execution time and Memory consumptions.
Input
- lambdaname - provide the lambda function name
- memory - the list of memories you want to test against
- payload - the payload to be sent to the lambda function
- timeinmin - time intervals to test lambda warm time in minutes Output
- results - all the results are stored in this variable
Use this function to trigger lambda function with various memory values specified in the "memory" variable. It will provide the execution time for both "warm" and "cold" states.
Use this function to trigger lambda function with between time intervals specified in the "timeinmin" variable. It will provide the execution time for both "warm" and "cold" starts.

