I don't know why it's very slow if I use prefixfilter to query. Can someone explain which is the best way to query HBase, thanks.
hbase(main):002:0> scan 'userlib',{FILTER=>org.apache.hadoop.hbase.filter.PrefixFilter.new(org.apache.hadoop.hbase.util.Bytes.toBytes('0000115831F8'))}
ROW COLUMN+CELL
0000115831F8001 column=track:aid, timestamp=1339121507633, value=aaa
1 row(s) in 41.0700 seconds
hbase(main):002:0> scan 'userlib',{STARTROW=>'0000115831F8',ENDROW=>'0000115831F9'}
ROW COLUMN+CELL
0000115831F8001 column=track:aid, timestamp=1339121507633, value=aaa
1 row(s) in 0.1100 seconds
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…