Uploaded image for project: 'Spring Web Flow'
  1. Spring Web Flow
  2. SWF-318

FlowExecutionHolder not available during portlet render phase

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Duplicate
    • Affects Version/s: 1.0.3
    • Fix Version/s: 2.0 M2
    • Component/s: JSF
    • Labels:
      None

      Description

      I am trying to get JSF and Spring Webflow working together in a portlet.
      I ran into problems with my first page interaction. My first page has a link that initiates a flow. What I noticed is that the FlowNavigationHandler has the following code:

      ViewSelection selectedView = flowExecution.start(createInput(context), context);
      // set the starting view to render
      FlowExecutionHolderUtils.getFlowExecutionHolder(facesContext).setViewSelection(selectedView);

      In this process the FlowExecutionHolder is placed in the request.
      Later, during the render phase the FlowPhaseListener beforePhase goes through the following:

      if (FlowExecutionHolderUtils.isFlowExecutionRestored(event.getFacesContext())) {
      prepareResponse(getCurrentContext(), FlowExecutionHolderUtils.getFlowExecutionHolder(event.getFacesContext()));
      }

      At this point an attempt is made to get the FlowExecutionHolder from the request. In a portlet scenario, however, the render is a separate request and the FlowExecutionHolder is no longer in the request.
      As a result the view root does not get updated with the new view and the previous view gets redisplayed.

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jeremyg484 Jeremy Grelle
              Reporter:
              msauer Mike Sauer
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: