I have a general question regarding using a remote stateless session bean as a facade for a group of local entity beans. Is it ok to do initial context lookups in the ejbCreate() method of the session bean and then use private fields of the session bean to hold the local home objects of the entity beans, or is this potentially a problem if the session bean is passivated? I'm currently doing this to save time from having to do lookups in the beginning of each session bean method. Instead, each method can immediately perform actions on the home objects that are stored in the private fields of the session bean.
Yes, this is perfectly acceptable.
The stateless bean can store state, provided it is
not "conversational state" with the client.
Stateless beans are never passivated,
they are just thrown away when there are too many
to go back into the pool.