You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@helix.apache.org by GitBox <gi...@apache.org> on 2020/08/27 16:38:41 UTC

[GitHub] [helix] brentwritescode opened a new issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

brentwritescode opened a new issue #1319:
URL: https://github.com/apache/helix/issues/1319


   ### Describe the bug
   The documentation for building Apache Helix on https://helix.apache.org/1.0.1-docs/Building.html and https://helix.apache.org/ states that Apache Helix is compatible with JDK 1.8+, Maven 3.5.0+, but the build fails with Java 11 with the following error:
   
   ```
   %> sudo mvn install package -DskipTests
   [INFO] BUILD FAILURE
   [INFO] ------------------------------------------------------------------------
   [INFO] Total time:  01:06 min
   [INFO] Finished at: 2020-08-12T21:42:06Z
   [INFO] ------------------------------------------------------------------------
   [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:2.5.1:compile (default-compile) on project zookeeper-api: Compilation failure: Compilation failure:
   [ERROR] /home/brent/helix/zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkServer.java:[23,23] error: package javax.annotation does not exist
   [ERROR] /home/brent/helix/zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkServer.java:[24,23] error: package javax.annotation does not exist
   [ERROR] /home/brent/helix/zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkServer.java:[79,5] error: cannot find symbol
   [ERROR]   symbol:   class PostConstruct
   [ERROR]   location: class ZkServer
   [ERROR] /home/brent/helix/zookeeper-api/src/main/java/org/apache/helix/zookeeper/zkclient/ZkServer.java:[148,5] error: cannot find symbol
   [ERROR] -> [Help 1]
   [ERROR]
   [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
   [ERROR] Re-run Maven using the -X switch to enable full debug logging.
   [ERROR]
   [ERROR] For more information about the errors and possible solutions, please read the following articles:
   [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
   [ERROR]
   [ERROR] After correcting the problems, you can resume the build with the command
   [ERROR]   mvn <goals> -rf :zookeeper-api
   ```
   
   ### To Reproduce
   
   Run `sudo mvn install package -DskipTests` with Java 11 as the default JDK.
   
   ### Expected behavior
   One of two things:
   
   1. Apache Helix successfully builds with Java 11
   
   OR
   
   2.  The documentation is updated to indicate that Java 11 (and beyond) are not currently supported
   
   ### Additional context
   
   The issue stems from the fact that, as of Java 11, some legacy J2EE-related packages such as javax.annotation.* and javax.xml.bind.* have been removed from the JDK, but the `helix/zookeeper-api` and `helix-core` sub-builds of the project still require these libraries.
   
   The issue can be fixed for Java 11 by adding the following dependency to `helix/zookeeper-api/pom.xml`:
   
   ```
   <dependency>
     <groupId>javax.annotation</groupId>
     <artifactId>javax.annotation-api</artifactId>
     <version>1.3.2</version>
   </dependency>
   ```
   
   And by adding the following dependency to `helix/helix-core/pom.xml`:
   
   ```
   <dependency>
     <groupId>javax.xml.bind</groupId>
     <artifactId>jaxb-api</artifactId>
     <version>2.1</version>
   </dependency>
   ```
   
   Those two additions re-add the packages that have been removed from Java 11 and allow the build to complete successfully.
   
   I understand that claiming full Java 11 support is a large undertaking, so if Java 11 and beyond are not officially supported, it would be great if the corresponding documentation on pages like https://helix.apache.org/ and https://helix.apache.org/1.0.1-docs/Building.html could be clear about indicating this.
   
   Unfortunately for me, Java 11 was the default on my OS (Ubuntu 18.04) and I lost a few hours tracking this down.  My hope is that we can save some other developers from chasing down the same issue.  I'd be happy to submit a pull request if that would be helpful, just let me know.  Thank you!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode removed a comment on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode removed a comment on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685007677


   Great, thank you for the details.
   
   As a side note (if this derails this discussion, feel free to ignore) have you considered creating a `contributors.md` or `contributing.md` file as recommended by https://docs.github.com/en/github/building-a-strong-community/setting-guidelines-for-repository-contributors somewhere in the root of the project?  That's at least where I've been conditioned to look for that stuff if it's not mentioned in the README.md (e.g. https://github.com/apache/kafka/blob/trunk/CONTRIBUTING.md).
   
   UPDATE: I just discovered these links, ignore the previous comment. :-)
   
   https://github.com/apache/helix/wiki/Pull-Request-Guidelines
   https://github.com/apache/helix/wiki/Pull-Request-Description-Template
   https://github.com/apache/helix/wiki/Pull-Request-Merge-Steps
   https://github.com/apache/helix/wiki/Helix-Code-Style-in-Intellij-IDE
   
   My apologies!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] narendly commented on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
narendly commented on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685000167


   Some general logistics are documented in https://github.com/apache/helix/wiki on the right sidebar.
   
   As for running tests, we follow standard practices for maven projects. There are some failing tests though, so what we want to do is
   
   1. Build the project at the top-level project path (where the parent pom.xml is): mvn clean install package -DskipTests
   2. Run tests for separate modules (e.g. /helix-core, /zookeeper-api, /helix-rest, /helix-common, etc)
   Usually these 4 modules cover everything. Other modules have some failing tests, so I wouldn't be too concerned about those.
   
   With the exception of /helix-core, you should see all tests pass. For helix-core, we see as many as 3-4 failing tests depending on the machine (we are currently trying to stabilize tests). At that point, we run these tests individually using the following mvn command:
   mvn test -Dtest=<your test name>
   
   Usually when the failed tests are run individually, they pass. If they don't that means something went wrong.
   
   It would also be helpful for us to know which tests are failing exactly as well. You could document that in your pull request draft as well.
   
   If this is helpful, you're more than welcome to add this piece of information on the wiki page sidebar for future contributors. 


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode commented on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode commented on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-701496511


   My apologies for the delay @narendly , PR has been submitted (and hopefully passes).
   
   Independent of that, I did end up adding a new https://github.com/apache/helix/wiki/Pull-Request-Testing page if you want to give it a once-over and I linked to it on https://github.com/apache/helix/wiki/Pull-Request-Guidelines as well as under the "Resources for Contributors" section on the sidebar.


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode edited a comment on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode edited a comment on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685007677


   Great, thank you for the details.
   
   As a side note (if this derails this discussion, feel free to ignore) have you considered creating a `contributors.md` or `contributing.md` file as recommended by https://docs.github.com/en/github/building-a-strong-community/setting-guidelines-for-repository-contributors somewhere in the root of the project?  That's at least where I've been conditioned to look for that stuff if it's not mentioned in the README.md (e.g. https://github.com/apache/kafka/blob/trunk/CONTRIBUTING.md).
   
   UPDATE: I just discovered these links, ignore the previous comment. :-)
   
   https://github.com/apache/helix/wiki/Pull-Request-Guidelines
   https://github.com/apache/helix/wiki/Pull-Request-Description-Template
   https://github.com/apache/helix/wiki/Pull-Request-Merge-Steps
   https://github.com/apache/helix/wiki/Helix-Code-Style-in-Intellij-IDE
   
   My apologies!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode removed a comment on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode removed a comment on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685007677


   Great, thank you for the details.
   
   As a side note (if this derails this discussion, feel free to ignore) have you considered creating a `contributors.md` or `contributing.md` file as recommended by https://docs.github.com/en/github/building-a-strong-community/setting-guidelines-for-repository-contributors somewhere in the root of the project?  That's at least where I've been conditioned to look for that stuff if it's not mentioned in the README.md (e.g. https://github.com/apache/kafka/blob/trunk/CONTRIBUTING.md).
   
   UPDATE: I just discovered these links, ignore the previous comment. :-)
   
   https://github.com/apache/helix/wiki/Pull-Request-Guidelines
   https://github.com/apache/helix/wiki/Pull-Request-Description-Template
   https://github.com/apache/helix/wiki/Pull-Request-Merge-Steps
   https://github.com/apache/helix/wiki/Helix-Code-Style-in-Intellij-IDE
   
   My apologies!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] narendly closed issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
narendly closed issue #1319:
URL: https://github.com/apache/helix/issues/1319


   


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode commented on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode commented on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685007677


   Great, thank you for the details.
   
   As a side note (if this derails this discussion, feel free to ignore) have you considered creating a `contributors.md` or `contributing.md` file as recommended by https://docs.github.com/en/github/building-a-strong-community/setting-guidelines-for-repository-contributors somewhere in the root of the project?  That's at least where I've been conditioned to look for that stuff if it's not mentioned in the README.md (e.g. https://github.com/apache/kafka/blob/trunk/CONTRIBUTING.md).


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode edited a comment on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode edited a comment on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-685007677


   Great, thank you for the details.
   
   As a side note (if this derails this discussion, feel free to ignore) have you considered creating a `contributors.md` or `contributing.md` file as recommended by https://docs.github.com/en/github/building-a-strong-community/setting-guidelines-for-repository-contributors somewhere in the root of the project?  That's at least where I've been conditioned to look for that stuff if it's not mentioned in the README.md (e.g. https://github.com/apache/kafka/blob/trunk/CONTRIBUTING.md).
   
   UPDATE: I just discovered these links, ignore the previous comment. :-)
   
   https://github.com/apache/helix/wiki/Pull-Request-Guidelines
   https://github.com/apache/helix/wiki/Pull-Request-Description-Template
   https://github.com/apache/helix/wiki/Pull-Request-Merge-Steps
   https://github.com/apache/helix/wiki/Helix-Code-Style-in-Intellij-IDE
   
   My apologies!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] narendly commented on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
narendly commented on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-682213761


   @brentwritescode 
   
   Thanks for letting us know. You're right, Helix hasn't actually been tested against Java 11. You're welcome to submit a pull request as this seems to be a straightforward fix that you've already figured out 👍 


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org


[GitHub] [helix] brentwritescode commented on issue #1319: Documentation states build requirements as JDK 1.8+, Maven 3.5.0+, but Helix fails to build for Java 11+

Posted by GitBox <gi...@apache.org>.
brentwritescode commented on issue #1319:
URL: https://github.com/apache/helix/issues/1319#issuecomment-684941020


   Just as a quick follow-up, that seemingly innocuous change causes one of the annotation-oriented unit tests to fail in Java 8, so I need to figure out what's up with that before I submit the PR.
   
   Do you happen to have any instructions for contributors anywhere so I can make sure I'm properly testing and doing whatever else needs doing before I submit?  Thanks!


----------------------------------------------------------------
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:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@helix.apache.org
For additional commands, e-mail: reviews-help@helix.apache.org