yangl commented on a change in pull request #10715:
URL: https://github.com/apache/pulsar/pull/10715#discussion_r642972503
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/PulsarService.java
##########
@@ -1022,6 +1025,28 @@ public ZooKeeper getZkClient() {
return this.localZooKeeperConnectionProvider.getLocalZooKeeper();
}
+ // get bookkeeper's zookeeper
+ public ZooKeeper getBookieZkClient() {
+ ZooKeeper zkClient = null;
+ String bookkeeperMetadataServiceUri =
config.getBookkeeperMetadataServiceUri();
+ if (StringUtils.isBlank(bookkeeperMetadataServiceUri)) {
+ bookkeeperMetadataServiceUri =
PulsarService.bookieMetadataServiceUri(config);
+ }
+
+ URI uri = URI.create(bookkeeperMetadataServiceUri);
+ String path = ZkUtils.trimLedgersDefaultRootPath(uri.getPath());
+ String bookieZkConnect = StringUtils.replace(uri.getAuthority(), ";",
",") + path;
Review comment:
done.
##########
File path:
pulsar-broker/src/main/java/org/apache/pulsar/broker/PulsarService.java
##########
@@ -1022,6 +1025,28 @@ public ZooKeeper getZkClient() {
return this.localZooKeeperConnectionProvider.getLocalZooKeeper();
}
+ // get bookkeeper's zookeeper
+ public ZooKeeper getBookieZkClient() {
Review comment:
done.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]