Hi..
Brent's approach is absolutely fine. Use a Business Deligate class which is nothing but a plane
java class (POJO approach) which takes care of all EJB specific tasks. However, don't put your JNDI lookups into deligate class. Rather use Service Locator pattern to do that. A Service Locator is again a java class which may contain methods (say) like
, which may do all the JNDI lookups for an EJB (say) CustomerManagerEJB and keeps that remote reference in a Hashtable so that next time you require the same reference, you can get it from the Hashtable. Just search in SUN's web site for Service Locator pattern. And with the help of Business Deligate and Service Locator patterns you can isolate your business layer from web layer. And your struts action class or other
servlets may call methods on Business Deligate class only.
Hope this helps.
Regards,
Niranjan