diff --git a/src/main/java/org/apache/cassandra/db/ColumnFamilyStore.java b/src/main/java/org/apache/cassandra/db/ColumnFamilyStore.java index 6761763..44d4d1a 100644 --- a/src/main/java/org/apache/cassandra/db/ColumnFamilyStore.java +++ b/src/main/java/org/apache/cassandra/db/ColumnFamilyStore.java @@ -132,14 +132,10 @@ public class ColumnFamilyStore implements ColumnFamilyStoreMBean { } } missed_response = 0; - } catch (ProcessingException e) { - if (Throwables.getRootCause(e) instanceof ConnectException) { - if (missed_response++ > MAX_RETRY) { - System.err.println("API is not available, JMX is shuting down"); - System.exit(-1); - } - } else { - // ignoring exceptions, will retry on the next interval + } catch (IllegalStateException e) { + if (missed_response++ > MAX_RETRY) { + System.err.println("API is not available, JMX is shuting down"); + System.exit(-1); } } catch (Exception e) { // ignoring exceptions, will retry on the next interval diff --git a/src/main/java/org/apache/cassandra/net/MessagingService.java b/src/main/java/org/apache/cassandra/net/MessagingService.java index 9da5281..efe3e47 100644 --- a/src/main/java/org/apache/cassandra/net/MessagingService.java +++ b/src/main/java/org/apache/cassandra/net/MessagingService.java @@ -138,7 +138,7 @@ public final class MessagingService implements MessagingServiceMBean { } connection_failure = 0; report_error = 1; - } catch (ProcessingException e) { + } catch (IllegalStateException e) { // Connection problem, No need to do anything, just retry. } catch (Exception e) { connection_failure++;