Uploaded image for project: 'Struts 2'
  1. Struts 2
  2. WW-4480

DefaultActionInvocation.invokeAction calls unknownHandlerManager.handleUnknownMethod for any OgnlException

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Duplicate
    • 2.3.20
    • 2.3.24
    • Core Actions
    • None

    Description

      In our environment we are allowing method invocation exceptions in ognl to propagate. (This is so we can fail fast if someone tries to write code that invokes a static method)

      However, DefaultActionInvocation.invokeAction() does not distinguish between an OgnlException because of the method missing, and an OgnlException because the method threw an exception during execution. It calls handleUnknownMethod in both cases.

      Instead of just checking for OgnlException it should only consider the method unknown if it is an ognl MethodFailedException and the cause is a java.lang.NoSuchMethodException

      Attachments

        Issue Links

          Activity

            People

              Unassigned Unassigned
              perfnorm Jasper Rosenberg
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: