[
https://issues.apache.org/jira/browse/ARTEMIS-2564?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Justin Bertram updated ARTEMIS-2564:
------------------------------------
Description:
There is a possible bug with {{retryMessages()}} JMX call.
**Step 1:** Send messages to a queue
{noformat}
bin/artemis producer --user me --password mypassword --destination
queue://MESSAGING.QUEUE.3 --message TEST
{noformat}
Durable message count is 1000 and Durable persistence size is 394000. Message
count is 1000 and FirstMessageTimestamp is 1574947152841 for this queue. First
Message As Json has JSON text inside it.
**Step 2:** Retry the messages
It makes no sense to retry messages that hasn't gone to DLQ but that was what I
did:
{noformat}
http://my.happy.machine:8181/console/jolokia/exec/org.apache.activemq.artemis:broker=!%22amq-c!%22,component=addresses,address=!%22MESSAGING.QUEUE.3!%22,subcomponent=queues,routing-type=!%22anycast!%22,queue=!%22MESSAGING.QUEUE.3!%22/retryMessages()
{noformat}
Got 1000 back
{{FirstMessageTimestamp}} is empty and {{FirstMessageAsJson}} is {{{}}} other
than that all fields above is unchanged.
It looks to me that when {{retryMessages()}} runs on messages that have not
been rollbacked enough times to reach DLQ removes the messages but does not
update message count. Better would be if {{retryMessages}} didn't remove
messages that have not been sent to DLQ, but as it is now it is reported to be
1000 messages on the queue but it is empty when browsing it.
{{resetMessageCounter()}} does not fix anything and {{removeAllMessages()}}
reports 0 and still 1000 messages in message count (no change to the other
fields either).
Of course, this is not done that often and service is still running fine, so it
is a minor problem.
was:
There is a possible bug with {{retryMessages()}} JMX call.
* Step 1: Send messages to a queue
{noformat}
bin/artemis producer --user me --password mypassword --destination
queue://MESSAGING.QUEUE.3 --message TEST
{noformat}
Durable message count is 1000 and Durable persistence size is 394000. Message
count is 1000 and FirstMessageTimestamp is 1574947152841 for this queue. First
Message As Json has JSON text inside it.
* Step 2: Retry the messages
It makes no sense to retry messages that hasn't gone to DLQ but that was what I
did:
{noformat}
http://my.happy.machine:8181/console/jolokia/exec/org.apache.activemq.artemis:broker=!%22amq-c!%22,component=addresses,address=!%22MESSAGING.QUEUE.3!%22,subcomponent=queues,routing-type=!%22anycast!%22,queue=!%22MESSAGING.QUEUE.3!%22/retryMessages()
{noformat}
Got 1000 back
{{FirstMessageTimestamp}} is empty and {{FirstMessageAsJson}} is {{{}}} other
than that all fields above is unchanged.
It looks to me that when retryMessages() runs on messages that have not been
rollbacked enough times to reach DLQ removes the messages but does not update
message count. Better would be if retryMessages didn't remove messages that
have not been sent to DLQ, but as it is now it is reported to be 1000 messages
on the queue but it is empty when browsing it.
resetMessageCounter() does not fix anything and removeAllMessages() reports 0
and still 1000 messages in message count (no change to the other fields either).
Of course, this is not done that often and service is still running fine, so it
is a minor problem.
Edit: Fixed minor spelling and grammar mistakes. English is not my native
language so there are probably more there, please fix them as you spot them.
> Possible durable message count error with retryMessages()
> ---------------------------------------------------------
>
> Key: ARTEMIS-2564
> URL: https://issues.apache.org/jira/browse/ARTEMIS-2564
> Project: ActiveMQ Artemis
> Issue Type: Bug
> Affects Versions: 2.10.1
> Reporter: Anders Andersson
> Priority: Minor
>
> There is a possible bug with {{retryMessages()}} JMX call.
> **Step 1:** Send messages to a queue
> {noformat}
> bin/artemis producer --user me --password mypassword --destination
> queue://MESSAGING.QUEUE.3 --message TEST
> {noformat}
> Durable message count is 1000 and Durable persistence size is 394000. Message
> count is 1000 and FirstMessageTimestamp is 1574947152841 for this queue.
> First Message As Json has JSON text inside it.
> **Step 2:** Retry the messages
> It makes no sense to retry messages that hasn't gone to DLQ but that was what
> I did:
> {noformat}
> http://my.happy.machine:8181/console/jolokia/exec/org.apache.activemq.artemis:broker=!%22amq-c!%22,component=addresses,address=!%22MESSAGING.QUEUE.3!%22,subcomponent=queues,routing-type=!%22anycast!%22,queue=!%22MESSAGING.QUEUE.3!%22/retryMessages()
> {noformat}
> Got 1000 back
> {{FirstMessageTimestamp}} is empty and {{FirstMessageAsJson}} is {{{}}} other
> than that all fields above is unchanged.
> It looks to me that when {{retryMessages()}} runs on messages that have not
> been rollbacked enough times to reach DLQ removes the messages but does not
> update message count. Better would be if {{retryMessages}} didn't remove
> messages that have not been sent to DLQ, but as it is now it is reported to
> be 1000 messages on the queue but it is empty when browsing it.
> {{resetMessageCounter()}} does not fix anything and {{removeAllMessages()}}
> reports 0 and still 1000 messages in message count (no change to the other
> fields either).
> Of course, this is not done that often and service is still running fine, so
> it is a minor problem.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)