Uploaded image for project: 'Apache Ozone'
  1. Apache Ozone
  2. HDDS-4285

Read is slow due to frequent calls to UGI.getCurrentUser() and getTokens()

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 1.1.0
    • None

    Description

      Ozone read operation turned out to be slow mainly because we do a new UGI.getCurrentUser for block token for each of the calls.

      We need to cache the block token / UGI.getCurrentUserCall() to make it faster.

      To reproduce:

      Checkout: https://github.com/elek/hadoop-ozone/tree/mocked-read

      cd hadoop-ozone/client
      
      export MAVEN_OPTS=-agentpath:/home/elek/prog/async-profiler/build/libasyncProfiler.so=start,file=/tmp/profile-%t-%p.svg
      
      mvn compile exec:java -Dexec.mainClass=org.apache.hadoop.ozone.client.io.TestKeyOutputStreamUnit -Dexec.classpathScope=test
      

      Attachments

        1. profile-20200928-161631-180518.svg
          1.15 MB
          Marton Elek
        2. image-2020-09-28-16-19-17-581.png
          98 kB
          Marton Elek

        Issue Links

          Activity

            People

              adoroszlai Attila Doroszlai
              elek Marton Elek
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: