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);
    }
}
相关文章
|
29天前
|
Java
SpringBoot启动报错:org.apache.catalina.LifecycleException: Protocol handler start failed
SpringBoot启动报错:org.apache.catalina.LifecycleException: Protocol handler start failed
20 0
|
1月前
|
Java 数据库连接 mybatis
解决Error querying database. Cause: org.apache.ibatis.executor.ExecutorException: No constructor found
解决Error querying database. Cause: org.apache.ibatis.executor.ExecutorException: No constructor found
87 1
|
26天前
org.apache.catalina.LifecycleException: Protocol handler start failed
org.apache.catalina.LifecycleException: Protocol handler start failed
11 0
|
2月前
|
Java
org.springframework.web.util.NestedServletException: Request processing failed; nested exception....
org.springframework.web.util.NestedServletException: Request processing failed; nested exception....
33 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.
2280 0
|
10月前
|
Java 应用服务中间件 Maven
Error configuring application listener of class org.springframework.web.context.ContextLoaderListene
Error configuring application listener of class org.springframework.web.context.ContextLoaderListene
78 0
|
11月前
|
前端开发 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.
187 0
严重: Exception sending context destroyed event to listener instance of class org.springframework.web.
|
Java 数据库连接 数据库
### Error building SqlSession. ### Cause: org.apache.ibatis.builder.BuilderException: Error creating
在写数据库的url地址时用了“&”符号,将“&”换成“&;”
165 0
### Error building SqlSession. ### Cause: org.apache.ibatis.builder.BuilderException: Error creating
|
Java Maven
严重: Error configuring application listener of class org.springframework.web.util.Log4jConfigListener
严重: Error configuring application listener of class org.springframework.web.util.Log4jConfigListener
106 0
严重: Error configuring application listener of class org.springframework.web.util.Log4jConfigListener