Reproducing the ‘SQS Trigger and Lambda Concurrency Limit’ Issue

Photo by Harshil Gudka via Unsplash


To deploy, install the dependencies via NPM ([1] npm install) and tell Serverless to deploy using the [2]serverless deploy command.


Once you have the queue URL, [4]copy it to line 14 of test.js. This script simply sends ten messages to the queue using SendMessageBatch.


The test script just loaded the queue with messages and Lambda has probably pulled all of them off the queue. You can see this in the SQS console as messages move from Messages Available to Messages in Flight.

Messages in Flight are invisible to receivers until the visibility timeout expires.


SQS overpull is still happening and you should be aware of it when setting low concurrency limits. As far as I know, the advice I gave in the What to do about it section of my previous post is still the best you can do to avoid problems.



Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store