Skip to content

Commit b1319ad

Browse files
gavinkingbeikov
authored andcommitted
HHH-17683 never look for session getters in mapped superclasses or embeddables
1 parent 8837090 commit b1319ad

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tooling/metamodel-generator/src/main/java/org/hibernate/jpamodelgen/annotation/AnnotationMetaEntity.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,9 @@ else if ( containsAnnotation( method, Constants.HQL, Constants.SQL, Constants.FI
302302
}
303303

304304
private void findSessionGetter(TypeElement type) {
305-
if ( !containsAnnotation( type, Constants.ENTITY ) ) {
305+
if ( !containsAnnotation( type, Constants.ENTITY )
306+
&& !containsAnnotation( type, Constants.MAPPED_SUPERCLASS )
307+
&& !containsAnnotation( type, Constants.EMBEDDABLE ) ) {
306308
for ( ExecutableElement method : methodsIn( type.getEnclosedElements() ) ) {
307309
if ( isSessionGetter( method ) ) {
308310
dao = true;

0 commit comments

Comments
 (0)