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.
20 // ZNode data in hbase are serialized protobufs with a four byte
21 // 'magic' 'PBUF' prefix.
24 option java_package = "org.apache.hadoop.hbase.shaded.protobuf.generated";
25 option java_outer_classname = "ZooKeeperProtos";
26 option java_generic_services = true;
27 option java_generate_equals_and_hash = true;
28 option optimize_for = SPEED;
31 import "ClusterStatus.proto";
34 * Content of the meta-region-server znode.
36 message MetaRegionServer {
37 // The ServerName hosting the meta region currently, or destination server,
38 // if meta region is in transition.
39 required ServerName server = 1;
40 // The major version of the rpc the server speaks. This is used so that
41 // clients connecting to the cluster can have prior knowledge of what version
42 // to send to a RegionServer. AsyncHBase will use this to detect versions.
43 optional uint32 rpc_version = 2;
45 // State of the region transition. OPEN means fully operational 'hbase:meta'
46 optional RegionState.State state = 3;
50 * Content of the master znode.
53 // The ServerName of the current Master
54 required ServerName master = 1;
55 // Major RPC version so that clients can know what version the master can accept.
56 optional uint32 rpc_version = 2;
57 optional uint32 info_port = 3;
61 * Content of the '/hbase/running', cluster state, znode.
64 // If this znode is present, cluster is up. Currently
65 // the data is cluster start_date.
66 required string start_date = 1;
70 * WAL SplitLog directory znodes have this for content. Used doing distributed
71 * WAL splitting. Holds current state and name of server that originated split.
73 message SplitLogTask {
81 required State state = 1;
82 required ServerName server_name = 2;
83 // optional RecoveryMode DEPRECATED_mode = 3 [default = UNKNOWN];
87 * The znode that holds state of table.
88 * Deprected, table state is stored in hbase:meta since 2.0.0.
90 message DeprecatedTableState {
91 // Table's current state
98 // This is the table's state. If no znode for a table,
99 // its state is presumed enabled. See o.a.h.h.zookeeper.ZKTable class
101 required State state = 1 [default = ENABLED];
105 * State of the switch.
107 message SwitchState {
108 optional bool enabled = 1;