hbase-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jan Kunigk (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (HBASE-16415) Replication in different namespace
Date Tue, 20 Jun 2017 11:59:00 GMT

    [ https://issues.apache.org/jira/browse/HBASE-16415?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16055630#comment-16055630
] 

Jan Kunigk commented on HBASE-16415:
------------------------------------

I mean that, adding the method to ReplicationEndpoint would define a general interface for
redirecting entries.
Other Endpoints (RegionReplicaReplicationEndpoint, or new future ones) could implement a redirectEntries()
method too if they want to provide this, maybe with slightly different semantics.
Maybe those Endpoints would choose slightly different semantics for their own implementation
of redirectEntries().
If they do not provide an implementation, then the empty default implementation from the interface
will kick in.

If we implement redirection within RedirectingInterClusterReplicationEndpoint.createBatches(),
the concept of redirection would not be exposed beyond RedirectingInterClusterReplicationEndpoint.

I do not have enough experience with the HBase codebase to weigh the merits of making this
a general interface vs. encapsulating this functionality in the new endpoint entirely and
will rely on your guidance.

I hope I could clarify my idea though.

J




> Replication in different namespace
> ----------------------------------
>
>                 Key: HBASE-16415
>                 URL: https://issues.apache.org/jira/browse/HBASE-16415
>             Project: HBase
>          Issue Type: New Feature
>          Components: Replication
>            Reporter: Christian Guegi
>            Assignee: Jan Kunigk
>
> It would be nice to replicate tables from one namespace to another namespace.
> Example:
> Master cluster, namespace=default, table=bar
> Slave cluster, namespace=dr, table=bar
> Replication happens in class ReplicationSink:
>   public void replicateEntries(List<WALEntry> entries, final CellScanner cells,
...){
>     ...
>     TableName table = TableName.valueOf(entry.getKey().getTableName().toByteArray());
>     ...
>     addToHashMultiMap(rowMap, table, clusterIds, m);
>     ...
>     for (Entry<TableName, Map<List<UUID>, List<Row>>> entry :
rowMap.entrySet()) {
>       batch(entry.getKey(), entry.getValue().values());
>     }
>    }



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Mime
View raw message