Re: EJB v2 and EJB v3 conflict when deploying .ear

Scott Ferguson <[email protected]> Wed, 5 Jul 2006 06:52:44 -0700
Newsgroups gmane.text.xml.resin.user
Message-ID <[email protected]>
On Jul 5, 2006, at 2:37 AM, Tero Ripattila wrote:

> Hello all, I'm trying to deploy an .ear, but ran into troubles. Resin
> seems to think that I'd like to use EJB v3 (Amber) when I'm not.
>
> This is how I've got ejb-server block set up in my resin-web.xml:
>
> <ejb-server>
>   <config-directory>WEB-INF</config-directory>
> </ejb-server>
>
> Is there a way to declare which EJB version to use in ejb-server  
> tag or
> so?

I think you're just missing a jndi-name

<ejb-server jndi-name="java:comp/env/cmp">
   <config-directory>...</config-directory>
</ejb-server>

EJB 2.1 and JPA (Amber/EJB 3.0) use different discovery mechanisms,  
so Resin can tell which version to use based on how it's configured.

EJB 2.1 uses the ejb-jar.xml.  JPA uses META-INF/persistence.xml.

-- Scott

>
> Any pointers or suggestions how to fix this?
>
> TIA,
>
> -- Tero
>
>