Cloud Defense Logo

Products

Solutions

Company

Book A Live Demo

Rule: Lambda Functions Concurrent Execution Limit Configured

This rule ensures that the concurrent execution limit for Lambda functions is properly configured.

RuleLambda functions concurrent execution limit configured
FrameworkSOC 2
Severity
Low

Lambda Function Concurrent Execution Limit

Description:

The Lambda function concurrent execution limit is a configuration setting in AWS Lambda that defines the maximum number of concurrent executions allowed for a specific Lambda function. This setting helps control the scalability and ensures resources are not overwhelmed during peak times.

Troubleshooting Steps:

If you encounter issues related to the concurrent execution limit, follow the steps below to troubleshoot:

  1. 1.
    Monitoring: Use AWS CloudWatch to monitor the concurrent execution metrics for your Lambda function. Check if the number of concurrent executions is reaching the configured limit.
  2. 2.
    Error Messages: Pay attention to error messages from your application or Lambda function that may indicate exceeding the concurrent execution limit.
  3. 3.
    Analyze Peak Times: Identify the periods where your Lambda function experiences higher traffic or concurrent executions. This information helps fine-tune the concurrent execution limit.
  4. 4.
    Review Resource Utilization: Assess the CPU and memory utilization of the Lambda function during peak times. If the resources are not fully utilized, you may consider increasing the concurrent execution limit.

Code/Configuration:

To modify the concurrent execution limit, you can update the Lambda function's configuration through the AWS Management Console, AWS CLI, or AWS SDK.

AWS Management Console:

  1. 1.
    Open the AWS Management Console and navigate to the Lambda service.
  2. 2.
    Select the desired Lambda function from the list.
  3. 3.
    In the "Configuration" tab, scroll down to the "Concurrency" section.
  4. 4.
    Adjust the "Reserve concurrency" value to set the maximum number of concurrent executions.
  5. 5.
    Click "Save" to apply the changes.

AWS CLI:

Use the AWS CLI and execute the following command to update the concurrent execution limit:

aws lambda put-function-concurrency --function-name <lambda-function-name> --reserved-concurrent-executions <concurrent-execution-limit>

Replace

<lambda-function-name>
with the actual name of your Lambda function and
<concurrent-execution-limit>
with the desired maximum concurrent execution value.

Remediation Steps:

To remediate issues related to the Lambda function concurrent execution limit, you can follow these steps:

  1. 1.
    Analyze Usage Patterns: Review usage patterns, and if you observe consistent spikes in concurrent executions, consider increasing the concurrent execution limit accordingly.
  2. 2.
    Increase Concurrent Execution Limit: Update the Lambda function's configuration, as mentioned in the "Code/Configuration" section above, to increase the concurrent execution limit.
  3. 3.
    Retry Mechanism: Implement a retry mechanism within your application code to handle any throttling errors due to concurrent execution limits.
  4. 4.
    CloudWatch Alarm: Set up a CloudWatch alarm to notify you when the concurrent execution limit is being reached. This can help monitor and proactively adjust the limit as required.

By following these steps, you can effectively manage the concurrent execution limit for your Lambda functions and ensure their scalability and availability as per the SOC 2 guidelines.

Is your System Free of Underlying Vulnerabilities?
Find Out Now