title: Compile-time checks for JPA entities and queries
body: <p>Some IDEs (I'm looking at you, IntelliJ IDEA) are able to perform some static checking of both JPA entity classes, as well as queries, including parameters.</p>
  
  <p>Are there any ways to do the same thing at compile time, so that such checks could be integrated into the build process, similar to running unit tests? Obviously, a good unit test suite will exercise all of the entities and queries, but it would be nice to be able to have this extra level of validation.</p>