YARN-6248. user is not removed from UsersManager’s when app is killed with pending container requests. Contributed by Eric Payne.

This commit is contained in:
Sunil G 2017-03-04 13:46:35 +05:30
parent c61bc2d843
commit c1386a90d7
1 changed files with 3 additions and 1 deletions

View File

@ -872,7 +872,9 @@ public class UsersManager implements AbstractUsersManager {
this.writeLock.lock();
// For UT case: We might need to add the user to users list.
User user = getUserAndAddIfAbsent(userName);
User user = getUser(userName);
if (user == null) return;
ResourceUsage resourceUsage = user.getResourceUsage();
// If User is moved to non-active list, moved resource usage from
// non-active to active list.