You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
maven-javadoc-plugin fails due to Automatic-Module-Name #5136
Error: Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:3.3.2:jar (attach-javadocs) on project dropwizard-testing: MavenReportException: Error while generating Javadoc:
Error: Exit code: 1 - /home/runner/work/dropwizard/dropwizard/dropwizard-testing/src/main/java/io/dropwizard/testing/common/DropwizardTestResourceConfig.java:22: error: cannot access ResourceConfig
Error: class DropwizardTestResourceConfig extends DropwizardResourceConfig {
Error: ^
Error: class file for org.glassfish.jersey.server.ResourceConfig not found
Error: /home/runner/work/dropwizard/dropwizard/dropwizard-testing/src/main/java/io/dropwizard/testing/junit5/DropwizardExtensionsSupport.java:8: error: package org.junit.platform.commons.util is not visible
Error: import org.junit.platform.commons.util.ReflectionUtils;
Error: ^
Error: (package org.junit.platform.commons.util is declared in module org.junit.platform.commons, which does not export it to module io.dropwizard.testing)
Error:
Error: Command line was: /usr/lib/jvm/temurin-11-jdk-amd64/bin/javadoc @options @packages
Should we then migrate from JSR-305 to an other nullness checking library? If so, we could think of checker-qual as a replacement since we already have a dependency on it.
@zUniQueX Unfortunately it's still failing at another location now:
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-javadoc-plugin:3.3.2:jar (attach-javadocs) on project dropwizard-request-logging: MavenReportException: Error while generating Javadoc:
[ERROR] Exit code: 1 - javadoc: error - An internal exception has occurred.
[ERROR] (com.sun.tools.javac.code.Symbol$CompletionFailure: class file for ch.qos.logback.core.AsyncAppenderBase not found)
[ERROR] Please file a bug against the javadoc tool via the Java bug reporting page
[ERROR] (http://bugreport.java.com) after checking the Bug Database (http://bugs.java.com)
[ERROR] for duplicates. Include error messages and the following diagnostic in your report. Thank you.
[ERROR] com.sun.tools.javac.code.Symbol$CompletionFailure: class file for ch.qos.logback.core.AsyncAppenderBase not found
[ERROR]
[ERROR] Command line was: $HOME/.asdf/installs/java/temurin-11.0.13+8/bin/javadoc @options @packages
[ERROR]
[ERROR] Refer to the generated Javadoc files in '$HOME/src/dropwizard/dropwizard-request-logging/target/apidocs' dir.
@joschi I've now further investigated this and this error is really strange. dropwizard-logging also uses the AsyncAppenderBase and there is no error in the JavaDoc generation.
When manually overriding the version of logback-core to 1.3.0-alpha0 and excluding it from all other places, the build of dropwizard-request-logging still works and the JavaDoc-JAR gets generated without an error.
However, when comparing the tags in the logback repo in GitHub, the only changes in AsyncAppenderBase are changes in the JavaDoc of this file itself, which shouldn't cause our problem in my opinion.
I couldn't find a reason why this should be necessary but I don't see an other solution for now. Seems like logback is working on support for Jetty 10 on the 1.3.x branch, so this workaround should be only temporary then.
The error in dropwizard-request-logging is fixed, since the 3.0.x branch now uses Logback 1.3.0, which introduced modules.
However, Jersey is still an issue in dropwizard-testing. The error with the ReflectionUtils class can be fixed easily, but the ResourceConfig class cannot be resolved by the maven-javadoc-plugin.
Activity
Revert "Add automatic module names for all Dropwizard modules" (#5137)
joschi commentedon Apr 8, 2022
https://nipafx.dev/jsr-305-java-9/
zUniQueX commentedon Apr 8, 2022
Should we then migrate from JSR-305 to an other nullness checking library? If so, we could think of
checker-qualas a replacement since we already have a dependency on it.zUniQueX commentedon Apr 18, 2022
Since #5176 is merged, should we re-introduce the module names?
joschi commentedon Apr 18, 2022
@zUniQueX Unfortunately it's still failing at another location now:
zUniQueX commentedon May 5, 2022
@joschi I've now further investigated this and this error is really strange.
dropwizard-loggingalso uses theAsyncAppenderBaseand there is no error in the JavaDoc generation.When manually overriding the version of
logback-coreto1.3.0-alpha0and excluding it from all other places, the build ofdropwizard-request-loggingstill works and the JavaDoc-JAR gets generated without an error.However, when comparing the tags in the logback repo in GitHub, the only changes in
AsyncAppenderBaseare changes in the JavaDoc of this file itself, which shouldn't cause our problem in my opinion.zUniQueX commentedon May 10, 2022
To not override the
logback-coredependency to an other version, we could introduce the following javadoc configuration as a workaround:I couldn't find a reason why this should be necessary but I don't see an other solution for now. Seems like logback is working on support for Jetty 10 on the 1.3.x branch, so this workaround should be only temporary then.
zUniQueX commentedon Sep 2, 2022
The error in
dropwizard-request-loggingis fixed, since the 3.0.x branch now uses Logback 1.3.0, which introduced modules.However, Jersey is still an issue in
dropwizard-testing. The error with theReflectionUtilsclass can be fixed easily, but theResourceConfigclass cannot be resolved by themaven-javadoc-plugin.