From d4bba011cc5bf54a7d019ad34f872138609bf300 Mon Sep 17 00:00:00 2001 From: Daniel Templeton Date: Tue, 21 Mar 2017 14:15:40 -0700 Subject: [PATCH] YARN-6284. hasAlreadyRun should be final in ResourceManager.StandByTransitionRunnable (Contributed by Laura Adams via Daniel Templeton) (cherry picked from commit 0a05c5c5989edeba2cffe16e80350245778cefce) --- .../hadoop/yarn/server/resourcemanager/ResourceManager.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/ResourceManager.java b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/ResourceManager.java index 7c38a9bf289..827e6a3dfe6 100644 --- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/ResourceManager.java +++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-server/hadoop-yarn-server-resourcemanager/src/main/java/org/apache/hadoop/yarn/server/resourcemanager/ResourceManager.java @@ -798,7 +798,7 @@ public class ResourceManager extends CompositeService implements Recoverable { private class StandByTransitionRunnable implements Runnable { // The atomic variable to make sure multiple threads with the same runnable // run only once. - private AtomicBoolean hasAlreadyRun = new AtomicBoolean(false); + private final AtomicBoolean hasAlreadyRun = new AtomicBoolean(false); @Override public void run() {