views:

244

answers:

1

Hello,

I have two ears, ear1 contains an ejb project and client, containing the interfaces (local). Ear2 contains a war that needs to call the ejb3 service. When I call the ejb service I am getting a classcastexception, I think because there are two classloaders involved here. Is there a clean way to achieve this?

I'm working in RAD75 and Websphere 7.0.0.7

Thank you

A: 

If both the ears run on the same server instance, you could set the Classloader Policy to "single" so that a single classloader is used. But then again, if both the EARs run on the same server, then a better option would be to package the war within the EAR1. This way you do not have to change the Classloader Policy ( and hence other apps that may run on the same server will not be impacted)

Shreeni