MCPcopy
hub / github.com/apache/zookeeper

github.com/apache/zookeeper @release-3.9.5 sqlite

repository ↗ · DeepWiki ↗ · release release-3.9.5 ↗
11,576 symbols 50,314 edges 1,008 files 2,738 documented · 24%
README

README file for Packaging Notes

The ZooKeeper project publishes releases as tarballs. For ZooKeeper packages specific to your OS (such as rpm and deb), consider using Apache Bigtop:

http://bigtop.apache.org/

Requirements

  • you need maven to build the java code
  • gcc, cppunit, openssl and python-setuptools are required to build C and python bindings (only needed when using -Pfull-build). Cyrus SASL is optional, but recommended for a maximally functional client.

On RHEL machine:

yum install cppunit
yum install python-setuptools
yum install openssl openssl-devel
yum install cyrus-sasl-md5 cyrus-sasl-gssapi cyrus-sasl-devel

On Ubuntu (in case of 16.4+):

apt-get install libcppunit-dev
apt-get install python-setuptools python2.7-dev
apt-get install openssl libssl-dev
apt-get install libsasl2-modules-gssapi-mit libsasl2-modules libsasl2-dev

Package build command (using maven)

Commands to clean everything and build the tarball package without executing the tests: mvn clean install -DskipTests

zookeeper-assembly/target/apache-zookeeper-<version>-bin.tar.gz tarball file structure layout:

  • /bin - User executables
  • /conf - Configuration files
  • /lib - ZooKeeper JAR files and all the required java library dependencies
  • /docs - Documents

Beside the binary tarball, you can find the whole original source project packaged into: zookeeper-assembly/target/apache-zookeeper-<version>.tar.gz

Building the C client (using maven)

To also build the C client, you need to activate the full-build profile:

mvn clean -Pfull-build
mvn install -Pfull-build -DskipTests

Optional parameters you might consider when using maven: - -Pfull-build - activates the full-build profile, causing the C client to be built - -DskipTests - this parameter will skip both java and C++ unit test execution during the build - -Pc-test-coverage - activates the test coverage calculation during the execution of C client tests - -Dc-client-openssl - specify ssl support and openssl library location. Default value: yes, resulting in the autodetection of the openssl library. If the openssl library will not be detected, then a warning will be shown and the C client will be compiled without SSL support. Use -Dc-client-openssl=no to explicitly disable SSL feature in C client. Or use -Dc-client-openssl=/path/to/openssl/ if you want to use a non-default / specific openssl library location. - -Dc-client-sasl - specify SASL support and Cyrus SASL 1.x library location. Works similarly to the c-client-openssl flag above (yes, no, or path).

Please note: if you don't provide the -Pfull-build parameter, then the C client will not be built, the C client tests will not be executed and the previous C client builds will no be cleaned up (e.g. with simply using mvn clean).

The compiled C client can be found here: - zookeeper-client/zookeeper-client-c/target/c/bin - User executable - zookeeper-client/zookeeper-client-c/target/c/lib - Native libraries - zookeeper-client/zookeeper-client-c/target/c/include/zookeeper - Native library headers

The same folders gets archived to the zookeeper-assembly/target/apache-zookeeper-<version>-lib.tar.gz file, assuming you activated the full-build maven profile.

Extension points exported contracts — how you extend this code

Record (Interface)
Interface that is implemented by generated classes. [12 implementers]
zookeeper-jute/src/main/java/org/apache/jute/Record.java
ZooInspectorNodeManager (Interface)
A Manager for all interactions between the application and the nodes in a Zookeeper instance [9 implementers]
zookeeper-contrib/zookeeper-contrib-zooinspector/src/main/java/org/apache/zookeeper/inspector/manager/ZooInspectorNodeManager.java
Instance (Interface)
This interface is implemented by a class that can be run in an instance container. [6 implementers]
zookeeper-it/src/main/java/org/apache/zookeeper/test/system/Instance.java
DigestWatcher (Interface)
This interface is used to notify the digest mismatch event. [57 implementers]
zookeeper-server/src/main/java/org/apache/zookeeper/DigestWatcher.java
ZooKeeperOperation (Interface)
A callback object which can be used for implementing retry-able operations in the {@link org.apache.zookeeper.recipes.lo [5 …
zookeeper-recipes/zookeeper-recipes-lock/src/main/java/org/apache/zookeeper/recipes/lock/ZooKeeperOperation.java
LogSource (Interface)
(no doc) [8 implementers]
zookeeper-contrib/zookeeper-contrib-loggraph/src/main/java/org/apache/zookeeper/graph/LogSource.java
LeaderElectionAware (Interface)
An interface to be implemented by clients that want to receive election events. [1 implementers]
zookeeper-recipes/zookeeper-recipes-election/src/main/java/org/apache/zookeeper/recipes/leader/LeaderElectionAware.java
TestReader (Interface)
(no doc) [7 implementers]
zookeeper-jute/src/test/java/org/apache/jute/TestReader.java

Core symbols most depended-on inside this repo

get
called by 1058
zookeeper-server/src/main/java/org/apache/zookeeper/metrics/Gauge.java
add
called by 1002
zookeeper-server/src/main/java/org/apache/zookeeper/metrics/Summary.java
put
called by 687
zookeeper-server/src/main/java/org/apache/zookeeper/server/NodeHashMap.java
append
called by 656
zookeeper-server/src/main/java/org/apache/zookeeper/server/persistence/TxnLog.java
toString
called by 630
zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/flexible/QuorumVerifier.java
setProperty
called by 573
zookeeper-server/src/main/java/org/apache/zookeeper/common/ZKConfig.java
write
called by 448
zookeeper-jute/src/test/java/org/apache/jute/TestWriter.java
size
called by 432
zookeeper-server/src/main/java/org/apache/zookeeper/server/NodeHashMap.java

Shape

Method 9,546
Class 1,385
Function 477
Interface 118
Enum 50

Languages

Java94%
TypeScript4%
Python3%

Modules by API surface

zookeeper-docs/src/main/resources/markdown/skin/prototype.js312 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/QuorumPeer.java189 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/ZooKeeperServer.java153 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/admin/Commands.java98 symbols
zookeeper-server/src/test/java/org/apache/zookeeper/test/AsyncOps.java96 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/quorum/Leader.java93 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/ZooKeeperServerBean.java84 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/DataTree.java83 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/server/ZooKeeperServerMXBean.java81 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/ClientCnxn.java81 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/KeeperException.java78 symbols
zookeeper-server/src/main/java/org/apache/zookeeper/ZooKeeper.java77 symbols

Dependencies from manifests, versioned

asm:asm
ch.qos.logback:logback-classic
ch.qos.logback:logback-core
com.github.spotbugs:spotbugs-annotations
com.puppycrawl.tools:checkstyle
com.sun.grizzly:grizzly-servlet-webserver
com.sun.jersey:jersey-client
com.sun.jersey:jersey-json
com.sun.jersey:jersey-server
commons-cli:commons-cli

For agents

$ claude mcp add zookeeper \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact