HBASE-8063 Addendum adds HalfStoreFileReader#passesKeyRangeFilter()

git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1462235 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
Zhihong Yu 2013-03-28 17:49:11 +00:00
parent b0e1395fc6
commit 96a5c023c2
2 changed files with 8 additions and 2 deletions

View File

@ -28,6 +28,7 @@ import org.apache.hadoop.fs.FSDataInputStream;
import org.apache.hadoop.fs.FileSystem;
import org.apache.hadoop.fs.Path;
import org.apache.hadoop.hbase.KeyValue;
import org.apache.hadoop.hbase.client.Scan;
import org.apache.hadoop.hbase.io.encoding.DataBlockEncoding;
import org.apache.hadoop.hbase.io.hfile.CacheConfig;
import org.apache.hadoop.hbase.io.hfile.HFileScanner;
@ -286,6 +287,11 @@ public class HalfStoreFileReader extends StoreFile.Reader {
};
}
@Override
public boolean passesKeyRangeFilter(Scan scan) {
return true;
}
@Override
public byte[] getLastKey() {
if (top) {

View File

@ -1357,7 +1357,7 @@ public class StoreFile {
* @param scan the scan specification. Used to determine the rowkey range.
* @return true if there is overlap, false otherwise
*/
boolean passesKeyRangeFilter(Scan scan) {
public boolean passesKeyRangeFilter(Scan scan) {
if (this.getFirstKey() == null || this.getLastKey() == null) {
// the file is empty
return false;