Home > Blockchain >  Rate limiting consumption from AWS SQS
Rate limiting consumption from AWS SQS

Time:06-09

I have a scenario wherein I am supposed to consume messages from an AWS SQS.

I need to limit the consumption from the queue, say x messages per minute.

I know there are 3rd party libraries like Guava, which can help here. But is there a feature that AWS provides to rate limit the consumption from SQS - may be an attribute to @SqsListener or something like that?

I tried googling and exploring stackoverflow with no luck. Got this - SQS rate limiting

As I said, this can be implemented using Guava or custom implementation but that's not what I am looking for.

Thanks

CodePudding user response:

is there a feature that AWS provides to rate-limit the consumption from SQS

The short & long answer is no.

AWS SDKs do not provide a native way to rate-limit consumption from SQS. It is up to you to implement custom logic to rate-limit message consumption.

  • Related