}
private EventSession findEventSession(EventSource hibernateSession) {
if (hibernateSession.isTransactionInProgress()) {
final Transaction transaction = hibernateSession.getTransaction();
EventSession session = _map.get(transaction);
if (session == null) {
session = _batchedEventProcessor.startSession();
transaction.registerSynchronization(new Esi4JHibernateSynchronization(transaction));