You are viewing a plain text version of this content. The canonical link for it is here.
Posted to common-issues@hadoop.apache.org by GitBox <gi...@apache.org> on 2019/08/08 17:46:13 UTC

[GitHub] [hadoop] goiri commented on a change in pull request #1253: HDFS-8631. WebHDFS : Support setQuota

goiri commented on a change in pull request #1253: HDFS-8631. WebHDFS : Support setQuota
URL: https://github.com/apache/hadoop/pull/1253#discussion_r312143159
 
 

 ##########
 File path: hadoop-common-project/hadoop-common/src/main/java/org/apache/hadoop/fs/FileSystem.java
 ##########
 @@ -1788,6 +1788,34 @@ public QuotaUsage getQuotaUsage(Path f) throws IOException {
     return getContentSummary(f);
   }
 
+  /**
+   * Set quota for the given {@link Path}.
+   *
+   * @param src the target path to set quota for
+   * @param namespaceQuota the namespace quota (i.e., # of files/directories) to set
+   * @param storagespaceQuota the storage space quota to set
+   * @throws IOException IO failure
+   */
+  public void setQuota(Path src, final long namespaceQuota,
+      final long storagespaceQuota) throws IOException {
+    throw new UnsupportedOperationException(getClass().getCanonicalName() +
 
 Review comment:
   This is a pattern used in many places.
   I think we should have a static method to do this.
   I think the easiest way to get the function name is to get the stack trace.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: common-issues-unsubscribe@hadoop.apache.org
For additional commands, e-mail: common-issues-help@hadoop.apache.org