anmolnar commented on code in PR #7361:
URL: https://github.com/apache/hbase/pull/7361#discussion_r2466258602


##########
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/storefiletracker/StoreFileTrackerBase.java:
##########
@@ -98,7 +101,10 @@ public final void add(Collection<StoreFileInfo> newFiles) 
throws IOException {
   @Override
   public final void replace(Collection<StoreFileInfo> compactedFiles,
     Collection<StoreFileInfo> newFiles) throws IOException {
-    if (isPrimaryReplica) {
+    if (
+      isPrimaryReplica && 
!conf.getBoolean(HConstants.HBASE_GLOBAL_READONLY_ENABLED_KEY,
+        HConstants.HBASE_GLOBAL_READONLY_ENABLED_DEFAULT)
+    ) {

Review Comment:
   > I don't see these functions safeguarded for secondary replicas.
   
   In which case we probably don't need to. 



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