1 個回答
- 最新
- 最多得票
- 最多評論
0
Hi,
The AWS Lambda function can be triggered with multiple messages from the Amazon SQS queue (unless the Batch Size is set to zero in the Trigger configuration).
The Lambda function should loop through each record that is passed in the event parameter, for example:
exports.handler = async function(event, context) {
event.Records.forEach(record => {
const { body } = record;
console.log(body);
});
return {};
}
So, is Batch Size set to 0 in your case? See https://docs.aws.amazon.com/lambda/latest/dg/with-sqs.html for details about batch size
Best,
Didier
Hi, Batch size is set to 1, hence we dont need loop in our consumer lambda.
相關內容
- AWS 官方已更新 2 年前
- AWS 官方已更新 7 個月前
- AWS 官方已更新 1 年前
- AWS 官方已更新 2 個月前
Could you give your Lambda Function concurrency and Unreserved account concurrency limit ? You can find this information in the Configuration > Concurrency tab of your consumer Lambda