WARN:spring.jpa.open-in-view is enabled by default. Therefore, database queries may be performed during view rendering. Explicitly configure spring.jpa.open-in-view to disable this warning
警告:Spring Data Jpa,默认情况下,“在视图中打开”处于启用状态。因此,可以在视图渲染期间执行数据库查询。显式配置open-in-view=false。在视图中打开以禁用此警告
解决方案
在yml配置文件中加入如下配置
jpa:
open-in-view: false