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

zhihai xu commented on YARN-3857:
---------------------------------

thanks for the updated patch [~mujunchao]!
The patch looks most good to me, some nits:
# Add {{@VisibleForTesting}} before function {{hasMasterKey}} to mark this 
function used for test only. So you can remove the comment {{// Only for test}}
# It looks like the code in {{testNoSecureNoRegistClientToken}} are similar as 
{{testRegistClientTokenInSecure}}. Can we merge 
{{testNoSecureNoRegistClientToken}} with {{testRegistClientTokenInSecure}} to 
one test? We can rename the test as {{testApplicationAttemptMasterKey}}. You 
can check {{isMasterKeyExisted}} based on {{isSecurityEnabled}}. You can change 
your comments {{can not get ClientToken}}/{{can get ClientToken}} to {{can not 
get MasterKey}}/{{can get MasterKey}}

> Memory leak in ResourceManager with SIMPLE mode
> -----------------------------------------------
>
>                 Key: YARN-3857
>                 URL: https://issues.apache.org/jira/browse/YARN-3857
>             Project: Hadoop YARN
>          Issue Type: Bug
>          Components: resourcemanager
>    Affects Versions: 2.7.0
>            Reporter: mujunchao
>            Assignee: mujunchao
>            Priority: Critical
>         Attachments: YARN-3857-1.patch, 
> hadoop-yarn-server-resourcemanager.patch
>
>
>  We register the ClientTokenMasterKey to avoid client may hold an invalid 
> ClientToken after RM restarts. In SIMPLE mode, we register 
> Pair<ApplicationAttemptId, null> ,  But we never remove it from HashMap, as 
> unregister only runing while in Security mode, so memory leak coming. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to