Package org.apache.zookeeper.server
Class ZooKeeperServerMain
- java.lang.Object
-
- org.apache.zookeeper.server.ZooKeeperServerMain
-
@Public public class ZooKeeperServerMain extends Object
This class starts and runs a standalone ZooKeeperServer.
-
-
Constructor Summary
Constructors Constructor Description ZooKeeperServerMain()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
close()
Shutdowns properly the service, this method is not a public API.int
getClientPort()
int
getSecureClientPort()
protected void
initializeAndRun(String[] args)
static void
main(String[] args)
void
runFromConfig(ServerConfig config)
Run from a ServerConfig.protected void
serverStarted()
protected void
shutdown()
Shutdown the serving instance
-
-
-
Method Detail
-
main
public static void main(String[] args)
-
initializeAndRun
protected void initializeAndRun(String[] args) throws QuorumPeerConfig.ConfigException, IOException, AdminServer.AdminServerException
-
runFromConfig
public void runFromConfig(ServerConfig config) throws IOException, AdminServer.AdminServerException
Run from a ServerConfig.- Parameters:
config
- ServerConfig to use.- Throws:
IOException
AdminServer.AdminServerException
-
shutdown
protected void shutdown()
Shutdown the serving instance
-
getClientPort
public int getClientPort()
-
getSecureClientPort
public int getSecureClientPort()
-
close
public void close()
Shutdowns properly the service, this method is not a public API.
-
serverStarted
protected void serverStarted()
-
-