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
I have added jpa2ddl to a project where I also ahve source classes.
jpa2ddl generates nothing, even if configuration is very similar to the one in example.
After debuggging, I found out that FileResolver#listClassNamesInPackage(...) associates the package name to the source folder of my classes (and not the classes folder). As a consequence, contained files are .java which the pathMatcher object can't recognize as .class. And in turn, this prevent my classes from being recognized and creates an empty schema.
Possible solutions are
Tweak the contect class loader to not use the src/main/java folder but the target/classes one
Change the pathMatcher to match .java and .class files. This one is way easier.
The text was updated successfully, but these errors were encountered:
By default the plugin runs in the process-classes phase which is executed after compiling all classes. The classpath contains the target as well as the src directory. Could you please provide us with the https://stackoverflow.com/help/minimal-reproducible-example ?
I have added jpa2ddl to a project where I also ahve source classes.
jpa2ddl generates nothing, even if configuration is very similar to the one in example.
After debuggging, I found out that
FileResolver#listClassNamesInPackage(...)
associates the package name to the source folder of my classes (and not the classes folder). As a consequence, contained files are.java
which thepathMatcher
object can't recognize as.class
. And in turn, this prevent my classes from being recognized and creates an empty schema.Possible solutions are
src/main/java
folder but thetarget/classes
one.java
and.class
files. This one is way easier.The text was updated successfully, but these errors were encountered: