开发者

ClassCastException when call local ejb3 from different classloader on Websphere 7

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开发者_Go百科 a clean way to achieve this?

I'm working in RAD75 and Websphere 7.0.0.7

Thank you


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)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜