Naming Exception


EJB programming & troubleshooting: Naming Exception

  1. Naming Exception (1 messages)


    After running ejb client in JDeveloper3.0 for deploying on oracle 8i the following exception occurs.

    The jvm classpath is set and this problem indicates This exception is mainly because the jndi name which is used in the client to look up the session bean is not consistent with the jndi name given in the deployment descriptor of the bean.(plz correcct me if wrong)
    But dd file and client Interface urls are same.Then what's the problem??
    Can anyone tell the settings for the same.

    Thanks in advance!!

    Exception occurred!
    Cause: This may be an unknown URL, or some classes required by the EJB are missing from your classpath.
    Suggestion: Check the components of the URL, and make sure your project includes a library containing the EJB .jar files

    generated by the deployment utility.

    [Root exception is java.lang.ClassNotFoundException: HelloEJBBean1.MyEJBHomeHelper]
    javax.naming.NamingException: Unknown reasons
    at oracle.aurora.jndi.sess_iiop.SessionCtx._activate(Compiled Code)
    at oracle.aurora.jndi.sess_iiop.SessionCtx.activate(Compiled Code)
    at oracle.aurora.jndi.sess_iiop.ServiceCtx.lookup(Compiled Code)
    at oracle.aurora.jndi.sess_iiop.sess_iiopURLContext.lookup(Compiled Code)
    at oracle.aurora.jndi.sess_iiop.sess_iiopURLContext.lookup(Compiled Code)
    at javax.naming.InitialContext.lookup(Compiled Code)
    at HelloEJBBean1.MyEJBJSClient.main(Compiled Code)

    Threaded Messages (1)

  2. Naming Exception[ Go to top ]

    I am notsure but it seems , ur EJB is using some java class which is not in the classpath, put this file with proper directory structure into the serverclasses directory of ur weblogic server and specify serverclasses in ur classpath.
      DO NOT put this helper class in the EJB jar file which u r deploying.