DonalEvans commented on a change in pull request #6794:
URL: https://github.com/apache/geode/pull/6794#discussion_r698869156



##########
File path: 
geode-apis-compatible-with-redis/src/main/java/org/apache/geode/redis/internal/executor/sortedset/ZUnionStoreExecutor.java
##########
@@ -52,6 +57,11 @@ public RedisResponse executeCommand(Command command, 
ExecutionHandlerContext con
       return RedisResponse.error(ERROR_SYNTAX);
     }
 
+    // Rough validation so that we can use numKeys to initialize the array 
sizes below.

Review comment:
       `numKeys` is not used to initialize the arrays, despite this comment 
implying it will be.

##########
File path: 
geode-apis-compatible-with-redis/src/main/java/org/apache/geode/redis/internal/executor/sortedset/ZUnionStoreExecutor.java
##########
@@ -36,6 +36,11 @@
 
 public class ZUnionStoreExecutor extends AbstractExecutor {
 
+  /**
+   * The position in the command array where the source set keys start.
+   */
+  private static final int SOURCE_KEY_OFFSET = 3;

Review comment:
       This constant is never used.

##########
File path: 
geode-apis-compatible-with-redis/src/main/java/org/apache/geode/redis/internal/netty/StringBytesGlossary.java
##########
@@ -198,6 +192,8 @@
   public static final byte bPLUS = SIMPLE_STRING_ID; // +
   public static final byte bMINUS = ERROR_ID; // -
 
+  public static final byte[] bZERO = stringToBytes("0");

Review comment:
       There is already a `NUMBER_0_BYTE` constant defined in this class, but 
it's a `byte` rather than a `byte[]`. I'm not sure if there's a sensible way 
that it could be used instead of defining a new constant here, but it's worth a 
try, I think.




-- 
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