[ 
https://issues.apache.org/jira/browse/AMQ-7246?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17263208#comment-17263208
 ] 

Jean-Baptiste Onofré commented on AMQ-7246:
-------------------------------------------

ActiveMQ 5.5.x is JMS 1.1 for now (JMS 2.0 will come in 5.18.x).

The delivery delay is the minimum time once the message has been produced 
before the message is available to "consumption".

Inflight count is the number of messages sent to a consumer session and have 
not received an ack.

Dispatch count is the total number of messages sent to consumer sessions 
(Dequeue + Inflight).

So, inflight + dispatch is not related to production, but just consumption.

In your case, with ActiveMQ 5.x (JMS 1.1 for now), you can use:
{code:java}
msg.setLongProperty(ScheduledMessage.AMQ_SCHEDULED_DELAY, delay); {code}
You will have a delayed message (the scheduler should be enabled).

Then, you can check all message in the scheduler.

> Having a JMX counter for delayed messages
> -----------------------------------------
>
>                 Key: AMQ-7246
>                 URL: https://issues.apache.org/jira/browse/AMQ-7246
>             Project: ActiveMQ
>          Issue Type: Improvement
>          Components: JMX
>    Affects Versions: 5.15.6
>            Reporter: François Courtault
>            Assignee: Jean-Baptiste Onofré
>            Priority: Major
>
> As of today there is no easy way to monitor the number of delayed messages.
> One possibility is to use the getAllJobs() operation on JobScheduler MBean. 
> But we have to specify a timeframe so it's quite difficult to use.
> Instead, could we have a new JMX counter which provides the number of delayed 
> messages ?



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to