Archive

Posts Tagged ‘Hibernate’

Hibernate Exception – No CurrentSessionContext configured

June 30, 2013 Comments off

Exception :
Exception in thread “main” org.hibernate.HibernateException: No CurrentSessionContext configured!
at org.hibernate.impl.SessionFactoryImpl.getCurrentSession(SessionFactoryImpl.java:620)
at org.hibernate.tutorial.web.EventManager.createAndStoreEvent(EventManager.java:52)
at org.hibernate.tutorial.web.EventManager.main(EventManager.java:20)

Solution :

The below solution worked for me.
http://stackoverflow.com/questions/11160463/no-currentsessioncontext-configured-threadlocalsessioncontext-bindsession-i?_sm_au_=iNsb6K5st4Zsv7RD

Advertisements
%d bloggers like this: