spring 事务管理只读问题,跪求大神解答

用spring 事务管理的时候报错:
Write operations are not allowed in read-only mode (FlushMode.MANUAL): Turn your Session into FlushMode.COMMIT/AUTO or remove 'readOnly' marker from transaction definition. 跪求大神解答

事物配置有readonly吧,只读事物只能进行查询操作,不能进行修改操作。将readonly去掉就好

this.getHibernateTemplate().save的时候报只读的,跪求大神解答

你应该是在xml中配置的事物拦截吧,你的方法名被拦截了,换个不被拦截的方法名就行了