Running EJB client problem,please help.


EJB programming & troubleshooting: Running EJB client problem,please help.

  1. Running EJB client problem,please help. (2 messages)

       I am new to ejb development. I have successfully deployed a helloworld ejb component on Jrun server, then I started running the ejb client to invoke the ejb method. But there are always errors.
       When running the ejb client class on the local machine as follows:
       java example1.HelloWorldClient
       I got an exception of java.lang.NoClassDefFoundError: example1/HelloWorldClient. In the client class source code, the initialcontextfactory and providerurl properties are set to jrun.naming.JRunContextFactory and localhost:2918.

       When running the ejb client class from a remote host as
    above, I got another exception of java.lang.ClassNotFoundException: jrun.naming.JRunContextFactory.But the providerurl property has changed to which is the url of the Jrun server.

       I really don't what hell is going on, please give me some hint.
  2. you need to setup your classpath to include the helloworld class
  3. the full path to the jar file is also set in the classpath of the jrun server
    host, but the problem still exists.
    To solve the exception of running the client from remote host, could you give
    some help?