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

Develop optimization that will disable BridgeRequestScope during Ajax requests



      In the TCK, TestPage073 (scopeAfterRedisplayResourcePPRTest) tests the following use case:

      1. Initial get of portal page invokes RENDER_PHASE of the portlet lifecycle

      • BridgeRequestScope instance created and destroyed

      2. Click on button which invokes RESOURCE_PHASE of the portlet lifecycle

      • BridgeRequestScope instance created
      • BridgeRequestScope instance placed in managed cache/map
      • Test saves a request attribute
      • Request attribute is preserved in the BridgeRequestScope
      • BridgeRequestScope "id" saved as a PortletSession attribute

      3. Click on link which invokes RENDER_PHASE of the portlet lifecycle

      • BridgeRequestScope "id" retrieved from PortletSession attribute
      • PortletSession attribute removed
      • BridgeRequestScope instance retrieved form managed cache/map
      • Request attribute is restored into the request attribute map from the BridgeRequestScope
      • Test validates that request attribute is present

      However, this seems to be a very rare use-case for JSF2 portlets. So this issue involves developing an optimization feature that disables the BridgeRequestScope during Ajax requests by default.

      Developers can specify the following in the WEB-INF/portlet.xml descriptor in order to get the standard behavior required by the Spec:

        <!-- false by default in liferay-faces-bridge; setting it to true gets back the standard behavior -->




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


              • Created: