We recently upgraded from ActiveMQ 5.9.0 to 5.14.4. After this upgrade when we use a QueueReceiver to browse a Queue, we only receive the top (first) 400 messages. Prior to the upgrade we would receive all messages from the Queue. I've tried using a high prefetch (consumer.prefetchSize=1000 in the destination name) but it isn't helping return all messages.
Is this a bug that got introduced somewhere between 5.9 and 5.14?
Is there a way we can retrieve all messages after this upgrade?
Re: QueueReceiver only receives first 400 messages
I found a destination policy of maxBrowsePageSize (set to 400 by default) was introduced in some release after 5.9.0 that is causing this behavior. I've raised that limit and now a QueueBrowser will return the correct number of messages. Now I'm trying to figure out what we should set the max to so we can browse all (most?) messages without memory issues with ActiveMQ.