EdColeman edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892155365


   For discussion on output format - it looks like there are some options - 
using powers of 10 or 2.  To produce a sample:
   
   ```
       for (int x = 1; x < 15; x++) {
         System.out.println(
             String.format("%s%11s", " ", NumUtil.bigNumberForQuantity((long) 
Math.pow(10, x))));
       } 
       System.out.println("---");
       for (int x = 1; x < 16; x++) {
         System.out.println(
             String.format("%s%11s", " ", NumUtil.bigNumberForSize((long) 
Math.pow(16, x))));
       }
   ```
   This produces:
   ```
             10
            100
          1.00K
         10.00K
        100.00K
          1.00M
         10.00M
        100.00M
          1.00B
         10.00B
        100.00B
          1.00T
         10.00T
        100.00T
   ---
             16
            256
          4.00K
         64.00K
          1.00M
         16.00M
        256.00M
          4.00G
         64.00G
          1.00T
         16.00T
   ```
   Having even numbers seems more pleasing (to me) base 2 or 10 work, but being 
the buckets are calculated using 100, bigNumberForQuantity might be easier to 
implement with this PR.  Being this is size, an argument for the second option 
is valid, but might require additional work to calculate the buckets correctly.


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