Uploaded image for project: 'Commons Chain'
  1. Commons Chain
  2. CHAIN-25

[chain] Should DispatchCommand unwrap InvocationTargetException?

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.0
    • 1.1
    • None
    • None
    • Operating System: other
      Platform: Other

    • 34402

    Description

      Since Command can throw exception, would it be more correct for DispatchCommand
      to extract the source exception when the dispatch operation throws an
      InvocationTargetException?

      This comes into play, for example, when you want to use a DispatchCommand in
      Struts while using declarative exception handling. Obviously one can't do much
      to declare handling for something like InvocationTargetException, but in the
      case where I want to throw a business exception instead of routing to a view
      page, I can't do that from a DispatchCommand because the business exception is
      always wrapped in InvocationTargetException.

      If I don't get any feedback in the next few days, I'll probably make this change.

      Attachments

        Activity

          People

            Unassigned Unassigned
            germuska Joseph Lad Germuska
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: