camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dan Brown <>
Subject Backpressure with aws-sqs Consumer?
Date Tue, 06 Jan 2015 00:18:19 GMT

We're using a camel Consumer with an aws-sqs endpoint and running into
issues with large queues and slow consumers. The consumer jvm appears to
download messages very fast from sqs, onto the jvm heap, even though the
camel receive method processes each message very slowly (and Ack's when
done, with autoAck = false). The result of this is that the consumer jvm
continually fills its heap with an unbounded queue of incoming messages and
eventually throws OOME.

To avoid this failure, is there a way to enable backpressure when using
aws-sqs?—e.g. an on-heap bounded queue between the component fetching from
sqs and the user-defined actor processing the messages. I didn't see
anything relevant in the config:

And I didn't see any relevant jira issues:

Looking at the code, I see that SqsConsumer subtypes
ScheduledBatchPollingConsumer, which subtypes ScheduledPollConsumer. To get
backpressure, should it use something like EventDrivenPollingConsumer
somewhere, which uses a blocking queue to avoid the heap blowup above?


View this message in context:
Sent from the Camel - Users mailing list archive at

View raw message