Uploaded image for project: 'PUBLIC - Liferay Faces'
  1. PUBLIC - Liferay Faces
  2. FACES-1309

BridgePhaseRenderImpl not reporting queued exceptions

    Details

      Description

      The bridge is not reporting exceptions that might be queued-up in the FacesContext.

      I realized this when I developed a JSF portlet that had a typo in the javax.portlet.faces.defaultViewId.view element in the WEB-INF/portlet.xml descriptor.

      For example, portlet.xml had something like this:

      <portlet>
      	<portlet-name>my_portlet</portlet-name>
      	<portlet-class&gt;javax.portlet.faces.GenericFacesPortlet</portlet-class&gt;
      	<init-param>
      		<name>javax.portlet.faces.defaultViewId.view</name>
      		<value>/views/view.xhtml</value>
      	</init-param>
      	...
      </portlet>
      

      But the file view.xhtml didn't physically exist at that path... This caused the Mojarra com.sun.faces.facelets.impl.DefaultFaceletFactory.resolveURL(URL, String) method to throw com.sun.faces.context.FacesFileNotFoundException, which ultimately gets queued-up in the FacesContext.

      The solution to this problem is to have the BridgePhaseRenderImpl class iterate over the handled/unhandled exceptions in the FacesContext and throw a BridgeException if an exception is found while iterating.

        Attachments

          Activity

            People

            • Assignee:
              neil.griffin Neil Griffin
              Reporter:
              neil.griffin Neil Griffin
              Participants of an Issue:
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Packages

                Version Package
                liferay-faces-3.0.0-legacy-ga1
                liferay-faces-3.0.0-ga1
                liferay-faces-3.1.0-ga1