hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From inigo...@apache.org
Subject [4/5] hadoop git commit: HDFS-13714. Fix TestNameNodePrunesMissingStorages test failures on Windows. Contributed by Lukas Majercak.
Date Mon, 02 Jul 2018 23:39:31 GMT
HDFS-13714. Fix TestNameNodePrunesMissingStorages test failures on Windows. Contributed by
Lukas Majercak.

(cherry picked from commit 7296b644f7c44400f03995668573a4cfd2ee552c)


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

Branch: refs/heads/branch-2
Commit: 3e177a1d62a1b5832e99684f0ba6cc29e204b6b8
Parents: f951d92
Author: Inigo Goiri <inigoiri@apache.org>
Authored: Mon Jul 2 16:36:25 2018 -0700
Committer: Inigo Goiri <inigoiri@apache.org>
Committed: Mon Jul 2 16:38:13 2018 -0700

----------------------------------------------------------------------
 .../blockmanagement/TestNameNodePrunesMissingStorages.java      | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/3e177a1d/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestNameNodePrunesMissingStorages.java
----------------------------------------------------------------------
diff --git a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestNameNodePrunesMissingStorages.java
b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestNameNodePrunesMissingStorages.java
index 68a0d6d..ababdbc 100644
--- a/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestNameNodePrunesMissingStorages.java
+++ b/hadoop-hdfs-project/hadoop-hdfs/src/test/java/org/apache/hadoop/hdfs/server/blockmanagement/TestNameNodePrunesMissingStorages.java
@@ -289,8 +289,9 @@ public class TestNameNodePrunesMissingStorages {
       in = null;
       out.close();
       out = null;
-      newVersionFile.renameTo(versionFile);
-      success = true;
+      // Delete old version file
+      success = versionFile.delete();
+      success &= newVersionFile.renameTo(versionFile);
     } finally {
       if (in != null) {
         in.close();


---------------------------------------------------------------------
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