[Discovery] Fault detection should also check cause exceptions for disconnects
The change introduced in #6686 checks for ConnectionTransportException during pinging. However, transport layer wraps it in SendRequestTransportException
This commit is contained in:
parent
955473f475
commit
7beac4ddbf
|
@ -299,7 +299,7 @@ public class MasterFaultDetection extends AbstractComponent {
|
|||
synchronized (masterNodeMutex) {
|
||||
// check if the master node did not get switched on us...
|
||||
if (masterToPing.equals(MasterFaultDetection.this.masterNode())) {
|
||||
if (exp instanceof ConnectTransportException) {
|
||||
if (exp instanceof ConnectTransportException || exp.getCause() instanceof ConnectTransportException) {
|
||||
handleTransportDisconnect(masterToPing);
|
||||
return;
|
||||
} else if (exp.getCause() instanceof NoLongerMasterException) {
|
||||
|
|
|
@ -233,7 +233,7 @@ public class NodesFaultDetection extends AbstractComponent {
|
|||
if (!nodeFD.running) {
|
||||
return;
|
||||
}
|
||||
if (exp instanceof ConnectTransportException) {
|
||||
if (exp instanceof ConnectTransportException || exp.getCause() instanceof ConnectTransportException) {
|
||||
handleTransportDisconnect(node);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue