getHibernateFlushMode is not valid without active transaction;
程序员文章站
2022-04-15 18:37:33
...
HTTP Status 500 - getHibernateFlushMode is not valid without active transaction; nested exception is org.hibernate.HibernateException: getHibernateFlushMode is not valid without active transaction
如果你是以上异常,可以在hibernate核心配置文件中查看是否有以下配置
<property name="hibernate.current_session_context_class">thread</property>
如果有,请删除(具体原因有待了解)
推荐阅读
-
getHibernateFlushMode is not valid without active transaction;
-
isConnected is not valid without active transaction报错原因
-
spring和hibernate整合时异常(详解): getFlushMode is not valid without active transaction
-
SSH下Hibernate事务问题createCriteria is not valid without active transaction
-
spring+hibernate4异常org.hibernate.HibernateExc和createCriteria is not valid without active transaction