Class RouterQuotaUsage

java.lang.Object
org.apache.hadoop.fs.QuotaUsage
org.apache.hadoop.hdfs.server.federation.router.RouterQuotaUsage

public final class RouterQuotaUsage extends org.apache.hadoop.fs.QuotaUsage
The subclass of QuotaUsage used in Router-based federation.
  • Nested Class Summary

    Nested Classes
    Modifier and Type
    Class
    Description
    static class 
    Build the instance based on the builder.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final long
    Default quota usage count.

    Fields inherited from class org.apache.hadoop.fs.QuotaUsage

    QUOTA_HEADER, QUOTA_HEADER_FIELDS, QUOTA_STRING_FORMAT, SPACE_QUOTA_STRING_FORMAT
  • Method Summary

    Modifier and Type
    Method
    Description
     
    void
    Verify if namespace quota is violated once quota is set.
    void
    Verify space quota by storage type is violated once quota is set.
    void
    Verify if storage space quota is violated once quota is set.

    Methods inherited from class org.apache.hadoop.fs.QuotaUsage

    equals, getFileAndDirectoryCount, getHeader, getQuota, getQuotaUsage, getSpaceConsumed, getSpaceQuota, getStorageTypeHeader, getTypeConsumed, getTypeQuota, getTypesQuotaUsage, hashCode, isTypeConsumedAvailable, isTypeQuotaSet, setQuota, setSpaceConsumed, setSpaceQuota, toString, toString

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait
  • Field Details

    • QUOTA_USAGE_COUNT_DEFAULT

      public static final long QUOTA_USAGE_COUNT_DEFAULT
      Default quota usage count.
      See Also:
  • Method Details

    • verifyNamespaceQuota

      public void verifyNamespaceQuota() throws org.apache.hadoop.hdfs.protocol.NSQuotaExceededException
      Verify if namespace quota is violated once quota is set. Relevant method DirectoryWithQuotaFeature.verifyNamespaceQuota(long).
      Throws:
      org.apache.hadoop.hdfs.protocol.NSQuotaExceededException - If the quota is exceeded.
    • verifyStoragespaceQuota

      public void verifyStoragespaceQuota() throws org.apache.hadoop.hdfs.protocol.DSQuotaExceededException
      Verify if storage space quota is violated once quota is set. Relevant method DirectoryWithQuotaFeature.verifyStoragespaceQuota(long).
      Throws:
      org.apache.hadoop.hdfs.protocol.DSQuotaExceededException - If the quota is exceeded.
    • verifyQuotaByStorageType

      public void verifyQuotaByStorageType() throws org.apache.hadoop.hdfs.protocol.DSQuotaExceededException
      Verify space quota by storage type is violated once quota is set. Relevant method DirectoryWithQuotaFeature.verifyQuotaByStorageType(org.apache.hadoop.hdfs.util.EnumCounters<org.apache.hadoop.fs.StorageType>).
      Throws:
      org.apache.hadoop.hdfs.protocol.DSQuotaExceededException - If the quota is exceeded.
    • toString

      public String toString()
      Overrides:
      toString in class org.apache.hadoop.fs.QuotaUsage