标签: hibernate spring-data spring-data-jpa
我想避免Hibernate对我获取的实体进行脏检查。 使用Hibernate API,您可以使用以下方法执行此操作:Query#setReadOnly(boolean)。
我可以使用Spring Data实现相同的功能吗?
事务本身修改了其他实体,因此将事务标记为只读而不是选项。