-
1. Re: Configure different EJB application to use different ejb versions - jboss AS 6
wdfink Mar 9, 2014 10:52 AM (in response to imeshd)If you deploy an ejb application to a server it dosn't matter which ejb version it is. The only requirement is that the server support the version.
So an EJB3.0 application will be deployed the same way as a EJB3.1 app.
If you really use JBossAS6.x you might use mappedName annotation to deploy with a different name.
With JBossAS7 (EAP6.1 is based on this one) this is not longer supported and the attribute might be ignored.
But in that case the JND name is <app/ear name>/<module name>/<bean name>/<interface> and you might change the ear name to have a different name.
-
2. Re: Configure different EJB application to use different ejb versions - jboss AS 6
imeshd Mar 9, 2014 11:03 AM (in response to wdfink)Hi Wolf-Dieter,
Thanks for the reply. I actually tried the EJB3.0 annotation but did not work for me. This is why I thought that the JBoss some how use EJB3.1 spec. Because in my JBoss I have some other application which use EJB3.1. When I deploy my application the JNDI name was <ear name>/<bean name>/<interface type (local) this is how it worked for me. It is not even taking the module name. weird.. I am actually lost between EJB3.0 , EJB3.1 and JBOSS AS6.X JNDI conventions. The examples in the web to overwrite the JNDI name @EJB(mappedName="my_own_jndi_name") did not work in my ear.
How can I understand the correct behaviour within EJB3.0, 3.1 and Jboss AS6.x ?
-
3. Re: Configure different EJB application to use different ejb versions - jboss AS 6
wdfink Mar 9, 2014 11:11 AM (in response to imeshd)You might use the @Stateless(mappedName=XXX) to rename the JNDI entry. You might need to experiment a bit.
Do you really use JBossAS6 and not EAP6 or AS7?
JBossAS6 is outdated and I'm not sure how the behaviour is. I recommend to use AS7 or WildFly8.
-
4. Re: Configure different EJB application to use different ejb versions - jboss AS 6
imeshd Mar 9, 2014 12:21 PM (in response to wdfink)Hi Wolf-Dieter,
I tried all the ways but did not work. That's why I suspect is there a way to say specifically use the specific EJB version. So two things below pls verify
1. Jboss AS7 use EJB3.1 spec and cannot change the JNDI name or custom JNDI. Is it ?
2. Older Jboss version like AS6.x even it use EJB3.1 spec still can change the JNDI name.
-
5. Re: Configure different EJB application to use different ejb versions - jboss AS 6
wdfink Mar 9, 2014 4:06 PM (in response to imeshd)1) Yes, with AS7 and EJB3.1 th JNDI name handling has changed and was unified.
2) With former AS and EJB versions this was different.
You might use the application.xml descriptor to use a different name for deployments