ZOOKEEPER-3423:use the maven-like way to ignore the generated version java files and doc the cmd:'./zkServer.sh version'#980
Conversation
maoling
commented
Jun 11, 2019
- more details in the ZOOKEEPER-3423
|
I will wait for @nkalmar feedback Another maven-like approach would be to create such files into ${project.build.directory}/generated-sources/versioninfo |
.gitignore
Outdated
| zookeeper-client/zookeeper-client-c/ltmain.sh | ||
| zookeeper-client/zookeeper-client-c/missing | ||
| zookeeper-server/src/main/java/org/apache/zookeeper/version/Info.java | ||
| zookeeper-server/src/main/java/org/apache/zookeeper/version/VersionInfoMain.java |
There was a problem hiding this comment.
I just noticed this issue during a build, good to fix. I agree with Norbert - this should be part of "generate-sources" phase/directory.
c2f9a2f to
caed68e
Compare
|
@eolivelli Could you plz offer some help? :D |
|
Ant PreCommit has failed which will be discarded? this PR works well in my local. |
eolivelli
left a comment
There was a problem hiding this comment.
Sorry for late reply.
Your change is perfect!
I left a just a comment. Please take a look.
In theory I have disabled the ant precommit but in practice it is still kicking in.
Do not consider it
| rev = rev.trim(); | ||
| } | ||
| generateFile(new File("."), version, rev, args[2]); | ||
| generateFile(new File("../../../target/generated-sources/java"), version, rev, args[2]); |
There was a problem hiding this comment.
It is better to have this path passed as a parameter, this way it will be easier to drive this code from the pom.xml
|
Neat, thanks for the documentation! :) |
|
I'm afraid this causes the ant build to fail. "ant clean compile-test" failed with compilation errors. |
|
Running |
|
retest this please |
|
I also have compile errors with Ant: Though I've just disabled the Ant precommit job on master, so we won't see it running again. |
|
@maoling please fix it, it should be in the configuration of javac in build.xml you have to add the new directory |
|
retest ant build |
1 similar comment
|
retest ant build |
nkalmar
left a comment
There was a problem hiding this comment.
Sorry for the late entry.
This is looking good now, +1 from my side.
|
pinging @eolivelli because of his -1 on this. (I believe all concerns are fixed now). |
|
Committed to master, thanks @maoling |
…n java files and doc the cmd:'./zkServer.sh version' - more details in the[ ZOOKEEPER-3423](https://issues.apache.org/jira/browse/ZOOKEEPER-3423) Author: maoling <maoling199210191@sina.com> Reviewers: Enrico Olivelli <eolivelli@apache.org>, Norbert Kalmar <nkalmar@apache.org> Closes apache#980 from maoling/ZOOKEEPER-3423
…n java files and doc the cmd:'./zkServer.sh version' - more details in the[ ZOOKEEPER-3423](https://issues.apache.org/jira/browse/ZOOKEEPER-3423) Author: maoling <maoling199210191@sina.com> Reviewers: Enrico Olivelli <eolivelli@apache.org>, Norbert Kalmar <nkalmar@apache.org> Closes apache#980 from maoling/ZOOKEEPER-3423
…n java files and doc the cmd:'./zkServer.sh version' - more details in the[ ZOOKEEPER-3423](https://issues.apache.org/jira/browse/ZOOKEEPER-3423) Author: maoling <maoling199210191@sina.com> Reviewers: Enrico Olivelli <eolivelli@apache.org>, Norbert Kalmar <nkalmar@apache.org> Closes apache#980 from maoling/ZOOKEEPER-3423