Uploaded image for project: 'Struts 1'
  1. Struts 1
  2. STR-3168

Add dispatching support to Controller and Action configuration

    XMLWordPrintableJSON

    Details

    • Type: New Feature
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.4.0
    • Component/s: Core, Extras
    • Labels:
      None

      Description

      Based on the discussions of STR-2940 and the general trend of the industry, the correct place for a framework to support dispatching is not in the Action, but as part of the Controller. The Action can do anything it wants once it has the request, but the support belongs to the framework.

      See also http://www.theserverside.com/patterns/thread.tss?thread_id=21854

      The following changes are proposed:

      • Introduce a Dispatcher interface that accepts the current ActionContext and returns an Object
      • Add @dispatch to the <action> element
      • Either modify ExecuteAction or create subclass that executes the action by delegating to the Dispatcher interface
      • Object is then marshalled into an ActionForward through a conversion process
      • Retrofit ActionDispatcher with the interface

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                pbenedict Paul Benedict
                Reporter:
                pbenedict Paul Benedict
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: