1 Reply Latest reply on Jun 2, 2008 10:16 AM by Sean Burns

    Difference between CR2 and SP1

    Sean Burns Newbie

      Hi,


      I have a app that is a mix of Seam POJOs, EJB 3 POJOs, and Seam/EJB3 POJO's and Servlets interacting with the whole lot (no jsf yet).


      This app runs fine on CR2 but when I upgrade my JAR's to SP1 I get No Transaction exceptions when persisting/updating entities.


      This is/was easily fixed by adding entityManager.joinTransaction() to my Persist / Update methods.



      I would like to know what changed between the versions for this to happen. (I want to know if it a bad configuration on my part, or if I was exploiting a bug or just plain misunderstaing of mixing Seam Managed persistence with normal EJB persistence or just bad programming on my part)... I just need to know for piece of mind...


      I had a look at the JIRA and I could see nothing that stood out that would do this.


      Thanks,
      Sean.

        • 1. Re: Difference between CR2 and SP1
          Sean Burns Newbie

          I found a cleaner work around :-)


          My original DAO's (Home beans) were extending PersistenceController <EntityManager> and I was getting the entityManager via getPersistenceContext... I replaced all that will


          @In
          EntityManager entityManager


          Everything is back to normal.  (Im not sure why this works either, because reading the source... all getPersistenceContext() does is a Component.getInstance(...) anyway)


          Sean.