This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes EJB and other Java EE Technologies and the fly likes Application with 2 EARs Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Application with 2 EARs" Watch "Application with 2 EARs" New topic
Author

Application with 2 EARs

ram yassine
Greenhorn

Joined: Apr 06, 2005
Posts: 1
Dear java ranchers,

I am trying to create an application that contains 2 ears connected through an EJB-JAR, i am really new at this, any hints or tips , or even links to that subject would be useful,

Thank you
Valentin Tanase
Ranch Hand

Joined: Feb 17, 2005
Posts: 704
I understand that you have an application that is deployed at two ears, but I don�t understand why would you do that. If that�s the case, you might notice one thing: from the container perspective they are two different applications. Your container will use different classloaders for loading classes in both ears and you have no way to overcome this. If for example you have a bean A in first ear that needs to call a method on a bean B in the second ear, you have to do the usual jndi lookup, and use B�s remote interface in order to invoke business methods. This also implies that the first ear needs to include B�s home and remote interfaces, just like any other client application. Even worse, because they are distinct applications you won�t be able to use local interfaces.
So I guess that you might reconsider your approach.
Regards.


I think, therefore I exist -- Rene Descartes
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Application with 2 EARs
 
Similar Threads
Pass parameters between 2 EARs.
Thought for today
web module of ear is not getting picked up by WL10.3.0.0
passing the session from one application to another
InstanceAlreadyExistsException when deploying multiple versions of the same ear