Uploaded image for project: 'Accumulo'
  1. Accumulo
  2. ACCUMULO-4789

Scans spend significant time constructing debug string.

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.7.3, 1.8.1
    • Fix Version/s: 1.9.0, 2.0.0
    • Component/s: None

      Description

      While profiling a Fluo test running lots of little scans, I noticed a string builder operation showing up prominently in the profiling results.  Below is a link to the problematic code.  Calling range toString was the most expensive part followed by KeyExtent toString.

      https://github.com/apache/accumulo/blob/rel/1.7.3/core/src/main/java/org/apache/accumulo/core/client/impl/ThriftScanner.java#L405

       

      I am not sure if we can change this in 1.7 and 1.8/1.9 because people may rely on this for debugging.  In 2.0 we may want to consider removing this (or moving it inside the logging code block).

      Also, while looking at this I noticed that some of the log statements called String.format.  Those should be placed in a if(llog.traceEnabled()) block.

       

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                kturner Keith Turner
                Reporter:
                kturner Keith Turner
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 1h
                  1h