ZOOKEEPER-4037: Closing autoCloseable resource with try-with-resources block

Author: lan <1728209643@qq.com>

Reviewers: maoling <maoling199210191@sina.com>, Matteo Minardi <matteo.minardi@diennea.com>

Closes #1565 from lanicc/ZOOKEEPER-4037
1 file changed
tree: 78b24cfe79b340ddae82abe17ed073f629723927
  1. .github/
  2. bin/
  3. conf/
  4. dev/
  5. tools/
  6. zookeeper-assembly/
  7. zookeeper-client/
  8. zookeeper-compatibility-tests/
  9. zookeeper-contrib/
  10. zookeeper-docs/
  11. zookeeper-it/
  12. zookeeper-jute/
  13. zookeeper-metrics-providers/
  14. zookeeper-recipes/
  15. zookeeper-server/
  16. .asf.yaml
  17. .gitattributes
  18. .gitignore
  19. .travis.yml
  20. checkstyle-simple.xml
  21. checkstyle-strict.xml
  22. checkstyleSuppressions.xml
  23. excludeFindBugsFilter.xml
  24. Jenkinsfile
  25. Jenkinsfile-owasp
  26. Jenkinsfile-PreCommit
  27. LICENSE.txt
  28. NOTICE.txt
  29. owaspSuppressions.xml
  30. pom.xml
  31. README.md
  32. README_packaging.md
  33. zk-merge-pr.py
README.md

Apache ZooKeeper GitHub Actions CI Travis CI Maven Central License

alt text

For the latest information about Apache ZooKeeper, please visit our website at:

https://zookeeper.apache.org

and our wiki, at:

https://cwiki.apache.org/confluence/display/ZOOKEEPER

Packaging/release artifacts

Either downloaded from https://zookeeper.apache.org/releases.html or found in zookeeper-assembly/target directory after building the project with maven.

apache-zookeeper-[version].tar.gz

    Contains all the source files which can be built by running:
    mvn clean install

    To generate an aggregated apidocs for zookeeper-server and zookeeper-jute:
    mvn javadoc:aggregate
    (generated files will be at target/site/apidocs)

apache-zookeeper-[version]-bin.tar.gz

    Contains all the jar files required to run ZooKeeper
    Full documentation can also be found in the docs folder

As of version 3.5.5, the parent, zookeeper and zookeeper-jute artifacts are deployed to the central repository after the release is voted on and approved by the Apache ZooKeeper PMC:

https://repo1.maven.org/maven2/org/apache/zookeeper/zookeeper

Java 8

If you are going to compile with Java 1.8, you should use a recent release at u211 or above.

Contributing

We always welcome new contributors to the project! See How to Contribute for details on how to submit patch through pull request and our contribution workflow.