Caused by: org.springframework.context.ApplicationContextException: Unable to start ServletWebServer

简介: Caused by: org.springframework.context.ApplicationContextException: Unable to start ServletWebServer

错误原因:

SpringApplication.run();中的类名书写错误,应该是写成springboot启动类的类名而不是其他的

如下所示,我启动类的类名为Main,那么在run方法中应该为Main.class而不是其它

@SpringBootApplication
public class Main {
    public static void main(String[] args) {
        SpringApplication.run(Main.class,args);
    }
}
相关文章
|
7月前
|
Java
SpringBoot启动报错:org.apache.catalina.LifecycleException: Protocol handler start failed
SpringBoot启动报错:org.apache.catalina.LifecycleException: Protocol handler start failed
106 0
|
7月前
|
搜索推荐 Java 开发者
org.springframework.context.ApplicationContextException: Failed to start bean 'documentationPluginsBootstrapper'; nested exception is java.lang.NullPointerException 问题处理
【5月更文挑战第14天】org.springframework.context.ApplicationContextException: Failed to start bean 'documentationPluginsBootstrapper'; nested exception is java.lang.NullPointerException 问题处理
840 1
|
4月前
|
Java Maven
Unable to start web server; nested exception is org.springframework.context.ApplicationContextException: Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory bean.
Unable to start web server; nested exception is org.springframework.context.ApplicationContextException: Unable to start ServletWebServerApplicationContext due to missing ServletWebServerFactory bean.
76 0
|
4月前
Consider defining a bean of type 'org.springframework.security.authentication.AuthenticationManager' in your configuration.
Consider defining a bean of type 'org.springframework.security.authentication.AuthenticationManager' in your configuration.
107 0
|
Java 容器
《Springboot极简教程》问题解决:org.apache.catalina.LifecycleException: A child container failed during start
错误日志 org.apache.catalina.LifecycleException: A child container failed during start 原因分析 项目依赖里面单独指定了servlet-api,类路径里面有多个版本servlet-api,导致类冲突 javax.
2434 0
|
6月前
|
Java
Exception in thread “main“ org.apache.ibatis.exceptions.PersistenceException:
Exception in thread “main“ org.apache.ibatis.exceptions.PersistenceException:
|
7月前
org.apache.catalina.LifecycleException: Protocol handler start failed
org.apache.catalina.LifecycleException: Protocol handler start failed
80 0
|
7月前
|
Java
org.springframework.web.util.NestedServletException: Request processing failed; nested exception....
org.springframework.web.util.NestedServletException: Request processing failed; nested exception....
169 0
|
前端开发 Java 应用服务中间件
Error configuring application listener of class org.springframework.web.context.ContextLoader
Error configuring application listener of class org.springframework.web.context.ContextLoader
Error configuring application listener of class org.springframework.web.context.ContextLoader
|
Java 应用服务中间件
严重: Exception sending context destroyed event to listener instance of class org.springframework.web.
严重: Exception sending context destroyed event to listener instance of class org.springframework.web.
303 0
严重: Exception sending context destroyed event to listener instance of class org.springframework.web.