javax.servlet.ServletException:com.acme.dao.StudentDao

时间:2016-08-17 00:25:51

标签: jboss7.x spring-4 nhibernate-3

我正在尝试在不同的服务器中部署我的项目。成功地,它与Tomcat7,Tomcat8,WildFly8和WildFly10一起工作。

有一次,我用JBoss 7.1运行它,显示以下异常:

09:37:42,894 INFO  [org.hibernate.tool.hbm2ddl.TableMetadata] (http-localhost-127.0.0.1-8080-1) HHH000261: Table found: JPAHibernateSpring.dbo.Employee
09:37:42,894 INFO  [org.hibernate.tool.hbm2ddl.TableMetadata] (http-localhost-127.0.0.1-8080-1) HHH000037: Columns: [id, name, country]
09:37:42,897 WARN  [org.hibernate.internal.SessionFactoryImpl] (http-localhost-127.0.0.1-8080-1) HHH000008: JTASessionContext being used with JDBCTransactionFactory; auto-flush will not operate correctly with getCurrentSession()
09:37:43,465 INFO  [stdout] (http-localhost-127.0.0.1-8080-1) Hibernate: select employee0_.id as id2_, employee0_.country as country2_, employee0_.name as name2_ from Employee employee0_

09:37:43,543 INFO  [stdout] (http-localhost-127.0.0.1-8080-1) ---------------------------------------List size= 3

09:37:49,665 SEVERE [javax.enterprise.resource.webcontainer.jsf.application] (http-localhost-127.0.0.1-8080-1) com.acme.dao.EmpDao from [Module "com.sun.jsf-impl:main" from local module loader @1f3eab7 (roots: D:\jboss-as-7.1.1.Final\modules)]: java.lang.ClassNotFoundException: com.acme.dao.EmpDao from [Module "com.sun.jsf-impl:main" from local module loader @1f3eab7 (roots: D:\jboss-as-7.1.1.Final\modules)]
    at org.jboss.modules.ModuleClassLoader.findClass(ModuleClassLoader.java:190)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClassUnchecked(ConcurrentClassLoader.java:468)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClassChecked(ConcurrentClassLoader.java:456)
    at org.jboss.modules.ConcurrentClassLoader.performLoadClass(ConcurrentClassLoader.java:398)
    at org.jboss.modules.ConcurrentClassLoader.loadClass(ConcurrentClassLoader.java:120)
    at java.lang.Class.forName0(Native Method) [rt.jar:1.7.0_55]
    at java.lang.Class.forName(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.resolveProxyClass(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readProxyDesc(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readClassDesc(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.defaultReadFields(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readSerialData(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.util.HashMap.readObject(Unknown Source) [rt.jar:1.7.0_55]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_55]
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at java.lang.reflect.Method.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectStreamClass.invokeReadObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readSerialData(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.defaultReadFields(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readSerialData(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readArray(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.util.HashMap.readObject(Unknown Source) [rt.jar:1.7.0_55]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_55]
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at java.lang.reflect.Method.invoke(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectStreamClass.invokeReadObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readSerialData(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readOrdinaryObject(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject0(Unknown Source) [rt.jar:1.7.0_55]
    at java.io.ObjectInputStream.readObject(Unknown Source) [rt.jar:1.7.0_55]
    at com.sun.faces.renderkit.ClientSideStateHelper.doGetState(ClientSideStateHelper.java:255) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.renderkit.ClientSideStateHelper.getState(ClientSideStateHelper.java:198) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.renderkit.ResponseStateManagerImpl.getState(ResponseStateManagerImpl.java:100) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.application.view.StateManagementStrategyImpl.restoreView(StateManagementStrategyImpl.java:224) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.application.StateManagerImpl.restoreView(StateManagerImpl.java:188) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.application.view.ViewHandlingStrategy.restoreView(ViewHandlingStrategy.java:123) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.application.view.FaceletViewHandlingStrategy.restoreView(FaceletViewHandlingStrategy.java:453) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.application.view.MultiViewHandler.restoreView(MultiViewHandler.java:142) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:192) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:116) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118) [jsf-impl-2.1.7-jbossorg-2.jar:]
    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:593) [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final]
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:329) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:248) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:275) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:161) [jbossweb-7.0.13.Final.jar:]
    at org.jboss.as.jpa.interceptor.WebNonTxEmCloserValve.invoke(WebNonTxEmCloserValve.java:50) [jboss-as-jpa-7.1.1.Final.jar:7.1.1.Final]
    at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:153) [jboss-as-web-7.1.1.Final.jar:7.1.1.Final]
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:155) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) [jbossweb-7.0.13.Final.jar:]
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:368) [jbossweb-7.0.13.Final.jar:]
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:877) [jbossweb-7.0.13.Final.jar:]
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:671) [jbossweb-7.0.13.Final.jar:]
    at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:930) [jbossweb-7.0.13.Final.jar:]
    at java.lang.Thread.run(Unknown Source) [rt.jar:1.7.0_55]

我正在寻找这个问题的解决方案。你能帮我吗?

0 个答案:

没有答案