@NamedNativeQueries broken on @MappedSuperclass abstract classes
Description
5.4.30.Final breaks @NamedNativeQueries on @MappedSuperclass abstract classes
Latest version of hibernate does not find NamedNativeQueries. All previous version including 5.4.29.Final work with no errors.
Steps to reproduce the error: open attached project hibernate-orm-5-test run ORMUnitTestCase.java test case test will complete succesfully
edit project pom change version.org.hibernate value to 5.4.30.Final rerun test, test will fail
Attachments
1
Activity
Show:
Ivo Hrádek July 5, 2021 at 2:35 PM
Edited
I was looking on this and it seems that from fix of HHHH-14499 [1], classes annotated with MappedSuperclass are skipped and analyzed “indirectly” through their children.
In your example, your MappedSuperclass is not inherited by any entity and hence skipped. Therefore Hibernate does not register any @NamedNativeQuery.
5.4.30.Final breaks @NamedNativeQueries on @MappedSuperclass abstract classes
Latest version of hibernate does not find NamedNativeQueries. All previous version including 5.4.29.Final work with no errors.
Steps to reproduce the error:
open attached project hibernate-orm-5-test
run ORMUnitTestCase.java test case
test will complete succesfully
edit project pom
change version.org.hibernate value to 5.4.30.Final
rerun test, test will fail