Commit 0ef0e255 authored by Flavio Paiva Junqueira's avatar Flavio Paiva Junqueira
Browse files

ZOOKEEPER-1852. ServerCnxnFactory instance is not properly cleanedup (Rakesh R via fpj)

git-svn-id: 13f79535-47bb-0310-9956-ffa450edef68
parent c4996872
......@@ -324,6 +324,9 @@ public abstract class ClientBase extends ZKTestCase {
return Integer.parseInt(portstr);
* Starting the given server instance
public static void startServerInstance(File dataDir,
ServerCnxnFactory factory, String hostPort) throws IOException,
InterruptedException {
......@@ -335,6 +338,20 @@ public abstract class ClientBase extends ZKTestCase {
* This method instantiates a new server. Starting of the server
* instance has been moved to a separate method
* {@link ClientBase#startServerInstance(File, ServerCnxnFactory, String)}.
* Because any exception on starting the server would leave the server
* running and the caller would not be able to shutdown the instance. This
* may affect other test cases.
* @return newly created server instance
* @see <a
* href="">ZOOKEEPER-1852</a>
* for more information.
public static ServerCnxnFactory createNewServerInstance(
ServerCnxnFactory factory, String hostPort, int maxCnxns)
throws IOException, InterruptedException {
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment