目 录CONTENT

文章目录

SpringBoot启动报错:Error creating bean with name 'servletEndpointRegistrar' defined in class path resource

大T
2021-11-28 / 0 评论 / 0 点赞 / 21 阅读 / 0 字

SpringBoot启动报错:Error creating bean with name 'servletEndpointRegistrar' defined in class path resource

SpringBoot启动报错:Error creating bean with name 'servletEndpointRegistrar' defined in class path resource

2021-11-24 15:25:26.381 ERROR 11040 --- o.s.b.w.e.t.TomcatStarter : Error starting Tomcat context. Exception: org.springframework.beans.factory.BeanCreationException. Message: Error creating bean with name 'servletEndpointRegistrar' defined in class path resource 。

image

往下翻会看到一句:

Error creating bean with name 'servletEndpointRegistrar' defined in class path resource

再往下仔细查找,有下面的报错:

Factory method 'dataSource' threw exception; nested exception is java.lang.IllegalStateException: Cannot load driver class: org.postgresql.Driver

image

很明显,缺少驱动,检查pom文件,没发现问题。

image

解决问题的操作:

清空缓存重启IDEA

输入maven命令:mvn idea:idea

0

评论区