简体   繁体   English

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

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

Getting a deployment error when deploying an ear (myapp.ear) to weblogic 12.1.3. 将耳朵(myapp.ear)部署到weblogic 12.1.3时遇到部署错误。 Error: 错误:

NoClassDefFoundError: org/apache/commons/io/IOUtils NoClassDefFoundError:org / apache / commons / io / IOUtils

Notes: 笔记:

  1. Compiles fine: mvn clean; 编译良好:mvn clean; mvn install mvn安装
  2. The EAR has APP-INF/lib/commons-io-2.4.jar which has that class EAR的APP-INF / lib / commons-io-2.4.jar具有该类
  3. Thought maybe a jar conflict. 以为可能是罐子冲突。 weblogic has 2 jars w/ same package.class (wlserver/modules/com.bea.core.apache.commons.io_1.2.0.0_1-4.jar & wlserver/modules/features/weblogic.server.merged.jar) but ... those aren't in classpath 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. Tried again w/o adding jar to app (scope=provided - pom.xml) but same error 再次尝试不向应用程序添加jar(范围=已提供-pom.xml),但存在相同错误

Actual Error: 实际错误:

####<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 ::.> 

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

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

And similar questions like: 以及类似的问题:

How to set order of jars in WebLogic? 如何在WebLogic中设置jar的顺序?

I would try a <prefer-application-packages> solution first. 我会先尝试<prefer-application-packages>解决方案。

However, NoClassDef means the class was literally not found. 但是,NoClassDef意味着实际上找不到该类。 You compiled it but it's no longer on the classpath (so also check the structure of your ear). 您已经对其进行了编译,但是它不再位于类路径中(因此还要检查您的耳朵的结构)。 See: What causes and what are the differences between NoClassDefFoundError and ClassNotFoundException? 请参阅: 什么原因以及NoClassDefFoundError和ClassNotFoundException之间有什么区别?

暂无
暂无

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

相关问题 Android等效于org.apache.commons.io.IOUtils.toByteArray - Android equivalent for org.apache.commons.io.IOUtils.toByteArray 我应该关闭org.apache.commons.io.IOUtils的InputStream吗? - Should I close the InputStream of org.apache.commons.io.IOUtils org / apache / commons / io / FileUtils-NoClassDefFoundError - org/apache/commons/io/FileUtils - NoClassDefFoundError 模拟apache.commons.io.IOUtils类 - Mocking apache.commons.io.IOUtils class 运行 maven 项目时出错 java.lang.ClassNotFoundException: org.apache.commons.io.IOUtils - error while running maven project java.lang.ClassNotFoundException: org.apache.commons.io.IOUtils java.lang.NoSuchMethodError:org.apache.commons.io.IOUtils.read with Tika(检测方法) - java.lang.NoSuchMethodError: org.apache.commons.io.IOUtils.read with Tika (detect method) 使用Apache commons-io IOUtils.close可以安全吗? - Is it safe to use Apache commons-io IOUtils.closeQuietly? NoClassDefFoundError: org/apache/commons/lang3/StringUtils - NoClassDefFoundError: org/apache/commons/lang3/StringUtils javax.servlet.ServletException:java.lang.NoClassDefFoundError:org / apache / commons / io / output / DeferredFileOutputStream - javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/commons/io/output/DeferredFileOutputStream Java 9 JRE在jar执行时导致java.lang.NoClassDefFoundError:org / apache / commons / lang3 / StringUtils - Java 9 JRE causes java.lang.NoClassDefFoundError: org/apache/commons/lang3/StringUtils on jar execution
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM