Posted By:
Arun_Parthasarathy
Posted On:
Friday, March 13, 2009 09:57 PM
How to get rid of javax.naming.NoInitialContext Exception Iam using Eclipse IDE. I have created a bean project. it got synchronized with the jboss server. Then i have created a java project fr client. When i execute the client, iam getting the following exception : Exception in thread "main" javax.naming.NoInitialContextException: 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 at javax.naming.spi.NamingManager.getInitialContext(Unknown Source) at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source) at javax.naming.InitialContext.getURLOrDefaultInitC
More>>
How to get rid of javax.naming.NoInitialContext Exception
Iam using Eclipse IDE. I have created a bean project. it got synchronized with the jboss server.
Then i have created a java project fr client. When i execute the client, iam getting the following exception :
Exception in thread "main"
javax.naming.NoInitialContextException: 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
at javax.naming.spi.NamingManager.getInitialContext(Unknown Source)
at javax.naming.InitialContext.getDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.getURLOrDefaultInitCtx(Unknown Source)
at javax.naming.InitialContext.lookup(Unknown Source)
at hw.HelloClient.main(HelloClient.java:20)
the error points to the line
Object obj = ctx.lookup("HelloHome");
Please help me in running the simple ejb application.
<<Less