繁体   English   中英

WebLogic-Jar存在,但NoClassDefFoundError:org / apache / commons / io / IOUtils

[英]WebLogic - Jar is there but NoClassDefFoundError: org/apache/commons/io/IOUtils

将耳朵(myapp.ear)部署到weblogic 12.1.3时遇到部署错误。 错误:

NoClassDefFoundError:org / apache / commons / io / IOUtils

笔记:

  1. 编译良好:mvn clean; mvn安装
  2. EAR的APP-INF / lib / commons-io-2.4.jar具有该类
  3. 以为可能是罐子冲突。 weblogic有2个带有相同package.class的jar(wlserver / modules / com.bea.core.apache.commons.io_1.2.0.0_1-4.jar和wlserver / modules / features / weblogic.server.merged.jar),但是...那些不在classpath中
  4. 再次尝试不向应用程序添加jar(范围=已提供-pom.xml),但存在相同错误

实际错误:

####<Apr 7, 2015 8:12:01 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451921167> <BEA-423147> <Exception [com.bea.portlet.adapter.scopedcontent.ActionLookupFailedException: java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils] thrown while trying to do task [handlePostbackData] in class [com.bea.netuix.servlets.controls.content.PageFlowContent].> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922415> <BEA-423405> <An exception [java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils] was thrown while rendering the content at [null].> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922415> <BEA-423137> <There was an error loading the requested URI null.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922431> <BEA-423223> <There was an error while running a lifecycle stage :: Lifecycle: UIControl.render :: for the control :: null ::.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423405> <An exception [java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils] was thrown while rendering the content at [/com/bea/console/actions/app/install/Flow.jpf].> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423137> <There was an error loading the requested URI /com/bea/console/actions/app/install/Flow.jpf.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423223> <There was an error while running a lifecycle stage :: Lifecycle: UIControl.render :: for the control :: null ::.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423405> <An exception [java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils] was thrown while rendering the content at [null].> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423137> <There was an error loading the requested URI null.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922446> <BEA-423223> <There was an error while running a lifecycle stage :: Lifecycle: UIControl.render :: for the control :: null ::.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922477> <BEA-423405> <An exception [java.lang.NoClassDefFoundError: org/apache/commons/io/IOUtils] was thrown while rendering the content at [null].> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922477> <BEA-423137> <There was an error loading the requested URI null.> 
####<Apr 7, 2015 8:12:02 PM EDT> <Error> <netuix> <IBMADM-BL787D> <myserver> <[ACTIVE] ExecuteThread: '8' for queue: 'weblogic.kernel.Default (self-tuning)'> <weblogic> <> <> <1428451922477> <BEA-423223> <There was an error while running a lifecycle stage :: Lifecycle: UIControl.render :: for the control :: null ::.> 

请参阅<prefer-web-inf-classes><prefer-application-packages>

http://docs.oracle.com/cd/E24329_01/web.1211/e21049/weblogic_xml.htm#WBAPP602

以及类似的问题:

如何在WebLogic中设置jar的顺序?

我会先尝试<prefer-application-packages>解决方案。

但是,NoClassDef意味着实际上找不到该类。 您已经对其进行了编译,但是它不再位于类路径中(因此还要检查您的耳朵的结构)。 请参阅: 什么原因以及NoClassDefFoundError和ClassNotFoundException之间有什么区别?

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM