Uploaded image for project: 'Hadoop HDFS'
  1. Hadoop HDFS
  2. HDFS-4461

DirectoryScanner: volume path prefix takes up memory for every block that is scanned

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.0.3-alpha
    • Fix Version/s: 2.1.0-beta, 0.23.11
    • Component/s: None
    • Labels:
      None

      Description

      In the DirectoryScanner, we create a class ScanInfo for every block. This object contains two File objects-- one for the metadata file, and one for the block file. Since those File objects contain full paths, users who pick a lengthly path for their volume roots will end up using an extra N_blocks * path_prefix bytes per block scanned. We also don't really need to store File objects-- storing strings and then creating File objects as needed would be cheaper. This would be a nice efficiency improvement.

        Attachments

        1. memory-analysis.png
          140 kB
          Colin P. McCabe
        2. HDFS-4461.002.patch
          4 kB
          Colin P. McCabe
        3. HDFS-4461.003.patch
          4 kB
          Colin P. McCabe
        4. HDFS-4461.004.patch
          6 kB
          Colin P. McCabe
        5. HDFS-4661.006.patch
          10 kB
          Colin P. McCabe
        6. HDFS-4461.branch-0.23.patch
          11 kB
          Kihwal Lee

          Issue Links

            Activity

              People

              • Assignee:
                cmccabe Colin P. McCabe
                Reporter:
                cmccabe Colin P. McCabe
              • Votes:
                0 Vote for this issue
                Watchers:
                14 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: