YARN-2042. String shouldn't be compared using == in QueuePlacementRule#NestedUserQueue#getQueueForApp (Chen He via Sandy Ryza)

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1594482 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Sanford Ryza 2014-05-14 06:55:04 +00:00
parent 84dfae2f8a
commit 561c014e77
2 changed files with 4 additions and 1 deletions

View File

@ -117,6 +117,9 @@ Release 2.5.0 - UNRELEASED
YARN-2016. Fix a bug in GetApplicationsRequestPBImpl to add the missed fields
to proto. (Junping Du via jianhe)
YARN-2042. String shouldn't be compared using == in
QueuePlacementRule#NestedUserQueue#getQueueForApp (Chen He via Sandy Ryza)
Release 2.4.1 - UNRELEASED
INCOMPATIBLE CHANGES

View File

@ -227,7 +227,7 @@ public abstract class QueuePlacementRule {
String queueName = nestedRule.assignAppToQueue(requestedQueue, user,
groups, configuredQueues);
if (queueName != null && queueName != "") {
if (queueName != null && queueName.length() != 0) {
if (!queueName.startsWith("root.")) {
queueName = "root." + queueName;
}