struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jose L Martinez-Avial (JIRA)" <>
Subject [jira] [Created] (WW-4274) DefaultActionInvocation shows invalid log
Date Thu, 09 Jan 2014 23:47:51 GMT
Jose L Martinez-Avial created WW-4274:

             Summary: DefaultActionInvocation  shows invalid log
                 Key: WW-4274
             Project: Struts 2
          Issue Type: Improvement
          Components: Core Actions
            Reporter: Jose L Martinez-Avial
            Priority: Trivial

The method invokeAction of com.opensymphony.xwork2.DefaultActionInvocation logs the following
line for each action it executes:

DEBUG com.opensymphony.xwork2.DefaultActionInvocation  - Executing action method = null

I was curious about why the method was null, and find the following:
    protected String invokeAction(Object action, ActionConfig actionConfig) throws Exception
        String methodName = proxy.getMethod();

        if (LOG.isDebugEnabled()) {
            LOG.debug("Executing action method = " + actionConfig.getMethodName());
but it does not use actionConfig.getMethodName() at all. It uses methodName, from proxy.getMethod().
And actionConfig.getMethodName() is null if no method was declared on the action definition
(then it uses the standard execute). I believe that the log should be modified to show methodName
instead if  actionConfig.getMethodName(). I'm sending attached a patch for this issue.

This message was sent by Atlassian JIRA

View raw message