Hi All,

 

My questions are 1.) how fast can the FailoverManager handle a failover?
and 2.) will FailoverManager handle the case that all the brokers are
unavailable? 

 

As I understand it, FailoverManager::execute() will try to reconnect if
no open connection is available, by using the last known brokers
list(because it uses connect() which has an empty brokers url list?),
and if that succeeded, a new session will be created and
Command::execute() will be called. And if the reconnect failed, it will
through an exception. 

 

If the above is correct, then when broker1 in my cluster is dead, the
messages sent by sender should immediately failover to broker2, and the
client shouldn't notice anything. But in my test, what actually happened
is it took about 6-7 minutes for the clients to failover, during that
time both the sender and receiver clients were frozen. 

 

And if I kill both of the brokers in the cluster, it also takes about
6-7 minutes for the clients to notice that there are no connections
available. Even if I restart the brokers within that frozen time,
clients still won't be able to connect the newly started broker but will
fail with "Cannot establish a connection" exception at last.

 

My test clients are almost the same as replay_sender and resume_receiver
examples from M4, the only variation is in the beginning they use
connect( url ) to connect the cluster rather than a specific host:port
string. Also I put sleep between each send so I can manage the test
easier.

 

So am I doing something wrong here? Can anyone suggest what do I need to
do in my application to have maximum resilience besides relying on
FailoverManager? 

 

 

Thanks & Regards,

Shan

The information contained in this email is strictly confidential and for the 
use of the addressee only, unless otherwise indicated. If you are not the 
intended recipient, please do not read, copy, use or disclose to others this 
message or any attachment. Please also notify the sender by replying to this 
email or by telephone (+44 (0)20 7896 0011) and then delete the email and any 
copies of it. Opinions, conclusions (etc.) that do not relate to the official 
business of this company shall be understood as neither given nor endorsed by 
it. IG Index plc is a company registered in England and Wales under number 
01190902. VAT registration number 761 2978 07. Registered Office: Friars House, 
157-168 Blackfriars Road, London SE1 8EZ. Authorised and regulated by the 
Financial Services Authority. FSA Register number 114059.

Reply via email to