@Override
    public void membershipFailure(String reason, Throwable t) {
      dm.exceptionInThreads = true;
      Throwable cause = t;
      if (cause != null && !(cause instanceof ForcedDisconnectException)) {
        logger.info("cluster membership failed due to ", cause);
        cause = new ForcedDisconnectException(cause.getMessage());
      }
      dm.setRootCause(cause);
      try {
        List<MembershipTestHook> testHooks = dm.getMembershipTestHooks();
        if (testHooks != null) {
          for (final MembershipTestHook testHook : testHooks) {
            testHook.beforeMembershipFailure(reason, cause);
          }
        }
        dm.getSystem().disconnect(reason, true);
        testHooks = dm.getMembershipTestHooks();
        if (testHooks != null) {
          for (final MembershipTestHook testHook : testHooks) {
            testHook.afterMembershipFailure(reason, cause);
          }
        }
      } catch (RuntimeException re) {
        logger.warn("Exception caught while shutting down", re);
      }
    }
This is the listener implementation for responding from events from the Membership Manager.
geode-core/src/main/java/org/apache/geode/distributed/internal/ClusterDistributionManager.java