YARN-8185. Improve log in DirectoryCollection constructor. (Yufei Gu via Haibo Chen)

This commit is contained in:
Haibo Chen 2018-04-20 07:39:45 -07:00
parent 55e4252fc5
commit 860cc28a5a

View File

@ -181,11 +181,10 @@ public DirectoryCollection(String[] dirs,
long utilizationSpaceCutOff) {
conf = new YarnConfiguration();
try {
diskValidator = DiskValidatorFactory.getInstance(
conf.get(YarnConfiguration.DISK_VALIDATOR,
YarnConfiguration.DEFAULT_DISK_VALIDATOR));
LOG.info("Disk Validator: " + YarnConfiguration.DISK_VALIDATOR +
" is loaded.");
String diskValidatorName = conf.get(YarnConfiguration.DISK_VALIDATOR,
YarnConfiguration.DEFAULT_DISK_VALIDATOR);
diskValidator = DiskValidatorFactory.getInstance(diskValidatorName);
LOG.info("Disk Validator '" + diskValidatorName + "' is loaded.");
} catch (Exception e) {
throw new YarnRuntimeException(e);
}