Error in Name Space after migrating to JSF 2.2

こ雲淡風輕ζ 提交于 2019-12-01 07:35:08

问题


I am facing below issue, after I migrated to JSF2.2

 com.sun.faces.config.ConfigurationException: The tag named passThroughAttribute from namespace http://xmlns.jcp.org/jsf/core has a null handler-class defined
    at com.sun.faces.config.processor.FaceletTaglibConfigProcessor.processHandlerClass(FaceletTaglibConfigProcessor.java:422) [:2.2.0]
    at com.sun.faces.config.processor.FaceletTaglibConfigProcessor.processTags(FaceletTaglibConfigProcessor.java:378) [:2.2.0]
    at com.sun.faces.config.processor.FaceletTaglibConfigProcessor.processTagLibrary(FaceletTaglibConfigProcessor.java:321) [:2.2.0]
    at com.sun.faces.config.processor.FaceletTaglibConfigProcessor.process(FaceletTaglibConfigProcessor.java:270) [:2.2.0]
    at com.sun.faces.config.ConfigManager.initialize(ConfigManager.java:437) [:2.2.0]
    at com.sun.faces.config.ConfigureListener.contextInitialized(ConfigureListener.java:214) [:2.2.0]

I have made changes as per specifications as well I went through below url : http://jsfcorner.blogspot.in

and My changes are like:

<html xmlns="http://www.w3.org/1999/xhtml"
    xmlns:h="http://xmlns.jcp.org/jsf/html"
    xmlns:f="http://xmlns.jcp.org/jsf/core"
    xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
    xmlns:p="http://primefaces.org/ui">

and including passthrough as well

<html xmlns="http://www.w3.org/1999/xhtml"
    xmlns:h="http://xmlns.jcp.org/jsf/html"
    xmlns:f="http://xmlns.jcp.org/jsf/core"
    xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
    xmlns:pt="http://xmlns.jcp.org/jsf/passthrough"
    xmlns:p="http://primefaces.org/ui">

回答1:


The way how the new xmlns.jcp.org XML namespaces are been handled is broken in the first Mojarra releases 2.2.0 and 2.2.1. Among others, they overlooked to properly register the new JSF 2.2 components/tags/attributes/handlers. It has been fixed in Mojarra 2.2.2 as per issue 2900 (note: issue ticket describes different problem symptom, but under the covers, it's essentially the same cause).

So, upgrading to at least Mojarra 2.2.2 should fix your problem. It's currently already at 2.2.5.



来源:https://stackoverflow.com/questions/17331406/error-in-name-space-after-migrating-to-jsf-2-2

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!