The examples I have seen (in S1) for using hibernate with struts involve using a plugin which creates a hibernate sessionFactory and stores it in session context. Each Action then retrieves the sessionFactory from the session and passes it to a model bean.

It is my understanding that if I were using a real J2EE container (which I am not doing, nor am I going to do) I could use JNDI to store the session factory and then retrieve it from within a model bean.

But I'm only using a servlet container (tomcat) so is my current strategy the only option? I would prefer if the model beans did not rely on the Actions to forward a sessionFactory, but I'm not sure if there is a way around it.

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to