Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-18193

Support nested mount points in INodeTree

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.10.0
    • 3.4.0
    • viewfs
    • Reviewed

    Description

      Defining following client mount table config is not supported in  INodeTree and will throw FileAlreadyExistsException

       

      fs.viewfs.mounttable.link./foo/bar=hdfs://nn1/foo/bar
      fs.viewfs.mounttable.link./foo=hdfs://nn02/foo
      

      INodeTree has 2 methods that need change to support nested mount points.

      createLink(): build INodeTree during fs init.
      resolve(): resolve path in INodeTree with viewfs apis.
      

      ViewFileSystem and ViewFs maintains an INodeTree instance(fsState) in both classes and call fsState.resolve(..) to resolve path to specific mount point. INodeTree.resolve encapsulates the logic of nested mount point resolving. So no changes are expected in both classes. 

      AC:

      1. INodeTree.createlink should support creating nested mount points.(INodeTree is constructed during fs init)
      2. INodeTree.resolve should support resolve path based on nested mount points. (INodeTree.resolve is used in viewfs apis)
      3. No regression in existing ViewFileSystem and ViewFs apis.
      4. Ensure some important apis are not broken with nested mount points. (Rename, getContentSummary, listStatus...)

       

      Spec:

      Please review attached pdf for spec about this feature.

      Attachments

        Issue Links

          Activity

            People

              Lei Yang Lei Yang
              Lei Yang Lei Yang
              Votes:
              0 Vote for this issue
              Watchers:
              4 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 - 7h 40m
                  7h 40m