Spring Boot启动应用总是报错如下:
Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory bean
与“Unable to start EmbeddedWebApplicationContext due to missing EmbeddedServletContainerFactory bean”如出一辙。
不是技术论坛中大家常说的应用入口类缺少@SpringBootApplication标注,或者是Spring bean缺少@EnableAutoConfiguration标注等问题。
是因为默认使用的嵌入式Tomcat容器无法启动。
解决的办法来了