title: @Transaction Issue: TransactionSynchronization.beforeCompletion threw exception
body: <p>I am facing an issue where I have one method which is calling another method in the service layer as follows:</p>
  
  <pre><code>@Transactional
      @Override
      public void method1(List&lt;String&gt; vals)
      {
          for (String value : vals){
              method2(value);
          }
      }
  
  @Transactional(propagation= Propagation.REQUIRED)
  public void method2(String value)
  {
      //Hibernate Call 1
  
      //Hibernate Call 2
  
  }
  </code></pre>
  
  <p>I have put the Transactional annotation in method 2 as it can be called from Controller also.</p>
  
  <p>And my transaction manager looks like this:</p>
  
  <pre><code>&lt;tx:annotation-driven transaction-manager="transactionManager"/&gt;
  &lt;aop:aspectj-autoproxy/&gt;
  
  &lt;!-- Transaction manager for hibernate --&gt;
  
  &lt;bean id="transactionManager"
      class="org.springframework.orm.hibernate3.HibernateTransactionManager"&gt;
      &lt;property name="sessionFactory" ref="sessionFactory" /&gt;
      &lt;property name="dataSource" ref="dataSource"&gt;&lt;/property&gt;
  
  &lt;/bean&gt;
  </code></pre>
  
  <p>When I am running this code when the controller is calling method 1 it is giving the following error :</p>
  
  <blockquote>
    <p>12/22/11 18:4455410: ERROR [    http-8181-1]
    (.support.TransactionSynchronizationUtils:87  ) -
    TransactionSynchronization.beforeCompletion threw exception
    java.lang.IllegalStateException: No value for key
    [org.hibernate.impl.SessionFactoryImpl@1b2668f] bound to thread
    [http-8181-1]
            at org.springframework.transaction.support.TransactionSynchronizationManager.unbindResource(TransactionSynchronizationManager.java:190)
            at org.springframework.orm.hibernate3.SpringSessionSynchronization.beforeCompletion(SpringSessionSynchronization.java:187)
            at org.springframework.transaction.support.TransactionSynchronizationUtils.triggerBeforeCompletion(TransactionSynchronizationUtils.java:84)
            at org.springframework.transaction.support.AbstractPlatformTransactionManager.triggerBeforeCompletion(AbstractPlatformTransactionManager.java:895)
            at org.springframework.transaction.support.AbstractPlatformTransactionManager.processCommit(AbstractPlatformTransactionManager.java:693)
            at org.springframework.transaction.support.AbstractPlatformTransactionManager.commit(AbstractPlatformTransactionManager.java:678)
            at org.springframework.transaction.interceptor.TransactionAspectSupport.commitTransactionAfterReturning(TransactionAspectSupport.java:321)
            at org.springframework.transaction.interceptor.TransactionInterceptor.invoke(TransactionInterceptor.java:116)
            at org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
            at org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
            at $Proxy31.method1(Unknown Source)</p>
  </blockquote>