Discussions

EJB programming & troubleshooting: JRun EJB Client program

  1. JRun EJB Client program (2 messages)

    I am getting the following exception when I try to run the client program for stateless session bean on JRun App Server 3.0.
    The Exception is :
    Exception in thread "main" javax.naming.NoInitialContextException: Cannot instantiate clas
    s: allaire.ejipt.ContextFactory. Root exception is java.lang.ClassNotFoundException: alla
    ire.ejipt.ContextFactory
            at java.net.URLClassLoader$1.run(Unknown Source)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(Unknown Source)
            at java.lang.ClassLoader.loadClass(Unknown Source)
            at sun.misc.Launcher$AppClassLoader.loadClass(Unknown Source)
            at java.lang.ClassLoader.loadClass(Unknown Source)
            at java.lang.ClassLoader.loadClassInternal(Unknown Source)
            at java.lang.Class.forName0(Native Method)
            at java.lang.Class.forName(Unknown Source)
            at com.sun.naming.internal.VersionHelper12.loadClass(Unknown Source)
            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 Client.getInitialContext(Client.java:61)
            at Client.main(Client.java:27)
    ***************************
    and code is:
    Properties h = new Properties();
    h.setProperty(Context.INITIAL_CONTEXT_FACTORY,"allaire.ejipt.ContextFactory");
          h.setProperty(Context.PROVIDER_URL, "ejipt://localhost:8000");
    ****

    Thanks
          

    Threaded Messages (2)

  2. JRun EJB Client program[ Go to top ]

    Verify your CLASSPATH to see that all the required Jars are included.
  3. JRun EJB Client program[ Go to top ]

    in the property where in you set the url use port number 2323 instead of the server port as this a port set internally by the server for accessing ejbs