这个问题已经在这里有了答案: > getting error missing a runtime dependency: java.lang.NoClassDefFoundError: org/apache/commons/fileupload/FileItem 1个
当我在NetBeans中运行项目时,一切正常,但是当我尝试部署它时,出现以下错误:
Error occurred during deployment:
Exception while loading the app : java.lang.IllegalStateException:
ContainerBase.addChild: start: org.apache.catalina.LifecycleException:
java.lang.RuntimeException:
com.sun.faces.config.ConfigurationException: Source Document:
jar:file:/C:/Users/User/Downloads/glassfish-4.0/glassfish4/glassfish/domains/domain1/applications/Zaman/WEB-INF/lib/primefaces-3.4.jar!/META-INF/faces-config.xml
Cause: Class 'org.primefaces.component.fileupload.FileUploadRenderer'
is missing a runtime dependency: java.lang.NoClassDefFoundError:
org/apache/commons/fileupload/FileItem. Please see server.log for more
details.
它说原因是:
Cause: Class 'org.primefaces.component.fileupload.FileUploadRenderer'
is missing a runtime dependency: java.lang.NoClassDefFoundError:
org/apache/commons/fileupload/FileItem.
我不知道该怎么办.
解决方法:
您应该将Commons Fileupload添加到您的应用程序.