title: Spring+JPA @Transactional not committing
body: <p>I understand the similar question have been asked before here, but I couldn't find the solution to my problem. Basically, I am trying to use JPA through Hibernate in Spring, but the data is <strong>not</strong> being persisted for some reason.Turning on debug on spring transaction reveals nothing - EntityManager open and closed, but nothing shows up as far as transaction manager concerns ... I am sure I miss something big, any help is appreciated! see the following for more details.</p>
  
  <p>TIA </p>
  
  <p>Oliver</p>
  
  <p>The basic layout is as follows: class <code>FooDaoJPA</code>’s save function calls out <code>entityManager.persist(object)</code> to persist the object.</p>
  
  <p>class <code>FooServiceImpl</code> implements the service interface by:</p>
  
  <pre><code>@Transactional(rollbackFor = DataAccessException.class,
                      readOnly = false, timeout = 30,
                      propagation = Propagation.SUPPORTS,
                      isolation = Isolation.DEFAULT)
   public void saveFoo(Foo foo) throws DataAccessException {
          fooDao.save(foo);
  }
  </code></pre>
  
  <p>Noted that <code>fooDao</code> is injected by Spring IoC</p>
  
  <p>Finally controller is injected a <code>FooService</code> and call <code>saveFoo()</code> to persist data.</p>
  
  <p>JPA configuration </p>
  
  <pre><code>&lt;!-- JPA Entity Manager Factory --&gt;
  &lt;bean id="entityManagerFactory" 
            class="org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean"
            p:dataSource-ref="feDataSource"/&gt;
  
  &lt;!-- Transaction Config --&gt;
  &lt;bean id="transactionManager"
            class="org.springframework.orm.jpa.JpaTransactionManager"
            p:entityManagerFactory-ref="entityManagerFactory"/&gt;
  
  &lt;tx:annotation-driven mode="aspectj"                        
  transaction-manager="transactionManager"/&gt;
  </code></pre>