繁体   English   中英

问题一旦将jsf 1.2迁移到jsf 2.2.12

[英]Problems once migrate jsf 1.2 to jsf 2.2.12

我正在将项目从jsf 1.2迁移到jsf 2.2.12。 构建成功后,我部署到jboss 7服务器,并收到如下错误消息:

14:14:10,255 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-7) MSC00001: Failed to start service jboss.deployment.unit."myproject-war.war".POST_MODULE: org.jboss.msc.service.StartException in service jboss.deployment.unit."myproject-war.war".POST_MODULE: Failed to process phase POST_MODULE of deployment "myproject-war.war"
    at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:119) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.startService(ServiceControllerImpl.java:1811) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    at org.jboss.msc.service.ServiceControllerImpl$StartTask.run(ServiceControllerImpl.java:1746) [jboss-msc-1.0.2.GA.jar:1.0.2.GA]
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_80]
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_80]
    at java.lang.Thread.run(Thread.java:745) [rt.jar:1.7.0_80]
Caused by: java.lang.RuntimeException: Error getting reflective information for class org.richfaces.taglib.ColumnsTag with ClassLoader ModuleClassLoader for Module "deployment.myproject-war.war:main" from Service Module Loader
    at org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex.getClassIndex(DeploymentReflectionIndex.java:70) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    at org.jboss.as.ee.metadata.MethodAnnotationAggregator.runtimeAnnotationInformation(MethodAnnotationAggregator.java:58)
    at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.handleAnnotations(InterceptorAnnotationProcessor.java:85)
    at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.processComponentConfig(InterceptorAnnotationProcessor.java:70)
    at org.jboss.as.ee.component.deployers.InterceptorAnnotationProcessor.deploy(InterceptorAnnotationProcessor.java:55)
    at org.jboss.as.server.deployment.DeploymentUnitPhaseService.start(DeploymentUnitPhaseService.java:113) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    ... 5 more
Caused by: java.lang.LinkageError: loader constraint violation in interface itable initialization: when resolving method "javax.faces.webapp.UIComponentClassicTagBase.getParent()Ljavax/servlet/jsp/tagext/Tag;" the class loader (instance of org/jboss/modules/ModuleClassLoader) of the current class, org/richfaces/taglib/ColumnsTag, and the class loader (instance of org/jboss/modules/ModuleClassLoader) for interface javax/servlet/jsp/tagext/Tag have different Class objects for the type ervlet/jsp/tagext/Tag; used in the signature
    at java.lang.Class.getDeclaredFields0(Native Method) [rt.jar:1.7.0_80]
    at java.lang.Class.privateGetDeclaredFields(Class.java:2509) [rt.jar:1.7.0_80]
    at java.lang.Class.getDeclaredFields(Class.java:1819) [rt.jar:1.7.0_80]
    at org.jboss.as.server.deployment.reflect.ClassReflectionIndex.<init>(ClassReflectionIndex.java:57) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    at org.jboss.as.server.deployment.reflect.DeploymentReflectionIndex.getClassIndex(DeploymentReflectionIndex.java:66) [jboss-as-server-7.1.1.Final.jar:7.1.1.Final]
    ... 10 more

14:14:10,286 INFO  [org.jboss.as.server] (management-handler-thread - 2) JBAS015870: Deploy of deployment "myproject-war.war" was rolled back with failure message {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"myproject-war.war\".POST_MODULE" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"myproject-war.war\".POST_MODULE: Failed to process phase POST_MODULE of deployment \"myproject-war.war\""}}
14:14:10,484 INFO  [org.jboss.as.server.deployment] (MSC service thread 1-4) JBAS015877: Stopped deployment myproject-war.war in 198ms
14:14:10,486 INFO  [org.jboss.as.controller] (management-handler-thread - 2) JBAS014774: Service status report
JBAS014777:   Services which failed to start:      service jboss.deployment.unit."myproject-war.war".POST_MODULE: org.jboss.msc.service.StartException in service jboss.deployment.unit."myproject-war.war".POST_MODULE: Failed to process phase POST_MODULE of deployment "myproject-war.war"

[2015-09-30 02:14:10,579] Artifact myproject-war:war exploded: Error during artifact deployment. See server log for details.
[2015-09-30 02:14:10,579] Artifact myproject-war:war exploded: java.lang.Exception: {"JBAS014671: Failed services" => {"jboss.deployment.unit.\"myproject-war.war\".POST_MODULE" => "org.jboss.msc.service.StartException in service jboss.deployment.unit.\"myproject-war.war\".POST_MODULE: Failed to process phase POST_MODULE of deployment \"myproject-war.war\""}}

您对此有任何想法吗?

这是我的系统详细信息:服务器:jboss7当前库:jsf 1.2,richfaces 3.3.3迁移库:jsf 2.2.17构建:maven

最好的祝福,

由以下原因导致:java.lang.LinkageError:接口可迭代初始化中的加载程序约束违规:当解析方法“ javax.faces.webapp.UIComponentClassicTagBase.getParent()Ljavax / servlet / jsp / tagext / Tag;”时 当前类org / richfaces / taglib / ColumnsTag的类加载器(org / jboss / modules / ModuleClassLoader的实例)和接口javax / servlet / jsp /的类加载器(org / jboss / modules / ModuleClassLoader的实例) tagext / Tag对于ervlet / jsp / tagext / Tag类型具有不同的Class对象; 用于签名

java.lang.LinkageError是带有多个不同版本库的类路径污染的标志。 您最好让Maven生成WAR文件,然后检查其/WEB-INF/lib中是否存在不属于该文件的任何库(即,目标服务器已经提供的库,例如Java EE,JSP ,Servlet,JSF等)。 然后相应地修复Maven pom.xml ,以准确标记provided

您获得的特定建议建议使用重复的javax.servlet.jsp.* API。 您将在/WEB-INF/lib很可能有一个jsp-api.jar或另一个涵盖此内容的JAR(例如javaee.jar )。 在这种情况下,您需要按provided那样在pom.xml准确标记该依赖项。 或者,如果它实际上是jsp-api ,则将其完全删除,并使用具有版本6.0和所provided范围的单个javaee-apijavaee-web-api依赖项,它已经完全覆盖了整个Java EE 6(Web配置文件)由JBoss AS 7。

暂无
暂无

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

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