Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread afryer
I didn't know about the @ManagedBean annotation. I got it to work using the @LocalClient annotation and creating an empty META-INF/application-client.xml file. What's the difference between @ManagedBean and @LocalClient? I just tried using @ManagedBean but i still got the same error as before

Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread Romain Manni-Bucau
localclient or managedbean should do about the same, which managedbean annotation did you use i think javaee-api contain different version (multiple package). @Inject should work too. You can Simply close your container by test class ; typically you start it in BeforClass in each test class and

Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread afryer
I'm using openejb-core 4.0.0-beta-1 for my test cases. I was using @javax.annotation.ManagedBean but i haven't managed to get it to work yet. I'll keep trying tomorrow though. I was aware that creating and destroying an EJBContainer per test case removed the need for any annotations such as

Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread Romain Manni-Bucau
hmm, maybe you should update to beta-2, we did a lot of fix about cdi. if you want fast test maybe you should have a look to ApplicationComposer. - Romain 2012/2/17 afryer apfr...@hotmail.com I'm using openejb-core 4.0.0-beta-1 for my test cases. I was using @javax.annotation.ManagedBean

Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread David Blevins
On Feb 17, 2012, at 5:08 AM, afryer wrote: Just upgraded to beta-2 and now @ManagedBean works. I had to change the context I was binding to, to get this to work. Using @LocalClient i had to bind using this code... Using @ManagedBean i have to bind like this... That difference

Re: Maven plugin for OpenEJB

2012-02-17 Thread David Blevins
On Feb 17, 2012, at 10:03 AM, Charles Moulliard wrote: Hi, Is there a maven plugin to use OpenEJB in embedded more like we can do with Glassfish groupIdorg.glassfish/groupId artifactIdmaven-embedded-glassfish-plugin/artifactId

Re: Maven plugin for OpenEJB

2012-02-17 Thread Romain Manni-Bucau
Snapshot is deployed i think, openejb-maven-plugin (maybe with an s i dont remember). Not listed by buildbot but work. Le 17 févr. 2012 20:16, Jean-Baptiste Onofré j...@nanthrax.net a écrit : We can imagine to use the karaf-maven-plugin with an OpenEJB kar ;) On 02/17/2012 07:03 PM, Charles

Re: Injection fails in any class that didn't instantiate an embedded ejb container

2012-02-17 Thread Romain Manni-Bucau
Beta 2 is gold, next will be diamond ;) Le 17 févr. 2012 19:09, David Blevins david.blev...@gmail.com a écrit : On Feb 17, 2012, at 5:08 AM, afryer wrote: Just upgraded to beta-2 and now @ManagedBean works. I had to change the context I was binding to, to get this to work. Using