MAPREDUCE-5971. Move the default options for distcp -p to DistCpOptionSwitch. Contributed by Charles Lamb.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1611217 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
43a12f3c01
commit
e8a1ff7efe
@ -153,6 +153,9 @@ Release 2.6.0 - UNRELEASED
|
||||
|
||||
IMPROVEMENTS
|
||||
|
||||
MAPREDUCE-5971. Move the default options for distcp -p to
|
||||
DistCpOptionSwitch. (clamb via wang)
|
||||
|
||||
OPTIMIZATIONS
|
||||
|
||||
BUG FIXES
|
||||
|
@ -162,6 +162,7 @@ public enum DistCpOptionSwitch {
|
||||
BANDWIDTH(DistCpConstants.CONF_LABEL_BANDWIDTH_MB,
|
||||
new Option("bandwidth", true, "Specify bandwidth per map in MB"));
|
||||
|
||||
static final String PRESERVE_STATUS_DEFAULT = "-prbugpc";
|
||||
private final String confLabel;
|
||||
private final Option option;
|
||||
|
||||
|
@ -50,7 +50,7 @@ private static class CustomParser extends GnuParser {
|
||||
protected String[] flatten(Options options, String[] arguments, boolean stopAtNonOption) {
|
||||
for (int index = 0; index < arguments.length; index++) {
|
||||
if (arguments[index].equals("-" + DistCpOptionSwitch.PRESERVE_STATUS.getSwitch())) {
|
||||
arguments[index] = "-prbugpc";
|
||||
arguments[index] = DistCpOptionSwitch.PRESERVE_STATUS_DEFAULT;
|
||||
}
|
||||
}
|
||||
return super.flatten(options, arguments, stopAtNonOption);
|
||||
|
Loading…
Reference in New Issue
Block a user