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

ASF GitHub Bot commented on YARN-7969:
--------------------------------------

github-actions[bot] closed pull request #346: YARN-7969 Fix confusing log 
messages that do not match with the method name
URL: https://github.com/apache/hadoop/pull/346




> Confusing log messages that do not match with the method name
> -------------------------------------------------------------
>
>                 Key: YARN-7969
>                 URL: https://issues.apache.org/jira/browse/YARN-7969
>             Project: Hadoop YARN
>          Issue Type: Bug
>    Affects Versions: 3.0.0
>            Reporter: Zhenhao Li
>            Priority: Minor
>              Labels: easyfix, pull-request-available
>
> Our *previous issue (YARN-7926)* found that there are some possible copy and 
> paste errors in the log messages which may cause some confusion when 
> operators are reading the log messages. After a further check, we found some 
> more similar problems. And we will propose a pull request to fix those 
> problems.
>  
> Here is a list of the problems we found:
> *1.*
> _org.apache.hadoop.yarn.server.MockResourceManagerFacade._*_forceKillApplication_*_,_
> _and_
> _org.apache.hadoop.yarn.server.router.webapp.MockDefaultRequestInterceptorREST._*_updateAppState_*
>  
> The log messages in *both methods* are:
> _LOG.info("_*_Force killing application:_* _" + appId);_
> _and they also throw an exception:_
> _throw new ApplicationNotFoundException( "_*_Trying to kill an absent 
> application:_* _" + appId);_
> _However after checking the code we found that 
> MockDefaultRequestInterceptorREST._*_updateAppState()_* has no relation to 
> killing an application; it just updates the status of an application. So 
> maybe the log message of it should be changed.
>  
> *2.* 
> _org.apache.hadoop.yarn.server.timeline.security.TimelineV1DelegationTokenSecretManagerService._*_removeStoredToken_*_,_
> _org.apache.hadoop.yarn.server.timeline.security.TimelineV1DelegationTokenSecretManagerService._*_storeNewToken_*
>  
> The log messages in *both methods* are:
> _LOG.debug("Storing token " + tokenId.getSequenceNumber());_
>  
> Since one method is storing token and one method is removing token, we 
> believe that the log messages are incorrectly copied and should be changed. 
> Maybe just simply change the log in *removeStoredToken()* to *“Removing 
> token”*
>  
> *3.* 
> _org.apache.hadoop.yarn.server.router.webapp.FederationInterceptorREST._*_getClusterMetricsInfo_*_,_
> _org.apache.hadoop.yarn.server.router.webapp.FederationInterceptorREST._*_getNodes_*
>  
> The log messages in *both methods* are:
> _LOG.warn("Failed to get nodes report ", e);_
>  
> However  the function of the first method is getting cluster metrics info, so 
> maybe the log message of it should changed to *“Failed to get Cluster 
> Metrics”*



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to