springboot打包jar后,启动报错,请大牛帮助

关注 发布于 2017/02/07 13:27
阅读 1K+
收藏 0

2017-02-07 13:05:39.033  INFO 9908 --- [           main] ationConfigEmbeddedWebApplicationContext : Refreshing org.springframework.boot.context.embedded.AnnotationConfigEmbeddedWebApplicationContext@2d38eb89: startup date [Tue Feb 07 13:05:39 CST 2017]; root of context hierarchy
2017-02-07 13:05:43.319  INFO 9908 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Multiple Spring Data modules found, entering strict repository configuration mode!
2017-02-07 13:05:43.569  INFO 9908 --- [           main] .s.d.r.c.RepositoryConfigurationDelegate : Multiple Spring Data modules found, entering strict repository configuration mode!
2017-02-07 13:05:44.099  WARN 9908 --- [           main] o.s.c.a.ConfigurationClassEnhancer       : @Bean method ProperiesConfig.initPropertyPlaceholder is non-static and returns an object assignable to Spring's BeanFactoryPostProcessor interface. This will result in a failure to process annotations such as @Autowired, @Resource and @PostConstruct within the method's declaring @Configuration class. Add the 'static' modifier to this method to avoid these container lifecycle issues; see @Bean javadoc for complete details.
2017-02-07 13:05:44.288  INFO 9908 --- [           main] f.a.AutowiredAnnotationBeanPostProcessor : JSR-330 'javax.inject.Inject' annotation found and supported for autowiring
2017-02-07 13:05:44.571  INFO 9908 --- [           main] trationDelegate$BeanPostProcessorChecker : Bean 'redisCacheConfig' of type [class net.hbzs.rzn.config.RedisCacheConfig$$EnhancerBySpringCGLIB$$96db3a13] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-02-07 13:05:44.578  INFO 9908 --- [           main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.cache.annotation.ProxyCachingConfiguration' of type [class org.springframework.cache.annotation.ProxyCachingConfiguration$$EnhancerBySpringCGLIB$$6240c389] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-02-07 13:05:44.668  INFO 9908 --- [           main] trationDelegate$BeanPostProcessorChecker : Bean 'org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration' of type [class org.springframework.transaction.annotation.ProxyTransactionManagementConfiguration$$EnhancerBySpringCGLIB$$192e8d6b] is not eligible for getting processed by all BeanPostProcessors (for example: not eligible for auto-proxying)
2017-02-07 13:05:45.834  INFO 9908 --- [           main] s.b.c.e.t.TomcatEmbeddedServletContainer : Tomcat initialized with port(s): 8080 (http)
2017-02-07 13:05:45.856  INFO 9908 --- [           main] o.apache.catalina.core.StandardService   : Starting service Tomcat
2017-02-07 13:05:45.860  INFO 9908 --- [           main] org.apache.catalina.core.StandardEngine  : Starting Servlet Engine: Apache Tomcat/8.5.11
2017-02-07 13:05:46.034 ERROR 9908 --- [cat-startStop-1] org.apache.catalina.core.ContainerBase   : A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].TomcatEmbeddedContext[/rzn]]                                                                 at java.util.concurrent.FutureTask.report(FutureTask.java:122) [na:1.8.0_51]
        at java.util.concurrent.FutureTask.get(FutureTask.java:192) [na:1.8.0_51]                                               at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:939) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                        at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]         at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409) [tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                      at java.util.concurrent.FutureTask.run(FutureTask.java:266) [na:1.8.0_51]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) [na:1.8.0_51]                        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) [na:1.8.0_51]
        at java.lang.Thread.run(Thread.java:745) [na:1.8.0_51]
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost].TomcatEmbeddedContext[/rzn]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 6 common frames omitted
Caused by: org.apache.catalina.LifecycleException: Failed to start component [Pipeline[StandardEngine[Tomcat].StandardHost[localhost].TomcatEmbeddedContext[/rzn]]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5099) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 6 common frames omitted
Caused by: org.apache.catalina.LifecycleException: Failed to start component [org.apache.catalina.authenticator.NonLoginAuthenticator[/rzn]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardPipeline.startInternal(StandardPipeline.java:170) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]         ... 8 common frames omitted                                                                                     Caused by: java.lang.NoSuchMethodError: javax.servlet.ServletContext.getVirtualServerName()Ljava/lang/String;
        at org.apache.catalina.authenticator.AuthenticatorBase.startInternal(AuthenticatorBase.java:1137) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                      at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 10 common frames omitted
 2017-02-07 13:05:46.039 ERROR 9908 --- [           main] org.apache.catalina.core.ContainerBase   : A child container failed during start

java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost]]
        at java.util.concurrent.FutureTask.report(FutureTask.java:122) ~[na:1.8.0_51]                                           at java.util.concurrent.FutureTask.get(FutureTask.java:192) ~[na:1.8.0_51]
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:939) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) [tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                       at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.startup.Tomcat.start(Tomcat.java:343) [tomcat-embed-core-8.5.11.jar!/:8.5.11]                    at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:98) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.<init>(TomcatEmbeddedServletContainer.java:84) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getTomcatEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:535) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:177) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.createEmbeddedServletContainer(EmbeddedWebApplicationContext.java:164) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:134) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:536) [spring-context-4.3.6.RELEASE.jar!/:4.3.6.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:762) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]                                                                                                               at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:372) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:316) [spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]                                                                                                                   at net.hbzs.rzn.config.RznApplication.main(RznApplication.java:17) [classes!/:2.1]
        at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_51]
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_51]                         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_51]
        at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_51]
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [rzn.jar:2.1]
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [rzn.jar:2.1]
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) [rzn.jar:2.1]                                      at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) [rzn.jar:2.1]
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat].StandardHost[localhost]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1419) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1409) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                     at java.util.concurrent.FutureTask.run(FutureTask.java:266) ~[na:1.8.0_51]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) ~[na:1.8.0_51]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) ~[na:1.8.0_51]
        at java.lang.Thread.run(Thread.java:745) ~[na:1.8.0_51]                                                         Caused by: org.apache.catalina.LifecycleException: A child container failed during start
        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:947) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:872) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                          at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) [tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 6 common frames omitted
 
 2017-02-07 13:05:46.041  WARN 9908 --- [           main] ationConfigEmbeddedWebApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat                                                                             2017-02-07 13:05:46.055 ERROR 9908 --- [           main] o.s.boot.SpringApplication               : Application startup failed                                                                                                                  
org.springframework.context.ApplicationContextException: Unable to start embedded container; nested exception is org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:137) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:536) ~[spring-context-4.3.6.RELEASE.jar!/:4.3.6.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.refresh(EmbeddedWebApplicationContext.java:122) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:762) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:372) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.SpringApplication.run(SpringApplication.java:316) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at net.hbzs.rzn.config.RznApplication.main(RznApplication.java:17) [classes!/:2.1]                                      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.8.0_51]
        at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[na:1.8.0_51]                         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.8.0_51]                 at java.lang.reflect.Method.invoke(Method.java:497) ~[na:1.8.0_51]
        at org.springframework.boot.loader.MainMethodRunner.run(MainMethodRunner.java:48) [rzn.jar:2.1]                         at org.springframework.boot.loader.Launcher.launch(Launcher.java:87) [rzn.jar:2.1]
        at org.springframework.boot.loader.Launcher.launch(Launcher.java:50) [rzn.jar:2.1]                                      at org.springframework.boot.loader.JarLauncher.main(JarLauncher.java:51) [rzn.jar:2.1]
Caused by: org.springframework.boot.context.embedded.EmbeddedServletContainerException: Unable to start embedded Tomcat
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:117) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.<init>(TomcatEmbeddedServletContainer.java:84) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]                                                              at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getTomcatEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:535) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainerFactory.getEmbeddedServletContainer(TomcatEmbeddedServletContainerFactory.java:177) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.createEmbeddedServletContainer(EmbeddedWebApplicationContext.java:164) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        at org.springframework.boot.context.embedded.EmbeddedWebApplicationContext.onRefresh(EmbeddedWebApplicationContext.java:134) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        ... 14 common frames omitted
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardServer[-1]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                                at org.apache.catalina.startup.Tomcat.start(Tomcat.java:343) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        at org.springframework.boot.context.embedded.tomcat.TomcatEmbeddedServletContainer.initialize(TomcatEmbeddedServletContainer.java:98) ~[spring-boot-1.4.4.RELEASE.jar!/:1.4.4.RELEASE]
        ... 19 common frames omitted
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Tomcat]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                                at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:793) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                      at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 21 common frames omitted                                                                                    Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Tomcat]]
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                                at org.apache.catalina.core.StandardService.startInternal(StandardService.java:422) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                    at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                                ... 23 common frames omitted                                                                                    Caused by: org.apache.catalina.LifecycleException: A child container failed during start                                        at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:947) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                        at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:262) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]                                                                                                                      at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ~[tomcat-embed-core-8.5.11.jar!/:8.5.11]
        ... 25 common frames omitted

加载中
0
关注
关注

已经解决了,pom文件中少加几个依赖包

0
l
li_hai_wu

能说下少加了哪几个依赖包么?谢谢!

返回顶部
顶部