示例

public interface Example extends javax.ejb.EJBLocalObject {

public EJBLocalHome getEJBLocalHome() throws EJBException;

public Object getPrimaryKey() throws EJBException;

public boolean isIdentical(EJBLocalObject arg0) throws EJBException;

public void remove() throws RemoveException, EJBException;

public void exampleMethod() throws RemoteException;
}

解决方案
不要对任何方法抛出 java.rmi.RemoteException。


public interface Example extends javax.ejb.EJBLocalObject {

public EJBLocalHome getEJBLocalHome() throws EJBException;

public Object getPrimaryKey() throws EJBException;

public boolean isIdentical(EJBLocalObject arg0) throws EJBException;

public void remove() throws RemoveException, EJBException;

public void exampleMethod();
}