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

setStoragePolicy should check quota and update consume on storage type quota.

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Patch Available
    • Major
    • Resolution: Unresolved
    • 3.1.0
    • None
    • None

    Description

      At present when the storage policy of a directory or a file is changed, we just simply change the recorded policy. But the change of storage policy also change the consume, and that will cause violation of Quota, and cause the consume recorded in DirectoryWithQuotaFeature out of date. 

      We should do the quota check and consume update when setStoragePolicy():

      1. Compute the new consume and check quota on ancestors. If quota exceed throwing the QuotaExceedException. Else go to 2.
      2. Update the consume to all ancestors with Quota.

       

      Related to HDFS-14633,  see HDFS-14633 to get more discussions.

       

      Attachments

        1. HDFS-14568.002.patch
          10 kB
          Jinglun
        2. HDFS-14568.003.patch
          10 kB
          Jinglun
        3. HDFS-14568.004.patch
          10 kB
          Jinglun
        4. HDFS-14568-001.patch
          6 kB
          Jinglun
        5. HDFS-14568-unit-test.patch
          2 kB
          Jinglun

        Issue Links

          Activity

            People

              LiJinglun Jinglun
              LiJinglun Jinglun
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

                Created:
                Updated: