I got this error message at runtime.
After adding value to the Intialcontext by adding the following code snippet:
Properties p = new Properties();
initContext = new javax.naming.InitialContext(p);
After this i am getting different error message:
minor code: 1 completed: Maybe at om.sun.corba.se.internal.iiop.IIOPConnection.purge_calls(Unknown Source)
at com.sun.corba.se.internal.iiop.ReaderThread.run(Unknown Source)
Looking forward a proper solution
for this problem.
Thanks in advance.
iam getting this problem even if i give ejb/jndiname
can you please anyone help me
Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
Try adding the naming.jar file in the Java Build Path of your Application Bean. For that in the Bean Properties Menu >> Libraries >> Add Enternal JARs >> naming.jar could be added by providing the path from the runtime/base_v5/lib directory.
Save and Run the Application.
Should not give the error posted.
All the Best !
I encountered the same problem while trying to run the client.
I found a short cut to get the default property for the Context.INITIAL_CONTEXT_FACTORY and Context.PROVIDER_URL while trying to access the EJB deployed in SunServer.
You need not have Properties Object defined in your client code.
The JNDI name should be as it is found in the deployment and not the java:comp/env/ejb etc...
The command line will be like
java -cp /usr/java/SUNWappserver/lib/j2ee.jar:.:/usr/java/SUNWappserver/lib/appserv-rt.jar EJBCLIENTNAME.class
So Just adding the "appserv-rt.jar" in sun server lib folder to the classpath does the trick for providing the corba properties.
It works for me!!
I have find the code to specify the naming context property to access another host
Properties props = new Properties();
// optional. Defaults to localhost. Only needed if web server is running
// on a different host than the appserver
// optional. Defaults to 3700. Only needed if target orb port is not 3700.
I am doing ejb 3.0
I try to implement Account example from Mastering Enterprise JavaBeans 3.0
When I run the client I also get the exception..Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: java.naming.factory.initial
How to get around in EJB 3.0??
urgent help plz.
I'm also studying EJB3.0 with the help of Mastering EJB3.0. When I running my client side bean I'm also get the same problem so please help me also.
I'm using JBoss server4.0.4G.A
Hi I am new to EJB. i m getting the same error.plz could any point where i can find the appserv-rt.jar file plz i was trying to find for 2 hrs i am not able to find it.i am in urget any help would help me in great
thanks in advance