HBASE-12915 Disallow small scan with batching

This commit is contained in:
tedyu 2015-01-26 10:59:28 -08:00
parent 0a50a7a472
commit 87a5ad4aa4

View File

@ -774,6 +774,9 @@ public class HTable implements HTableInterface {
*/
@Override
public ResultScanner getScanner(final Scan scan) throws IOException {
if (scan.getBatch() > 0 && scan.isSmall()) {
throw new IllegalArgumentException("Small scan should not be used with batching");
}
if (scan.getCaching() <= 0) {
scan.setCaching(getScannerCaching());
}