I have an AWS Lambda that uses 2 environment variables. I want to run this lambda up to several hundred times a day, however i need to change the environment variables between runs.
Ideally, I would like something where I could a list a set of variables pairs and run the lambdas on a schedule
The only way I see of doing this, is have separate lambdas and setting the environment variables for each manually
Any Ideas about how to achieve this
You could use an SQS queue for this. Instead of your scheduler initiating the Lambda function directly, it could simply send a message with the two data values to an SQS queue, and the SQS queue could be configured to trigger the Lambda. When triggered, the Lambda will receive the data from the message. So, the Lambda function does not need to change.
Of course, if you have complete control over the client that generates the two data values then that client could also simply invoke the Lambda function directly, passing the two data values in the payload.
AWS Lambda - Run Lambda multiply times with different environment variables