Why does a deployment descriptor for a bean have ejb-ref?

I'm reading the Monson-Haeful book and I don't quite understand why it is
necessary for the TravelAgent bean to have an ejb-ref to the CabinBean in
it's deployment descriptor.

When I deploy my TravelAgent bin I'll give it a JNI path and the TravelAgent
bean can use this path to lookup the Cabin Beans home under JNI.

In the past he used vendor specific implementations of the
getInitialContext() method that basically set the properties based on the
vendors specifications. Now all of a sudden he's described the mapping used
to find the CabinBeans Home from the TravelAgent bean.

Is he saying here that a bean in a container can locate a home reference
through the mapping in the deployment descriptor without a vendor specific
getInitialContext() method but when using a client on the client side you
must get an initalContext using the vendors specific implementation?

So in this sense a bean acting a client to another bean is different from a
client application and thus location transparency WRT to doing JNDI lookups
does exist?

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