diff --git a/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/RMNodeWrapper.java b/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/RMNodeWrapper.java index a082e20a1ee..2e9cccb2778 100644 --- a/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/RMNodeWrapper.java +++ b/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/RMNodeWrapper.java @@ -172,10 +172,11 @@ public class RMNodeWrapper implements RMNode { // TODO Auto-generated method stub } + @SuppressWarnings("unchecked") @Override public List pullNewlyIncreasedContainers() { // TODO Auto-generated method stub - return null; + return Collections.EMPTY_LIST; } @Override diff --git a/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/ResourceSchedulerWrapper.java b/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/ResourceSchedulerWrapper.java index fce220bf79e..106525d915c 100644 --- a/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/ResourceSchedulerWrapper.java +++ b/hadoop-tools/hadoop-sls/src/main/java/org/apache/hadoop/yarn/sls/scheduler/ResourceSchedulerWrapper.java @@ -819,6 +819,14 @@ final public class ResourceSchedulerWrapper ((AbstractYarnScheduler) scheduler).init(conf); super.serviceInit(conf); + initScheduler(conf); + } + + private synchronized void initScheduler(Configuration configuration) throws + IOException { + this.applications = + new ConcurrentHashMap>(); } @SuppressWarnings("unchecked") diff --git a/hadoop-yarn-project/CHANGES.txt b/hadoop-yarn-project/CHANGES.txt index 4c8eecb7793..b551aae82ac 100644 --- a/hadoop-yarn-project/CHANGES.txt +++ b/hadoop-yarn-project/CHANGES.txt @@ -1260,6 +1260,8 @@ Release 2.7.3 - UNRELEASED YARN-4315. NaN in Queue percentage for cluster apps page. (Bibin A Chundatt via wangda) + YARN-4510. Fix SLS startup failure caused by NPE. (Bibin A Chundatt via wangda) + Release 2.7.2 - UNRELEASED INCOMPATIBLE CHANGES