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 e9d829ef846..47ec2d1f016 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 @@ -820,6 +820,14 @@ 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 b26a5f18918..c208c172f5c 100644 --- a/hadoop-yarn-project/CHANGES.txt +++ b/hadoop-yarn-project/CHANGES.txt @@ -1205,6 +1205,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