You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by EvgenyM <ev...@gmail.com> on 2018/04/18 03:34:20 UTC

Artemis 2.4.0 : Messages lost on broker restart

Good day, 

I am just starting with Artemis ActiveMQ and might not be fully across all
the details. 

My issue is that even though I have (seemingly) enabled the persistence and
configured queues as durable and persistent, I am loosing messages on the
broker restart. 

Essentially I am missing something simple, but not sure what exactly. 

Any help is appreciated. 

My configuration: 

CoreQueueConfiguration cg = new CoreQueueConfiguration() 
                    .setAddress("MASTER") 
                    .setRoutingType(RoutingType.MULTICAST) 
                    .setDurable(true) 
                    .setName("QUEUE1"); 

CoreQueueConfiguration cg2 = new CoreQueueConfiguration() 
                    .setAddress("MASTER") 
                    .setRoutingType(RoutingType.MULTICAST) 
                    .setDurable(true) 
                    .setName("QUEUE2"); 

configuration.addQueueConfiguration(cg); 
configuration.addQueueConfiguration(cg2); 

configuration.setPersistenceEnabled(true); 

configuration.setJournalDirectory("/u00/artemis/journal"); 
configuration.setBindingsDirectory("/u00/artemis/bindings"); 

configuration.setJournalDatasync(true); 
configuration.setJournalSyncNonTransactional(true); 
configuration.setJournalSyncTransactional(true); 

What am I missing? How do I preserve messages over the broker restart? 



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html

Re: Artemis 2.4.0 : Messages lost on broker restart

Posted by Justin Bertram <jb...@apache.org>.
What client API or protocol are you using? Different ones have different
defaults for messages they send. It would be helpful for future users to
know what you're using.


Justin

On Wed, Apr 18, 2018 at 2:08 AM, EvgenyM <ev...@gmail.com> wrote:

> Figured this out.
>
> The message itself needs to be marked persistent EXPLICITLY.
> Automatically it is non-persistent.
>
>
>
> --
> Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-
> f2341805.html
>

Re: Artemis 2.4.0 : Messages lost on broker restart

Posted by EvgenyM <ev...@gmail.com>.
Figured this out.

The message itself needs to be marked persistent EXPLICITLY.
Automatically it is non-persistent.



--
Sent from: http://activemq.2283324.n4.nabble.com/ActiveMQ-User-f2341805.html