tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sudhish81 <sudhish.yesodha...@ust-global.com>
Subject EJB Deployment in TomEE 6
Date Thu, 29 Dec 2016 04:47:05 GMT
Hi,
I am working on a migration project moving a legacy system from Websphere to
TomEE. The legacy system  is mainly having EJB2 and EJB 3 specifications.
This application is wrapped as an EAR which contains two EJB projects and
one web project. When I deployed this application in TomEE's apps folder, I
can see all the  EJB's getting registered in the logs. But when I try to
lookup the EJBs Remote interface withe the registered JNDI name and type
casting it to java.rmi.Remote , I am getting a class cast exception as below

java.lang.ClassCastException: com.sun.proxy.$Proxy85 cannot be cast to
java.rmi.Remote

I used the below context properties to get the Initial Context
p.put("java.naming.factory.initial",
"org.apache.openejb.core.LocalInitialContextFactory");
p.put("java.naming.provider.url", "http://127.0.0.1:8082/tomee/ejb");

Also if I try to lookup the EJB interface object without typcasting, I can
see the object in the form
proxy=fully qualified class name of the Remote interface. 
Since I am struck up with this issue, I cannot proceed further, could any
one of you help me in resolving this issue



--
View this message in context: http://tomee-openejb.979440.n4.nabble.com/EJB-Deployment-in-TomEE-6-tp4680839.html
Sent from the TomEE Users mailing list archive at Nabble.com.

Mime
View raw message