HDFS-14241. Provide feedback on successful renameSnapshot and deleteSnapshot. Contributed by Siyao Meng.

Signed-off-by: Wei-Chiu Chuang <weichiu@apache.org>
This commit is contained in:
Siyao Meng 2019-02-13 19:48:02 -08:00 committed by Wei-Chiu Chuang
parent fa067aa157
commit fd026863b1

View File

@ -125,6 +125,7 @@ protected void processArguments(LinkedList<PathData> items)
assert (items.size() == 1);
PathData sroot = items.getFirst();
sroot.fs.deleteSnapshot(sroot.path, snapshotName);
out.println("Deleted snapshot " + snapshotName + " under " + sroot.path);
}
}
@ -166,6 +167,8 @@ protected void processArguments(LinkedList<PathData> items)
Preconditions.checkArgument(items.size() == 1);
PathData sroot = items.getFirst();
sroot.fs.renameSnapshot(sroot.path, oldName, newName);
out.println("Renamed snapshot " + oldName + " to " + newName +
" under " + sroot.path);
}
}