To reassure myself, I started searching the web for ways to do the JPA metamodel creation. At least, fortunately, the problem should be solvable without any social interaction. Both have been there for ages (in terms of project development scale), so also apparently none of the venerable colleagues were to blame, either. I looked at the pom.xml, where we have in the dependencies part Īnd no special compiler plugin configuration for annotation processing, just So, at least IntelliJ is not to blame here. The compiler again spewed a hundred errors at me, then gave up. Since we had experienced difficulties with the metamodel generation by IntelliJ some years ago, I first tried the maven build directly: mvn clean compile The project is built by Apache Maven, and IntelliJ should pick up its project configuration from the pom.xml file. We're generating those classes using the Hibernate's jpamodelgen annotation processor and use IntelliJ as IDE for development. The Java source code of those classes is typically generated by the JPA provider (for example Hibernate) by looking at the source code of your JPA entity classes. Using them, you can avoid using Strings as entity or property names, or avoid casting result values to the correct Java type. They enable you to write Java code for creating database queries in a typesafe way. JPA (Java persistence API) metamodel classes are classes that describe the structure of JPA entity classes (classes used to store database state as Java objects). I'll quickly explain what happened, so you can hopefully quickly walk out of this trap in case you should experience the same. Of course, I did not change anything™ in conjunction with JPA stuff! After making some small changes, the compiler spewed a hundred errors about JPA metamodel classes it could not find before giving up. Yesterday, my Java project stopped compiling.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |