public FailoverController(Configuration conf, RequestSource source) { this.conf = conf; this.gracefulFenceConf = new Configuration(conf); this.requestSource = source; this.gracefulFenceTimeout = getGracefulFenceTimeout(conf); this.rpcTimeoutToNewActive = getRpcTimeoutToNewActive(conf); //Configure less retries for graceful fence int gracefulFenceConnectRetries = conf.getInt( CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES, CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES_DEFAULT); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, gracefulFenceConnectRetries); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY, gracefulFenceConnectRetries); }
private synchronized void becomeStandby() { LOG.info("ZK Election indicated that " + localTarget + " should become standby"); try { int timeout = FailoverController.getGracefulFenceTimeout(conf); localTarget.getProxy(conf, timeout).transitionToStandby(createReqInfo()); LOG.info("Successfully transitioned " + localTarget + " to standby state"); } catch (Exception e) { LOG.error("Couldn't transition " + localTarget + " to standby state", e); // TODO handle this. It's a likely case since we probably got fenced // at the same time. } serviceState = HAServiceState.STANDBY; }
private void doCedeActive(int millisToCede) throws AccessControlException, ServiceFailedException, IOException { int timeout = FailoverController.getGracefulFenceTimeout(conf);
int timeout = FailoverController.getGracefulFenceTimeout(conf) * 2;
public FailoverController(Configuration conf, RequestSource source) { this.conf = conf; this.gracefulFenceConf = new Configuration(conf); this.requestSource = source; this.gracefulFenceTimeout = getGracefulFenceTimeout(conf); this.rpcTimeoutToNewActive = getRpcTimeoutToNewActive(conf); //Configure less retries for graceful fence int gracefulFenceConnectRetries = conf.getInt( CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES, CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES_DEFAULT); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, gracefulFenceConnectRetries); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY, gracefulFenceConnectRetries); }
public FailoverController(Configuration conf, RequestSource source) { this.conf = conf; this.gracefulFenceConf = new Configuration(conf); this.requestSource = source; this.gracefulFenceTimeout = getGracefulFenceTimeout(conf); this.rpcTimeoutToNewActive = getRpcTimeoutToNewActive(conf); //Configure less retries for graceful fence int gracefulFenceConnectRetries = conf.getInt( CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES, CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES_DEFAULT); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, gracefulFenceConnectRetries); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY, gracefulFenceConnectRetries); }
public FailoverController(Configuration conf, RequestSource source) { this.conf = conf; this.gracefulFenceConf = new Configuration(conf); this.requestSource = source; this.gracefulFenceTimeout = getGracefulFenceTimeout(conf); this.rpcTimeoutToNewActive = getRpcTimeoutToNewActive(conf); //Configure less retries for graceful fence int gracefulFenceConnectRetries = conf.getInt( CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES, CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES_DEFAULT); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, gracefulFenceConnectRetries); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY, gracefulFenceConnectRetries); }
public FailoverController(Configuration conf, RequestSource source) { this.conf = conf; this.gracefulFenceConf = new Configuration(conf); this.requestSource = source; this.gracefulFenceTimeout = getGracefulFenceTimeout(conf); this.rpcTimeoutToNewActive = getRpcTimeoutToNewActive(conf); //Configure less retries for graceful fence int gracefulFenceConnectRetries = conf.getInt( CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES, CommonConfigurationKeys.HA_FC_GRACEFUL_FENCE_CONNECTION_RETRIES_DEFAULT); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_KEY, gracefulFenceConnectRetries); gracefulFenceConf.setInt( CommonConfigurationKeys.IPC_CLIENT_CONNECT_MAX_RETRIES_ON_SOCKET_TIMEOUTS_KEY, gracefulFenceConnectRetries); }
private synchronized void becomeStandby() { LOG.info("ZK Election indicated that " + localTarget + " should become standby"); try { int timeout = FailoverController.getGracefulFenceTimeout(conf); localTarget.getProxy(conf, timeout).transitionToStandby(createReqInfo()); LOG.info("Successfully transitioned " + localTarget + " to standby state"); } catch (Exception e) { LOG.error("Couldn't transition " + localTarget + " to standby state", e); // TODO handle this. It's a likely case since we probably got fenced // at the same time. } serviceState = HAServiceState.STANDBY; }
private synchronized void becomeStandby() { LOG.info("ZK Election indicated that " + localTarget + " should become standby"); try { int timeout = FailoverController.getGracefulFenceTimeout(conf); localTarget.getProxy(conf, timeout).transitionToStandby(createReqInfo()); LOG.info("Successfully transitioned " + localTarget + " to standby state"); } catch (Exception e) { LOG.error("Couldn't transition " + localTarget + " to standby state", e); // TODO handle this. It's a likely case since we probably got fenced // at the same time. } serviceState = HAServiceState.STANDBY; }
private synchronized void becomeStandby() { LOG.info("ZK Election indicated that " + localTarget + " should become standby"); try { int timeout = FailoverController.getGracefulFenceTimeout(conf); localTarget.getProxy(conf, timeout).transitionToStandby(createReqInfo()); LOG.info("Successfully transitioned " + localTarget + " to standby state"); } catch (Exception e) { LOG.error("Couldn't transition " + localTarget + " to standby state", e); // TODO handle this. It's a likely case since we probably got fenced // at the same time. } serviceState = HAServiceState.STANDBY; }
private void doCedeActive(int millisToCede) throws AccessControlException, ServiceFailedException, IOException { int timeout = FailoverController.getGracefulFenceTimeout(conf);
private void doCedeActive(int millisToCede) throws AccessControlException, ServiceFailedException, IOException { int timeout = FailoverController.getGracefulFenceTimeout(conf);
private void doCedeActive(int millisToCede) throws AccessControlException, ServiceFailedException, IOException { int timeout = FailoverController.getGracefulFenceTimeout(conf);
private void doCedeActive(int millisToCede) throws AccessControlException, ServiceFailedException, IOException { int timeout = FailoverController.getGracefulFenceTimeout(conf);
private synchronized void becomeStandby() { LOG.info("ZK Election indicated that " + localTarget + " should become standby"); try { int timeout = FailoverController.getGracefulFenceTimeout(conf); localTarget.getProxy(conf, timeout).transitionToStandby(createReqInfo()); LOG.info("Successfully transitioned " + localTarget + " to standby state"); } catch (Exception e) { LOG.error("Couldn't transition " + localTarget + " to standby state", e); // TODO handle this. It's a likely case since we probably got fenced // at the same time. } serviceState = HAServiceState.STANDBY; }
int timeout = FailoverController.getGracefulFenceTimeout(conf) * 2;
int timeout = FailoverController.getGracefulFenceTimeout(conf) * 2;
int timeout = FailoverController.getGracefulFenceTimeout(conf) * 2;
int timeout = FailoverController.getGracefulFenceTimeout(conf) * 2;