Bom dia pessoal,
estou fazendo um aplicação de teste e qdo tento executar ocorre o seguinte erro:
Exception in thread "main" org.hibernate.HibernateException: No CurrentSessionContext configured!
at org.hibernate.impl.SessionFactoryImpl.getCurrentSession(SessionFactoryImpl.java:540)
at com.jchrisos.dao.GenericDAO.create(GenericDAO.java:14)
at com.jchrisos.test.Test.main(Test.java:21)
meu hibernate.cfg.xml está assim:
<!DOCTYPE hibernate-configuration PUBLIC
"-//Hibernate/Hibernate Configuration DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
<session-factory>
<property name="show_sql">true</property>
<property name="dialect">org.hibernate.dialect.MySQL5Dialect</property>
<property name="connection.driver_class">com.mysql.jdbc.Driver</property>
<property name="connection.url">jdbc:mysql://localhost/test</property>
<property name="connection.username">root</property>
<property name="connection.password">123456</property>
<mapping class="com.test.vo.PostVO"/>
</session-factory>
</hibernate-configuration>
Agradeço desde já!
Obrigado!
