JavaWebError01(HTTP Status 500 - Write operations are not allowed in read-only mode)

样式:

HTTP Status 500 - 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

图片:

解决方式:service层没有添加事务管理,因此在service层添加@Transactional注解即可

猜你喜欢

转载自www.cnblogs.com/liu-shi-xiong/p/8975153.html