[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15048528#comment-15048528 ] Xavier Dury commented on OPENEJB-2120: -- For my part, I am using the openejb-core-hibernate module but the bundled hibernate version that comes with it is a 4.2.x while hibernate did not support JPA 2.1 until 4.3.x. If hibernate 4.3.x can already run with openejb 7.0.0-SNAPSHOT, do you think you could update the version of hibernate in openejb-core-hibernate to be at least a 4.3.x? Thanks > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15048532#comment-15048532 ] Romain Manni-Bucau commented on OPENEJB-2120: - [~kalgon] yep, do you want to provide us a patch (and please open another issue since this one is resolved) > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14980352#comment-14980352 ] Pascal Knüppel commented on OPENEJB-2120: - okay, I wasn't familiar with the @Produces paaradigm and had to look into that. It works but with one restriction that gets me stuck again... If I execute my test methods alone in isolation they pass. But If I execute all test-methods of one class all tests but the first one that is getting executed will fail. The Exception is the following: java.lang.IllegalStateException: Attempting to execute an operation on a closed EntityManager. any suggestions why the entitymanager is getting closed? > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14980363#comment-14980363 ] Romain Manni-Bucau commented on OPENEJB-2120: - this is cause you need to scope your entitymanager - make CDI create/destroy it - accordingly your usage. Anyway this is beyond bugtracking and should be discussed on the user list if needed. > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14980370#comment-14980370 ] Pascal Knüppel commented on OPENEJB-2120: - you're right. sorry. But really thanks for helping me here :-) > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14980112#comment-14980112 ] Pascal Knüppel commented on OPENEJB-2120: - Hi I've got another question on this issue. The tip you gave me with unwrap works perfectly fine, but if I inject an EJB that is injecting an EntityManager and another class that also is injecting an EntityManager of the same persistence-unit, how could I make sure that the unwrap is reached through the injections? to make it clearer: @LocalClient public class MyJUnitTest { ... // some OpenEjb configurations @PersistenceContext(unitName = DBDefinitions.ORACLE_PERSISTENCE_UNIT) private EntityManager oracleEntityManager; @Inject private Service service; @Test public void myTest() { oracleEntityManager = oracleEntityManager.unwrap(JpaEntityManager.class); service.executeTasks(); // some assertions } } @Stateless public class Service { @PersistenceContext(unitName = DBDefinitions.ORACLE_PERSISTENCE_UNIT) private EntityManager oracleEntityManager; @Inject RequestHandler myRequestHandler ... } @Dependent public class RequestHandler { @PersistenceContext(unitName = DBDefinitions.ORACLE_PERSISTENCE_UNIT) private EntityManager oracleEntityManager; ... } in this example it is obvious that the overriden EntityManager is not reached through to class Service and RequestHandler. I get the openejb JtaEntityManager in these classes. Is there a way to guarantee that the injected classes will always have the JpaEntityManager instead of JtaEntityManager without interfering manually at any spot where the EntityManager is injected? > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14978722#comment-14978722 ] Romain Manni-Bucau commented on OPENEJB-2120: - I see, if you can use a jpa 2.0 persistence.xml then using em = injectedEntityManager.unwrap(HibernateEntityManagerType.class) you can use jpa 2.1 with em. > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14978703#comment-14978703 ] Romain Manni-Bucau commented on OPENEJB-2120: - [~CaptGoldfish] sorry I dont get your issue. Share a project on github to make it clearer maybe? > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14978718#comment-14978718 ] Pascal Knüppel commented on OPENEJB-2120: - my problem is that I am not using tomee, just openejb-core and openejb-junit in version 4.7.2. These are the latest versions if I am not mistaken. The JPA support reaches only 2.0 here not 2.1. And your comment ("you needed to unwrap entity manager to use new features") let me think that there is a way to upgrade the JPA support in these versions. Did I misunderstand you? > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14978672#comment-14978672 ] Pascal Knüppel commented on OPENEJB-2120: - sorry for my late response. Could you give an example how I can do this without breaking JTA-management? I reached a point where the lack of support for jpa 2.1 gets not just annoying but makes testing some things nearly impossible... and thats all because of that stupid oracle xmltype that I have to use... xmltype and jpa 2.0 do not get along very well... > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14978779#comment-14978779 ] Pascal Knüppel commented on OPENEJB-2120: - Thank you so much. It is working > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14976144#comment-14976144 ] Romain Manni-Bucau commented on OPENEJB-2120: - It is master on https://git-wip-us.apache.org/repos/asf?p=tomee.git;a=summary (proxed on apache/tomee on github IIRC) 4.7.2 tolerated few things but was not exposing the full 2.1 API (you needed to unwrap entity manager to use new features) > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OPENEJB-2120) JPA 2.1 Support
[ https://issues.apache.org/jira/browse/OPENEJB-2120?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=14976141#comment-14976141 ] Pascal Knüppel commented on OPENEJB-2120: - can you give me another hint please? I am working with maven and use version 4.7.2. org.apache.openejb openejb-core 4.7.2 test Did you mean this version with branch 7? I cannot find a branch named version 7 on github either "https://github.com/apache/openejb; > JPA 2.1 Support > --- > > Key: OPENEJB-2120 > URL: https://issues.apache.org/jira/browse/OPENEJB-2120 > Project: OpenEJB > Issue Type: Wish > Components: general >Reporter: Pascal Knüppel >Assignee: Romain Manni-Bucau > Labels: jpa21 > > It would be really great if support for JPA 2.1 was provided. Is there any > chance that support for this api level will come soon? > In order to keep my Unit-Tests alive I need to downgrade all the requests to > the database to jpa 2.0 which makes working on my project very difficult... -- This message was sent by Atlassian JIRA (v6.3.4#6332)