Hi

You can set the prefetch size on the destination policy entry in the 
ActiveMQ.xml. 

Regards 
JB

> Le 8 févr. 2022 à 07:53, Simon Lundström <si...@su.se> a écrit :
> 
> On Mon, 2022-02-07 at 10:37:52 +0100, CASAUX Nicolas wrote:
>> Hello,
>> 
>> I'm using ActiveMQ < classic > 5.16.0 and I have a question related to slow 
>> consumers.
>> 
>> In my use case, I only use topics with non-durable messages. As per the doc, 
>> the prefetchSize is 32767.
>> I have a constantPendingMessageLimitStrategy on this topic with a limit of 
>> 1000 messages.
>> I can observe both values on the webconsole accordingly when they reach the 
>> limit (I see 32767 messages in the dispatch queue size and 1000 messages in 
>> the pending queue size)
>> 
>> I have a bunch of slow consumers, which do not set any prefetchSize (hence 
>> they have the default 32767 value).
>> 
>> My question is: how can I set, change or force this value from ActiveMQ side 
>> ?
>> 
>> I don't want those consumers to connect without a prefetchSize value, and I 
>> consider the default value too high for my usecase.
>> That's why I would like to reduce this value.
>> 
>> Any hints on this ?
>> Thanks! :)
>> 
>> Nicolas
>> 
>> 
>> C2 - Usage restreint
> 
> I belive you can set the default on your transportConnector, see 
> https://activemq.apache.org/mqtt.html#message-prefetch
> 
> BR,
> - Simon

Reply via email to