This is an automated email from the ASF dual-hosted git repository.
cnauroth pushed a commit to branch branch-3.3
in repository https://gitbox.apache.org/repos/asf/hadoop.git
The following commit(s) were added to refs/heads/branch-3.3 by this push:
new b4b6a008e66 YARN-11839. [RM HA] - In corner case, RM stay in ACTIVE
with RMStateStore in FENCED state
b4b6a008e66 is described below
commit b4b6a008e6695000f3632424c70de1808c5282ea
Author: Vinayakumar B <[email protected]>
AuthorDate: Fri Oct 31 17:29:57 2025 +0000
YARN-11839. [RM HA] - In corner case, RM stay in ACTIVE with RMStateStore
in FENCED state
Closes #7999
Signed-off-by: Shilun Fan <[email protected]>
Signed-off-by: Chris Nauroth <[email protected]>
Signed-off-by: Ayush Saxena <[email protected]>
---
.../apache/hadoop/yarn/server/resourcemanager/ResourceManager.java | 6 +++++-
1 file changed, 5 insertions(+), 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 e3b7fa114ed..e80e4ac19db 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
@@ -1122,7 +1122,11 @@ protected void serviceStop() throws Exception {
* Transition to standby state in a new thread. The transition operation is
* asynchronous to avoid deadlock caused by cyclic dependency.
*/
- private void handleTransitionToStandByInNewThread() {
+ private synchronized void handleTransitionToStandByInNewThread() {
+ if (rmContext.getHAServiceState() ==
HAServiceProtocol.HAServiceState.STANDBY) {
+ LOG.info("RM already in standby state");
+ return;
+ }
Thread standByTransitionThread =
new Thread(activeServices.standByTransitionRunnable);
standByTransitionThread.setName("StandByTransitionThread");
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]