activemq-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Chris Audley" <>
Subject Queue advisory doesn't generate messages
Date Wed, 17 Jun 2009 14:38:40 GMT
I'm trying to get advisory messages to work in an ActiveMQ server and
I'm not having any luck.  I'm using a Spring container that is already
successfully interacting with non-advisory queues on the ActiveMQ
server.  I use Spring to add a listener for consumed messages on a queue
like this:

    <property name="connectionFactory" ref="connectionFactory"/>
    <property name="destinationName">
    <property name="messageListener">
      <bean class="testing.MyClass">
        <property name="responseTemplate" ref="anotherJmsTemplate"/>
    <property name="sessionTransacted" value="true"/>

I've also tried removing the sessionTransacted property, and setting it
to false.

In the activemq server configuration, I've updated the destination

                    <policyEntry queue=">" memoryLimit="5mb"/>
                    <policyEntry topic=">" memoryLimit="5mb"/>
                    <policyEntry queue="MYQUEUE"

I've also tried:

                    <policyEntry queue=">" memoryLimit="5mb"
                    <policyEntry topic=">" memoryLimit="5mb"/>

And just for completeness, after all of this failed, I tried adding
advisorySupport="true" to the broker element in the configuration.

When I run tests, I can see in the ActiveMQ HTTP interface that a
message was sent to and received from the MYQUEUE queue, and I can see
that there is a consumer on
ActiveMQ.Advisory.MessageConsumed.Queue.MYQUEUE.  However, at no time is
my onMessage callback on the MessageListener run, nor do I see any
messages sent or received on the
ActiveMQ.Advisory.MessageConsumed.Queue.MYQUEUE queue in the server HTTP

As a final test, I tried switching my advisory queue listener to
ActiveMQ.Advisory.Connection, a topic that is supposed to be enabled by
default.  I can see in the HTTP monitor that the topic has a consumer,
but I still get no messages, and the monitor shows that no messages
where sent, even though I had programs connecting, sending messages and

Finally, if I disable the regular consumer on MYQUEUE and edit the
destinationName of the advisory listener to listen to MYQUEUE directly,
it does get called, so its not a problem with the listener

Why isn't this working?


View raw message