主要原因:spring-boot-dependencies 版本不稳定
我出错的版本:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>2.6.6</version>
<type>pom</type>
<scope>import</scope>
</dependency>导致出现以下错误:
无法启动 bean 'documentationPluginsBootstrapper';嵌套异常是 java.lang.NullPointerException

做法:将spring-boot-dependencies依赖的版本改为一个稳定的版本如下:改为 2.5.6 再次刷新maven 项目启动成功!
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>2.5.6</version>
<type>pom</type>
<scope>import</scope>
</dependency>版权声明:本文为m0_56044033原创文章,遵循CC 4.0 BY-SA版权协议,转载请附上原文出处链接和本声明。