How place Hibernate SessionFactory in JNDI on SAS 8.1 ?
Hi,
I've some stateless session beans that, behind the scenes, use hibernate for persisting my pojo domain model.
In the Hibernate 3.2.2 documentation I read that you can bind the Hibernate SessionFactory to JNDI and that there are two options to do so:
- in your stateless session bean use "cfg.buildSessionFactory()", or
- use JMX deployment with the HibernateService.
If I go for the first option then the question I have is whether the sessionfactory will be placed multiple times in JNDI (each bean calling cfg.buildSessionFactory), or will the implementation detect that the factory has already been placed in JNDI and therefore won't try to delete and replace it ?
If I go for the JMX option then how do I configure this on SAS 8.1 (J2EE 1.4) ? I really don't have a clue how to get started with this.
Are there other options than the two above ones ?
Cheers,
EDH