Hi,
I'm just trying to call a remote interface with sample code provided.
InitialContext ctx = new InitialContext(p);
Object
ref=ctx.lookup("java:global/securitypoc-engine/HelloWorldSessionBean");
HelloWorldSessionBeanRemote bean=(HelloWorldSessionBeanRemote)ref;
Error caught :
GRAVE: Servlet.service() for servlet [jsp] in context with path
[/securitypoc-ui] threw exception [java.lang.ClassCastException: $Proxy59
cannot be cast to ch.skay.poc.ejb.HelloWorldSessionBeanRemote] with root
cause
java.lang.ClassCastException: $Proxy59 cannot be cast to
ch.skay.poc.ejb.HelloWorldSessionBeanRemote
If I look inside debugger, I can notice that the reference is OK with a
StatelessEjbObjectHandler
proxy=ch.skay.poc.ejb.HelloWorldSessionBeanRemote;deployment=HelloWorldSessionBean;pk=null
So everything seems Ok, except from the casting.
Any idea ???
Please note that the sample code is running on Glassfish, JBoss AS7 and
Weblogic 12c.
Only TomEE is crashing with that error.
--
View this message in context:
http://openejb.979440.n4.nabble.com/Classcast-execption-on-proxy-when-looking-up-remote-interface-tp4662060.html
Sent from the OpenEJB User mailing list archive at Nabble.com.