當前位置:
首頁 >
前端技术
> javascript
>内容正文
javascript
SpringBoot项目启动提示:An attempt was made to call the method org.apache.coyote.AbstractProtocol.setAccept
生活随笔
收集整理的這篇文章主要介紹了
SpringBoot项目启动提示:An attempt was made to call the method org.apache.coyote.AbstractProtocol.setAccept
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
場景
在Eclipse中新建SpringBoot項目后啟動項目提示:
具體報錯信息如下:
? .?? ____????????? _??????????? __ _ _/\\ / ___'_ __ _ _(_)_ __? __ _ \ \ \ \ ( ( )\___ | '_ | '_| | '_ \/ _` | \ \ \ \\\/? ___)| |_)| | | | | || (_| |? ) ) ) )'? |____| .__|_| |_|_| |_\__, | / / / /=========|_|==============|___/=/_/_/_/:: Spring Boot ::??????? (v2.1.3.RELEASE)2019-03-06 23:21:03.829? INFO 5080 --- [?????????? main] c.e.demo.HelloSpringBootApplication????: Starting HelloSpringBootApplication on PC-20180724WIAC with PID 5080 (F:\EcpliseWorkspace\helloSpringBoot\target\classes started by Administrator in F:\EcpliseWorkspace\helloSpringBoot) 2019-03-06 23:21:03.835? INFO 5080 --- [?????????? main] c.e.demo.HelloSpringBootApplication????: No active profile set, falling back to default profiles: default 2019-03-06 23:21:05.047? WARN 5080 --- [?????????? main]ConfigServletWebServerApplicationContext : Exception encountered during context initialization -cancelling refresh attempt: org.springframework.context.ApplicationContextException: Unable tostart web server; nested exception is java.lang.NoSuchMethodError:org.apache.coyote.AbstractProtocol.setAcceptCount(I)V 2019-03-06 23:21:05.059? INFO 5080 --- [?????????? main]ConditionEvaluationReportLoggingListener :Error starting ApplicationContext. To display the conditions report re-run your application with'debug' enabled. 2019-03-06 23:21:05.066 ERROR 5080 --- [?????????? main] o.s.b.d.LoggingFailureAnalysisReporter?:*************************** APPLICATION FAILED TO START ***************************Description:An attempt was made to call the method org.apache.coyote.AbstractProtocol.setAcceptCount(I)V butit does not exist. Its class, org.apache.coyote.AbstractProtocol, is available from thefollowing locations:jar:file:/D:/Tomcat7/apache-tomcat-7/lib/tomcat-coyote.jar!/org/apache/coyote/AbstractProtocol.classjar:file:/D:/Maven/maven-repository/org/apache/tomcat/embed/tomcat-embed-core/9.0.16/tomcat-embed-core-9.0.16.jar!/org/apache/coyote/AbstractProtocol.classIt was loaded from the following location:解決
這是因為給項目配置Tomcat了。
右擊項目--Build Path--Config Build Path
選擇Tomcat,選擇Remove--Apply and Close
重新啟動項目,不再報錯。
總結
以上是生活随笔為你收集整理的SpringBoot项目启动提示:An attempt was made to call the method org.apache.coyote.AbstractProtocol.setAccept的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: 新建springBoot项目提示:The
- 下一篇: 访问新建的SpringBoot项目提示: