Uploaded image for project: 'Spring Framework'
  1. Spring Framework
  2. SPR-14359

Hibernate 5.2 misses SessionImplementor.getTransactionCoordinator()

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Invalid
    • Affects Version/s: 4.3 RC1, 4.3 RC2, 4.3 GA
    • Fix Version/s: None
    • Component/s: Core
    • Labels:
      None
    • Last commented by a User:
      true

      Description

      Since updating to Hibernate 5.2 and Spring 4.3.GA our Integrationtests fail with

      java.lang.NoSuchMethodError: org.hibernate.event.spi.EventSource.getTransactionCoordinator()Lorg/hibernate/resource/transaction/TransactionCoordinator;
      
      	at org.hibernate.search.backend.impl.EventSourceTransactionContext.isLocalTransaction(EventSourceTransactionContext.java:117)
      	at org.hibernate.search.backend.impl.EventSourceTransactionContext.registerSynchronization(EventSourceTransactionContext.java:84)
      	at org.hibernate.search.backend.impl.PerTransactionWorker.performWork(PerTransactionWorker.java:73)
      	at org.hibernate.search.event.impl.FullTextIndexEventListener.processWork(FullTextIndexEventListener.java:237)
      	at org.hibernate.search.event.impl.FullTextIndexEventListener.onPostInsert(FullTextIndexEventListener.java:110)
      	at org.hibernate.action.internal.EntityInsertAction.postInsert(EntityInsertAction.java:164)
      	at org.hibernate.action.internal.EntityInsertAction.execute(EntityInsertAction.java:131)
      	at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:560)
      	at org.hibernate.engine.spi.ActionQueue.executeActions(ActionQueue.java:434)
      	at org.hibernate.event.internal.AbstractFlushingEventListener.performExecutions(AbstractFlushingEventListener.java:337)
      	at org.hibernate.event.internal.DefaultFlushEventListener.onFlush(DefaultFlushEventListener.java:39)
      	at org.hibernate.internal.SessionImpl.flush(SessionImpl.java:1396)
      	at org.hibernate.internal.SessionImpl.managedFlush(SessionImpl.java:472)
      	at org.hibernate.internal.SessionImpl.flushBeforeTransactionCompletion(SessionImpl.java:3132)
      	at org.hibernate.internal.SessionImpl.beforeTransactionCompletion(SessionImpl.java:2369)
      	at org.hibernate.engine.jdbc.internal.JdbcCoordinatorImpl.beforeTransactionCompletion(JdbcCoordinatorImpl.java:467)
      	at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.beforeCompletionCallback(JdbcResourceLocalTransactionCoordinatorImpl.java:147)
      	at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl.access$100(JdbcResourceLocalTransactionCoordinatorImpl.java:38)
      	at org.hibernate.resource.transaction.backend.jdbc.internal.JdbcResourceLocalTransactionCoordinatorImpl$TransactionDriverControlImpl.commit(JdbcResourceLocalTransactionCoordinatorImpl.java:221)
      	at org.hibernate.engine.transaction.internal.TransactionImpl.commit(TransactionImpl.java:68)
      	at org.springframework.orm.jpa.JpaTransactionManager.doCommit(JpaTransactionManager.java:517)
      	at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:761)
      	at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:730)
      	at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:485)
      	at org.springframework.transaction.interceptor.TransactionAspectSupport.invokeWithinTransaction(TransactionAspectSupport.java:291)
      	at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:96)
      	at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:179)
      	at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:213)
      	at de.xxx.mad.core.service.spi.ConfigServiceImplTest_IT.ShouldCheckCopyFile(ConfigServiceImplTest_IT.java:348)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at org.springframework.test.context.junit4.statements.RunBeforeTestMethodCallbacks.evaluate(RunBeforeTestMethodCallbacks.java:75)
      	at org.springframework.test.context.junit4.statements.RunAfterTestMethodCallbacks.evaluate(RunAfterTestMethodCallbacks.java:86)
      	at org.springframework.test.context.junit4.statements.SpringRepeat.evaluate(SpringRepeat.java:84)
      	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:252)
      	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.runChild(SpringJUnit4ClassRunner.java:94)
      	at org.springframework.test.context.junit4.statements.RunBeforeTestClassCallbacks.evaluate(RunBeforeTestClassCallbacks.java:61)
      	at org.springframework.test.context.junit4.statements.RunAfterTestClassCallbacks.evaluate(RunAfterTestClassCallbacks.java:70)
      	at org.springframework.test.context.junit4.SpringJUnit4ClassRunner.run(SpringJUnit4ClassRunner.java:191)
      	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:119)
      	at com.intellij.junit4.JUnit4IdeaTestRunner.startRunnerWithArgs(JUnit4IdeaTestRunner.java:42)
      	at com.intellij.rt.execution.junit.JUnitStarter.prepareStreamsAndStart(JUnitStarter.java:234)
      	at com.intellij.rt.execution.junit.JUnitStarter.main(JUnitStarter.java:74)
      	at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at java.lang.reflect.Method.invoke(Method.java:497)
      	at com.intellij.rt.execution.application.AppMain.main(AppMain.java:144)
      

      Looking at the code, the interface org.hibernate.engine.spi.SessionImplementor, which is extended by EventSource lost the method getTransactionCoordinator.

        Attachments

          Activity

            People

            • Assignee:
              snicoll St├ęphane Nicoll
              Reporter:
              fprumbau Frank Prumbaum
              Last updater:
              Niko Wittenbeck
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Days since last comment:
                1 year, 43 weeks, 3 days ago