HHH-10900 - ExceptionConverter throws an exception if the Proxy is no longer reachable
This commit is contained in:
parent
9c74438e99
commit
dc5fe2cde8
|
@ -191,7 +191,7 @@ public class ExceptionConverterImpl implements ExceptionConverter {
|
|||
final Serializable identifier = sose.getIdentifier();
|
||||
if ( identifier != null ) {
|
||||
try {
|
||||
final Object entity = sharedSessionContract.load( sose.getEntityName(), identifier );
|
||||
final Object entity = sharedSessionContract.internalLoad( sose.getEntityName(), identifier, false, true);
|
||||
if ( entity instanceof Serializable ) {
|
||||
//avoid some user errors regarding boundary crossing
|
||||
pe = new OptimisticLockException( e.getMessage(), e, entity );
|
||||
|
|
Loading…
Reference in New Issue