You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by GitBox <gi...@apache.org> on 2022/06/29 10:27:10 UTC

[GitHub] [ozone] mohan3d opened a new pull request, #3568: HDDS-6938. handle NPE when removing prefixAcl

mohan3d opened a new pull request, #3568:
URL: https://github.com/apache/ozone/pull/3568

   ## What changes were proposed in this pull request?
   Handle the case when removing prefixAcl of a non-existing prefix (A prefix that has no acls set before, or invalid prefix). it throws NPE if no acls are there.
   
   ## What is the link to the Apache JIRA
   https://issues.apache.org/jira/browse/HDDS-6938
   
   
   ## How was this patch tested?
   manual tests.
   


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] aswinshakil commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
aswinshakil commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r910644446


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/acl/prefix/OMPrefixAclRequest.java:
##########
@@ -93,6 +94,11 @@ public OMClientResponse validateAndUpdateCache(OzoneManager ozoneManager,
 
       omPrefixInfo = omMetadataManager.getPrefixTable().get(prefixPath);
 
+      if(omPrefixInfo == null) {
+        throw new OMException("No prefix info for the prefix path: " + prefixPath,

Review Comment:
   This line might cause checkstyle error. Please run `hadoop-ozone/dev-support/checks/checkstyle.sh`



##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/acl/prefix/OMPrefixAclRequest.java:
##########
@@ -93,6 +94,11 @@ public OMClientResponse validateAndUpdateCache(OzoneManager ozoneManager,
 
       omPrefixInfo = omMetadataManager.getPrefixTable().get(prefixPath);
 
+      if(omPrefixInfo == null) {

Review Comment:
   ```suggestion
         if (omPrefixInfo == null) {
   ```



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] mohan3d commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
mohan3d commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r912476233


##########
hadoop-ozone/ozone-manager/src/test/java/org/apache/hadoop/ozone/om/request/key/TestOMPrefixRemoveAclRequest.java:
##########
@@ -0,0 +1,131 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om.request.key;
+
+import org.apache.hadoop.ozone.OzoneAcl;
+import org.apache.hadoop.ozone.om.PrefixManager;
+import org.apache.hadoop.ozone.om.PrefixManagerImpl;
+import org.apache.hadoop.ozone.om.request.OMRequestTestUtils;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAddAclRequest;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixRemoveAclRequest;
+import org.apache.hadoop.ozone.om.response.OMClientResponse;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.AddAclRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.RemoveAclRequest;
+import org.apache.hadoop.ozone.security.acl.OzoneObj;
+import org.apache.hadoop.ozone.security.acl.OzoneObjInfo;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.util.UUID;
+
+import static org.mockito.Mockito.when;
+
+/**
+ * Tests Remove Prefix ACL requests.
+ */
+public class TestOMPrefixRemoveAclRequest extends TestOMKeyRequest {
+
+  @Test

Review Comment:
   @ayushtkn updated accordingly.



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] mohan3d commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
mohan3d commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r910652809


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/acl/prefix/OMPrefixAclRequest.java:
##########
@@ -93,6 +94,11 @@ public OMClientResponse validateAndUpdateCache(OzoneManager ozoneManager,
 
       omPrefixInfo = omMetadataManager.getPrefixTable().get(prefixPath);
 
+      if(omPrefixInfo == null) {

Review Comment:
   Yeah sure, working on it.



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] ayushtkn commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
ayushtkn commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r912472276


##########
hadoop-ozone/ozone-manager/src/test/java/org/apache/hadoop/ozone/om/request/key/TestOMPrefixRemoveAclRequest.java:
##########
@@ -0,0 +1,131 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om.request.key;
+
+import org.apache.hadoop.ozone.OzoneAcl;
+import org.apache.hadoop.ozone.om.PrefixManager;
+import org.apache.hadoop.ozone.om.PrefixManagerImpl;
+import org.apache.hadoop.ozone.om.request.OMRequestTestUtils;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAddAclRequest;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixRemoveAclRequest;
+import org.apache.hadoop.ozone.om.response.OMClientResponse;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.AddAclRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.RemoveAclRequest;
+import org.apache.hadoop.ozone.security.acl.OzoneObj;
+import org.apache.hadoop.ozone.security.acl.OzoneObjInfo;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.util.UUID;
+
+import static org.mockito.Mockito.when;
+
+/**
+ * Tests Remove Prefix ACL requests.
+ */
+public class TestOMPrefixRemoveAclRequest extends TestOMKeyRequest {
+
+  @Test

Review Comment:
   The change is in ``OMPrefixAclRequest.java`` and if we have a corresponding test class ``TestOMPrefixAclRequest``
   better to add tests there only unless there are issues doing so.
   Not very convinced with having one-one test class for each use case. Better keep all the related tests in one place only



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] mohan3d commented on pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
mohan3d commented on PR #3568:
URL: https://github.com/apache/ozone/pull/3568#issuecomment-1169815632

   Testing:
   
   ```bash
   bash-4.2$ kinit -kt /etc/security/keytabs/testuser.keytab testuser/scm@EXAMPLE.COM
   bash-4.2$ ozone shell volume create /vol1
   bash-4.2$ ozone shell bucket create /vol1/bucket1
   bash-4.2$ ozone shell key put /vol1/bucket1/prefix/key1 ./CONTRIBUTING.md
   bash-4.2$ ozone shell key put /vol1/bucket1/prefix/p/key2 ./CONTRIBUTING.md
   
   bash-4.2$ ozone shell prefix removeacl --acls=user:mohanad.elsafty:a /vol1/bucket1/prefix/
   PREFIX_NOT_FOUND No prefix info for the prefix path: /vol1/bucket1/prefix/
   
   bash-4.2$ ozone shell prefix removeacl --acls=user:mohanad.elsafty:a /vol1/bucket1/prefix/key1xyz
   PREFIX_NOT_FOUND No prefix info for the prefix path: /vol1/bucket1/prefix/key1xyz
   ```
   
   OMLog
   ```
   otocol.OzoneManagerProtocol
   om1_1        | 2022-06-29 10:24:02,415 [OM StateMachine ApplyTransaction Thread - 0] ERROR prefix.OMPrefixRemoveAclRequest: Remove acl [user:mohanad.elsafty:a[ACCESS]] to path /vol1/bucket1/prefix/ failed!
   om1_1        | PREFIX_NOT_FOUND org.apache.hadoop.ozone.om.exceptions.OMException: No prefix info for the prefix path: /vol1/bucket1/prefix/
   om1_1        | 	at org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAclRequest.validateAndUpdateCache(OMPrefixAclRequest.java:98)
   om1_1        | 	at org.apache.hadoop.ozone.protocolPB.OzoneManagerRequestHandler.handleWriteRequest(OzoneManagerRequestHandler.java:293)
   om1_1        | 	at org.apache.hadoop.ozone.om.ratis.OzoneManagerStateMachine.runCommand(OzoneManagerStateMachine.java:529)
   om1_1        | 	at org.apache.hadoop.ozone.om.ratis.OzoneManagerStateMachine.lambda$1(OzoneManagerStateMachine.java:324)
   om1_1        | 	at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
   om1_1        | 	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
   om1_1        | 	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
   om1_1        | 	at java.base/java.lang.Thread.run(Thread.java:829)
   om1_1        | 2022-06-29 10:24:16,204 [Socket Reader #1 for port 9862] INFO ipc.Server: Auth successful for testuser/scm@EXAMPLE.COM (auth:KERBEROS) from 172.25.0.116:52802
   om1_1        | 2022-06-29 10:24:16,219 [Socket Reader #1 for port 9862] INFO authorize.ServiceAuthorizationManager: Authorization successful for testuser/scm@EXAMPLE.COM (auth:KERBEROS) for protocol=interface org.apache.hadoop.ozone.om.protocol.OzoneManagerProtocol
   om1_1        | 2022-06-29 10:24:16,628 [OM StateMachine ApplyTransaction Thread - 0] ERROR prefix.OMPrefixRemoveAclRequest: Remove acl [user:mohanad.elsafty:a[ACCESS]] to path /vol1/bucket1/prefix/key1xyz failed!
   om1_1        | PREFIX_NOT_FOUND org.apache.hadoop.ozone.om.exceptions.OMException: No prefix info for the prefix path: /vol1/bucket1/prefix/key1xyz
   om1_1        | 	at org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAclRequest.validateAndUpdateCache(OMPrefixAclRequest.java:98)
   om1_1        | 	at org.apache.hadoop.ozone.protocolPB.OzoneManagerRequestHandler.handleWriteRequest(OzoneManagerRequestHandler.java:293)
   om1_1        | 	at org.apache.hadoop.ozone.om.ratis.OzoneManagerStateMachine.runCommand(OzoneManagerStateMachine.java:529)
   om1_1        | 	at org.apache.hadoop.ozone.om.ratis.OzoneManagerStateMachine.lambda$1(OzoneManagerStateMachine.java:324)
   om1_1        | 	at java.base/java.util.concurrent.CompletableFuture$AsyncSupply.run(CompletableFuture.java:1700)
   om1_1        | 	at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
   om1_1        | 	at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
   om1_1        | 	at java.base/java.lang.Thread.run(Thread.java:829)
   ```
   
   Earlier before this update, the OM will be terminated due to NullPointerException at this [line](https://github.com/apache/ozone/blob/03c5f7868be6e1642e5dcf8a2c970d938542d234/hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/acl/prefix/OMPrefixAclRequest.java#L114)
   
   
   


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] mohan3d commented on pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
mohan3d commented on PR #3568:
URL: https://github.com/apache/ozone/pull/3568#issuecomment-1171134555

   @adoroszlai Thanks Doroszlai! will be careful next time.


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] ferhui merged pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
ferhui merged PR #3568:
URL: https://github.com/apache/ozone/pull/3568


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] mohan3d commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
mohan3d commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r912416547


##########
hadoop-ozone/ozone-manager/src/test/java/org/apache/hadoop/ozone/om/request/key/TestOMPrefixRemoveAclRequest.java:
##########
@@ -0,0 +1,131 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om.request.key;
+
+import org.apache.hadoop.ozone.OzoneAcl;
+import org.apache.hadoop.ozone.om.PrefixManager;
+import org.apache.hadoop.ozone.om.PrefixManagerImpl;
+import org.apache.hadoop.ozone.om.request.OMRequestTestUtils;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAddAclRequest;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixRemoveAclRequest;
+import org.apache.hadoop.ozone.om.response.OMClientResponse;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.AddAclRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.RemoveAclRequest;
+import org.apache.hadoop.ozone.security.acl.OzoneObj;
+import org.apache.hadoop.ozone.security.acl.OzoneObjInfo;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.util.UUID;
+
+import static org.mockito.Mockito.when;
+
+/**
+ * Tests Remove Prefix ACL requests.
+ */
+public class TestOMPrefixRemoveAclRequest extends TestOMKeyRequest {
+
+  @Test

Review Comment:
   Not really, I thought it would be cleaner to have corresponding testing class for RemoveAcl. Yeah it can be done their as well.



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] adoroszlai commented on pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
adoroszlai commented on PR #3568:
URL: https://github.com/apache/ozone/pull/3568#issuecomment-1171119024

   @mohan3d Thanks for working on the fix.  Please try to avoid force-push when updating the PR.  Here are some great articles that explain why:
   
   https://developers.mattermost.com/blog/submitting-great-prs/#4-avoid-force-pushing
   https://www.freecodecamp.org/news/optimize-pull-requests-for-reviewer-happiness#request-a-review


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] ferhui commented on pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
ferhui commented on PR #3568:
URL: https://github.com/apache/ozone/pull/3568#issuecomment-1174662340

   @mohan3d Thanks for your contribution. @adoroszlai @aswinshakil @ayushtkn Thanks for your review! Merged


-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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


[GitHub] [ozone] ayushtkn commented on a diff in pull request #3568: HDDS-6938. handle NPE when removing prefixAcl

Posted by GitBox <gi...@apache.org>.
ayushtkn commented on code in PR #3568:
URL: https://github.com/apache/ozone/pull/3568#discussion_r912396176


##########
hadoop-ozone/ozone-manager/src/test/java/org/apache/hadoop/ozone/om/request/key/TestOMPrefixRemoveAclRequest.java:
##########
@@ -0,0 +1,131 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ * <p>
+ * http://www.apache.org/licenses/LICENSE-2.0
+ * <p>
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.hadoop.ozone.om.request.key;
+
+import org.apache.hadoop.ozone.OzoneAcl;
+import org.apache.hadoop.ozone.om.PrefixManager;
+import org.apache.hadoop.ozone.om.PrefixManagerImpl;
+import org.apache.hadoop.ozone.om.request.OMRequestTestUtils;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixAddAclRequest;
+import org.apache.hadoop.ozone.om.request.key.acl.prefix.OMPrefixRemoveAclRequest;
+import org.apache.hadoop.ozone.om.response.OMClientResponse;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.AddAclRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.OMRequest;
+import org.apache.hadoop.ozone.protocol.proto.OzoneManagerProtocolProtos.RemoveAclRequest;
+import org.apache.hadoop.ozone.security.acl.OzoneObj;
+import org.apache.hadoop.ozone.security.acl.OzoneObjInfo;
+import org.junit.Assert;
+import org.junit.Test;
+
+import java.util.UUID;
+
+import static org.mockito.Mockito.when;
+
+/**
+ * Tests Remove Prefix ACL requests.
+ */
+public class TestOMPrefixRemoveAclRequest extends TestOMKeyRequest {
+
+  @Test

Review Comment:
   Do we need a new test class for this?
   Can't we adjust it in some existing class? like ``TestOMPrefixAclRequest``?



-- 
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.

To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


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