You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2021/08/03 12:44:51 UTC

[GitHub] [accumulo] Shivakumar-SG opened a new pull request #2220: Fixed: printinfo's 'histogram' output

Shivakumar-SG opened a new pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220


   fixes issue #2217.
   Let me know if there should be any changes.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 merged pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 merged pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220


   


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892663277






-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 merged pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 merged pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220


   


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892842755


   Thanks for the contribution Shivakumar-SG and welcome to the Apache Accumulo community. If you would like to be listed as a contributor on Accumulo's people page please make a website PR for people.md. https://github.com/apache/accumulo-website/edit/main/pages/people.md by:
    -  adding your name (in alphabetical order) to the contributor's list.
    -  reference the PR number (#2220)
   If you intend to make more contributions, please consider subscribing to the dev list and introducing yourself. Also, you can use the dev list or slack to reach out if you have questions about anything. https://accumulo.apache.org/contact-us/


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on a change in pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on a change in pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#discussion_r682054694



##########
File path: core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
##########
@@ -106,10 +106,11 @@ public void add(int size) {
     }
 
     public void print(String indent) {
-      System.out.println(indent + "Up to size      count      %-age");
+      System.out.println(indent + "Up to size      Count      %-age");
       for (int i = 1; i < countBuckets.length; i++) {
-        System.out.println(String.format("%s%11.0f : %10d %6.2f%%", indent, Math.pow(10, i),
-            countBuckets[i], sizeBuckets[i] * 100. / totalSize));
+        System.out.println(String.format("%s%11s : %10d %6.2f%%", indent,
+            bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],

Review comment:
       ```suggestion
               NumUtil.bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],
   ```




-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892120923


   > It looks like you are missing the import for `bigNumberForSize()` which is `import org.apache.accumulo.core.util.NumUtil`
   
   Initially, I did import initially and when the command `mvn package -DskipTests` is run, it takes it out.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892122833


   
   > Initially, I did import and when the command mvn package -DskipTests is run, it takes it out.
   
   That is most likely due to the import being unused since you weren't calling the function correctly (as suggested above). One of the format rules removes all unused imports. 


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-891864482


   @Shivakumar-SG It looks like the build failed due to not being formatted correctly. You can run something like `mvn package -DskipTests` at the root of the project and it will apply the proper formatting for you. Include those changes into a new commit for this PR and the build should pass from there. 


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] DomGarguilo commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
DomGarguilo commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892118960


   It looks like with these changes the output is something like:
   ![Screenshot from 2021-08-03 15-48-14](https://user-images.githubusercontent.com/47725857/128076980-c94ad179-cfef-41d1-9993-580689abb517.png)
   
   Is this what we are looking for?


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892071890


   I have been trying from past few hours to run `mvn package -DskipTests`, but its throwing me many errors and I couldn't fix them. What would you want me to do?


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892863469


   Thank you for helping me out in this @EdColeman and @DomGarguilo :)


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892171689


   > 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.
   
   Good point, I concur that Quantity might be preferable since it lines up closer to the original output. 


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on a change in pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on a change in pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#discussion_r682759038



##########
File path: core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
##########
@@ -106,10 +107,11 @@ public void add(int size) {
     }
 
     public void print(String indent) {
-      System.out.println(indent + "Up to size      count      %-age");
+      System.out.println(indent + "Up to size      Count      %-age");
       for (int i = 1; i < countBuckets.length; i++) {
-        System.out.println(String.format("%s%11.0f : %10d %6.2f%%", indent, Math.pow(10, i),
-            countBuckets[i], sizeBuckets[i] * 100. / totalSize));
+        System.out.printf("%s%11s : %10d %6.2f%%", indent,
+            NumUtil.bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],
+            sizeBuckets[i] * 100. / totalSize);

Review comment:
       ```suggestion
           System.out.println(String.format("%s%11s : %10d %6.2f%%", indent,
               NumUtil.bigNumberForQuantity((long) Math.pow(10, i)), countBuckets[i],
               sizeBuckets[i] * 100. / totalSize));
   ```




-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892083006


   if the build failed because of just the formatting, it would be great if someone could help me with the formatted code of my version


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892842755


   Thanks for the contribution Shivakumar-SG and welcome to the Apache Accumulo community. If you would like to be listed as a contributor on Accumulo's people page please make a website PR for people.md. https://github.com/apache/accumulo-website/edit/main/pages/people.md by:
    -  adding your name (in alphabetical order) to the contributor's list.
    -  reference the PR number (#2220)
    
   If you intend to make more contributions, please consider subscribing to the dev list and introducing yourself. Also, you can use the dev list or slack to reach out if you have questions about anything. https://accumulo.apache.org/contact-us/


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892085093


   @DomGarguilo That would be great! Thank you so much


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892842755


   Thanks for the contribution Shivakumar-SG and welcome to the Apache Accumulo community. If you would like to be listed as a contributor on Accumulo's people page please make a website PR for people.md. https://github.com/apache/accumulo-website/edit/main/pages/people.md by:
    -  adding your name (in alphabetical order) to the contributor's list.
    -  reference the PR number (#2220)
    
   If you intend to make more contributions, please consider subscribing to the dev list and introducing yourself. Also, you can use the dev list or slack to reach out if you have questions about anything. https://accumulo.apache.org/contact-us/


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892126588


   > Is this what we are looking for?
   
   That output looks good to me. 


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892842755


   Thanks for the contribution Shivakumar-SG and welcome to the Apache Accumulo community. If you would like to be listed as a contributor on Accumulo's people page please make a website PR for people.md. https://github.com/apache/accumulo-website/edit/main/pages/people.md by:
    -  adding your name (in alphabetical order) to the contributor's list.
    -  reference the PR number (#2220)
   If you intend to make more contributions, please consider subscribing to the dev list and introducing yourself. Also, you can use the dev list or slack to reach out if you have questions about anything. https://accumulo.apache.org/contact-us/


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] DomGarguilo commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
DomGarguilo commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892079018


   @Shivakumar-SG what errors are being thrown?


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892115290


   It also looks like an extra file (.DS_Store) was pushed along with you commit - that file should not be included.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892697912


   > @Shivakumar-SG What are your thoughts on the conversation above?
   > 
   > > 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.
   
   @Manno15 Thank you for showing your interest in my views but I'm just a student who is still learning and knows pretty much nothing about this repo. So I don't think so that I'm fit to share my views on such a big project.
   I will just do what you tell me to do sir!


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892113563


   It looks like you are missing the import for `bigNumberForSize()` which is `import org.apache.accumulo.core.util.NumUtil`


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman commented 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 pr 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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892120923


   > It looks like you are missing the import for `bigNumberForSize()` which is `import org.apache.accumulo.core.util.NumUtil`
   
   Initially, I did import and when the command `mvn package -DskipTests` is run, it takes it out.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892113563


   It looks like you are missing the import for 'bigNumberForSize()' which is NumUtil. 


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on a change in pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on a change in pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#discussion_r682092533



##########
File path: core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
##########
@@ -106,10 +107,11 @@ public void add(int size) {
     }
 
     public void print(String indent) {
-      System.out.println(indent + "Up to size      count      %-age");
+      System.out.println(indent + "Up to size      Count      %-age");
       for (int i = 1; i < countBuckets.length; i++) {
-        System.out.println(String.format("%s%11.0f : %10d %6.2f%%", indent, Math.pow(10, i),
-            countBuckets[i], sizeBuckets[i] * 100. / totalSize));
+        System.out.println("%s%11s : %10d %6.2f%%", indent,

Review comment:
       ```suggestion
           System.out.printf("%s%11s : %10d %6.2f%%", indent,
   ```
   
   That is my mistake, I forgot to add this change. 




-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892080119


   A whole lot many actually :(


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892663277


   @Shivakumar-SG What are your thoughts on the conversation above? 
   
   > 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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] DomGarguilo commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
DomGarguilo commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892078509


   @Shivakumar-SG what errors are being thrown?


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892113563


   It looks like you are missing the import for 'bigNumberForSize()' which is `import org.apache.accumulo.core.util.NumUtil`


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] DomGarguilo removed a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
DomGarguilo removed a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892079018


   @Shivakumar-SG what errors are being thrown?


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892835059


   Thanks for the contribution @Shivakumar-SG and welcome to the Apache Accumulo community! If you would like to be listed as a contributor on Accumulo's people page please make a website PR for people.md. https://github.com/apache/accumulo-website/edit/main/pages/people.md
   
   If you intend to make more contributions, please consider subscribing to the dev list and introducing yourself. Also, you can use the dev list or slack to reach out if you have questions about anything. https://accumulo.apache.org/contact-us/


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892095846


   Can you provide more information?
   
   - What platform are you running on?
   - What command are you running?
   - What is the first or  first few errors that you are getting?
   
   You can do the same build as the verification checks, but skipping all of the tests by running:
   
   `mvn package javadoc:jar -Psec-bugs -DskipITs=true -DskipTests=true`
   
   The javadoc and sec-bugs will add to the build time, but running those before submitting the PR can highlight issues that will fail the automatic build.  This should also format the files to the community standards.
   
   More information on building is at [Building Accumulo](https://accumulo.apache.org/contributor/building)


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on a change in pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on a change in pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#discussion_r682759038



##########
File path: core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
##########
@@ -106,10 +107,11 @@ public void add(int size) {
     }
 
     public void print(String indent) {
-      System.out.println(indent + "Up to size      count      %-age");
+      System.out.println(indent + "Up to size      Count      %-age");
       for (int i = 1; i < countBuckets.length; i++) {
-        System.out.println(String.format("%s%11.0f : %10d %6.2f%%", indent, Math.pow(10, i),
-            countBuckets[i], sizeBuckets[i] * 100. / totalSize));
+        System.out.printf("%s%11s : %10d %6.2f%%", indent,
+            NumUtil.bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],
+            sizeBuckets[i] * 100. / totalSize);

Review comment:
       ```suggestion
           System.out.println(String.format("%s%11s : %10d %6.2f%%", indent,
               NumUtil.bigNumberForQuantity((long) Math.pow(10, i)), countBuckets[i],
               sizeBuckets[i] * 100. / totalSize));
   ```




-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] EdColeman commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
EdColeman commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892095846


   Can you provide more information?
   
   - What platform are you running on?
   - What command are you running?
   - What is the first or  first few errors that you are getting?
   
   You can do the same build as the verification checks, but skipping all of the tests by running:
   
   `mvn package javadoc:jar -Psec-bugs -DskipITs=true -DskipTests=true`
   
   The javadoc and sec-bugs will add to the build time, but running those before submitting the PR can highlight issues that will fail the automatic build.  This should also format the files to the community standards.
   
   More information on building is at (Building Accumulo](https://accumulo.apache.org/contributor/building)


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892697912






-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG edited a comment on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG edited a comment on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892120923


   > It looks like you are missing the import for `bigNumberForSize()` which is `import org.apache.accumulo.core.util.NumUtil`
   
   Initially, I did import and when the command `mvn package -DskipTests` is run, it takes `NumUtil` out.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Manno15 commented on a change in pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Manno15 commented on a change in pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#discussion_r682080896



##########
File path: core/src/main/java/org/apache/accumulo/core/file/rfile/PrintInfo.java
##########
@@ -106,10 +107,11 @@ public void add(int size) {
     }
 
     public void print(String indent) {
-      System.out.println(indent + "Up to size      count      %-age");
+      System.out.println(indent + "Up to size      Count      %-age");
       for (int i = 1; i < countBuckets.length; i++) {
-        System.out.println(String.format("%s%11.0f : %10d %6.2f%%", indent, Math.pow(10, i),
-            countBuckets[i], sizeBuckets[i] * 100. / totalSize));
+        System.out.println(String.format("%s%11s : %10d %6.2f%%", indent,
+            NumUtil.bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],
+            sizeBuckets[i] * 100. / totalSize));

Review comment:
       ```suggestion
           System.out.println("%s%11s : %10d %6.2f%%", indent,
               NumUtil.bigNumberForSize(Double.valueOf(Math.pow(10, i)).longValue()), countBuckets[i],
               sizeBuckets[i] * 100. / totalSize);
   ```
   Based from my testing, the String.format isn't necessary. 




-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] Shivakumar-SG commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
Shivakumar-SG commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892839151


   I will consider your options. Thank you so much for letting me do this.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [accumulo] DomGarguilo commented on pull request #2220: Fixed: printinfo's 'histogram' output

Posted by GitBox <gi...@apache.org>.
DomGarguilo commented on pull request #2220:
URL: https://github.com/apache/accumulo/pull/2220#issuecomment-892083616


   > if the build failed because of just the formatting, it would be great if someone could help me with the formatted code of my version
   
   Sure, I can make a PR to your branch with the formatting changes.


-- 
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: notifications-unsubscribe@accumulo.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org