Hi,
I am trying to fetch the data from MEJB present in oc4j 10g (10.1.3.0.0) using the following code
Object obj = null;
ManagementHome mgmtHome=null;
Management server = null;
InitialContext ctx = null;
Hashtable props = new Hashtable();
props.put(Context.PROVIDER_URL, "ormi://localhost:23791/default");
props.put(Context.SECURITY_PRINCIPAL, "oc4jadmin");
props.put(Context.SECURITY_CREDENTIALS, "Password12");
props.put(Context.INITIAL_CONTEXT_FACTORY ,"com.evermind.server.ApplicationClientInitialContextFactory");
ctx = new InitialContext(props);
obj = (ManagementHome) ctx.lookup("java:comp/env/ejb/mgmt/MEJB");
mgmtHome = (ManagementHome) PortableRemoteObject.narrow(obj, ManagementHome.class);
server = mgmtHome.create();
from the servlet in JBOSS4.0.3SP1.
and i am getting the following Exception
javax.naming.NoInitialContextException: Cannot instantiate class: com.evermind.server.ApplicationClientInitialContextFactory [Root
exception is java.lang.ClassNotFoundException: com.evermind.server.ApplicationClientInitialContextFactory]
I used the same code to connect to to oc4j using the standalone application and it was working fine.
can anyone give me some solution to this.
Thanks in advance.
Regards
Siva