Details
-
Bug
-
Status: Resolved
-
Minor
-
Resolution: Fixed
-
2.1.0
-
None
-
None
-
Reviewed
Description
During parsing of options, there are some validations. One such is checking whether autoFlush = false AND multiPut > 0. This validation code mandates an order that autoFlush=true should be specified before adding multiPut = x in PE command.
final String multiPut = "--multiPut="; if (cmd.startsWith(multiPut)) { opts.multiPut = Integer.parseInt(cmd.substring(multiPut.length())); if (!opts.autoFlush && opts.multiPut > 0) { throw new IllegalArgumentException("autoFlush must be true when multiPut is more than 0"); } continue; }
'autoFlush ' default value is false. If multiPut is specified prior to autoFlush in the PE command, we will end up throwing IllegalArgumentException.
Checking other validations, seems not having such issue. Still better to move all the validations together into a private method and call that once the parse is over.
Attachments
Issue Links
- relates to
-
HBASE-20601 Add multiPut support and other miscellaneous to PE
- Resolved
- links to