> Please could you be more precise. Wich dependency problems might occur if the
> container replace the "org" refernce in the OrgUnit class (see bellow) with a
> logically equivalent one? How can these disturb load/store? What should be used

Just to illustrate it, I'll give you a different example. Let's suppose
Organization and OrgUnit both use a Location object (country, state,
city, whatever). Let's suppose that Location is not a remote object
(i.e. it's part of the implementation, but not available to the
outside), and that an OrgUnit and Organization are related by having the
same Location, thus, if you suddenly move your organization to Wyoming,
all the units move along with it.

So, Organization references a Location, Organization references any
number of OrgUnits, each OrgUnit references the Organization.

If you use the remote interface, then your OrgUnit cannot determine it's
location (which is not in the interface). But if you reference
Organization directly, you can reference Location.


> instead (of references and handles)? (home_handle + prim_key, home_name +
> prim_key, ..?)

Keep in mind that since Organization/OrgUnit are dependent classes (i.e.
they implement one EntityBean), they are loaded and stored together. You
can always assume that the Organization will exist along with the same
OrgUnit.

If you have two entity beans that relate to each other, you should
always use the remote interfaces to allow the EJB server to determine
which instance to use (one of the beans can always be remote).

If you have one entity bean that consists of multiple classes
(dependent), then these classes can (and should) reference each other
directly. This design guideline is true for both JavaBeans and EJB.

arkin


>
> Thanks.
>
> Francis.

===========================================================================
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".

Reply via email to