I\'ve a web application which uses framework like Struts and Hibernate. Currently I\'m developing a scheduler for this application using Quartz. While coding I realized that
One approach is to use a HibernateUtil class which builds the SessionFactory in a static initializer and makes it available via a public static getter. Your Quartz job can create a Session as HibernateUtil.getSessionFactory().getCurrentSession() and use it.