HDFS-12045. Add log when Diskbalancer volume is transient storage type. Contributed by steven-wugang.

This commit is contained in:
Anu Engineer 2017-06-27 00:39:47 -07:00
parent 2b87faf166
commit 8641a2c08b
1 changed files with 8 additions and 4 deletions

View File

@ -1011,15 +1011,19 @@ public void copyBlocks(VolumePair pair, DiskBalancerWorkItem item) {
return;
}
if (source.isTransientStorage() || dest.isTransientStorage()) {
final String errMsg = "Disk Balancer - Unable to support " +
"transient storage type.";
LOG.error(errMsg);
item.setErrMsg(errMsg);
return;
}
List<FsVolumeSpi.BlockIterator> poolIters = new LinkedList<>();
startTime = Time.now();
item.setStartTime(startTime);
secondsElapsed = 0;
if (source.isTransientStorage() || dest.isTransientStorage()) {
return;
}
try {
openPoolIters(source, poolIters);
if (poolIters.size() == 0) {