if ( ownerEntry != null ) {
ownerId = ownerEntry.getId();
}
}
if ( ownerId == null ) {
throw new AssertionFailure( "Unable to determine collection owner identifier for orphan-delete processing" );
}
}
EntityKey key = new EntityKey(
ownerId,
loadedPersister.getOwnerEntityPersister(),
session.getEntityMode()
);
Object owner = persistenceContext.getEntity(key);
if ( owner == null ) {
throw new AssertionFailure(
"collection owner not associated with session: " +
loadedPersister.getRole()
);
}
EntityEntry e = persistenceContext.getEntry(owner);