comnetwork commented on a change in pull request #4182: URL: https://github.com/apache/hbase/pull/4182#discussion_r821669668
########## File path: hbase-client/src/main/java/org/apache/hadoop/hbase/client/TableDescriptorBuilder.java ########## @@ -1335,11 +1335,14 @@ public boolean hasRegionMemStoreReplication() { * @return the modifyable TD */ public ModifyableTableDescriptor setRegionMemStoreReplication(boolean memstoreReplication) { - setValue(REGION_MEMSTORE_REPLICATION_KEY, Boolean.toString(memstoreReplication)); - // If the memstore replication is setup, we do not have to wait for observing a flush event + ModifyableTableDescriptor returnDesc = + setValue(REGION_MEMSTORE_REPLICATION_KEY, Boolean.toString(memstoreReplication)); + // If the memstore replication not setup, we do not have to wait for observing a flush event // from primary before starting to serve reads, because gaps from replication is not applicable - return setValue(REGION_REPLICA_WAIT_FOR_PRIMARY_FLUSH_CONF_KEY, - Boolean.toString(memstoreReplication)); + if (!memstoreReplication) { Review comment: @Apache9 , yes, the fix of the problem described on jira is here, if we explicitly set memstoreReplication to true at table level, we do not change the REGION_REPLICA_WAIT_FOR_PRIMARY_FLUSH_CONF_KEY, keep its original config(the default value is true). If REGION_REPLICA_WAIT_FOR_PRIMARY_FLUSH_CONF_KEY is false and memstoreReplication is true, the secondary region is enabled for read when open. -- 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-unsubscr...@hbase.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org