} else {
if (execution.getExitCode() == 0) {
log.info("Zookeeper started OK");
File pidFile = getPidFile(instanceDir);
Pid pid = Pid.read(pidFile);
if (pid == null) {
throw new IOException("Zookeeper started, but could not read pid from file");
}
return new ZookeeperProcess(config, pid);