Re: ActiveMQ HA on failover topic mode

2018-12-19 Thread Justin Bertram
If you ultimately find that ActiveMQ 5.x can't meet your performance goals, then I would recommend you checkout ActiveMQ Artemis. It supports all the same protocols as the 5.x broker (i.e. OpenWire, AMQP, STOMP, MQTT) and much of the same features (or equivalents) but it is based on a higher perfor

Re: ActiveMQ HA on failover topic mode

2018-12-19 Thread Tim Bain
I've never run the broker in that mode, but I'd expect that one major determiner of your throughput would be the speed at which the disk can do the frequent, small flushes to disk. I'd expect you to see the best performance on a locally-attached SSD with low write latency, but it's possible that yo

Re: ActiveMQ HA on failover topic mode

2018-12-19 Thread Tim Bain
You might also look at Christian Posta's blog post to see if any of those ideas and techniques would be of use for your situation: http://blog.christianposta.com/activemq/speeding-up-activemq-persistent-messaging-performance-by-25x/ Tim On Wed, Dec 19, 2018, 11:45 AM Tim Bain I've never run the

Re: ActiveMQ HA on failover topic mode

2018-12-12 Thread PedroRP
Hi Tim! Thank you very much for your answer! Yes, I was using non-durable subscription on my topic. When I changed to durable subscription, It didn't lose messages if I use sync sends. The main problem now is the sending response time. It spends too much time sending messages. Is there any way to

Re: ActiveMQ HA on failover topic mode

2018-12-11 Thread Tim Bain
You're using a non-durable subscription on your topic, aren't you? That's your (primary) problem: you're losing messages around the time of the failover because your consumer isn't subscribed during that period of time. It's possible that the broker is actually losing a few messages, especially if

Re: ActiveMQ HA on failover topic mode

2018-12-10 Thread PedroRP
Hi Tim! My sender app is sending text messages with the text: "Message (sequence)". The sender's log is showing the message after send it. This is the log: Message 6291 Message 6292 Message 6293 Message 6294 Message 6295 2018-12-10 10:37:43.175 WARN 8732 --- [.45:61626@55241] o.a.a.t.failover.Fa

Re: ActiveMQ HA on failover topic mode

2018-12-09 Thread PedroRP
Hi Tim! The lost messages are last few messages before the failover. I'm trying to simulate energy failure, so I kill the broker ungracefully (kill -9). Due to my requirements, I need to use async sends. Could this be a problem? I realized that If I reduce timeout to 1 ms no messages are lost.

Re: ActiveMQ HA on failover topic mode

2018-12-07 Thread Tim Bain
Can you please characterize the messages that are lost? Do you lose the last few messages sent before the failover, or one here and there, or...? Also, are you killing the broker gracefully (sending it a stop command) or ungracefully (kill -9, etc.)? Might the messages that are lost simply be the

Re: ActiveMQ HA on failover topic mode

2018-12-05 Thread PedroRP
Hi Tim! Sorry about the late answer. I fixed the configuration and now I have a master/slave that work fine. But I still lose messages. I checked the consumer connection and It is equal than the producer. Moreover when I disconnect master broker consumer and producer reconnect to the slave broker.

Re: ActiveMQ HA on failover topic mode

2018-11-30 Thread Tim Bain
You would use masterslave for connections to a master/slave cluster from another broker. So if broker C was connecting to the master/slave pair A/B, then C would use a masterslave networkConnector to A/B. But A and B would have no networkConnector to each other, and no masterslave networkConnectors

Re: ActiveMQ HA on failover topic mode

2018-11-30 Thread PedroRP
Hi Tim! Ok, so for a HA ActiveMQ master-slave is not required any network of brokers, isn't it? For the messages we are losing. We see that all messages are sent but when failover happens consumer stops listening messages. Does It makes sense with a wrong configuration? Thanks for your answer!

Re: ActiveMQ HA on failover topic mode

2018-11-30 Thread Tim Bain
Actually, you should be able to set the alwaysSyncSend via the URI by adding &jms.alwaysSyncSend=true to the end of your producer's URI, so you should be able to continue using JmsTemplate. Tim On Fri, Nov 30, 2018, 7:30 AM Tim Bain You're mixing your paradigms. > > The persistenceAdapter portio

Re: ActiveMQ HA on failover topic mode

2018-11-30 Thread Tim Bain
You're mixing your paradigms. The persistenceAdapter portion of your config is all you need for a master/slave cluster, *as long as* your activemq.data variable resolves to the same value in both processes. (Both processes run on the same machine, right?) If so, the second broker started will paus

Re: ActiveMQ HA on failover topic mode

2018-11-30 Thread PedroRP
We have used Spring boot to develop sender and consumer apps. *SENDER:* To send messages we used and API REST that sends 5000 messages to a topic. If some convertAndSend fails (ActiveMQ node 1 killed) we retry it until the failover. This is my sender class: @RestController public class RestApiC

Re: ActiveMQ HA on failover topic mode

2018-11-29 Thread Justin Bertram
ActiveMQ 5.x does support high availability via a master-slave configuration. See the documentation [1] for more details. Justin [1] http://activemq.apache.org/masterslave.html On Thu, Nov 29, 2018 at 11:09 AM PedroRP wrote: > Hi! > > Does ActiveMQ cluster (master-slave) offer high availabili

ActiveMQ HA on failover topic mode

2018-11-29 Thread PedroRP
Hi! Does ActiveMQ cluster (master-slave) offer high availability on failover mode? I am publishing messages on a topic but when I kill active node and my consumer connect to the other node It loses several messages. I need only topic mode, because I need to have different pods of the same opensh

ActiveMQ HA on failover topic mode

2018-11-29 Thread PedroRP
Hi! Does ActiveMQ cluster (master-slave) offer high availability on failover mode? I am publishing messages on a topic but when I kill active node and my consumer connect to the other node It loses several messages. I need only topic mode, because I need to have different pods of the same opensh