Unable to locate MappedSuperclass version attribute when mixing annotations with hibernate mapping files

Description

mapping file

Person.Class

AbstractAggregateRoot.Class

PersonLookupDTO.class

when create jpa query, do projection with dto and try to get the verison field, root.get("version"), an exception throwed. i debug into the source code of hibernate, i found final Property declaredVersion = persistentClass.getDeclaredVersion(); getDeclaredVersion is null, but getVersion has value.

exception details:

Activity

Show:
Fixed

Details

Assignee

Reporter

Worked in

Components

Fix versions

Affects versions

Priority

Created March 6, 2017 at 12:12 PM
Updated March 16, 2017 at 12:54 PM
Resolved March 7, 2017 at 4:32 PM