The last-value queue feature isn't yet supported for AMQP clients.
Justin On Fri, Aug 11, 2017 at 11:08 AM, vchen1 <[email protected]> wrote: > I was testing the last_value_queue and noticed that it is not working if > connected with AMQP. Here is what I have tested: > > 1.) With port 61616, I followed the example on Artemis github and have the > jndi file as: > > java.naming.factory.initial=org.apache.activemq.artemis.jndi. > ActiveMQInitialContextFactory > > connectionFactory.myFactoryLookup=tcp://localhost:61616 > > and set _AMQ_LVQ_NAME as directed: > > TextMessage message = session.createTextMessage(command); > > message.setStringProperty("_AMQ_LVQ_NAME", "STOCK_NAME"); > > it works as expected, only keep the last message in the queue. > > 2.) Still with port 61616, but change > > connectionFactory.myFactoryLookup=amqp://localhost:61616 > > then the last value queue breaks. It keeps all the messages sent to the > queue. > > 3.) Change the port to use AMQP port 5672: > > java.naming.factory.initial = > org.apache.qpid.jms.jndi.JmsInitialContextFactory > connectionfactory.myFactoryLookup = amqp://localhost:5672 > > again the last value queue breaks. It keeps all the messages sent to the > queue. > > I wonder if the last value queue is designed to only work for Artemis JMS > not AMQP? Thanks, > > > > -- > View this message in context: http://activemq.2283324.n4. > nabble.com/Artemis-2-2-0-last-value-queue-not-working-with- > AMQP-tp4729633.html > Sent from the ActiveMQ - User mailing list archive at Nabble.com. >
