2014-10-15 9:09 GMT+02:00 deepakkumarpitti <deepakkumarpi...@gmail.com>:
> > 1. I was wondering if ActiveMQ provides some replication support from > primary to failover brokers in real time so that even if I lose primary > broker (and its persistent store), my failover broker can continue with > it's > own replicated state. Looks like ActiveMQ provides Replicated leveldb > store. > Is there such a replication possible with kahadb based persistent store? > What do you mean? A network storage is already supposed to do that. Nothing provides "real time" anyway, not even ZooKeeper, you always need to wait for a minimum time to detect that your master got faulty, and switch to another server. ZooKeeper and leveldb just make it must faster compared to, i.e., 30 secs (default) for a lock expiration over NFS. > > 2. Does replicated leveldb store replicate from primary to failover broker > synchronously or asynchronously? Would the producer block waiting for > messages to be replicated from primary to failover? > Looks like you missed the documentation. http://activemq.apache.org/replicated-leveldb-store.html The answer is in the first two paragraphs of the "How it works" section. > > 3. I read about the master-slave discovery in network of brokers > (http://activemq.apache.org/networks-of-brokers.html). Could somebody > please > help me understand this in more detail? Specifically -- Does master-slave > network of brokers ensure only one master is active at a time and all > clients are connected to the same master broker? What happens when the > master broker goes down? Will one of the slaves get reelected as the new > master? Do all the slaves replicate from master in real time? synchronously > or asynchronously? > Didn't you say that you're already using it? As you know, in master/slave(s) only one server is active and working at a given time. So of course all the clients connect to a single instance (the master). Master/Slave discovery in a network of brokers only tells a server that he's going to be in a network with a master/slave structure, and as such he's already given a list of alternatives urls to be able to find the master. The server though won't replicate anything from the master/slave structure, as messages are inside only one server (or one master/slave structure, if you prefer) at a given time. For the rest of the question still look at http://activemq.apache.org/masterslave.html Best Regards