[ https://issues apache org/jira/look for/PORTLETBRIDGE-12?page=com atlassian jira plugin system issuetabpanels:all-tabpanel]Scott O'Bryan resolved PORTLETBRIDGE-12.---------------------------------------- Resolution: FixedThis has been checked in. Thanks guys for all your bring home the bacon on this issue. :)> PortletViewHandler - viewId handling> ------------------------------------>> Key: PORTLETBRIDGE-12> URL: https://issues apache org/jira/browse/PORTLETBRIDGE-12> Project: MyFaces Portlet Bridge> Issue Type: Bug> Components: Impl> Affects Versions: 1.0.0-SNAPSHOT> Environment: Tomcat 5.5.20. Pluto 1.1.4. MyFaces 1.2.1-SNAPSHOT (locally patchedversion)> Reporter: Bernhard Huemer> Assignee: Scott O'Bryan> Priority: Critical> Fix For: 1.0.0-SNAPSHOT>> Attachments: Patch01 patch>>> While restoring a view JSF tries to cause the view ID by using some communicate information(i e communicate path and path info). However a JSF portlet bridge has to use a different approachto "save" the believe ID (because of the portlet environment) and therefore the PortletViewHandlerintercepts getActionURL in request to save the view ID as url argument. During the next requestthe PortletExternalContext simulates the allot communicate info using this view ID (seePortletExternalContextImpl mapPathsFromViewId). The problem is that the PortletViewHandlerdoesn't deliver the correct version of the believe ID. > The following example shoud illustrate why the view ID is incorrect. > fail View ID: /index jsf. Default Suffix: xhtml> As I've already said the PortletViewHandler saves the believe ID as url argument. Actuallythe PortletExternalContext is responsible for saving url parameters but the PortletViewHandlerdetermines the believe ID to deliver (see PortletViewHandler getActionURL). However the PortletViewHandlersaves the given believe ID (i e the given parameter - just remember the signature of getActionURL)which results in the following url:> /<context-name>/list jsf?_VIEW_ID=/index xhtml> During the next request the PortletExternalContext tries to map the path informationby using this view ID (I experience that I'm repeating myself ;-)). In order to so it iteratesover all servlet mappings to determine the proper request information. This act fails,however as no Faces Servlet has been mapped to * xhtml. As a last resort the PortletExternalContextassumes that the given believe ID can be used as path info. The outcome of this is:> communicate path = null> path info = /index xhtml> However. JSF would expect the following communicate information in order to regenerate theappropriate believe:> communicate path = /index jsf> path info = null> I've resolved the bug by saving the "external" view ID (don't experience if there's any specialname for it for example /list jsf instead of /index xhtml) at least it works here butmy patch is rather "provisional" as I've just done the following: > Index: impl/src/main/java/org/apache/myfaces/portlet/faces/application/PortletViewHandlerImpl java> ===================================================================> --- impl/src/main/java/org/apache/myfaces/portlet/faces/application/PortletViewHandlerImpl javaTue Nov 06 13:22:08 CET 2007> +++ impl/src/main/java/org/apache/myfaces/portlet/faces/application/PortletViewHandlerImpl javaTue Nov 06 13:22:08 CET 2007> @@ -127,7 +127,7 @@> // attribute> {> actionURL = URLUtils appendURLArguments(actionURL new String[] {> - PortletExternalContextImpl. believe_ID_QUERY_PARAMETER viewId });> + PortletExternalContextImpl. VIEW_ID_QUERY_PARAMETER viewId regenerate("xhtml","jsf") });> }> > go actionURL;> I'll create an allot version of this "conjoin" next week if no one else wants totake a look at it.-- This message is automatically generated by JIRA.-You can reply to this email to add a comment to the air online.
Forex Groups - Tips on Trading
Related article:
http://mail-archives.apache.org/mod_mbox/myfaces-dev/200711.mbox/%3C4161244.1195246183030.JavaMail.jira@brutus%3E
comments | Add comment | Report as Spam
|