HDFS-10496. DiskBalancer: ExecuteCommand checks planFile in a wrong way. Contributed by Lei (Eddy) Xu.
This commit is contained in:
parent
64ccb232cc
commit
d2ff793ae4
|
@ -61,7 +61,7 @@ public class ExecuteCommand extends Command {
|
||||||
verifyCommandOptions(DiskBalancer.EXECUTE, cmd);
|
verifyCommandOptions(DiskBalancer.EXECUTE, cmd);
|
||||||
|
|
||||||
String planFile = cmd.getOptionValue(DiskBalancer.EXECUTE);
|
String planFile = cmd.getOptionValue(DiskBalancer.EXECUTE);
|
||||||
Preconditions.checkArgument(planFile == null || planFile.isEmpty(),
|
Preconditions.checkArgument(planFile != null && !planFile.isEmpty(),
|
||||||
"Invalid plan file specified.");
|
"Invalid plan file specified.");
|
||||||
|
|
||||||
String planData = null;
|
String planData = null;
|
||||||
|
|
Loading…
Reference in New Issue