View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=3821421#3821421

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=3821421

I think I'm going nuts, but for the life of me I cannot see why my bean won't deploy. 
It always complains with the error:



[ObjectName: jboss.j2ee:jndiName=CatSess,service=EJB

 state: FAILED

 I Depend On:

 Depends On Me: java.lang.NoSuchMethodException: org.jboss.ejb.StatelessSessionC

ontainer.addItemHome(java.lang.String, java.lang.Object)]



But there is no method defined called addItemHome, it is called addItem.  Can anyone 
see what is wrong? Here is my code:



import javax.ejb.EJBObject;

import java.rmi.RemoteException;



public interface CatSess extends EJBObject {



  public void addItem(String supplierId, Object e) throws java.rmi.RemoteException;



  public void deleteItem(String supplierId, Object e) throws java.rmi.RemoteException;



}



-----



import javax.ejb.*;





public class CatSessBean implements SessionBean {



  protected SessionContext ctx;



  public  void ejbCreate(){

  }



  public void addItemHome(String supplierId, Object e){



    System.out.println("Add Supplier Item: " + supplierId);

  }



  public void deleteItemHome(String supplierId, Object e){



    System.out.println("Delete Supplier Item: " + supplierId);

  }



  public void addItem(String supplierId, Object e){



    System.out.println("Add Supplier Item: " + supplierId);

  }



  public void deleteItem(String supplierId, Object e){



    System.out.println("Delete Supplier Item: " + supplierId);

  }



  public void ejbActivate() {

    System.out.println("Called Catalog Session ejbActivate");

  }



  public void ejbPassivate() {

    System.out.println("Called Catalog Session ejbPassivate");

  }



  public void ejbRemove() {

    System.out.println("Called Catalog Session ejbRemove");

  }



  public void setSessionContext(SessionContext parm1) {

    System.out.println("Called Catalog Session setSessionContext");

    this.ctx = parm1;

  }



  public void unsetSessionContext() {

    System.out.println("Called Catalog Session unsetSessionContext");

    this.ctx = null;

  }



----



import javax.ejb.*;



import java.rmi.*;



public interface CatSessHome extends EJBHome {



  public CatSess create () throws CreateException, RemoteException;



  public void addItem(String supplierId, Object e) throws java.rmi.RemoteException;



  public void deleteItem(String supplierId, Object e) throws java.rmi.RemoteException;

}




-------------------------------------------------------
SF.Net is sponsored by: Speed Start Your Linux Apps Now.
Build and deploy apps & Web services for Linux with
a free DVD software kit from IBM. Click Now!
http://ads.osdn.com/?ad_id=1356&alloc_id=3438&op=click
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to