HBASE-11436 Support start Row and stop Row in HBase Export (Ward Viaene)
This commit is contained in:
parent
c591a25f3c
commit
dce2520828
|
@ -95,6 +95,13 @@ public class Export {
|
||||||
s.setTimeRange(startTime, endTime);
|
s.setTimeRange(startTime, endTime);
|
||||||
// Set cache blocks
|
// Set cache blocks
|
||||||
s.setCacheBlocks(false);
|
s.setCacheBlocks(false);
|
||||||
|
// set Start and Stop row
|
||||||
|
if (conf.get(TableInputFormat.SCAN_ROW_START) != null) {
|
||||||
|
s.setStartRow(Bytes.toBytes(conf.get(TableInputFormat.SCAN_ROW_START)));
|
||||||
|
}
|
||||||
|
if (conf.get(TableInputFormat.SCAN_ROW_STOP) != null) {
|
||||||
|
s.setStopRow(Bytes.toBytes(conf.get(TableInputFormat.SCAN_ROW_STOP)));
|
||||||
|
}
|
||||||
// Set Scan Column Family
|
// Set Scan Column Family
|
||||||
boolean raw = Boolean.parseBoolean(conf.get(RAW_SCAN));
|
boolean raw = Boolean.parseBoolean(conf.get(RAW_SCAN));
|
||||||
if (raw) {
|
if (raw) {
|
||||||
|
@ -155,6 +162,8 @@ public class Export {
|
||||||
System.err.println(" to control/limit what is exported..");
|
System.err.println(" to control/limit what is exported..");
|
||||||
System.err.println(" -D " + TableInputFormat.SCAN_COLUMN_FAMILY + "=<familyName>");
|
System.err.println(" -D " + TableInputFormat.SCAN_COLUMN_FAMILY + "=<familyName>");
|
||||||
System.err.println(" -D " + RAW_SCAN + "=true");
|
System.err.println(" -D " + RAW_SCAN + "=true");
|
||||||
|
System.err.println(" -D " + TableInputFormat.SCAN_ROW_START + "=<ROWSTART>");
|
||||||
|
System.err.println(" -D " + TableInputFormat.SCAN_ROW_STOP + "=<ROWSTOP>");
|
||||||
System.err.println("For performance consider the following properties:\n"
|
System.err.println("For performance consider the following properties:\n"
|
||||||
+ " -Dhbase.client.scanner.caching=100\n"
|
+ " -Dhbase.client.scanner.caching=100\n"
|
||||||
+ " -Dmapreduce.map.speculative=false\n"
|
+ " -Dmapreduce.map.speculative=false\n"
|
||||||
|
|
Loading…
Reference in New Issue