SingleIdMapper does not extract values from Id-Class

Description

Hello,

I'm new to your issue tracking system and at first
I would like to thank you for your years of working on hibernate.

I have JPA-Entities with composite primary keys ( and therefore composite foreign keys ).
They consist of (Id : String, ClientId : String) and the Id-Class is not mapped as embedded.

When trying to audit a relation to another entity with envers,
Hibernate's BasicBinder class fails with a ClassCastException on trying to set Id-Class instance to ClientId/Id-values, when trying to persist to the audit table.

After spending a few hours of work, I found out, that in class
org.hibernate.envers.internal.entities.mapper.id.SingleIdMapper.mapToMapFromEntity(...)

properties of the Id-Class are not extracted, when having a proxy.
This seems to be a bug.

Environment

None

Assignee

Chris Cranford

Reporter

Sönke reimer

Fix versions

None

Labels

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Feedback Requested

2019/09/30

Feedback Requested By

Chris Cranford

Components

Affects versions

Priority

Major
Configure