ddanielr commented on code in PR #6411:
URL: https://github.com/apache/accumulo/pull/6411#discussion_r3365030745


##########
shell/src/main/java/org/apache/accumulo/shell/commands/GetSplitsCommand.java:
##########
@@ -139,8 +139,8 @@ public Options getOptions() {
     outputFileOpt = new Option("o", "output", true, "local file to write the 
splits to");
     outputFileOpt.setArgName("file");
 
-    maxSplitsOpt =
-        new Option("m", "max", true, "maximum number of splits to return 
(evenly spaced)");
+    maxSplitsOpt = new Option("m", "max", true, "maximum number of splits to 
return that are "
+        + "\"evenly\" selected from the existing splits based upon the 
algorithm implemented in TableOperations.listSplits");

Review Comment:
   `maximum number of splits to return` is still a bit fuzzy. 
   The javadoc for the interface doesn't clarify that the maxSplits are based 
on selected values. 
   
https://accumulo.apache.org/docs/2.x/apidocs/org/apache/accumulo/core/client/admin/TableOperations.html#listSplits(java.lang.String,int)
 
   
   The ordering isn't apparent to the user unless they look at our 
`TableOperationsImpl` class. 
   
https://www.javadoc.io/static/org.apache.accumulo/accumulo-core/2.1.4/org/apache/accumulo/core/clientImpl/TableOperationsImpl.html#listSplits(java.lang.String,int)
   
   I ran a quick test on 2.1 to show that a user who thinks `maxSplits` returns 
the first x splits will actually make very inaccurate decisions.
   ```
   root@uno test> addsplits A B C D E F G H I J K L M N O P Q R S T U V W X Y Z
   root@uno test> getsplits -m 5
   E
   I
   M
   R
   V
   ```



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