You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: src/main/asciidoc/_chapters/architecture.adoc
+35-10Lines changed: 35 additions & 10 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2884,29 +2884,45 @@ secondaries. When they observe the flush/compaction or bulk load event, the
2884
2884
secondary regions replay the event to pick up the new files and drop the old
2885
2885
ones.
2886
2886
2887
-
Committing writes in the same order as in primary ensures that the secondaries won’t diverge from the primary regions data, but since the log replication is asynchronous, the data might still be stale in secondary regions. Since this feature works as a replication endpoint, the performance and latency characteristics is expected to be similar to inter-cluster replication.
2887
+
Committing writes in the same order as in primary ensures that the secondaries
2888
+
won’t diverge from the primary regions data, but since the log replication is
2889
+
asynchronous, the data might still be stale in secondary regions.
2888
2890
2889
2891
Async WAL Replication is *disabled* by default. You can enable this feature by
2890
-
setting `hbase.region.replica.replication.enabled` to `true`. The Async WAL
2891
-
Replication feature will add a new replication peer named
2892
+
setting `hbase.region.replica.replication.enabled` to `true`.
2893
+
2894
+
Before 3.0.0, this feature works as a replication endpoint, the performance and
2895
+
latency characteristics is expected to be similar to inter-cluster replication.
2896
+
And once enabled, it will create a replication peer named
2892
2897
`region_replica_replication` as a replication peer when you create a table with
2893
-
region replication > 1 for the first time. Once enabled, if you want to disable
2894
-
this feature, you need to do two actions in the following order:
2895
-
* Set configuration property `hbase.region.replica.replication.enabled` to false in `hbase-site.xml` (see Configuration section below)
2896
-
* Disable the replication peer named `region_replica_replication` in the cluster using hbase shell or `Admin` class:
2898
+
region replication > 1 for the first time.
2899
+
2900
+
if you want to disable this feature, you need to do two actions in the
2901
+
following order:
2902
+
* Set configuration property `hbase.region.replica.replication.enabled` to
2903
+
false in `hbase-site.xml` (see Configuration section below)
2904
+
* Disable the replication peer named `region_replica_replication` in the cluster
2905
+
using hbase shell or `Admin` class:
2897
2906
[source,bourne]
2898
2907
----
2899
2908
hbase> disable_peer 'region_replica_replication'
2900
2909
----
2901
2910
2902
-
Async WAL Replication and the `hbase:meta` table is a little more involved and gets its own section below; see <<async.wal.replication.meta>>
2911
+
In 3.0.0, this feature is re-implemented to decouple with the general replication
2912
+
framework. Now we do not need to create a special replication peer. And during
2913
+
rolling upgrading, we will remove this replication peer automatically if it is
2914
+
present. See https://issues.apache.org/jira/browse/HBASE-26233[HBASE-26233] and
2915
+
the design doc in our git repo for more details.
2916
+
2917
+
Async WAL Replication and the `hbase:meta` table is a little more involved and
2918
+
gets its own section below; see <<async.wal.replication.meta>>
2903
2919
2904
2920
=== Store File TTL
2905
2921
In both of the write propagation approaches mentioned above, store files of the primary will be opened in secondaries independent of the primary region. So for files that the primary compacted away, the secondaries might still be referring to these files for reading. Both features are using HFileLinks to refer to files, but there is no protection (yet) for guaranteeing that the file will not be deleted prematurely. Thus, as a guard, you should set the configuration property `hbase.master.hfilecleaner.ttl` to a larger value, such as 1 hour to guarantee that you will not receive IOExceptions for requests going to replicas.
2906
2922
2907
2923
[[async.wal.replication.meta]]
2908
2924
=== Region replication for META table’s region
2909
-
Async WAL Replication does not work for the META table’s WAL.
2925
+
The general Async WAL Replication does not work for the META table’s WAL.
2910
2926
The meta table’s secondary replicas refresh themselves from the persistent store
2911
2927
files every `hbase.regionserver.meta.storefile.refresh.period`, (a non-zero value).
2912
2928
Note how the META replication period is distinct from the user-space
@@ -2924,7 +2940,16 @@ would a user-space table (if `hbase.meta.replica.count` is set, it will take
2924
2940
precedent over what is set for replica count in the META table updating META
2925
2941
replica count to match).
2926
2942
2927
-
===== Load Balancing META table load =====
2943
+
==== Async WAL Replication for META table as of hbase-3.0.0+ ====
2944
+
In https://issues.apache.org/jira/browse/HBASE-26233[HBASE-26233] we
2945
+
re-implemented the region replication framework to not rely on the general
2946
+
replication framework, so it can work together with META table as well. The
2947
+
code described in the above section have been removed mostly, but the config
2948
+
`hbase.region.replica.replication.catalog.enabled` is still kept, you
2949
+
could still use it to control whether to enable async wal replication for META
2950
+
table. And the ability to alter META table is also kept.
2951
+
2952
+
==== Load Balancing META table load ====
2928
2953
2929
2954
hbase-2.4.0 also adds a *new* client-side `LoadBalance` mode. When enabled
2930
2955
client-side, clients will try to read META replicas first before falling back on
0 commit comments