saintstack commented on a change in pull request #2413:
URL: https://github.com/apache/hbase/pull/2413#discussion_r490412853



##########
File path: 
hbase-server/src/main/java/org/apache/hadoop/hbase/regionserver/handler/AssignRegionHandler.java
##########
@@ -129,8 +135,15 @@ public void process() throws IOException {
       }
       // pass null for the last parameter, which used to be a 
CancelableProgressable, as now the
       // opening can not be interrupted by a close request any more.
-      region = HRegion.openHRegion(regionInfo, htd, rs.getWAL(regionInfo), 
rs.getConfiguration(),
-        rs, null);
+      Configuration conf = rs.getConfiguration();
+      TableName tn = htd.getTableName();
+      if (ServerRegionReplicaUtil.isMetaRegionReplicaReplicationEnabled(conf, 
tn)) {
+        if 
(RegionReplicaUtil.isDefaultReplica(this.regionInfo.getReplicaId())) {
+          // Add the hbase:meta replication source on replica zero/default.
+          
rs.getReplicationSourceService().getReplicationManager().addHBaseMetaSource();
+        }
+      }
+      region = HRegion.openHRegion(regionInfo, htd, rs.getWAL(regionInfo), 
conf, rs, null);
     } catch (IOException e) {
       cleanUpAndReportFailure(e);

Review comment:
       We do in the UnassignRegionHandler.




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


Reply via email to