1 Reply Latest reply on Sep 2, 2003 7:50 AM by Adrian Brock

    jndi problem

    eranhovav Newbie

      Hello!
      I'm trying to write an entity EJB. I worked with JBoss Workbook , 3rd Edition, and i run the first example in the book by using ant (and build.xml file). i'm trying to do that without use ant - compile, make jar file, put it in deploy directory - but unfortunately it doesn't'n work.
      when i run the client i get this exception:

      javax.naming.NoInitialContextException: Cannot instantiate class: org.jnp.interf
      aces.NamingContextFactory. Root exception is java.lang.ClassNotFoundException:
      org.jnp.interfaces.NamingContextFactory
      at java.net.URLClassLoader$1.run(URLClassLoader.java:198)
      at java.security.AccessController.doPrivileged(Native Method)
      at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
      at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:265)
      at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
      at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
      at java.lang.Class.forName0(Native Method)
      at java.lang.Class.forName(Class.java:217)
      at com.sun.naming.internal.VersionHelper12.loadClass(VersionHelper12.jav
      a:42)
      at javax.naming.spi.NamingManager.getInitialContext(NamingManager.java:6
      49)
      at javax.naming.InitialContext.getDefaultInitCtx(InitialContext.java:243
      )
      at javax.naming.InitialContext.init(InitialContext.java:219)
      at javax.naming.InitialContext.(InitialContext.java:175)
      at Client_1.getInitialContext(Client_1.java:44)
      at Client_1.main(Client_1.java:16)
      the files: jnp-client.jar, jboss-j2ee.jar, jbossall-client.jar are included in my classpath.


      tank you.