3 Replies Latest reply on Jan 19, 2006 6:57 AM by Cedric Montfort

    EJB not bound

    Cedric Montfort Newbie

      I make a struts application with EJB. I deploy it (JBoss 3.2.7 or 4.0.3) but i've got an error in my Action file :
      javax.naming.NameNotFoundException: com.cirdec.ejbsessions.EjbClientHome not bound


      Here is my Action file :

      public ActionForward execute(
       ActionMapping mapping,
       ActionForm form,
       HttpServletRequest request,
       HttpServletResponse response) {
       ClientListForm clientListForm = (ClientListForm) form;
      
       try{
       EjbClientHome home = EjbClientUtil.getHome();
       EjbClient bean = home.create();
      
       clientListForm.setClients(bean.getAllClient());
      
       return mapping.findForward("success");
       }catch(Exception e){
       System.out.println("[DEBUG]-> "+e);
       return mapping.findForward("error");
       }
      
       }
      


      Now, my jboss.xml :
      <jboss>
      
       <enterprise-beans>
      
       <session>
       <ejb-name>EjbClient</ejb-name>
       <jndi-name>com.esil.ejbsessions.EjbClientHome</jndi-name>
       </session>
      
       </enterprise-beans>
      
       <resource-managers>
       </resource-managers>
      
       <container-configurations/>
      </jboss>
      


      My ejb-jar.xml :
      <ejb-jar >
      
       <description><![CDATA[No Description.]]></description>
       <display-name>Generated by XDoclet</display-name>
      
       <enterprise-beans>
      
       <!-- Session Beans -->
       <session >
       <description><![CDATA[EjbAnalysisBean]]></description>
       <display-name>EjbAnalysisBean</display-name>
      
       <session >
       <description><![CDATA[EjbClientBean]]></description>
       <display-name>EjbClientBean</display-name>
      
       <ejb-name>EjbClient</ejb-name>
      
       <home>com.esil.ejbsessions.EjbClientHome</home>
       <remote>com.esil.ejbsessions.EjbClient</remote>
       <ejb-class>com.esil.ejbsessions.EjbClientSession</ejb-class>
       <session-type>Stateless</session-type>
       <transaction-type>Container</transaction-type>
      
       </session>
       </assembly-descriptor>
      
      </ejb-jar>


      May someone help me? It's for a school project.