Caused by: java.lang.ClassNotFoundException: org.hibernate.Session
微wx笑 2020-04-08【编程语言】 10 0关键字: java
Caused by: java.lang.ClassNotFoundException: org.hibernate.Session缺少hibernate 主要的 Jar包:完整的错误信息:一月 06, 2018 4:19:09 下午 org.apache.catalina.core.Ap
Caused by: java.lang.ClassNotFoundException: org.hibernate.Session
缺少hibernate 主要的 Jar包:
完整的错误信息:
一月 06, 2018 4:19:09 下午 org.apache.catalina.core.AprLifecycleListener init INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: …… 一月 06, 2018 4:19:09 下午 org.apache.tomcat.util.digester.SetPropertiesRule beginWARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:NoteServices-Test' did not find a matching property. 一月 06, 2018 4:19:10 下午 org.apache.coyote.AbstractProtocol init INFO: Initializing ProtocolHandler ["http-bio-8080"] 一月 06, 2018 4:19:10 下午 org.apache.coyote.AbstractProtocol init INFO: Initializing ProtocolHandler ["ajp-bio-8009"] 一月 06, 2018 4:19:10 下午 org.apache.catalina.startup.Catalina loadINFO: Initialization processed in 1280 ms 一月 06, 2018 4:19:10 下午 org.apache.catalina.core.StandardService startInternal INFO: Starting service Catalina 一月 06, 2018 4:19:10 下午 org.apache.catalina.core.StandardEngine startInternal INFO: Starting Servlet Engine: Apache Tomcat/7.0.35一月 06, 2018 4:19:12 下午 org.apache.catalina.core.ContainerBase startInternal SEVERE: A child container failed during startjava.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/LearnResourceService]]at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)at java.util.concurrent.FutureTask.get(Unknown Source)at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:800)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)at java.util.concurrent.FutureTask.run(Unknown Source)at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)at java.lang.Thread.run(Unknown Source) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/LearnResourceService]]at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154) ... 7 more Caused by: java.lang.NoClassDefFoundError: Lorg/hibernate/Session; at java.lang.Class.getDeclaredFields0(Native Method) at java.lang.Class.privateGetDeclaredFields(Unknown Source) at java.lang.Class.getDeclaredFields(Unknown Source) at org.apache.catalina.util.Introspection.getDeclaredFields(Introspection.java:106) at org.apache.catalina.startup.WebAnnotationSet.loadFieldsAnnotation(WebAnnotationSet.java:261) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationServletAnnotations(WebAnnotationSet.java:140) at org.apache.catalina.startup.WebAnnotationSet.loadApplicationAnnotations(WebAnnotationSet.java:67) at org.apache.catalina.startup.ContextConfig.applicationAnnotationsConfig(ContextConfig.java:405) at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:881) at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:369) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5179) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 7 more Caused by: java.lang.ClassNotFoundException: org.hibernate.Session at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1714) at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559) ... 21 more 一月 06, 2018 4:19:12 下午 org.apache.catalina.core.ContainerBase startInternal SEVERE: A child container failed during startjava.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]at java.util.concurrent.FutureTask$Sync.innerGet(Unknown Source)at java.util.concurrent.FutureTask.get(Unknown Source)at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:302)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:732)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)at org.apache.catalina.startup.Catalina.start(Catalina.java:684)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)at java.lang.reflect.Method.invoke(Unknown Source)at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:322)at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:456) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1559)at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1549)at java.util.concurrent.FutureTask$Sync.innerRun(Unknown Source)at java.util.concurrent.FutureTask.run(Unknown Source)at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)at java.lang.Thread.run(Unknown Source) Caused by: org.apache.catalina.LifecycleException: A child container failed during startat org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:800)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 7 more 一月 06, 2018 4:19:12 下午 org.apache.catalina.startup.Catalina startSEVERE: Catalina.start: org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]]at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)at org.apache.catalina.startup.Catalina.start(Catalina.java:684)at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)at java.lang.reflect.Method.invoke(Unknown Source)at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:322)at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:456) Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]]at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:732)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 7 more Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]]at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 9 more Caused by: org.apache.catalina.LifecycleException: A child container failed during startat org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:302)at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) ... 11 more 一月 06, 2018 4:19:12 下午 org.apache.catalina.startup.Catalina startINFO: Server startup in 2922 ms
这个问题很多人会认为问题的根本原因是:A child container failed during start,然而并非如此。
本文由 微wx笑 创作,采用 署名-非商业性使用-相同方式共享 4.0 许可协议,转载请附上原文出处链接及本声明。
原文链接:https://www.ivu4e.cn/blog/lang/2020-04-08/381.html