我可以限制对AWS Lambda的并发调用吗? [英] Can I limit concurrent invocations of an AWS Lambda?
问题描述
我有一个Lambda函数,该函数由P3到S3存储桶的触发.
I have a Lambda function that’s triggered by a PUT to an S3 bucket.
我想限制此Lambda函数,使其一次只能运行一个实例–我不希望两个实例同时运行.
I want to limit this Lambda function so that it’s only running one instance at a time – I don’t want two instances running concurrently.
我浏览了Lambda配置和文档,但看不到任何明显的内容.我可以编写自己的锁定系统,但是如果已经解决了这个问题,那就太好了.
I’ve had a look through the Lambda configuration and docs, but I can’t see anything obvious. I can about writing my own locking system, but it would be nice if this was already a solved problem.
如何限制Lambda的并发调用次数?
推荐答案
AWS Lambda现在支持单个函数的并发限制: https://aws.amazon.com/about-aws/whats-new/2017/11/set-concurrency-limits-on-individual-aws-lambda-functions/
AWS Lambda now supports concurrency limits on individual functions: https://aws.amazon.com/about-aws/whats-new/2017/11/set-concurrency-limits-on-individual-aws-lambda-functions/
这篇关于我可以限制对AWS Lambda的并发调用吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!