ReturnUrlAware/ReturnableRedirectResult should be removed

XMLWordPrintable

    • Type: Suggestion
    • Resolution: Won't Fix
    • None
    • Component/s: Infrastructure
    • None

      There is a mechanism, provided by the ReturnUrlAware interface and the ReturnableRedirectResult class, used to "short-circuit" WebWork action processing, and allow Freemarker templates to specify the URL to be redirected to as the result of the following action. The actual result of the action, and any action mappings defined, are completely ignored.

      This goes against the design principles behind WebWork, makes debugging the non-obvious behaviour that results confusing (costing time and requiring effort), and limits application flexibility and the potential for re-use (again costing time and requiring effort).

      See BAM-2404 for an example of a the kind of problem this causes.

      A more appropriate solution would be to pass in the desired WebWork result (not the URL) as a parameter, and have the Action return this result once the Action has completed processing. The action mapping would then map each result to the correct URL. This way, the Action still has the final say over what the result is.

              Assignee:
              Unassigned
              Reporter:
              Adrian Hempel [Atlassian]
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Created:
                Updated:
                Resolved: