/** * Try to get the HA state of the node at the given address. This * function is guaranteed to be "quick" -- ie it has a short timeout * and no retries. Its only purpose is to avoid fencing a node that * has already restarted. */ boolean tryGracefulFence(HAServiceTarget svc) { HAServiceProtocol proxy = null; try { proxy = svc.getProxy(gracefulFenceConf, gracefulFenceTimeout); proxy.transitionToStandby(createReqInfo()); return true; } catch (ServiceFailedException sfe) { LOG.warn("Unable to gracefully make {} standby ({})", svc, sfe.getMessage()); } catch (IOException ioe) { LOG.warn("Unable to gracefully make {} standby (unable to connect)", svc, ioe); } finally { if (proxy != null) { RPC.stopProxy(proxy); } } return false; }
HAServiceProtocolHelper.transitionToActive( toSvc.getProxy(conf, rpcTimeoutToNewActive), createReqInfo()); } catch (ServiceFailedException sfe) { LOG.error("Unable to make {} active ({}). Failing back.",
HAServiceProtocolHelper.monitorHealth(toSvc, createReqInfo()); } catch (HealthCheckFailedException hce) { throw new FailoverFailedException(
/** * Try to get the HA state of the node at the given address. This * function is guaranteed to be "quick" -- ie it has a short timeout * and no retries. Its only purpose is to avoid fencing a node that * has already restarted. */ boolean tryGracefulFence(HAServiceTarget svc) { HAServiceProtocol proxy = null; try { proxy = svc.getProxy(gracefulFenceConf, gracefulFenceTimeout); proxy.transitionToStandby(createReqInfo()); return true; } catch (ServiceFailedException sfe) { LOG.warn("Unable to gracefully make " + svc + " standby (" + sfe.getMessage() + ")"); } catch (IOException ioe) { LOG.warn("Unable to gracefully make " + svc + " standby (unable to connect)", ioe); } finally { if (proxy != null) { RPC.stopProxy(proxy); } } return false; }
/** * Try to get the HA state of the node at the given address. This * function is guaranteed to be "quick" -- ie it has a short timeout * and no retries. Its only purpose is to avoid fencing a node that * has already restarted. */ boolean tryGracefulFence(HAServiceTarget svc) { HAServiceProtocol proxy = null; try { proxy = svc.getProxy(gracefulFenceConf, gracefulFenceTimeout); proxy.transitionToStandby(createReqInfo()); return true; } catch (ServiceFailedException sfe) { LOG.warn("Unable to gracefully make " + svc + " standby (" + sfe.getMessage() + ")"); } catch (IOException ioe) { LOG.warn("Unable to gracefully make " + svc + " standby (unable to connect)", ioe); } finally { if (proxy != null) { RPC.stopProxy(proxy); } } return false; }
/** * Try to get the HA state of the node at the given address. This * function is guaranteed to be "quick" -- ie it has a short timeout * and no retries. Its only purpose is to avoid fencing a node that * has already restarted. */ boolean tryGracefulFence(HAServiceTarget svc) { HAServiceProtocol proxy = null; try { proxy = svc.getProxy(gracefulFenceConf, gracefulFenceTimeout); proxy.transitionToStandby(createReqInfo()); return true; } catch (ServiceFailedException sfe) { LOG.warn("Unable to gracefully make " + svc + " standby (" + sfe.getMessage() + ")"); } catch (IOException ioe) { LOG.warn("Unable to gracefully make " + svc + " standby (unable to connect)", ioe); } finally { if (proxy != null) { RPC.stopProxy(proxy); } } return false; }
/** * Try to get the HA state of the node at the given address. This * function is guaranteed to be "quick" -- ie it has a short timeout * and no retries. Its only purpose is to avoid fencing a node that * has already restarted. */ boolean tryGracefulFence(HAServiceTarget svc) { HAServiceProtocol proxy = null; try { proxy = svc.getProxy(gracefulFenceConf, gracefulFenceTimeout); proxy.transitionToStandby(createReqInfo()); return true; } catch (ServiceFailedException sfe) { LOG.warn("Unable to gracefully make " + svc + " standby (" + sfe.getMessage() + ")"); } catch (IOException ioe) { LOG.warn("Unable to gracefully make " + svc + " standby (unable to connect)", ioe); } finally { if (proxy != null) { RPC.stopProxy(proxy); } } return false; }
HAServiceProtocolHelper.transitionToActive( toSvc.getProxy(conf, rpcTimeoutToNewActive), createReqInfo()); } catch (ServiceFailedException sfe) { LOG.error("Unable to make " + toSvc + " active (" +
HAServiceProtocolHelper.transitionToActive( toSvc.getProxy(conf, rpcTimeoutToNewActive), createReqInfo()); } catch (ServiceFailedException sfe) { LOG.error("Unable to make " + toSvc + " active (" +
HAServiceProtocolHelper.transitionToActive( toSvc.getProxy(conf, rpcTimeoutToNewActive), createReqInfo()); } catch (ServiceFailedException sfe) { LOG.error("Unable to make " + toSvc + " active (" +
HAServiceProtocolHelper.monitorHealth(toSvc, createReqInfo()); } catch (HealthCheckFailedException hce) { throw new FailoverFailedException(
HAServiceProtocolHelper.monitorHealth(toSvc, createReqInfo()); } catch (HealthCheckFailedException hce) { throw new FailoverFailedException(
HAServiceProtocolHelper.monitorHealth(toSvc, createReqInfo()); } catch (HealthCheckFailedException hce) { throw new FailoverFailedException(
HAServiceProtocolHelper.monitorHealth(toSvc, createReqInfo()); } catch (HealthCheckFailedException hce) { throw new FailoverFailedException(
HAServiceProtocolHelper.transitionToActive( toSvc.getProxy(conf, rpcTimeoutToNewActive), createReqInfo()); } catch (ServiceFailedException sfe) { LOG.error("Unable to make " + toSvc + " active (" +