• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Intial Context Problem on Jboss

 
sripad_devaraju
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am new to Jboss. I have written Hello World session bean. And deployed successfully. I have also written a simple client application. but while running Client application I am facing following exception.
Javax.naming.NoIntialContextException: Need to specify class name in environment or system property, or as an applet parameter, or in an application resource file: Java.naming.factory.intial
To rectify this I have Taken following actions.But couldnt find any solution
1.I wrote a jndi.properties files as following.
java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory
java.naming.provider.url=localhost:1099
java.naming.factory.url.pkgs=org.jboss.naming rg.jnp.interfaces
I did put path of this file in my classpath Environment variable
2.I did put folloing files in class path.
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\lib;
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\jnet.jar;
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\log4j.jar;
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\jnp-client.jar;
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\jbossmq-client.jar;
c:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\jboss-client.jar;
C:\jboss-3.0.0_tomcat-4.0.3\jboss-3.0.0_tomcat-4.0.3\client\jboss-j2ee.jar;
C:\Hello World\resources\jndi.properties
I am working on jboss3.0.0 and Tomcat. Operating System is Windows 2000 server.
Actually this example is from ? Developing EJB2.0 Components by Praveen Tulachan?s book Chapter 4(http://www.j2eebootcamp.com)
Thanks
 
jawwad ahmed
Ranch Hand
Posts: 179
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well put jndi.properties in the folder where u have putten client file of your ejb.
Jawwad Ahmed
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic