I am out of the
office until September 5th. Please contact Mark.Reeves:oracle.com if you
require assistance.
Regards
Antony
BEGIN:VCARD VERSION:2.1 N:Reynolds;Antony;J FN:Antony J Reynolds ORG:<a href="http://www.oracle.com/index.html" target="_top"><img src="http://www.oracle.com/admin/images/oraclelogo.gif" width=188 height=44 border=0 alt=""></a><br><b><A href="http://www.uk.oracle.com">Oracle Corporation UK Limited</A>;<A href="http://presales.uk.oracle.com"><B>Corporate Pre-Sales</A> TITLE:Principal Sales Consultant NOTE;ENCODING=QUOTED-PRINTABLE:Principal Consultant in Corporate Pre-Sales for Oracle UK=0D=0Aspecialising = in Java, CORBA and large-scale online transaction=0D=0Aprocessing systems us= ing Oracle Server platform.=0D=0A=0D=0AInternally my time can be requested v= ia a <a href=3D"http://presales.uk.oracle.com/cps_tools/plsql/cpsreq$.startu= p">CPS request</a>. TEL;WORK;VOICE:+44 (0)118 924 3245 TEL;WORK;VOICE:+44 (0) 1454 631524 TEL;CELL;VOICE:+44 (0)7775 896150 TEL;WORK;FAX:+44 (0)118 924 3721 ADR;POSTAL;ENCODING=QUOTED-PRINTABLE:;;Castlegate=0D=0ATower Hill;Bristol;;BS2 OJA;UK LABEL;POSTAL;ENCODING=QUOTED-PRINTABLE:Castlegate=0D=0ATower Hill=0D=0ABristol BS2 OJA=0D=0AUK URL:http://www.oracle.com EMAIL;PREF;INTERNET:[EMAIL PROTECTED] EMAIL;INTERNET:[EMAIL PROTECTED] EMAIL;INTERNET:[EMAIL PROTECTED] REV:20010601T130645Z END:VCARD
Hi, The Elephant walker. Sure the error says domain was null, but the situation is that the servlet is just an another stand-alone program (not part of deployed Hello Session Bean) residing in D:\Oracle\iSuites\j2ee\home\default-web-app\WEB-INF\classes\trg\HelloServlet directory and from there I'm trying to access Hello Session Bean which is deployed on the Orion. Both client and server are on the same machine as I'm testing this saught of workability. So I guess domain name won't be needed and if yes could you elaborate on domain name you are talking about Regards Prashant -----Original Message----- From: The elephantwalker [mailto:[EMAIL PROTECTED]] Sent: Tuesday, September 11, 2001 4:28 PM To: Orion-Interest Subject: RE: Calling EJB From a Servlet.. First, if the servlet and ejb are in the same application, you don't need to use properties to initialize your context....but if you did, it looks like you left off the domain in the properties. Regards, the elephantwalker -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On Behalf Of Prashant Gaikwad Sent: Tuesday, September 11, 2001 3:27 AM To: Orion-Interest Subject: Calling EJB From a Servlet.. HI Friends, I'm having a serious problem in my code and am unable to understand. I've deployed a simple Hello bean on the orion container and want to access it from a servlet. I have the servlet in D:\Oracle\iSuites\j2ee\home\default-web-app\WEB-INF\classes\trg\HelloServlet . Following is the code in servlet try { trace("In Try"); Hashtable h = new Hashtable(); h.put(javax.naming.Context.INITIAL_CONTEXT_FACTORY,"com.evermind.server.rmi. RMIInitialContextFactory"); h.put(javax.naming.Context.SECURITY_PRINCIPAL, "ejb"); h.put(javax.naming.Context.SECURITY_CREDENTIALS, "ejbadmin"); h.put(javax.naming.Context.PROVIDER_URL,"ormi://localhost/Hello"); trace("Before Init Contect "); Context context = new InitialContext (h); trace("after Initial context"); Object boundObject = context.lookup("java:comp/env/ejb/HelloHome"); trace("At Trap"); helloHome = (HelloHome) javax.rmi.PortableRemoteObject.narrow(boundObject,HelloHome.class); } catch (Throwable exception) { exception.printStackTrace(); //System.out.println("Look up exception :" + exception.toString()); //throw new ServletException( // "Unable to get home interface: " + exception.toString()); } When I run servlet from browser I get an exception when the Context is getting crerated as folloew D:\Oracle\iSuites\j2ee\home>java -jar orion.jar Oracle9iAS (1.0.2.2) Containers for J2EE initialized ConstructorBefore TryIn TryBefore Init Contect java.lang.NullPointerException: d omain was null at com.evermind.server.rmi.RMIServer.addNode(RMIServer.java:428) at com.evermind.server.rmi.RMIServer.getConnection(RMIServer.java:497) at com.evermind.server.rmi.RMIInitialContextFactory.getInitialContext(RM IInitialContextFactory.java:150) at javax.naming.spi.NamingManager.getInitialContext(Unknown Source) at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source) at javax.naming.InitialContext.init(Unknown Source) at javax.naming.InitialContext.<init>(Unknown Source) at trg.HelloServlet.init(HelloServlet.java:49) at com.evermind.server.http.HttpApplication.loadServlet(HttpApplication. java:1580) at com.evermind.server.http.HttpApplication.findServlet(HttpApplication. java:3722) at com.evermind.server.http.HttpApplication.getRequestDispatcher(HttpApp lication.java:1995) at com.evermind.server.http.HttpRequestHandler.processRequest(HttpReques tHandler.java:444) at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.ja va:189) at com.evermind.util.ThreadPoolThread.run(ThreadPoolThread.java:62) In _hello Please let me know where I'm going wrong. Thanks in advance Prashant