HHH-13672 The temporary PersistenceContext of a StatelessSession is not cleared after a refresh operation

This commit is contained in:
Andrea Boriero 2019-10-17 14:38:58 +01:00 committed by Sanne Grinovero
parent 43402ea51c
commit 96e7abf80b
1 changed files with 3 additions and 0 deletions

View File

@ -249,6 +249,9 @@ public class StatelessSessionImpl extends AbstractSharedSessionContract implemen
this.getLoadQueryInfluencers().setInternalFetchProfile( previousFetchProfile );
}
UnresolvableObjectException.throwIfNull( result, id, persister.getEntityName() );
if ( temporaryPersistenceContext.isLoadFinished() ) {
temporaryPersistenceContext.clear();
}
}
@Override