struts-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mirek Hankus (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (WW-4102) ActionSupport.LOG should be private
Date Mon, 17 Jun 2013 07:16:21 GMT

    [ https://issues.apache.org/jira/browse/WW-4102?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13685038#comment-13685038
] 

Mirek Hankus commented on WW-4102:
----------------------------------

Please fix also other classes, MethodFilterInterceptor also uses protected log, and ValidationInterceptor
uses its own LOG and log from MethodFilterInterceptor, so you have code like

{code}
if (log.isDebugEnabled()) {
            log.debug("Validating "
                    + invocation.getProxy().getNamespace() + "/" + invocation.getProxy().getActionName()
+ " with method "+ method +".");
}
{code}

and
{code}
 if (LOG.isDebugEnabled()) {
                LOG.debug("Invoking validate() on action "+validateable);
 }
{code}


so, good luck with  logger configuration witch this class. 




 
                
> ActionSupport.LOG should be private
> -----------------------------------
>
>                 Key: WW-4102
>                 URL: https://issues.apache.org/jira/browse/WW-4102
>             Project: Struts 2
>          Issue Type: Improvement
>          Components: Core Actions
>    Affects Versions: 2.3.14.3
>            Reporter: Marcin Kamionowski
>             Fix For: 2.5
>
>
> ActionSupport is base class for actions. Actions cannot (or at least shouldn't) use ActionSupport.LOG
because localisation source of messages is much harder in this situation. When ActionSuport.LOG
is protected, some programmers might accidentally use this instance (LOG is popular name for
loggers).

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message