Hallo!
I’m working with EJB3. I trying to do JDNI lookup from an Application Designer Adapter for a session bean.
But I get various class not found, class cast exception.
Can anyone tell me how to do the lookup right?
Where to put the @remote annotated interfaces, i seems the Application Designers own classloader can’t load them.
Thanks stephan.
I tested this:
@EJB(name=“ejb/ServiceManagementJNDI”) IServiceManagement management;
and that:
InitialContext ctx = new InitialContext();
management = (IServiceManagement) ctx.lookup(“ejb/ServiceManagementJNDI”);
I seems to work, but
java.lang.ClassCastException: de.epoq.dycide2.server._IServiceDycideManagement_Wrapper
java.lang.ClassCastException: de.epoq.dycide2.server._IServiceManagement_Wrapper
at Test1Adapter.save(Test1Adapter.java:43)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at com.softwareag.cis.server.InteractionModel.invokeMethodInternally(