HDFS-9626. TestBlockReplacement#testBlockReplacement fails occasionally. Contributed by Xiao Chen.

Change-Id: Ia766a5bfb89f8cf8a48b473bb27c30d5818ebfc0
This commit is contained in:
Zhe Zhang 2016-01-08 13:14:36 -08:00
parent 38c4c14472
commit 0af2022e6d
2 changed files with 7 additions and 3 deletions

View File

@ -406,6 +406,9 @@ Trunk (Unreleased)
HDFS-9615. Fix variable name typo in DFSConfigKeys. (Ray Chiang via HDFS-9615. Fix variable name typo in DFSConfigKeys. (Ray Chiang via
Arpit Agarwal) Arpit Agarwal)
HDFS-9626. TestBlockReplacement#testBlockReplacement fails occasionally.
(Xiao Chen via zhz)
BREAKDOWN OF HDFS-7285 SUBTASKS AND RELATED JIRAS BREAKDOWN OF HDFS-7285 SUBTASKS AND RELATED JIRAS
HDFS-7347. Configurable erasure coding policy for individual files and HDFS-7347. Configurable erasure coding policy for individual files and

View File

@ -198,9 +198,10 @@ public void testBlockReplacement() throws Exception {
LOG.info("Testcase 4: invalid del hint " + proxies.get(0) ); LOG.info("Testcase 4: invalid del hint " + proxies.get(0) );
assertTrue(replaceBlock(b, proxies.get(0), proxies.get(1), source)); assertTrue(replaceBlock(b, proxies.get(0), proxies.get(1), source));
// after cluster has time to resolve the over-replication, // after cluster has time to resolve the over-replication,
// block locations should contain two proxies, // block locations should contain any 3 of the blocks, since after the
// and either source or newNode, but not both. // deletion the number of racks is still >=2 for sure.
checkBlocks(proxies.toArray(new DatanodeInfo[proxies.size()]), // See HDFS-9314 for details, espacially the comment on 18/Nov/15 14:09.
checkBlocks(new DatanodeInfo[]{},
fileName.toString(), fileName.toString(),
DEFAULT_BLOCK_SIZE, REPLICATION_FACTOR, client); DEFAULT_BLOCK_SIZE, REPLICATION_FACTOR, client);
} finally { } finally {