bharathv commented on a change in pull request #1047: HBASE-23683 Make 
HBaseInterClusterReplicationEndpoint more extensible…
URL: https://github.com/apache/hbase/pull/1047#discussion_r366993169
 
 

 ##########
 File path: 
hbase-server/src/main/java/org/apache/hadoop/hbase/replication/regionserver/HBaseInterClusterReplicationEndpoint.java
 ##########
 @@ -114,6 +114,25 @@
   private boolean dropOnDeletedTables;
   private boolean isSerial = false;
 
+  /*
+   * Some implementations of HBaseInterClusterReplicationEndpoint may require 
instantiate different
+   * Connection implementations, or initialize it in a different way, so 
defining createConnection
+   * as protected for possible overridings.
+   */
+  protected Connection createConnection(Configuration conf) throws IOException 
{
+    return ConnectionFactory.createConnection(conf);
+  }
+
+  /*
+   * Some implementations of HBaseInterClusterReplicationEndpoint may require 
instantiate different
+   * ReplicationSinkManager implementations, or initialize it in a different 
way,
+   * so defining createReplicationSinkManager as protected for possible 
overridings.
+   */
+  protected ReplicationSinkManager createReplicationSinkManager(Connection 
conn) {
+    return new ReplicationSinkManager((ClusterConnection) conn, 
this.ctx.getPeerId(),
 
 Review comment:
   nit: redundant cast to conn.

----------------------------------------------------------------
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:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to