这两天在看http://blog.didispace.com/spring-boot-learning-21-2-2/的swagger教程,按着里面敲一遍,parent依赖版本为2.3.1的时候还没问题,第一遍的时候还正常运行,第二遍开始就一直报错
不知道什么原因,把pom里的parent版本改成跟教程里一致2.1.3就正常运行
补充:parent依赖的作用
sprintboot里的<parent>标签表示当前的springboot的各插件的默认版本,基于该父模板建立,提供默认的版本依赖。
参考:
1.《Spring Boot依赖spring-boot-starter-parent是干啥的?》https://blog.csdn.net/William0318/article/details/89854891
2.《Spring Boot学习--spring-boot-starter-parent及starters》https://blog.csdn.net/qq_35981283/article/details/77802771