users@glassfish.java.net

Re: 3.1 Embeddable EJBContainer and JPA/weaving problem

From: Laird Nelson <ljnelson_at_gmail.com>
Date: Wed, 13 Apr 2011 07:58:06 -0400

On Wed, Apr 13, 2011 at 2:28 AM, janne postilista <
jannepostilistat_at_gmail.com> wrote:

> I just don't get it. To test your ejbs you need to have the ejb
> classes in your test classpath. But having them in your classpath
> breaks EJBContainer deployment. How can that work?
>

I tried for over a year to get EJBContainer working properly and never did.
My advice to you is to give up now. :-) I used the embedded Glassfish APIs
instead. While they leak files all over the temp directory, they do not
appear to suffer from the same weaving issues. The weaving enabled property
does not function entirely as advertised. The Maven embedded glassfish
plugin is the thing you want to use, I was told. Sure hope you use Maven.
:-)

The Arquillian guys (http://www.jboss.org/arquillian) think that they've got
an embedded container working fine; I haven't tried it yet, and don't see
how they could have.

Sorry to not have better news here.

Best,
Laird