zookeeper 3.5.9 源码导入idea

clone

git clone -b release-3.5.9 https://github.com/apache/zookeeper.git

compile

mvn clean compile -DskipTests

provided

zookeeper-server下面的pom的 provided都注释掉,应该有7处

<dependency>
    <groupId>jline</groupId>
    <artifactId>jline</artifactId>
    <!--<scope>provided</scope>-->
</dependency>

zoo.cfg

复制zoo_sample.cfg,取名zoo.cfg

 

单机版启动

单机版zookeeper的启动类为org.apache.zookeeper.server.ZooKeeperServerMain

启动配置

zookeeper 3.5.9 源码导入idea

 

Program arguments :  $ProjectFileDir$\conf\zoo.cfg

Main Class : org.apache.zookeeper.server.ZooKeeperServerMain

# -Dlog4j.configuration=file:E:/github_project/zookeeper/conf/log4j.properties 
VM Options: -Dlog4j.configuration=file:$ProjectFileDir$\conf\log4j.properties

启动

zookeeper 3.5.9 源码导入idea

 

 

 

上一篇:pom文件中的project报错红色波浪线


下一篇:Maven: exec-maven-plugin 设置 classpathScope