public class ControllerServerConfig extends QuorumPeerConfig
QuorumPeerConfig.ConfigException
Modifier and Type | Field and Description |
---|---|
static String |
CLIENT_PORT_KEY |
static String |
CONTROLLER_PORT_KEY |
clientPortAddress, clientPortListenBacklog, configFileStr, connectToLearnerMasterLimit, dataDir, dataLogDir, dynamicConfigFileStr, electionAlg, electionPort, initialConfig, initLimit, jvmPauseInfoThresholdMs, jvmPauseMonitorToRun, jvmPauseSleepTimeMs, jvmPauseWarnThresholdMs, lastSeenQuorumVerifier, localSessionsEnabled, localSessionsUpgradingEnabled, maxClientCnxns, maxSessionTimeout, metricsProviderClassName, metricsProviderConfiguration, minSessionTimeout, nextDynamicConfigFileSuffix, observerMasterPort, peerType, purgeInterval, quorumCnxnThreadsSize, quorumEnableSasl, quorumLearnerLoginContext, quorumLearnerRequireSasl, quorumListenOnAllIPs, quorumServerLoginContext, quorumServerRequireSasl, quorumServicePrincipal, quorumVerifier, secureClientPortAddress, serverId, shouldUsePortUnification, snapRetainCount, sslQuorum, sslQuorumReloadCertFiles, syncEnabled, syncLimit, tickTime
Constructor and Description |
---|
ControllerServerConfig(InetAddress hostAddress,
int controllerPort,
int zkServerPort,
String dataDirPath)
Instantiate a config object with required parameters.
|
ControllerServerConfig(int controllerPort,
int zkServerPort,
String dataDirPath)
Instantiate a config object with required parameters.
|
ControllerServerConfig(String configFile)
Instantiate a new config via a zk config file.
|
Modifier and Type | Method and Description |
---|---|
void |
ensureComplete()
Ensure config is acceptable by filling in default values for any missing quorum configuration
(specifically in the case of a single machine ensemble)
|
InetSocketAddress |
getControllerAddress() |
ServerConfig |
getZooKeeperServerConfig() |
void |
parse(String configFile)
Parse a ZooKeeper configuration file
|
areLocalSessionsEnabled, checkValidity, configureSSLAuth, deleteFile, editStaticConfig, getClientPortAddress, getClientPortListenBacklog, getConfigFilename, getConnectToLearnerMasterLimit, getDataDir, getDataLogDir, getElectionAlg, getElectionPort, getInitialConfig, getInitLimit, getJvmPauseInfoThresholdMs, getJvmPauseSleepTimeMs, getJvmPauseWarnThresholdMs, getLastSeenQuorumVerifier, getMaxClientCnxns, getMaxSessionTimeout, getMetricsProviderClassName, getMetricsProviderConfiguration, getMinSessionTimeout, getMultiAddressReachabilityCheckTimeoutMs, getObserverMasterPort, getPeerType, getPurgeInterval, getQuorumListenOnAllIPs, getQuorumVerifier, getSecureClientPortAddress, getServerId, getServers, getSnapRetainCount, getSyncEnabled, getSyncLimit, getTickTime, getVersionFromFilename, isDistributed, isJvmPauseMonitorToRun, isLocalSessionsUpgradingEnabled, isMultiAddressEnabled, isMultiAddressReachabilityCheckEnabled, isReconfigEnabled, isSslQuorum, isStandaloneEnabled, parseDynamicConfig, parseProperties, setReconfigEnabled, setStandaloneEnabled, shouldUsePortUnification, writeDynamicConfig
public static final String CONTROLLER_PORT_KEY
public static final String CLIENT_PORT_KEY
public ControllerServerConfig(String configFile) throws QuorumPeerConfig.ConfigException
configFile
- path to the configuration fileConfigException
QuorumPeerConfig.ConfigException
public ControllerServerConfig(InetAddress hostAddress, int controllerPort, int zkServerPort, String dataDirPath)
hostAddress
- The address to bind to (likely loopback or localhost)controllerPort
- Port the controller will listen for incoming control command sent from CommandClient.zkServerPort
- Port the ZooKeeper server will listen on.dataDirPath
- Path to the data directory that ZooKeeperServer uses.public ControllerServerConfig(int controllerPort, int zkServerPort, String dataDirPath)
controllerPort
- Port the controller will listen for incoming control command sent from CommandClient.zkServerPort
- Port the ZooKeeper server will listen on.dataDirPath
- Path to the data directory that ZooKeeperServer uses.public InetSocketAddress getControllerAddress()
public ServerConfig getZooKeeperServerConfig()
public void parse(String configFile) throws QuorumPeerConfig.ConfigException
QuorumPeerConfig
parse
in class QuorumPeerConfig
configFile
- the patch of the configuration fileQuorumPeerConfig.ConfigException
- error processing configurationpublic void ensureComplete() throws IOException
IOException
Copyright © 2008–2021 The Apache Software Foundation. All rights reserved.