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

BlockIdManager.clear doesn't reset the counter for blockGroupIdGenerator

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 3.0.0-alpha1, 3.0.0-beta1
    • Fix Version/s: 3.0.0-alpha2
    • Component/s: hdfs
    • Labels:
    • Hadoop Flags:
      Reviewed
    • Tags:
      erasurecode

      Description

      BlockIdManager.clear resets the block id generator for contiguous blocks but not for striped blocks:

        void clear() {
          legacyGenerationStamp.setCurrentValue(GenerationStamp.LAST_RESERVED_STAMP);
          generationStamp.setCurrentValue(GenerationStamp.LAST_RESERVED_STAMP);
          getBlockIdGenerator().setCurrentValue(SequentialBlockIdGenerator
            .LAST_RESERVED_BLOCK_ID);
          legacyGenerationStampLimit = HdfsConstants.GRANDFATHER_GENERATION_STAMP;
        }
      

      This should have:

      getBlockGroupIdGenerator().setCurrentValue(Long.MIN_VALUE);
      

        Attachments

        1. HDFS-10769-002.patch
          2 kB
          Rakesh R
        2. HDFS-10769.001.patch
          0.8 kB
          Yiqun Lin

          Activity

            People

            • Assignee:
              linyiqun Yiqun Lin
              Reporter:
              ehiggs Ewan Higgs
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: