Resources framework is not initialised error when moving fro
lexlutor Feb 20, 2009 8:49 AMHi,
I've found an issue with Portlet Bridge B6. I have a simple portlet application (in fact is the rich faces greeting sample portletized). The portlet works ok with Portlet Bridge B5, but not with B6. The portlet config files (web.xml, portlet.xml, faces-config.xml) remain untouched, I just replace the portlet bridge jar files.
I'm using JSF 1.2_10 and RF3.3.0.GA.
The error trace I'm getting with the B6 version is the following:
[20/02/09 14:20:28:515 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetinPortlet/WebContent/WEB-INF/lib/jsf-facelets.jar!/META-INF/jsf-ui.taglib.xml [20/02/09 14:20:28:531 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/jsf-facelets.jar!/META-INF/jstl-core.taglib.xml [20/02/09 14:20:28:546 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/jsf-facelets.jar!/META-INF/jstl-fn.taglib.xml [20/02/09 14:20:28:562 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/richfaces-ui-3.3.0.GA.jar!/META-INF/a4j.taglib.xml [20/02/09 14:20:28:562 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/richfaces-ui-3.3.0.GA.jar!/META-INF/ajax4jsf.taglib.xml [20/02/09 14:20:28:578 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/richfaces-ui-3.3.0.GA.jar!/META-INF/jsp.taglib.xml [20/02/09 14:20:28:609 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/richfaces-ui-3.3.0.GA.jar!/META-INF/rich.taglib.xml [20/02/09 14:20:28:609 CET] 000000bc compiler I Added Library from: wsjar:file:/C:/mywork/cleanWS/GreetingPortlet/WebContent/WEB-INF/lib/richfaces-ui-3.3.0.GA.jar!/META-INF/richfaces.taglib.xml [20/02/09 14:20:29:015 CET] 000000bc viewhandler E Error Rendering View[/index.jspx] javax.faces.FacesException: Resources framework is not initialised, check web.xml for Filter configuration at org.ajax4jsf.resource.ResourceBuilderImpl.getWebXml(ResourceBuilderImpl.java:107) at org.ajax4jsf.resource.ResourceBuilderImpl.getUri(ResourceBuilderImpl.java:314) at org.ajax4jsf.resource.InternetResourceBase.getUri(InternetResourceBase.java:218) at org.ajax4jsf.resource.BaseResourceRenderer.encodeBegin(BaseResourceRenderer.java:64) at org.ajax4jsf.resource.OneTimeRenderer.encodeBegin(OneTimeRenderer.java:48) at org.ajax4jsf.resource.BaseResourceRenderer.encode(BaseResourceRenderer.java:47) at org.ajax4jsf.resource.InternetResourceBase.encode(InternetResourceBase.java:313) at org.ajax4jsf.renderkit.HeaderResourcesRendererBase.encodeResourcesArray(HeaderResourcesRendererBase.java:144) at org.ajax4jsf.renderkit.HeaderResourcesRendererBase.encodeToHead(HeaderResourcesRendererBase.java:156) at org.ajax4jsf.context.ViewResources.processComponent(ViewResources.java:325) at org.ajax4jsf.context.ViewResources.traverse(ViewResources.java:381) at org.ajax4jsf.context.ViewResources.traverse(ViewResources.java:385) at org.ajax4jsf.context.ViewResources.traverse(ViewResources.java:385) at org.ajax4jsf.context.ViewResources.processHeadResources(ViewResources.java:514) at org.jboss.portletbridge.renderkit.portlet.PortletAjaxViewRootRenderer.doEncodeEnd(PortletAjaxViewRootRenderer.java:70) at org.ajax4jsf.renderkit.RendererBase.encodeEnd(RendererBase.java:135) at org.ajax4jsf.component.AjaxViewRoot.encodeEnd(AjaxViewRoot.java:523) at javax.faces.component.UIComponent.encodeAll(UIComponent.java:937) at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:592) at org.ajax4jsf.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:100) at org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:176) at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:110) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100) at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) at org.jboss.portletbridge.AjaxPortletBridge.render(AjaxPortletBridge.java:840) at org.jboss.portletbridge.AjaxPortletBridge.renderResponse(AjaxPortletBridge.java:665) at org.jboss.portletbridge.AjaxPortletBridge.doFacesRequest(AjaxPortletBridge.java:501) at javax.portlet.faces.GenericFacesPortlet.doFacesDispatch(GenericFacesPortlet.java:351) at javax.portlet.faces.GenericFacesPortlet.doView(GenericFacesPortlet.java:312) at javax.portlet.GenericPortlet.doDispatch(GenericPortlet.java:328) at javax.portlet.faces.GenericFacesPortlet.doDispatch(GenericFacesPortlet.java:293) at javax.portlet.GenericPortlet.render(GenericPortlet.java:233)
I'm not sure if this has some relation with the error, but with the bridge B5 I can see the following traces in the output:
.. bridge I Start portletbridge initialization for GreetingPortlet .. bridge I Create instance of a JSF lifecycle DEFAULT .. bridge I Done portletbridge initialisation for GreetingPortlet .. bridge I Start bridge render request processing for portlet GreetingPortlet
These no longer appear with the B6 version.
I have tested with the javax.portlet.faces.renderPolicy param, but it no solves the problem with any of its values.
These are my config files:
web.xml
<context-param> <param-name>javax.faces.STATE_SAVING_METHOD</param-name> <param-value>server</param-value> </context-param> <context-param> <param-name>javax.faces.CONFIG_FILES</param-name> <param-value>/WEB-INF/faces-config.xml </param-value> </context-param> <context-param> <param-name>javax.faces.DEFAULT_SUFFIX</param-name> <param-value>.jspx</param-value> </context-param> <context-param> <param-name>org.ajax4jsf.RESOURCE_URI_PREFIX</param-name> <param-value>rfRes</param-value> </context-param> <context-param> <param-name>org.ajax4jsf.VIEW_HANDLERS</param-name> <param-value>org.jboss.portletbridge.application.FaceletPortletViewHandler</param-value> </context-param> <context-param> <param-name>org.richfaces.LoadStyleStrategy</param-name> <param-value>ALL</param-value> </context-param> <context-param> <param-name>org.richfaces.LoadScriptStrategy</param-name> <param-value>ALL</param-value> </context-param> <!-- Plugging the "Blue Sky" skin into the project --> <context-param> <param-name>org.richfaces.SKIN</param-name> <param-value>blueSky</param-value> </context-param> <!-- Making the RichFaces skin spread to standard HTML controls --> <context-param> <param-name>org.richfaces.CONTROL_SKINNING</param-name> <param-value>enable</param-value> </context-param> <!-- Special Debug Output for Development --> <context-param> <param-name>facelets.DEVELOPMENT</param-name> <param-value>true</param-value> </context-param> <!-- Optional JSF-RI Parameters to Help Debug --> <context-param> <param-name>com.sun.faces.validateXml</param-name> <param-value>true</param-value> </context-param> <filter> <display-name>RichFaces Filter</display-name> <filter-name>richfaces</filter-name> <filter-class>org.ajax4jsf.Filter</filter-class> </filter> <filter-mapping> <filter-name>richfaces</filter-name> <servlet-name>Faces Servlet</servlet-name> <dispatcher>REQUEST</dispatcher> <dispatcher>FORWARD</dispatcher> <dispatcher>INCLUDE</dispatcher> </filter-mapping> <listener> <listener-class>com.sun.faces.config.ConfigureListener</listener-class> </listener> <servlet> <servlet-name>Faces Servlet</servlet-name> <servlet-class>javax.faces.webapp.FacesServlet</servlet-class> <load-on-startup>1</load-on-startup> </servlet> <servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>/faces/*</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>*.faces</url-pattern> </servlet-mapping> <servlet-mapping> <servlet-name>Faces Servlet</servlet-name> <url-pattern>*.jsf</url-pattern> </servlet-mapping>
faces-config.xml
<application> <view-handler>org.jboss.portletbridge.application.FaceletPortletViewHandler</view-handler> <state-manager>org.jboss.portletbridge.application.PortletStateManager</state-manager> </application> <managed-bean> <managed-bean-name>user</managed-bean-name> <managed-bean-class>demo.User</managed-bean-class> <managed-bean-scope>request</managed-bean-scope> </managed-bean>
Some ideas about the problem??
Thanks and regards