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

Fix INodeId javadoc

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

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • None
    • 3.3.0
    • documentation, namenode
    • None
    • Reviewed

    Description

      The INodeId javadoc states that id 1 to 1000 is reserved and root inode id start from 1001. That is no longer true after HDFS-4434.

      Also, it's a little weird in INodeId

        public static final long LAST_RESERVED_ID = 2 << 14 - 1;
        public static final long ROOT_INODE_ID = LAST_RESERVED_ID + 1;
      

      It seems the intent was for LAST_RESERVED_ID to be (2^14) - 1 = 32767. But due to Java operator precedence, LAST_RESERVED_ID = 2^(14-1) = 16384. Maybe it doesn't matter, not sure.

      Attachments

        1. HDFS-12245.004.patch
          2 kB
          Adam Antal
        2. HDFS-12245.003.patch
          2 kB
          Adam Antal
        3. HDFS-12245.002.patch
          2 kB
          Adam Antal
        4. HDFS-12245.001.patch
          2 kB
          Adam Antal

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            adam.antal Adam Antal
            weichiu Wei-Chiu Chuang
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment