apurtell commented on code in PR #2657:
URL: https://github.com/apache/phoenix/pull/2657#discussion_r4472417271


##########
phoenix-core-client/src/main/java/org/apache/phoenix/util/ByteUtil.java:
##########
@@ -535,7 +537,11 @@ public static byte[] 
getLargestPossibleRowKeyInRange(byte[] startKey, byte[] end
           Bytes.toStringBinary(startKey), Bytes.toStringBinary(endKey));
         return null;
       }
-      if (Bytes.compareTo(startKey, rowKey) >= 0 || Bytes.compareTo(rowKey, 
endKey) >= 0) {
+      // An empty endKey is not an upper bound, so only a non-empty endKey 
limits the rowkey.
+      boolean hasUpperBound = endKey.length > 0;

Review Comment:
   Syntactic sugar but I accept it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to