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

Make RawLocalFileSystem more friendly to sub-classing

Add voteVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 0.23.0
    • Fix Version/s: None
    • Component/s: fs
    • Labels:
      None
    • Tags:
      RawLocalFileSystem FileSystem

      Description

      This patch does 3 things that makes sub-classing RawLocalFileSystem easier.

      First, it adds a constructor that allows a sub-class to avoid calling getInitialWorkingDirectory(). This is important because if a sub-class has an initially null uri (prior to initialize() being called), then getInitialWorkingDirectory() will cause a NullPointerException when it tries to work with the FS's uri.

      Second, allows subclasses to modify the working directory.

      The third thing this patch does is change loadPermissions to not pass the URI object to the File(URI) constructor, but rather pass the string representation of the path. This is important because URI's that are not using the "file" scheme will cause the File(URI) constructor to throw an exception.

        Attachments

        1. HADOOP-7099.patch
          1 kB
          Noah Watkins

        Issue Links

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              nwatkins Noah Watkins

              Dates

              • Created:
                Updated:

                Issue deployment