tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Blevins <david.blev...@visi.com>
Subject Re: Cannot find @Stateless annotation in other module
Date Wed, 27 Feb 2008 20:16:33 GMT

On Feb 26, 2008, at 9:48 AM, <Karsten.Ohme@t-systems.com> <Karsten.Ohme@t-systems.com

 > wrote:

> Hi,
>
> I have a working thanks to the help of you a working test. I use  
> TestNG now. Now I use in my bean a reference with @EJB annotation to  
> another bean in another module. The behaviour of the detected  
> modules when I use the include and exclude properties is strange.  
> Also when I place an empty ejb-jar.xml in the META-INF directory it  
> has problems to find the beans. When I go the hard way and include  
> everything with include=.* and exclude="" I would expect that the  
> bean must be found, but I get disappointed.
> Anyway, it works somehow in the current configuration, but although  
> the bean which should be injected in the @EJB field has a @Stateless  
> annotation OpenEJB complains what in cannot find any @Stateless,  
> @Stateful, ... annotation. What could be the reason?

Jack had the same issue with @EJB references between modules.  We  
added a few features in this area just this weekend in fact.  You can  
try out the new referencing ability by updating your pom.xml to  
openejb version 3.0-SNAPSHOT and adding http://people.apache.org/repo/m2-snapshot-repository/

  as a snapshot enabled repository.

You definitely shouldn't get the "@Stateless, @Stateful...annotation"  
warning under normal circumstances.  Can you send the full log output?

> By the way I have found differences in the behaviour between OpenJPA  
> and Hibernate. Named native SQL queries with parameters in OpenJPA  
> must be set by index, in Hibernate by name. Is this incompatibility  
> intentional?

I don't think any incompatibility is intentional.  OpenJPA has it's  
compatibility certification and Hibernate has yet to pass the tests.   
There's no guarantee that this part is actually tested, so I couldn't  
say for sure who is doing it right.

-David


Mime
View raw message