在尝试将 Richfaces 集成到 JSF2 项目中时,我收到了警告。
Warning: The page /template/template.xhtml declares namespace http://richfaces.org/a4j and uses the tag a4j:region , but no TagLibrary associated to namespace.
我没有使用 maven,所以我手动制作了所有内容。我做了以下事情来集成它: 将 EAR 部署程序集放入以下 jars 中:
richfaces-components-api-4.3.0.Final.jar
richfaces-components-ui-4.3.0.Final.jar
richfaces-core-api-4.3.0.Final.jar
richfaces-core-impl-4.3.0.Final.jar
sac-1.3.jar
guava-11.0.2.jar
cssparser-0.9.5.jar
将其添加到 WAR 的清单中。
这是页面片段:
<ui:composition
xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:t="http://myfaces.apache.org/tomahawk"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:a4j="http://richfaces.org/a4j"
id="TemplateView">
...
<h:form id="templateForm">
<a4j:region>
<a4j:jsFunction name="refreshSession">
<a4j:actionparam name="refresh" assignTo="#{ilapAdapter.refreshSession}"/>
</a4j:jsFunction>
</a4j:region>
</h:form>
...
我错过了什么吗?为什么我会收到此警告?根据“入门”指南,无需在 faces-config.xml 或 web.xml 中进行额外配置。
我只需要 Richfaces 的 Ajax 功能。
PS。将richfaces-core-api-4.3.0.Final.jar、richfaces-core-impl-4.3.0.Final.jar 放在WEB-INF.lib 中也不起作用。
Richfaces 相关 SystemOut:
[08.02.13 14:18:26:398 CET] 00000022 DefaultFacesC I Reading config : wsjar:file:/C:/projects/folab/workspace/FOLAB-WAS8/installedApps/CE02110Node02Cell/Dialog_Common_EAR.ear/richfaces-core-impl-4.3.0.Final.jar!/META-INF/faces-config.xml
[08.02.13 14:18:26:949 CET] 00000022 Config W org.richfaces.application.DefaultModule configure There was no service org.richfaces.focus.FocusManager found
[08.02.13 14:18:26:956 CET] 00000022 Cache I org.richfaces.cache.CacheManager getCacheFactory Selected fallback cache factory
[08.02.13 14:18:26:959 CET] 00000022 Cache I org.richfaces.cache.lru.LRUMapCacheFactory createCache Creating LRUMap cache instance using parameters: {com.ibm.ws.jsf.JSP_UPDATE_CHECK=true, javax.faces.STATE_SAVING_METHOD=server, javax.faces.PROJECT_STAGE=Development, com.ibm.ws.jsf.LOAD_FACES_CONFIG_AT_STARTUP=true, javax.faces.CONFIG_FILES=/WEB-INF/faces-navigation.xml, javax.faces.DEFAULT_SUFFIX=.xhtml}
[08.02.13 14:18:26:969 CET] 00000022 Cache I org.richfaces.cache.lru.LRUMapCacheFactory createCache Creating LRUMap cache instance of 512 items capacity
[08.02.13 14:18:26:985 CET] 00000022 Application I org.richfaces.application.InitializationListener onStart by , version
[08.02.13 14:18:26:989 CET] 00000022 Application W org.richfaces.application.InitializationListener logWarningWhenConnectionFactoryPresent JMS API was found on the classpath; if you want to enable RichFaces Push JMS integration, set context-param 'org.richfaces.push.jms.enabled' in web.xml