We're updating the issue view to help you get more done. 

IncrediblySillyJpaMapsIdMappedIdentifierValueMarshaller attempts to persist detached entities that are part of a composite Primary key for another entity

Description

I have an entity (BookVersion) with a composite ID consisting of many-to-one links to other entities in the system (BookID,Library). The (BookVersion) entity has an IdClass (BookVersionPK) which maps these to Long values.

When I call merge on a detached instance of the entity (BookVersion) IncrediblySillyJpaMapsIdMappedIdentifierValueMarshaller attempts to find the ID entities (BookID,Library) in the current context these fail which results in "Performing implicit derived identity cascade" which attempts to persist the detached ID entities (BookID,Library)

Environment

None

Status

Assignee

Unassigned

Reporter

Paul Nardone

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Affects versions

3.6.5

Priority

Major