ankitsinghal commented on code in PR #4827:
URL: https://github.com/apache/hbase/pull/4827#discussion_r992750959


##########
hbase-server/src/main/java/org/apache/hadoop/hbase/replication/SystemTableWALEntryFilter.java:
##########
@@ -17,16 +17,22 @@
  */
 package org.apache.hadoop.hbase.replication;
 
+import org.apache.hadoop.hbase.NamespaceDescriptor;
+import org.apache.hadoop.hbase.TableName;
 import org.apache.hadoop.hbase.wal.WAL.Entry;
 import org.apache.yetus.audience.InterfaceAudience;
 
 /**
- * Skips WAL edits for all System tables including hbase:meta.
+ * Skips WAL edits for all System tables including hbase:meta except hbase:acl.
  */
 @InterfaceAudience.Private
 public class SystemTableWALEntryFilter implements WALEntryFilter {
   @Override
   public Entry filter(Entry entry) {
+    if(entry.getKey().getTableName().equals(
+      TableName.valueOf(NamespaceDescriptor.SYSTEM_NAMESPACE_NAME_STR, 
"acl"))) {

Review Comment:
   Nit
   ```suggestion
         PermissionStorage.ACL_TABLE_NAME)) {
   ```



##########
hbase-server/src/test/java/org/apache/hadoop/hbase/replication/TestReplicationWALEntryFilters.java:
##########
@@ -80,6 +81,14 @@ public void testSystemTableWALEntryFilter() {
     Entry userEntry = new Entry(key3, null);
 
     assertEquals(userEntry, filter.filter(userEntry));
+
+    // hbase:acl should be allowed through the filter
+    final TableName ACL_TABLE_NAME =
+      TableName.valueOf(NamespaceDescriptor.SYSTEM_NAMESPACE_NAME_STR, "acl");
+    WALKeyImpl key4 =
+      new WALKeyImpl(new byte[0], ACL_TABLE_NAME, System.currentTimeMillis());

Review Comment:
   Nit
   
   ```suggestion
       WALKeyImpl key4 =
         new WALKeyImpl(new byte[0], PermissionStorage.ACL_TABLE_NAME, 
System.currentTimeMillis());
   ```



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

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to