Uploaded image for project: 'Apache Arrow'
  1. Apache Arrow
  2. ARROW-3694

[Java] Avoid superfluous string creation when logging level is disabled

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 0.11.1
    • 0.12.0
    • Java

    Description

      There are a few places where strings were unnecessarily created for logging purpose.

      https://github.com/apache/arrow/blob/ed70f051bb0636d994f285c38503b992d08efa00/java/vector/src/main/java/org/apache/arrow/vector/ipc/message/ArrowRecordBatch.java#L75

      For the above scenario in ArrowRecordBatch, roughly 2/3 of the total CPU was spent in string.format()

      Attachments

        Issue Links

          Activity

            People

              zzhao Zhenyuan Zhao
              zzhao Zhenyuan Zhao
              Votes:
              0 Vote for this issue
              Watchers:
              3 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 - 20m
                  20m