ICEfaces
  1. ICEfaces
  2. ICE-6599

ICEfaces (Spring Web Flow) Flow Execution support

    Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.0.1
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      Icefaces 2.x, Spring 3.x, Spring Security 3.x, Spring Webflow 2.2.1
    • Affects:
      Documentation (User Guide, Ref. Guide, etc.), Compatibility/Configuration

      Description

      I have a complete working demo of spring webflow checked in under my username in the ICEsoft SVN repository. The working demo requires the following update to the class SeamUtilities found in the icefaces-compat/src/main/java/com/icesoft/util/SeamUtilities

      The code below should handle the conditional case where (2 == springLoaded) (Line 537):

               try {
                      String flowExecutionKeyFinderClassName = "com.icesoft.spring.webflow.FlowExecutionKeyFinder";
                      log.fine("Creating instance of: " + flowExecutionKeyFinderClassName);
                      Class flowExecutionKeyFinderClass = Class.forName("com.icesoft.spring.webflow.FlowExecutionKeyFinder");
                      Object flowExecutionKeyFinderInstance = flowExecutionKeyFinderClass.newInstance();
                      //see
                      if(null != flowExecutionKeyFinderInstance) {
                          value = flowExecutionKeyFinderInstance.toString();
                      }
                      if (null != value) {
                          //Spring Web Flow 2.x confirmed
                          flowIdParameterName = "org.springframework.webflow.FlowExecutionKey";
                      }
                  } catch (Exception e) {
                      log.log(Level.WARNING,"Unable to load spring flow execution key finder");
                  }

      An integration class should be defined by application integrators as follows (will describe this in the Wiki/Tutorial):

      package com.icesoft.spring.webflow;

      import org.springframework.webflow.execution.RequestContextHolder;

      import java.util.logging.Logger;

      /**
       * @author ICEsoft Technologies, Inc.
       *
       * Purpose of this class is to provide access to the Spring Webflow RequestContextHolder
       * while not introducing Spring Webflow as a build or runtime dependency unless its actually being
       * used.
       *
       */
      public class FlowExecutionKeyFinder {

          private static Logger log = Logger.getLogger("com.icesoft.spring.webflow");

          public FlowExecutionKeyFinder() {
              log.fine("Constructed FlowExecutionKeyFinder - must be a Spring Webflow 2+ environment.");
          }

          public String toString() {
              String key = RequestContextHolder.getRequestContext().getFlowExecutionContext().getKey().toString();
              log.fine("Returning webflow key: "+ key);
              return key;
          }
      }

        Activity

          People

          • Assignee:
            Ben Simpson
            Reporter:
            Ben Simpson
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: