linyiqun commented on a change in pull request #1677:
URL: https://github.com/apache/ozone/pull/1677#discussion_r545183356



##########
File path: 
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/bucket/OMBucketCreateRequest.java
##########
@@ -314,7 +314,9 @@ private BucketEncryptionInfoProto getBeinfo(
    */
   private void checkQuotaInNamespace(OmVolumeArgs omVolumeArgs,
       long allocatedNamespace) throws IOException {
-    if (omVolumeArgs.getQuotaInNamespace() != OzoneConsts.QUOTA_RESET) {
+    // Client has ensured that no negative values other than -1 (clear quota)
+    // will occur when quota is set.
+    if (omVolumeArgs.getQuotaInNamespace() > OzoneConsts.QUOTA_RESET) {

Review comment:
       Why we change above condition check? Above check just means that we 
enabled the quota, and current quota isn't equal to default value. This should 
be a more accurate check. 




----------------------------------------------------------------
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:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to