Hi:
Can anybody help me on the example provided with the J2EEdocumentation ?
I tried on the shipper example at $J2EE_HOME/doc/guides/ejb/examples/shipper,
it did not work for me. The shipper bean did not recognize the Stock bean.
Here is what I did when I deployed each
EJB bean.
To StockBean:
Entity -- Bean Managed Persistence
No environment
No EJB references
No security set
Resource Ref's -- coded Name is jdbc/StockDB
Type is javax.sql.DataSource
Authentication is Container
Transactions -- Business methods are "required".
So, in conclusion to StockBean, the JNDI names are set to be:
Referenced By Component/Reference Name JNDI Name
StockBean MyStock
StockBean jdbc/StockDB jdbc/Cloudscape
-- Return Client JAR selected --
To ShipperBean:
No environment
EJB references -- Coded Name is "ejb/Stocker"
Type is "Entity"
Home is "StockHome"
Remote is "Stock"
No Resource Ref's
No Security set
Set to be Stateful SessionBean
In conclusion, it is set to be:
Referenced By Component/Reference Name JNDI Name
ShipperBean MyShipper
ShipperBean ejb/Stocker MyStock
-- Return Client JAR selected --
Everything makes sense till this step. However, when I run the client, I
got the error message which is listed in the error.log file like:
------------------------------------------------------------------------------
java.rmi.RemoteException: Unknown Exception/Error thrown by EJB method.; nested
exception is:
java.lang.NoClassDefFoundError: StockHome
java.lang.NoClassDefFoundError: StockHome
at ShipperEJB.class$(ShipperEJB.java:15)
at ShipperEJB.shipItem(ShipperEJB.java:36)
at ShipperEJB_EJBObjectImpl.shipItem(ShipperEJB_EJBObjectImpl.java:18)
at _ShipperEJB_EJBObjectImpl_Tie._invoke(Unknown Source)
at
com.sun.corba.ee.internal.POA.GenericPOAServerSC.dispatchToServant(GenericPOAServerSC.java:423)
at
com.sun.corba.ee.internal.POA.GenericPOAServerSC.internalDispatch(GenericPOAServerSC.java:137)
at
com.sun.corba.ee.internal.POA.GenericPOAServerSC.dispatch(GenericPOAServerSC.java:98)
at com.sun.corba.ee.internal.iiop.ORB.process(ORB.java:227)
at
com.sun.corba.ee.internal.iiop.CachedWorkerThread.doWork(IIOPConnection.java:262)
at
com.sun.corba.ee.internal.iiop.CachedWorkerThread.run(IIOPConnection.java:230)
----------------------------------------------------------------------------
I am really lost at this point.
So, please help me out.
Appreciate your help a lot.
Hong Zhou
===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff EJB-INTEREST". For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".