2 * Licensed to the Apache Software Foundation (ASF) under one
3 * or more contributor license agreements. See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership. The ASF licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License. You may obtain a copy of the License at
10 * http://www.apache.org/licenses/LICENSE-2.0
12 * Unless required by applicable law or agreed to in writing, software
13 * distributed under the License is distributed on an "AS IS" BASIS,
14 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15 * See the License for the specific language governing permissions and
16 * limitations under the License.
22 option java_package = "org.apache.hadoop.hbase.shaded.protobuf.generated";
23 option java_outer_classname = "ReplicationProtos";
24 option java_generic_services = true;
25 option java_generate_equals_and_hash = true;
26 option optimize_for = SPEED;
31 optional TableName table_name = 1;
32 repeated bytes families = 2;
36 * Used by replication. Holds a replication peer key.
38 message ReplicationPeer {
39 // clusterkey is the concatenation of the slave cluster's
40 // hbase.zookeeper.quorum:hbase.zookeeper.property.clientPort:zookeeper.znode.parent
41 optional string clusterkey = 1;
42 optional string replicationEndpointImpl = 2;
43 repeated BytesBytesPair data = 3;
44 repeated NameStringPair configuration = 4;
45 repeated TableCF table_cfs = 5;
46 repeated bytes namespaces = 6;
47 optional int64 bandwidth = 7;
48 optional bool replicate_all = 8;
49 repeated TableCF exclude_table_cfs = 9;
50 repeated bytes exclude_namespaces = 10;
51 optional bool serial = 11;
52 optional string remoteWALDir = 12;
56 * Used by replication. Holds whether enabled or disabled
58 message ReplicationState {
63 required State state = 1;
67 * Indicate the state of the current cluster in a synchronous replication peer.
69 message SyncReplicationState {
76 required State state = 1;
80 * Used by replication. Description of the replication peer.
82 message ReplicationPeerDescription {
83 required string id = 1;
84 required ReplicationState state = 2;
85 required ReplicationPeer config = 3;
86 optional SyncReplicationState syncReplicationState = 4;
90 * Used by replication. Holds the current position in an WAL file.
92 message ReplicationHLogPosition {
93 required int64 position = 1;
96 message AddReplicationPeerRequest {
97 required string peer_id = 1;
98 required ReplicationPeer peer_config = 2;
99 required ReplicationState peer_state = 3;
102 message AddReplicationPeerResponse {
103 optional uint64 proc_id = 1;
106 message RemoveReplicationPeerRequest {
107 required string peer_id = 1;
110 message RemoveReplicationPeerResponse {
111 optional uint64 proc_id = 1;
114 message EnableReplicationPeerRequest {
115 required string peer_id = 1;
118 message EnableReplicationPeerResponse {
119 optional uint64 proc_id = 1;
122 message DisableReplicationPeerRequest {
123 required string peer_id = 1;
126 message DisableReplicationPeerResponse {
127 optional uint64 proc_id = 1;
130 message GetReplicationPeerConfigRequest {
131 required string peer_id = 1;
134 message GetReplicationPeerConfigResponse {
135 required string peer_id = 1;
136 required ReplicationPeer peer_config = 2;
139 message UpdateReplicationPeerConfigRequest {
140 required string peer_id = 1;
141 required ReplicationPeer peer_config = 2;
144 message UpdateReplicationPeerConfigResponse {
145 optional uint64 proc_id = 1;
148 message ListReplicationPeersRequest {
149 optional string regex = 1;
152 message ListReplicationPeersResponse {
153 repeated ReplicationPeerDescription peer_desc = 1;
156 message TransitReplicationPeerSyncReplicationStateRequest {
157 required string peer_id = 1;
158 required SyncReplicationState syncReplicationState = 2;
161 message TransitReplicationPeerSyncReplicationStateResponse {
162 required uint64 proc_id = 1;