当先锋百科网
首页
1
2
3
4
5
6
7
org.hibernate.HibernateException: No CurrentSessio
org.hibernate.HibernateException: No CurrentSessionContext configured!
错误,解决方法:
hibernate.cfg.xml中添加:
<!-- Enable Hibernate's automatic session context management -->
<property name="current_session_context_class">thread</property>