Skip to content

[Issue 4480] Support setting zk chroot path when initialize cluster metadata #4502

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Jun 14, 2019

Conversation

murong00
Copy link
Contributor

Motivation

Fixes #4480

Modifications

Create the zookeeper chroot path at first if it doesn't exist.

@@ -93,7 +92,7 @@
private String globalZookeeper;

@Parameter(names = { "-cs",
"--configuration-store" }, description = "Configuration Store connection string", required = false)
"--configuration-store" }, description = "Configuration Store connection string", required = true)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @murong00, Is this change necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If someone missed this option, it will print error Configuration store address argument is required (--configuration-store) since --global-zookeeper option is hidden . So it may be better to make this option required.

@jiazhai jiazhai requested review from sijie and merlimat June 11, 2019 01:44
@jiazhai jiazhai added this to the 2.4.0 milestone Jun 11, 2019
@@ -273,6 +270,29 @@ public static void main(String[] args) throws Exception {
log.info("Cluster metadata for '{}' setup correctly", arguments.cluster);
}

private static ZooKeeper initZk(String connection, int sessionTimeout) throws Exception {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@murong00 can you rewrite unit tests for this method?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added.

@sijie
Copy link
Member

sijie commented Jun 13, 2019

@jiazhai can you review this again?

@jiazhai jiazhai merged commit e19e5ba into apache:master Jun 14, 2019
@murong00 murong00 deleted the branch-4502 branch March 8, 2020 04:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Specify zk chroot path failed when initialize cluster metadata
3 participants