0

What are some strategies and patterns for processing message queues quickly?

I have a Lambda function that is invoked on a schedule every x minutes to process a number of messages in the queue. I could reduce the interval, but a lot of the time there won’t be any messages to process and as Lambda is priced per request this would be cost inefficient. So I’m looking for a few ideas on other ways to achieve this

chicks
  • 1,911
  • 1
  • 13
  • 29
Simian
  • 103
  • 3

1 Answers1

3

An SQS queue can now be wired directly to a Lambda function as an event source, so you don't have to start the Lambda function on a schedule.

https://aws.amazon.com/blogs/aws/aws-lambda-adds-amazon-simple-queue-service-to-supported-event-sources/