Skip to content
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

Javadoc does not handle annotations in package-info.java correctly #295

Open
Aerixs opened this issue Nov 9, 2022 · 0 comments
Open

Javadoc does not handle annotations in package-info.java correctly #295

Aerixs opened this issue Nov 9, 2022 · 0 comments

Comments

@Aerixs
Copy link

Aerixs commented Nov 9, 2022

In 11.0.17.8.1 the OpenJDK version was updated. Javadoc in this OpenJDK version fails to resolve package level annotations in package-info.java. See also: https://bugs.openjdk.org/browse/JDK-8295850.

I've attached a simple Spring Boot Sample project where I added the situation where this error occurs. Using jaxb2 to generate example classes, which creates a package-info.java file.

demo-with-javadoc-jaxb2.zip

On Amazon Corretto 11.0.17 ./mvnw verify gives the following error:

[ERROR] /Users/<user>/Downloads/demo/target/generated-sources/xjc/com/example/demo/dto/package-info.java:8: error: unknown tag: javax.xml.bind.annotation.XmlSchema
[ERROR] @javax.xml.bind.annotation.XmlSchema(namespace = "http://localhost/WebService/", elementFormDefault = javax.xml.bind.annotation.XmlNsForm.QUALIFIED)
[ERROR] ^
[ERROR] 
[ERROR] Command line was: /Users/<user>/.sdkman/candidates/java/11.0.17-amzn/bin/javadoc @options @packages

On Amazon Corretto 11.0.16 this command does not fail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant