I have a build that uses the annotation processor plugin to generate JPA criteria classes with the Hibernate JPA 2 Metamodel Generator.
This works well when doing a normal mvn clean package
, but when I build the site, it fails:
[INFO] --- maven-processor-plugin:2.1.0:process (generate-jpa-metamodel) @ phtool-api ---
[INFO] Source directory: C:\jp\esv-projects\phtool\phtool-api\target\generated-sources\jpa added
[INFO] javac option: -cp
[INFO] javac option: ...
[INFO] javac option: -proc:only
[INFO] javac option: -processor
[INFO] javac option: org.hibernate.jpamodelgen.JPAMetaModelEntityProcessor
[INFO] javac option: -d
[INFO] javac option: C:\jp\esv-projects\phtool\phtool-api\target\classes
[INFO] javac option: -s
[INFO] javac option: C:\jp\esv-projects\phtool\phtool-api\target\generated-sources\jpa
[INFO] diagnostic Note: Hibernate JPA 2 Static-Metamodel Generator 1.2.0.Final
[INFO] diagnostic C:\jp\projects\phtool\phtool-api\target\generated-sources\jpa\phtool\impl\resource\ImageImpl_.java:10: error: duplicate c
lass: phtool.impl.resource.ImageImpl_
I noticed that the plugin runs twice during the site generation, but I don't know why. Perhaps it's a known Javadoc plugin bug?