hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From na...@apache.org
Subject hadoop git commit: HDDS-661. When a volume fails in datanode, VersionEndpointTask#call ends up in dead lock. Contributed by Hanisha Koneru.
Date Wed, 17 Oct 2018 13:30:34 GMT
Repository: hadoop
Updated Branches:
  refs/heads/ozone-0.3 b2ab592e0 -> 51a79cc71


HDDS-661. When a volume fails in datanode, VersionEndpointTask#call ends up in dead lock.
Contributed by Hanisha Koneru.

(cherry picked from commit d54f5598f4ccd1031e8295a215a3183f3647031a)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/51a79cc7
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/51a79cc7
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/51a79cc7

Branch: refs/heads/ozone-0.3
Commit: 51a79cc71d6c35b9ec4d22de61587c8beda969d9
Parents: b2ab592
Author: Nandakumar <nanda@apache.org>
Authored: Wed Oct 17 18:44:05 2018 +0530
Committer: Nandakumar <nanda@apache.org>
Committed: Wed Oct 17 19:00:19 2018 +0530

----------------------------------------------------------------------
 .../container/common/states/endpoint/VersionEndpointTask.java  | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/51a79cc7/hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/states/endpoint/VersionEndpointTask.java
----------------------------------------------------------------------
diff --git a/hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/states/endpoint/VersionEndpointTask.java
b/hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/states/endpoint/VersionEndpointTask.java
index 2d04677..79fa174 100644
--- a/hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/states/endpoint/VersionEndpointTask.java
+++ b/hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/common/states/endpoint/VersionEndpointTask.java
@@ -75,7 +75,7 @@ public class VersionEndpointTask implements
 
       // Check volumes
       VolumeSet volumeSet = ozoneContainer.getVolumeSet();
-      volumeSet.readLock();
+      volumeSet.writeLock();
       try {
         Map<String, HddsVolume> volumeMap = volumeSet.getVolumeMap();
 
@@ -94,12 +94,12 @@ public class VersionEndpointTask implements
           }
         }
         if (volumeSet.getVolumesList().size() == 0) {
-          // All volumes are inconsistent state
+          // All volumes are in inconsistent state
           throw new DiskOutOfSpaceException("All configured Volumes are in " +
               "Inconsistent State");
         }
       } finally {
-        volumeSet.readUnlock();
+        volumeSet.writeUnlock();
       }
 
       ozoneContainer.getDispatcher().setScmId(scmId);


---------------------------------------------------------------------
To unsubscribe, e-mail: common-commits-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-commits-help@hadoop.apache.org


Mime
View raw message