spring 事务问题:Transaction rolled back because it has been marked as rollback-only
问题描述:同事测试时使用异常数据,代码报错但是并不是异常产生的错误,而出现:Transaction rolled back because it has been marked as rollback-only中文翻译就是:事务已回滚,因为它被标记成了只回滚代码片段: // 我的代码 @Transactional(readOnly = true, rollbackFor = Exception.class) public String select(Stri
原创
2020-08-11 19:51:49 ·
21686 阅读 ·
2 评论