gpt4 book ai didi

java - NoClassDefFoundError 仅在我的机器上

转载 作者:行者123 更新时间:2023-12-02 05:04:05 26 4
gpt4 key购买 nike

我正在尝试运行应用程序,但我的计算机上出现错误。这似乎只针对我的机器 - 其他人让这个工作没有问题,我已经尝试设置我的环境很多很多次。谁能就造成这种情况的原因提出任何建议?

04:23:59,627 INFO  [STDOUT] 04:23:59,624 ERROR ServeResourcePhaseListener:105 - Exception wile retrieving addResource
java.lang.NoClassDefFoundError: org/apache/commons/el/Logger

at org.apache.myfaces.shared_tomahawk.util.ClassUtils.<clinit>(ClassUtils.java:44)
at org.apache.myfaces.shared_tomahawk.config.MyfacesConfig.<clinit>(MyfacesConfig.java:105)
at org.apache.myfaces.renderkit.html.util.AddResourceFactory.getInstance(AddResourceFactory.java:304)
at org.apache.myfaces.webapp.filter.ServeResourcePhaseListener.beforePhase(ServeResourcePhaseListener.java:96)
at com.sun.faces.lifecycle.Phase.handleBeforePhase(Phase.java:214)
at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:96)
at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:103)
at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
at javax.faces.webapp.FacesServlet.service(FacesServlet.java:265)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:530)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.app.package.filters.NewSessionFilter.doFilter(NewSessionFilter.java:89)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at com.app.package.filters.Perf4JFilter.doFilter(Perf4JFilter.java:53)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
at org.jboss.seam.web.IdentityFilter.doFilter(IdentityFilter.java:40)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:90)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:45)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.ajax4jsf.webapp.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:206)
at org.ajax4jsf.webapp.BaseFilter.handleRequest(BaseFilter.java:290)
at org.ajax4jsf.webapp.BaseFilter.processUploadsAndHandleRequest(BaseFilter.java:388)
at org.ajax4jsf.webapp.BaseFilter.doFilter(BaseFilter.java:515)
at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:56)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:60)
at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:158)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:235)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:190)
at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:92)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.process(SecurityContextEstablishmentValve.java:126)
at org.jboss.web.tomcat.security.SecurityContextEstablishmentValve.invoke(SecurityContextEstablishmentValve.java:70)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:158)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:330)
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:829)
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:598)
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: org.apache.commons.el.Logger from

这是来自控制台的一些附加信息,不确定是否有帮助。抱歉,格式不正确,但它最初是一大行,所以我试图将其分解。

BaseClassLoader@4198f74e{VFSClassLoaderPolicy@21944387{name=vfszip:/Users/user/Documents/jboss-5.1.0.GA/server/default/deploy/app.ear/app.war/ 
domain=ClassLoaderDomain@2d8816ec{name=vfszip:/Users/user/Documents/jboss-5.1.0.GA/server/default/deploy/app.ear/app.war/
parentPolicy=AFTER_BUT_JAVA_BEFORE
parent=BaseClassLoader@6d575fa5{vfszip:/Users/user/Documents/jboss-5.1.0.GA/server/default/deploy/app.ear/}} roots=[ZipEntryHandler@215835978[path=app.war/WEB-INF/classes
context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/classes],
DelegatingHandler@455402463[path=app.war/WEB-INF/lib/commons-beanutils-1.8.0.jar
context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/commons-beanutils-1.8.0.jar],
DelegatingHandler@317477733[path=app.war/WEB-INF/lib/commons-collections-3.2.1.jar
context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/commons-collections-3.2.1.jar],
DelegatingHandler@1498879383[path=app.war/WEB-INF/lib/commons-digester-2.0.jar context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/commons-digester-2.0.jar],
DelegatingHandler@1682610771[path=app.war/WEB-INF/lib/commons-logging-1.1.1.jar context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/commons-logging-1.1.1.jar],
DelegatingHandler@1574564501[path=app.war/WEB-INF/lib/jboss-seam-debug-2.2.0.GA.jar context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/jboss-seam-debug-2.2.0.GA.jar],
DelegatingHandler@264586326[path=app.war/WEB-INF/lib/jboss-seam-excel-2.2.0.GA.jar context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear real=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v/app.ear/app.war/WEB-INF/lib/jboss-seam-excel-2.2.0.GA.jar],
DelegatingHandler@1611231792[path=app.war/WEB-INF/lib/jboss-seam-ioc-2.2.0.GA.jar context=file:/Users/user/Documents/jboss-5.1.0.GA/server/default/tmp/a6m2n-ng4vfl-i4xmq3n8-1-i4xmqccy-v

最佳答案

似乎您在构建路径中缺少 Commons Logging 类。从 http://commons.apache.org/proper/commons-logging/download_logging.cgi 获取 Commons Logging 库并将它们添加到您的 lib 文件夹中,并将它们添加到您的项目类路径中。

如果您使用 Maven 等构建工具来管理依赖项,请在 pom.xml 中添加以下行

<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<version>1.2</version>
</dependency>

关于java - NoClassDefFoundError 仅在我的机器上,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27957002/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com