HBASE-2753 Remove sorted() methods from Result now that Gets are Scans
git-svn-id: https://svn.apache.org/repos/asf/hbase/trunk@1027293 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e3c5654626
commit
a702d2253c
|
@ -612,7 +612,7 @@ Release 0.21.0 - Unreleased
|
|||
HBASE-3139 Server shutdown processor stuck because meta not online
|
||||
HBASE-3136 Stale reads from ZK can break the atomic CAS operations we
|
||||
have in ZKAssign
|
||||
|
||||
HBASE-2753 Remove sorted() methods from Result now that Gets are Scans
|
||||
|
||||
IMPROVEMENTS
|
||||
HBASE-1760 Cleanup TODOs in HTable
|
||||
|
|
|
@ -159,7 +159,7 @@ public class Result implements Writable {
|
|||
if(this.kvs == null) {
|
||||
readFields();
|
||||
}
|
||||
return isEmpty()? null: Arrays.asList(sorted());
|
||||
return isEmpty()? null: Arrays.asList(raw());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -172,18 +172,9 @@ public class Result implements Writable {
|
|||
* @deprecated
|
||||
*/
|
||||
public KeyValue[] sorted() {
|
||||
raw(); // side effect of loading this.kvs
|
||||
if (!sorted) {
|
||||
assert Ordering.from(KeyValue.COMPARATOR).isOrdered(Arrays.asList(kvs));
|
||||
|
||||
Arrays.sort(kvs, KeyValue.COMPARATOR);
|
||||
sorted = true;
|
||||
return raw(); // side effect of loading this.kvs
|
||||
}
|
||||
|
||||
return raw();
|
||||
}
|
||||
private boolean sorted = false;
|
||||
|
||||
/**
|
||||
* Return the KeyValues for the specific column. The KeyValues are sorted in
|
||||
* the {@link KeyValue#COMPARATOR} order. That implies the first entry in
|
||||
|
|
Loading…
Reference in New Issue