Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id 76897200C29 for ; Tue, 24 Jan 2017 00:01:44 +0100 (CET) Received: by cust-asf.ponee.io (Postfix) id 7537C160B60; Mon, 23 Jan 2017 23:01:44 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 93BCD160B5E for ; Tue, 24 Jan 2017 00:01:42 +0100 (CET) Received: (qmail 14128 invoked by uid 500); 23 Jan 2017 23:01:38 -0000 Mailing-List: contact commits-help@hbase.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@hbase.apache.org Delivered-To: mailing list commits@hbase.apache.org Received: (qmail 10763 invoked by uid 99); 23 Jan 2017 23:01:36 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 23 Jan 2017 23:01:36 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 07570DFCCC; Mon, 23 Jan 2017 23:01:36 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: elserj@apache.org To: commits@hbase.apache.org Date: Mon, 23 Jan 2017 23:02:19 -0000 Message-Id: <7494562cc2324177bccae5af294793a8@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [46/50] [abbrv] hbase git commit: HBASE-16995 Build client Java API and client protobuf messages (Josh Elser) archived-at: Mon, 23 Jan 2017 23:01:44 -0000 HBASE-16995 Build client Java API and client protobuf messages (Josh Elser) Project: http://git-wip-us.apache.org/repos/asf/hbase/repo Commit: http://git-wip-us.apache.org/repos/asf/hbase/commit/df2916fc Tree: http://git-wip-us.apache.org/repos/asf/hbase/tree/df2916fc Diff: http://git-wip-us.apache.org/repos/asf/hbase/diff/df2916fc Branch: refs/heads/HBASE-16961 Commit: df2916fc2bc4cd55401d15ee4b069b7a17cefd64 Parents: 980c8c2 Author: tedyu Authored: Thu Nov 17 10:19:52 2016 -0800 Committer: Josh Elser Committed: Mon Jan 23 17:48:59 2017 -0500 ---------------------------------------------------------------------- .../hbase/quotas/QuotaSettingsFactory.java | 47 + .../apache/hadoop/hbase/quotas/QuotaType.java | 1 + .../hadoop/hbase/quotas/SpaceLimitSettings.java | 166 ++ .../hbase/quotas/SpaceViolationPolicy.java | 44 + .../hbase/shaded/protobuf/ProtobufUtil.java | 51 + .../hbase/quotas/TestQuotaSettingsFactory.java | 148 ++ .../hbase/quotas/TestSpaceLimitSettings.java | 119 ++ .../shaded/protobuf/generated/MasterProtos.java | 570 ++++-- .../shaded/protobuf/generated/QuotaProtos.java | 1739 +++++++++++++++++- .../src/main/protobuf/Master.proto | 2 + .../src/main/protobuf/Quota.proto | 21 + .../hbase/protobuf/generated/QuotaProtos.java | 1682 ++++++++++++++++- hbase-protocol/src/main/protobuf/Quota.proto | 21 + 13 files changed, 4284 insertions(+), 327 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaSettingsFactory.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaSettingsFactory.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaSettingsFactory.java index a7c49b3..b8e99b8 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaSettingsFactory.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaSettingsFactory.java @@ -28,6 +28,7 @@ import org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRe import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos; import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.Quotas; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceQuota; @InterfaceAudience.Public @InterfaceStability.Evolving @@ -91,6 +92,9 @@ public class QuotaSettingsFactory { if (quotas.getBypassGlobals() == true) { settings.add(new QuotaGlobalsSettingsBypass(userName, tableName, namespace, true)); } + if (quotas.hasSpace()) { + settings.add(fromSpace(tableName, namespace, quotas.getSpace())); + } return settings; } @@ -124,6 +128,18 @@ public class QuotaSettingsFactory { return settings; } + static QuotaSettings fromSpace(TableName table, String namespace, SpaceQuota protoQuota) { + if ((null == table && null == namespace) || (null != table && null != namespace)) { + throw new IllegalArgumentException("Can only construct SpaceLimitSettings for a table or namespace."); + } + if (null != table) { + return SpaceLimitSettings.fromSpaceQuota(table, protoQuota); + } else { + // namespace must be non-null + return SpaceLimitSettings.fromSpaceQuota(namespace, protoQuota); + } + } + /* ========================================================================== * RPC Throttle */ @@ -280,4 +296,35 @@ public class QuotaSettingsFactory { public static QuotaSettings bypassGlobals(final String userName, final boolean bypassGlobals) { return new QuotaGlobalsSettingsBypass(userName, null, null, bypassGlobals); } + + /* ========================================================================== + * FileSystem Space Settings + */ + + /** + * Creates a {@link QuotaSettings} object to limit the FileSystem space usage for the given table to the given size in bytes. + * When the space usage is exceeded by the table, the provided {@link SpaceViolationPolicy} is enacted on the table. + * + * @param tableName The name of the table on which the quota should be applied. + * @param sizeLimit The limit of a table's size in bytes. + * @param violationPolicy The action to take when the quota is exceeded. + * @return An {@link QuotaSettings} object. + */ + public static QuotaSettings limitTableSpace(final TableName tableName, long sizeLimit, final SpaceViolationPolicy violationPolicy) { + return new SpaceLimitSettings(tableName, sizeLimit, violationPolicy); + } + + /** + * Creates a {@link QuotaSettings} object to limit the FileSystem space usage for the given namespace to the given size in bytes. + * When the space usage is exceeded by all tables in the namespace, the provided {@link SpaceViolationPolicy} is enacted on + * all tables in the namespace. + * + * @param namespace The namespace on which the quota should be applied. + * @param sizeLimit The limit of the namespace's size in bytes. + * @param violationPolicy The action to take when the the quota is exceeded. + * @return An {@link QuotaSettings} object. + */ + public static QuotaSettings limitNamespaceSpace(final String namespace, long sizeLimit, final SpaceViolationPolicy violationPolicy) { + return new SpaceLimitSettings(namespace, sizeLimit, violationPolicy); + } } http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaType.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaType.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaType.java index 40a8b66..2c44201 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaType.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/QuotaType.java @@ -28,4 +28,5 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; public enum QuotaType { THROTTLE, GLOBAL_BYPASS, + SPACE, } http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceLimitSettings.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceLimitSettings.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceLimitSettings.java new file mode 100644 index 0000000..dded9b5 --- /dev/null +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceLimitSettings.java @@ -0,0 +1,166 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to you under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.quotas; + +import java.util.Objects; + +import org.apache.hadoop.hbase.TableName; +import org.apache.hadoop.hbase.classification.InterfaceAudience; +import org.apache.hadoop.hbase.classification.InterfaceStability; +import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos; +import org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest.Builder; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceQuota; + +/** + * A {@link QuotaSettings} implementation for implementing filesystem-use quotas. + */ +@InterfaceAudience.Private +@InterfaceStability.Evolving +class SpaceLimitSettings extends QuotaSettings { + + private final SpaceLimitRequest proto; + + SpaceLimitSettings(TableName tableName, long sizeLimit, SpaceViolationPolicy violationPolicy) { + super(null, Objects.requireNonNull(tableName), null); + if (0L > sizeLimit) { + throw new IllegalArgumentException("Size limit must be a non-negative value."); + } + proto = buildProtoQuota(sizeLimit, Objects.requireNonNull(violationPolicy)); + } + + SpaceLimitSettings(String namespace, long sizeLimit, SpaceViolationPolicy violationPolicy) { + super(null, null, Objects.requireNonNull(namespace)); + if (0L > sizeLimit) { + throw new IllegalArgumentException("Size limit must be a non-negative value."); + } + proto = buildProtoQuota(sizeLimit, Objects.requireNonNull(violationPolicy)); + } + + /** + * Builds a {@link SpaceQuota} protobuf object given the arguments. + * + * @param sizeLimit The size limit of the quota. + * @param violationPolicy The action to take when the quota is exceeded. + * @return The protobuf SpaceQuota representation. + */ + private SpaceLimitRequest buildProtoQuota(long sizeLimit, SpaceViolationPolicy violationPolicy) { + return SpaceLimitRequest.newBuilder().setQuota( + SpaceQuota.newBuilder() + .setSoftLimit(sizeLimit) + .setViolationPolicy(ProtobufUtil.toProtoViolationPolicy(violationPolicy)) + .build()) + .build(); + } + + /** + * Returns a copy of the internal state of this + */ + SpaceLimitRequest getProto() { + return proto.toBuilder().build(); + } + + @Override + public QuotaType getQuotaType() { + return QuotaType.SPACE; + } + + @Override + protected void setupSetQuotaRequest(Builder builder) { + // TableName/Namespace are serialized in QuotaSettings + builder.setSpaceLimit(proto); + } + + /** + * Constructs a {@link SpaceLimitSettings} from the provided protobuf message and tablename. + * + * @param tableName The target tablename for the limit. + * @param proto The protobuf representation. + * @return A QuotaSettings. + */ + static SpaceLimitSettings fromSpaceQuota(final TableName tableName, + final QuotaProtos.SpaceQuota proto) { + validateProtoArguments(proto); + return new SpaceLimitSettings(tableName, proto.getSoftLimit(), + ProtobufUtil.toViolationPolicy(proto.getViolationPolicy())); + } + + /** + * Constructs a {@link SpaceLimitSettings} from the provided protobuf message and namespace. + * + * @param namespace The target namespace for the limit. + * @param proto The protobuf representation. + * @return A QuotaSettings. + */ + static SpaceLimitSettings fromSpaceQuota(final String namespace, + final QuotaProtos.SpaceQuota proto) { + validateProtoArguments(proto); + return new SpaceLimitSettings(namespace, proto.getSoftLimit(), + ProtobufUtil.toViolationPolicy(proto.getViolationPolicy())); + } + + /** + * Validates that the provided protobuf SpaceQuota has the necessary information to construct + * a {@link SpaceLimitSettings}. + * + * @param proto The protobuf message to validate. + */ + static void validateProtoArguments(final QuotaProtos.SpaceQuota proto) { + if (!Objects.requireNonNull(proto).hasSoftLimit()) { + throw new IllegalArgumentException("Cannot handle SpaceQuota without a soft limit"); + } + if (!proto.hasViolationPolicy()) { + throw new IllegalArgumentException("Cannot handle SpaceQuota without a violation policy"); + } + } + + @Override + public int hashCode() { + return Objects.hash(getTableName(), getNamespace(), proto); + } + + @Override + public boolean equals(Object o) { + if (o == this) { + return true; + } + if (!(o instanceof SpaceLimitSettings)) { + return false; + } + // o is non-null and an instance of SpaceLimitSettings + SpaceLimitSettings other = (SpaceLimitSettings) o; + return Objects.equals(getTableName(), other.getTableName()) && + Objects.equals(getNamespace(), other.getNamespace()) && + Objects.equals(proto, other.proto); + } + + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("TYPE => SPACE"); + if (null != getTableName()) { + sb.append(", TABLE => ").append(getTableName()); + } + if (null != getNamespace()) { + sb.append(", NAMESPACE => ").append(getNamespace()); + } + sb.append(", LIMIT => ").append(proto.getQuota().getSoftLimit()); + sb.append(", VIOLATION_POLICY => ").append(proto.getQuota().getViolationPolicy()); + return sb.toString(); + } +} http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceViolationPolicy.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceViolationPolicy.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceViolationPolicy.java new file mode 100644 index 0000000..c63acb0 --- /dev/null +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/quotas/SpaceViolationPolicy.java @@ -0,0 +1,44 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to you under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.quotas; + +import org.apache.hadoop.hbase.classification.InterfaceAudience; +import org.apache.hadoop.hbase.classification.InterfaceStability; + +/** + * Enumeration that represents the action HBase will take when a space quota is violated. + */ +@InterfaceAudience.Public +@InterfaceStability.Evolving +public enum SpaceViolationPolicy { + /** + * Disables the table(s). + */ + DISABLE, + /** + * Disallows any mutations or compactions on the table(s). + */ + NO_WRITES_COMPACTIONS, + /** + * Disallows any mutations (but allows compactions) on the table(s). + */ + NO_WRITES, + /** + * Disallows any updates (but allows deletes and compactions) on the table(s). + */ + NO_INSERTS, +} http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ProtobufUtil.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ProtobufUtil.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ProtobufUtil.java index 7764f65..4f18138 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ProtobufUtil.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/ProtobufUtil.java @@ -88,6 +88,7 @@ import org.apache.hadoop.hbase.protobuf.ProtobufMagic; import org.apache.hadoop.hbase.shaded.protobuf.generated.ZooKeeperProtos; import org.apache.hadoop.hbase.quotas.QuotaScope; import org.apache.hadoop.hbase.quotas.QuotaType; +import org.apache.hadoop.hbase.quotas.SpaceViolationPolicy; import org.apache.hadoop.hbase.quotas.ThrottleType; import org.apache.hadoop.hbase.replication.ReplicationLoadSink; import org.apache.hadoop.hbase.replication.ReplicationLoadSource; @@ -2497,6 +2498,7 @@ public final class ProtobufUtil { public static QuotaType toQuotaScope(final QuotaProtos.QuotaType proto) { switch (proto) { case THROTTLE: return QuotaType.THROTTLE; + case SPACE: return QuotaType.SPACE; } throw new RuntimeException("Invalid QuotaType " + proto); } @@ -2510,11 +2512,45 @@ public final class ProtobufUtil { public static QuotaProtos.QuotaType toProtoQuotaScope(final QuotaType type) { switch (type) { case THROTTLE: return QuotaProtos.QuotaType.THROTTLE; + case SPACE: return QuotaProtos.QuotaType.SPACE; } throw new RuntimeException("Invalid QuotaType " + type); } /** + * Converts a protocol buffer SpaceViolationPolicy to a client SpaceViolationPolicy. + * + * @param proto The protocol buffer space violation policy. + * @return The corresponding client SpaceViolationPolicy. + */ + public static SpaceViolationPolicy toViolationPolicy(final QuotaProtos.SpaceViolationPolicy proto) { + switch (proto) { + case DISABLE: return SpaceViolationPolicy.DISABLE; + case NO_WRITES_COMPACTIONS: return SpaceViolationPolicy.NO_WRITES_COMPACTIONS; + case NO_WRITES: return SpaceViolationPolicy.NO_WRITES; + case NO_INSERTS: return SpaceViolationPolicy.NO_INSERTS; + } + throw new RuntimeException("Invalid SpaceViolationPolicy " + proto); + } + + /** + * Converts a client SpaceViolationPolicy to a protocol buffer SpaceViolationPolicy. + * + * @param policy The client SpaceViolationPolicy object. + * @return The corresponding protocol buffer SpaceViolationPolicy. + */ + public static QuotaProtos.SpaceViolationPolicy toProtoViolationPolicy( + final SpaceViolationPolicy policy) { + switch (policy) { + case DISABLE: return QuotaProtos.SpaceViolationPolicy.DISABLE; + case NO_WRITES_COMPACTIONS: return QuotaProtos.SpaceViolationPolicy.NO_WRITES_COMPACTIONS; + case NO_WRITES: return QuotaProtos.SpaceViolationPolicy.NO_WRITES; + case NO_INSERTS: return QuotaProtos.SpaceViolationPolicy.NO_INSERTS; + } + throw new RuntimeException("Invalid SpaceViolationPolicy " + policy); + } + + /** * Build a protocol buffer TimedQuota * * @param limit the allowed number of request/data per timeUnit @@ -2532,6 +2568,21 @@ public final class ProtobufUtil { } /** + * Builds a protocol buffer SpaceQuota. + * + * @param limit The maximum space usage for the quota in bytes. + * @param violationPolicy The policy to apply when the quota is violated. + * @return The protocol buffer SpaceQuota. + */ + public static QuotaProtos.SpaceQuota toProtoSpaceQuota(final long limit, + final SpaceViolationPolicy violationPolicy) { + return QuotaProtos.SpaceQuota.newBuilder() + .setSoftLimit(limit) + .setViolationPolicy(toProtoViolationPolicy(violationPolicy)) + .build(); + } + + /** * Generates a marker for the WAL so that we propagate the notion of a bulk region load * throughout the WAL. * http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestQuotaSettingsFactory.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestQuotaSettingsFactory.java b/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestQuotaSettingsFactory.java new file mode 100644 index 0000000..17015d6 --- /dev/null +++ b/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestQuotaSettingsFactory.java @@ -0,0 +1,148 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to you under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.quotas; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; + +import java.util.List; +import java.util.concurrent.TimeUnit; + +import org.apache.hadoop.hbase.TableName; +import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; +import org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.Quotas; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceQuota; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.Throttle; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.TimedQuota; +import org.apache.hadoop.hbase.testclassification.SmallTests; +import org.junit.Test; +import org.junit.experimental.categories.Category; + +/** + * Test class for {@link QuotaSettingsFactory}. + */ +@Category(SmallTests.class) +public class TestQuotaSettingsFactory { + + @Test + public void testAllQuotasAddedToList() { + final SpaceQuota spaceQuota = SpaceQuota.newBuilder() + .setSoftLimit(1024L * 1024L * 1024L * 50L) // 50G + .setViolationPolicy(QuotaProtos.SpaceViolationPolicy.DISABLE) // Disable the table + .build(); + final long readLimit = 1000; + final long writeLimit = 500; + final Throttle throttle = Throttle.newBuilder() + // 1000 read reqs/min + .setReadNum(TimedQuota.newBuilder().setSoftLimit(readLimit).setTimeUnit(HBaseProtos.TimeUnit.MINUTES).build()) + // 500 write reqs/min + .setWriteNum(TimedQuota.newBuilder().setSoftLimit(writeLimit).setTimeUnit(HBaseProtos.TimeUnit.MINUTES).build()) + .build(); + final Quotas quotas = Quotas.newBuilder() + .setSpace(spaceQuota) // Set the FS quotas + .setThrottle(throttle) // Set some RPC limits + .build(); + final TableName tn = TableName.valueOf("my_table"); + List settings = QuotaSettingsFactory.fromTableQuotas(tn, quotas); + assertEquals(3, settings.size()); + boolean seenRead = false; + boolean seenWrite = false; + boolean seenSpace = false; + for (QuotaSettings setting : settings) { + if (setting instanceof ThrottleSettings) { + ThrottleSettings throttleSettings = (ThrottleSettings) setting; + switch (throttleSettings.getThrottleType()) { + case READ_NUMBER: + assertFalse("Should not have multiple read quotas", seenRead); + assertEquals(readLimit, throttleSettings.getSoftLimit()); + assertEquals(TimeUnit.MINUTES, throttleSettings.getTimeUnit()); + assertEquals(tn, throttleSettings.getTableName()); + assertNull("Username should be null", throttleSettings.getUserName()); + assertNull("Namespace should be null", throttleSettings.getNamespace()); + seenRead = true; + break; + case WRITE_NUMBER: + assertFalse("Should not have multiple write quotas", seenWrite); + assertEquals(writeLimit, throttleSettings.getSoftLimit()); + assertEquals(TimeUnit.MINUTES, throttleSettings.getTimeUnit()); + assertEquals(tn, throttleSettings.getTableName()); + assertNull("Username should be null", throttleSettings.getUserName()); + assertNull("Namespace should be null", throttleSettings.getNamespace()); + seenWrite = true; + break; + default: + fail("Unexpected throttle type: " + throttleSettings.getThrottleType()); + } + } else if (setting instanceof SpaceLimitSettings) { + assertFalse("Should not have multiple space quotas", seenSpace); + SpaceLimitSettings spaceLimit = (SpaceLimitSettings) setting; + assertEquals(tn, spaceLimit.getTableName()); + assertNull("Username should be null", spaceLimit.getUserName()); + assertNull("Namespace should be null", spaceLimit.getNamespace()); + assertTrue("SpaceLimitSettings should have a SpaceQuota", spaceLimit.getProto().hasQuota()); + assertEquals(spaceQuota, spaceLimit.getProto().getQuota()); + seenSpace = true; + } else { + fail("Unexpected QuotaSettings implementation: " + setting.getClass()); + } + } + assertTrue("Should have seen a read quota", seenRead); + assertTrue("Should have seen a write quota", seenWrite); + assertTrue("Should have seen a space quota", seenSpace); + } + + @Test(expected = IllegalArgumentException.class) + public void testNeitherTableNorNamespace() { + final SpaceQuota spaceQuota = SpaceQuota.newBuilder() + .setSoftLimit(1L) + .setViolationPolicy(QuotaProtos.SpaceViolationPolicy.DISABLE) + .build(); + QuotaSettingsFactory.fromSpace(null, null, spaceQuota); + } + + @Test(expected = IllegalArgumentException.class) + public void testBothTableAndNamespace() { + final SpaceQuota spaceQuota = SpaceQuota.newBuilder() + .setSoftLimit(1L) + .setViolationPolicy(QuotaProtos.SpaceViolationPolicy.DISABLE) + .build(); + QuotaSettingsFactory.fromSpace(TableName.valueOf("foo"), "bar", spaceQuota); + } + + @Test + public void testSpaceLimitSettings() { + final TableName tableName = TableName.valueOf("foo"); + final long sizeLimit = 1024L * 1024L * 1024L * 75; // 75GB + final SpaceViolationPolicy violationPolicy = SpaceViolationPolicy.NO_INSERTS; + QuotaSettings settings = QuotaSettingsFactory.limitTableSpace(tableName, sizeLimit, violationPolicy); + assertNotNull("QuotaSettings should not be null", settings); + assertTrue("Should be an instance of SpaceLimitSettings", settings instanceof SpaceLimitSettings); + SpaceLimitSettings spaceLimitSettings = (SpaceLimitSettings) settings; + SpaceLimitRequest protoRequest = spaceLimitSettings.getProto(); + assertTrue("Request should have a SpaceQuota", protoRequest.hasQuota()); + SpaceQuota quota = protoRequest.getQuota(); + assertEquals(sizeLimit, quota.getSoftLimit()); + assertEquals(violationPolicy, ProtobufUtil.toViolationPolicy(quota.getViolationPolicy())); + } +} http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestSpaceLimitSettings.java ---------------------------------------------------------------------- diff --git a/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestSpaceLimitSettings.java b/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestSpaceLimitSettings.java new file mode 100644 index 0000000..77a00da --- /dev/null +++ b/hbase-client/src/test/java/org/apache/hadoop/hbase/quotas/TestSpaceLimitSettings.java @@ -0,0 +1,119 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to you under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.hadoop.hbase.quotas; + +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNotNull; + +import org.apache.hadoop.hbase.TableName; +import org.apache.hadoop.hbase.shaded.protobuf.ProtobufUtil; +import org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest; +import org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceQuota; +import org.apache.hadoop.hbase.testclassification.SmallTests; +import org.junit.Test; +import org.junit.experimental.categories.Category; + +/** + * Test class for {@link SpaceLimitSettings}. + */ +@Category({SmallTests.class}) +public class TestSpaceLimitSettings { + + @Test(expected = IllegalArgumentException.class) + public void testInvalidTableQuotaSizeLimit() { + new SpaceLimitSettings(TableName.valueOf("foo"), -1, SpaceViolationPolicy.NO_INSERTS); + } + + @Test(expected = NullPointerException.class) + public void testNullTableName() { + TableName tn = null; + new SpaceLimitSettings(tn, 1, SpaceViolationPolicy.NO_INSERTS); + } + + @Test(expected = NullPointerException.class) + public void testNullTableViolationPolicy() { + new SpaceLimitSettings(TableName.valueOf("foo"), 1, null); + } + + @Test(expected = IllegalArgumentException.class) + public void testInvalidNamespaceQuotaSizeLimit() { + new SpaceLimitSettings("foo_ns", -1, SpaceViolationPolicy.NO_INSERTS); + } + + @Test(expected = NullPointerException.class) + public void testNullNamespace() { + String ns = null; + new SpaceLimitSettings(ns, 1, SpaceViolationPolicy.NO_INSERTS); + } + + @Test(expected = NullPointerException.class) + public void testNullNamespaceViolationPolicy() { + new SpaceLimitSettings("foo_ns", 1, null); + } + + @Test + public void testTableQuota() { + final TableName tableName = TableName.valueOf("foo"); + final long sizeLimit = 1024 * 1024; + final SpaceViolationPolicy policy = SpaceViolationPolicy.NO_WRITES; + SpaceLimitSettings settings = new SpaceLimitSettings(tableName, sizeLimit, policy); + SetQuotaRequest proto = QuotaSettings.buildSetQuotaRequestProto(settings); + + assertFalse("User should be missing", proto.hasUserName()); + assertFalse("Namespace should be missing", proto.hasNamespace()); + assertEquals(ProtobufUtil.toProtoTableName(tableName), proto.getTableName()); + SpaceLimitRequest spaceLimitReq = proto.getSpaceLimit(); + assertNotNull("SpaceLimitRequest was null", spaceLimitReq); + SpaceQuota spaceQuota = spaceLimitReq.getQuota(); + assertNotNull("SpaceQuota was null", spaceQuota); + assertEquals(sizeLimit, spaceQuota.getSoftLimit()); + assertEquals(ProtobufUtil.toProtoViolationPolicy(policy), spaceQuota.getViolationPolicy()); + + assertEquals(QuotaType.SPACE, settings.getQuotaType()); + + SpaceLimitSettings copy = new SpaceLimitSettings(tableName, sizeLimit, policy); + assertEquals(settings, copy); + assertEquals(settings.hashCode(), copy.hashCode()); + } + + @Test + public void testNamespaceQuota() { + final String namespace = "foo_ns"; + final long sizeLimit = 1024 * 1024; + final SpaceViolationPolicy policy = SpaceViolationPolicy.NO_WRITES; + SpaceLimitSettings settings = new SpaceLimitSettings(namespace, sizeLimit, policy); + SetQuotaRequest proto = QuotaSettings.buildSetQuotaRequestProto(settings); + + assertFalse("User should be missing", proto.hasUserName()); + assertFalse("TableName should be missing", proto.hasTableName()); + assertEquals(namespace, proto.getNamespace()); + SpaceLimitRequest spaceLimitReq = proto.getSpaceLimit(); + assertNotNull("SpaceLimitRequest was null", spaceLimitReq); + SpaceQuota spaceQuota = spaceLimitReq.getQuota(); + assertNotNull("SpaceQuota was null", spaceQuota); + assertEquals(sizeLimit, spaceQuota.getSoftLimit()); + assertEquals(ProtobufUtil.toProtoViolationPolicy(policy), spaceQuota.getViolationPolicy()); + + assertEquals(QuotaType.SPACE, settings.getQuotaType()); + + SpaceLimitSettings copy = new SpaceLimitSettings(namespace, sizeLimit, policy); + assertEquals(settings, copy); + assertEquals(settings.hashCode(), copy.hashCode()); + } +} http://git-wip-us.apache.org/repos/asf/hbase/blob/df2916fc/hbase-protocol-shaded/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/generated/MasterProtos.java ---------------------------------------------------------------------- diff --git a/hbase-protocol-shaded/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/generated/MasterProtos.java b/hbase-protocol-shaded/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/generated/MasterProtos.java index 6a737b8..6305779 100644 --- a/hbase-protocol-shaded/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/generated/MasterProtos.java +++ b/hbase-protocol-shaded/src/main/java/org/apache/hadoop/hbase/shaded/protobuf/generated/MasterProtos.java @@ -59598,6 +59598,19 @@ public final class MasterProtos { * optional .hbase.pb.ThrottleRequest throttle = 7; */ org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.ThrottleRequestOrBuilder getThrottleOrBuilder(); + + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + boolean hasSpaceLimit(); + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest getSpaceLimit(); + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder getSpaceLimitOrBuilder(); } /** * Protobuf type {@code hbase.pb.SetQuotaRequest} @@ -59700,6 +59713,19 @@ public final class MasterProtos { bitField0_ |= 0x00000040; break; } + case 66: { + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder subBuilder = null; + if (((bitField0_ & 0x00000080) == 0x00000080)) { + subBuilder = spaceLimit_.toBuilder(); + } + spaceLimit_ = input.readMessage(org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.PARSER, extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(spaceLimit_); + spaceLimit_ = subBuilder.buildPartial(); + } + bitField0_ |= 0x00000080; + break; + } } } } catch (org.apache.hadoop.hbase.shaded.com.google.protobuf.InvalidProtocolBufferException e) { @@ -59923,6 +59949,27 @@ public final class MasterProtos { return throttle_ == null ? org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.ThrottleRequest.getDefaultInstance() : throttle_; } + public static final int SPACE_LIMIT_FIELD_NUMBER = 8; + private org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest spaceLimit_; + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public boolean hasSpaceLimit() { + return ((bitField0_ & 0x00000080) == 0x00000080); + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest getSpaceLimit() { + return spaceLimit_ == null ? org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.getDefaultInstance() : spaceLimit_; + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder getSpaceLimitOrBuilder() { + return spaceLimit_ == null ? org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.getDefaultInstance() : spaceLimit_; + } + private byte memoizedIsInitialized = -1; public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; @@ -59968,6 +60015,9 @@ public final class MasterProtos { if (((bitField0_ & 0x00000040) == 0x00000040)) { output.writeMessage(7, getThrottle()); } + if (((bitField0_ & 0x00000080) == 0x00000080)) { + output.writeMessage(8, getSpaceLimit()); + } unknownFields.writeTo(output); } @@ -60001,6 +60051,10 @@ public final class MasterProtos { size += org.apache.hadoop.hbase.shaded.com.google.protobuf.CodedOutputStream .computeMessageSize(7, getThrottle()); } + if (((bitField0_ & 0x00000080) == 0x00000080)) { + size += org.apache.hadoop.hbase.shaded.com.google.protobuf.CodedOutputStream + .computeMessageSize(8, getSpaceLimit()); + } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; @@ -60053,6 +60107,11 @@ public final class MasterProtos { result = result && getThrottle() .equals(other.getThrottle()); } + result = result && (hasSpaceLimit() == other.hasSpaceLimit()); + if (hasSpaceLimit()) { + result = result && getSpaceLimit() + .equals(other.getSpaceLimit()); + } result = result && unknownFields.equals(other.unknownFields); return result; } @@ -60094,6 +60153,10 @@ public final class MasterProtos { hash = (37 * hash) + THROTTLE_FIELD_NUMBER; hash = (53 * hash) + getThrottle().hashCode(); } + if (hasSpaceLimit()) { + hash = (37 * hash) + SPACE_LIMIT_FIELD_NUMBER; + hash = (53 * hash) + getSpaceLimit().hashCode(); + } hash = (29 * hash) + unknownFields.hashCode(); memoizedHashCode = hash; return hash; @@ -60210,6 +60273,7 @@ public final class MasterProtos { .alwaysUseFieldBuilders) { getTableNameFieldBuilder(); getThrottleFieldBuilder(); + getSpaceLimitFieldBuilder(); } } public Builder clear() { @@ -60236,6 +60300,12 @@ public final class MasterProtos { throttleBuilder_.clear(); } bitField0_ = (bitField0_ & ~0x00000040); + if (spaceLimitBuilder_ == null) { + spaceLimit_ = null; + } else { + spaceLimitBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000080); return this; } @@ -60296,6 +60366,14 @@ public final class MasterProtos { } else { result.throttle_ = throttleBuilder_.build(); } + if (((from_bitField0_ & 0x00000080) == 0x00000080)) { + to_bitField0_ |= 0x00000080; + } + if (spaceLimitBuilder_ == null) { + result.spaceLimit_ = spaceLimit_; + } else { + result.spaceLimit_ = spaceLimitBuilder_.build(); + } result.bitField0_ = to_bitField0_; onBuilt(); return result; @@ -60365,6 +60443,9 @@ public final class MasterProtos { if (other.hasThrottle()) { mergeThrottle(other.getThrottle()); } + if (other.hasSpaceLimit()) { + mergeSpaceLimit(other.getSpaceLimit()); + } this.mergeUnknownFields(other.unknownFields); onChanged(); return this; @@ -60930,6 +61011,124 @@ public final class MasterProtos { } return throttleBuilder_; } + + private org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest spaceLimit_ = null; + private org.apache.hadoop.hbase.shaded.com.google.protobuf.SingleFieldBuilderV3< + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder> spaceLimitBuilder_; + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public boolean hasSpaceLimit() { + return ((bitField0_ & 0x00000080) == 0x00000080); + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest getSpaceLimit() { + if (spaceLimitBuilder_ == null) { + return spaceLimit_ == null ? org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.getDefaultInstance() : spaceLimit_; + } else { + return spaceLimitBuilder_.getMessage(); + } + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public Builder setSpaceLimit(org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest value) { + if (spaceLimitBuilder_ == null) { + if (value == null) { + throw new NullPointerException(); + } + spaceLimit_ = value; + onChanged(); + } else { + spaceLimitBuilder_.setMessage(value); + } + bitField0_ |= 0x00000080; + return this; + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public Builder setSpaceLimit( + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder builderForValue) { + if (spaceLimitBuilder_ == null) { + spaceLimit_ = builderForValue.build(); + onChanged(); + } else { + spaceLimitBuilder_.setMessage(builderForValue.build()); + } + bitField0_ |= 0x00000080; + return this; + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public Builder mergeSpaceLimit(org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest value) { + if (spaceLimitBuilder_ == null) { + if (((bitField0_ & 0x00000080) == 0x00000080) && + spaceLimit_ != null && + spaceLimit_ != org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.getDefaultInstance()) { + spaceLimit_ = + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.newBuilder(spaceLimit_).mergeFrom(value).buildPartial(); + } else { + spaceLimit_ = value; + } + onChanged(); + } else { + spaceLimitBuilder_.mergeFrom(value); + } + bitField0_ |= 0x00000080; + return this; + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public Builder clearSpaceLimit() { + if (spaceLimitBuilder_ == null) { + spaceLimit_ = null; + onChanged(); + } else { + spaceLimitBuilder_.clear(); + } + bitField0_ = (bitField0_ & ~0x00000080); + return this; + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder getSpaceLimitBuilder() { + bitField0_ |= 0x00000080; + onChanged(); + return getSpaceLimitFieldBuilder().getBuilder(); + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + public org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder getSpaceLimitOrBuilder() { + if (spaceLimitBuilder_ != null) { + return spaceLimitBuilder_.getMessageOrBuilder(); + } else { + return spaceLimit_ == null ? + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.getDefaultInstance() : spaceLimit_; + } + } + /** + * optional .hbase.pb.SpaceLimitRequest space_limit = 8; + */ + private org.apache.hadoop.hbase.shaded.com.google.protobuf.SingleFieldBuilderV3< + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder> + getSpaceLimitFieldBuilder() { + if (spaceLimitBuilder_ == null) { + spaceLimitBuilder_ = new org.apache.hadoop.hbase.shaded.com.google.protobuf.SingleFieldBuilderV3< + org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequest.Builder, org.apache.hadoop.hbase.shaded.protobuf.generated.QuotaProtos.SpaceLimitRequestOrBuilder>( + getSpaceLimit(), + getParentForChildren(), + isClean()); + spaceLimit_ = null; + } + return spaceLimitBuilder_; + } public final Builder setUnknownFields( final org.apache.hadoop.hbase.shaded.com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); @@ -73729,194 +73928,195 @@ public final class MasterProtos { "edureResponse\022\034\n\024is_procedure_aborted\030\001 " + "\002(\010\"\027\n\025ListProceduresRequest\"@\n\026ListProc" + "eduresResponse\022&\n\tprocedure\030\001 \003(\0132\023.hbas" + - "e.pb.Procedure\"\315\001\n\017SetQuotaRequest\022\021\n\tus" + + "e.pb.Procedure\"\377\001\n\017SetQuotaRequest\022\021\n\tus" + "er_name\030\001 \001(\t\022\022\n\nuser_group\030\002 \001(\t\022\021\n\tnam" + "espace\030\003 \001(\t\022\'\n\ntable_name\030\004 \001(\0132\023.hbase", ".pb.TableName\022\022\n\nremove_all\030\005 \001(\010\022\026\n\016byp" + "ass_globals\030\006 \001(\010\022+\n\010throttle\030\007 \001(\0132\031.hb" + - "ase.pb.ThrottleRequest\"\022\n\020SetQuotaRespon" + - "se\"J\n\037MajorCompactionTimestampRequest\022\'\n" + - "\ntable_name\030\001 \002(\0132\023.hbase.pb.TableName\"U" + - "\n(MajorCompactionTimestampForRegionReque" + - "st\022)\n\006region\030\001 \002(\0132\031.hbase.pb.RegionSpec" + - "ifier\"@\n MajorCompactionTimestampRespons" + - "e\022\034\n\024compaction_timestamp\030\001 \002(\003\"\035\n\033Secur" + - "ityCapabilitiesRequest\"\354\001\n\034SecurityCapab", - "ilitiesResponse\022G\n\014capabilities\030\001 \003(\01621." + - "hbase.pb.SecurityCapabilitiesResponse.Ca" + - "pability\"\202\001\n\nCapability\022\031\n\025SIMPLE_AUTHEN" + - "TICATION\020\000\022\031\n\025SECURE_AUTHENTICATION\020\001\022\021\n" + - "\rAUTHORIZATION\020\002\022\026\n\022CELL_AUTHORIZATION\020\003" + - "\022\023\n\017CELL_VISIBILITY\020\004\"\"\n ListDrainingReg" + - "ionServersRequest\"N\n!ListDrainingRegionS" + - "erversResponse\022)\n\013server_name\030\001 \003(\0132\024.hb" + - "ase.pb.ServerName\"F\n\031DrainRegionServersR" + - "equest\022)\n\013server_name\030\001 \003(\0132\024.hbase.pb.S", - "erverName\"\034\n\032DrainRegionServersResponse\"" + - "P\n#RemoveDrainFromRegionServersRequest\022)" + - "\n\013server_name\030\001 \003(\0132\024.hbase.pb.ServerNam" + - "e\"&\n$RemoveDrainFromRegionServersRespons" + - "e*(\n\020MasterSwitchType\022\t\n\005SPLIT\020\000\022\t\n\005MERG" + - "E\020\0012\2221\n\rMasterService\022e\n\024GetSchemaAlterS" + - "tatus\022%.hbase.pb.GetSchemaAlterStatusReq" + - "uest\032&.hbase.pb.GetSchemaAlterStatusResp" + - "onse\022b\n\023GetTableDescriptors\022$.hbase.pb.G" + - "etTableDescriptorsRequest\032%.hbase.pb.Get", - "TableDescriptorsResponse\022P\n\rGetTableName" + - "s\022\036.hbase.pb.GetTableNamesRequest\032\037.hbas" + - "e.pb.GetTableNamesResponse\022Y\n\020GetCluster" + - "Status\022!.hbase.pb.GetClusterStatusReques" + - "t\032\".hbase.pb.GetClusterStatusResponse\022V\n" + - "\017IsMasterRunning\022 .hbase.pb.IsMasterRunn" + - "ingRequest\032!.hbase.pb.IsMasterRunningRes" + - "ponse\022D\n\tAddColumn\022\032.hbase.pb.AddColumnR" + - "equest\032\033.hbase.pb.AddColumnResponse\022M\n\014D" + - "eleteColumn\022\035.hbase.pb.DeleteColumnReque", - "st\032\036.hbase.pb.DeleteColumnResponse\022M\n\014Mo" + - "difyColumn\022\035.hbase.pb.ModifyColumnReques" + - "t\032\036.hbase.pb.ModifyColumnResponse\022G\n\nMov" + - "eRegion\022\033.hbase.pb.MoveRegionRequest\032\034.h" + - "base.pb.MoveRegionResponse\022\\\n\021MergeTable" + - "Regions\022\".hbase.pb.MergeTableRegionsRequ" + - "est\032#.hbase.pb.MergeTableRegionsResponse" + - "\022M\n\014AssignRegion\022\035.hbase.pb.AssignRegion" + - "Request\032\036.hbase.pb.AssignRegionResponse\022" + - "S\n\016UnassignRegion\022\037.hbase.pb.UnassignReg", - "ionRequest\032 .hbase.pb.UnassignRegionResp" + - "onse\022P\n\rOfflineRegion\022\036.hbase.pb.Offline" + - "RegionRequest\032\037.hbase.pb.OfflineRegionRe" + - "sponse\022J\n\013DeleteTable\022\034.hbase.pb.DeleteT" + - "ableRequest\032\035.hbase.pb.DeleteTableRespon" + - "se\022P\n\rtruncateTable\022\036.hbase.pb.TruncateT" + - "ableRequest\032\037.hbase.pb.TruncateTableResp" + - "onse\022J\n\013EnableTable\022\034.hbase.pb.EnableTab" + - "leRequest\032\035.hbase.pb.EnableTableResponse" + - "\022M\n\014DisableTable\022\035.hbase.pb.DisableTable", - "Request\032\036.hbase.pb.DisableTableResponse\022" + - "J\n\013ModifyTable\022\034.hbase.pb.ModifyTableReq" + - "uest\032\035.hbase.pb.ModifyTableResponse\022J\n\013C" + - "reateTable\022\034.hbase.pb.CreateTableRequest" + - "\032\035.hbase.pb.CreateTableResponse\022A\n\010Shutd" + - "own\022\031.hbase.pb.ShutdownRequest\032\032.hbase.p" + - "b.ShutdownResponse\022G\n\nStopMaster\022\033.hbase" + - ".pb.StopMasterRequest\032\034.hbase.pb.StopMas" + - "terResponse\022h\n\031IsMasterInMaintenanceMode" + - "\022$.hbase.pb.IsInMaintenanceModeRequest\032%", - ".hbase.pb.IsInMaintenanceModeResponse\022>\n" + - "\007Balance\022\030.hbase.pb.BalanceRequest\032\031.hba" + - "se.pb.BalanceResponse\022_\n\022SetBalancerRunn" + - "ing\022#.hbase.pb.SetBalancerRunningRequest" + - "\032$.hbase.pb.SetBalancerRunningResponse\022\\" + - "\n\021IsBalancerEnabled\022\".hbase.pb.IsBalance" + - "rEnabledRequest\032#.hbase.pb.IsBalancerEna" + - "bledResponse\022k\n\026SetSplitOrMergeEnabled\022\'" + - ".hbase.pb.SetSplitOrMergeEnabledRequest\032" + - "(.hbase.pb.SetSplitOrMergeEnabledRespons", - "e\022h\n\025IsSplitOrMergeEnabled\022&.hbase.pb.Is" + - "SplitOrMergeEnabledRequest\032\'.hbase.pb.Is" + - "SplitOrMergeEnabledResponse\022D\n\tNormalize" + - "\022\032.hbase.pb.NormalizeRequest\032\033.hbase.pb." + - "NormalizeResponse\022e\n\024SetNormalizerRunnin" + - "g\022%.hbase.pb.SetNormalizerRunningRequest" + - "\032&.hbase.pb.SetNormalizerRunningResponse" + - "\022b\n\023IsNormalizerEnabled\022$.hbase.pb.IsNor" + - "malizerEnabledRequest\032%.hbase.pb.IsNorma" + - "lizerEnabledResponse\022S\n\016RunCatalogScan\022\037", - ".hbase.pb.RunCatalogScanRequest\032 .hbase." + - "pb.RunCatalogScanResponse\022e\n\024EnableCatal" + - "ogJanitor\022%.hbase.pb.EnableCatalogJanito" + - "rRequest\032&.hbase.pb.EnableCatalogJanitor" + - "Response\022n\n\027IsCatalogJanitorEnabled\022(.hb" + - "ase.pb.IsCatalogJanitorEnabledRequest\032)." + - "hbase.pb.IsCatalogJanitorEnabledResponse" + - "\022^\n\021ExecMasterService\022#.hbase.pb.Coproce" + - "ssorServiceRequest\032$.hbase.pb.Coprocesso" + - "rServiceResponse\022A\n\010Snapshot\022\031.hbase.pb.", - "SnapshotRequest\032\032.hbase.pb.SnapshotRespo" + - "nse\022h\n\025GetCompletedSnapshots\022&.hbase.pb." + - "GetCompletedSnapshotsRequest\032\'.hbase.pb." + - "GetCompletedSnapshotsResponse\022S\n\016DeleteS" + - "napshot\022\037.hbase.pb.DeleteSnapshotRequest" + - "\032 .hbase.pb.DeleteSnapshotResponse\022S\n\016Is" + - "SnapshotDone\022\037.hbase.pb.IsSnapshotDoneRe" + - "quest\032 .hbase.pb.IsSnapshotDoneResponse\022" + - "V\n\017RestoreSnapshot\022 .hbase.pb.RestoreSna" + - "pshotRequest\032!.hbase.pb.RestoreSnapshotR", - "esponse\022P\n\rExecProcedure\022\036.hbase.pb.Exec" + - "ProcedureRequest\032\037.hbase.pb.ExecProcedur" + - "eResponse\022W\n\024ExecProcedureWithRet\022\036.hbas" + - "e.pb.ExecProcedureRequest\032\037.hbase.pb.Exe" + - "cProcedureResponse\022V\n\017IsProcedureDone\022 ." + - "hbase.pb.IsProcedureDoneRequest\032!.hbase." + - "pb.IsProcedureDoneResponse\022V\n\017ModifyName" + - "space\022 .hbase.pb.ModifyNamespaceRequest\032" + - "!.hbase.pb.ModifyNamespaceResponse\022V\n\017Cr" + - "eateNamespace\022 .hbase.pb.CreateNamespace", - "Request\032!.hbase.pb.CreateNamespaceRespon" + - "se\022V\n\017DeleteNamespace\022 .hbase.pb.DeleteN" + - "amespaceRequest\032!.hbase.pb.DeleteNamespa" + - "ceResponse\022k\n\026GetNamespaceDescriptor\022\'.h" + - "base.pb.GetNamespaceDescriptorRequest\032(." + - "hbase.pb.GetNamespaceDescriptorResponse\022" + - "q\n\030ListNamespaceDescriptors\022).hbase.pb.L" + - "istNamespaceDescriptorsRequest\032*.hbase.p" + - "b.ListNamespaceDescriptorsResponse\022\206\001\n\037L" + - "istTableDescriptorsByNamespace\0220.hbase.p", - "b.ListTableDescriptorsByNamespaceRequest" + - "\0321.hbase.pb.ListTableDescriptorsByNamesp" + - "aceResponse\022t\n\031ListTableNamesByNamespace" + - "\022*.hbase.pb.ListTableNamesByNamespaceReq" + - "uest\032+.hbase.pb.ListTableNamesByNamespac" + - "eResponse\022P\n\rGetTableState\022\036.hbase.pb.Ge" + - "tTableStateRequest\032\037.hbase.pb.GetTableSt" + - "ateResponse\022A\n\010SetQuota\022\031.hbase.pb.SetQu" + - "otaRequest\032\032.hbase.pb.SetQuotaResponse\022x" + - "\n\037getLastMajorCompactionTimestamp\022).hbas", - "e.pb.MajorCompactionTimestampRequest\032*.h" + - "base.pb.MajorCompactionTimestampResponse" + - "\022\212\001\n(getLastMajorCompactionTimestampForR" + - "egion\0222.hbase.pb.MajorCompactionTimestam" + - "pForRegionRequest\032*.hbase.pb.MajorCompac" + - "tionTimestampResponse\022_\n\022getProcedureRes" + - "ult\022#.hbase.pb.GetProcedureResultRequest" + - "\032$.hbase.pb.GetProcedureResultResponse\022h" + - "\n\027getSecurityCapabilities\022%.hbase.pb.Sec" + - "urityCapabilitiesRequest\032&.hbase.pb.Secu", - "rityCapabilitiesResponse\022S\n\016AbortProcedu" + - "re\022\037.hbase.pb.AbortProcedureRequest\032 .hb" + - "ase.pb.AbortProcedureResponse\022S\n\016ListPro" + - "cedures\022\037.hbase.pb.ListProceduresRequest" + - "\032 .hbase.pb.ListProceduresResponse\022_\n\022Ad" + - "dReplicationPeer\022#.hbase.pb.AddReplicati" + - "onPeerRequest\032$.hbase.pb.AddReplicationP" + - "eerResponse\022h\n\025RemoveReplicationPeer\022&.h" + - "base.pb.RemoveReplicationPeerRequest\032\'.h" + - "base.pb.RemoveReplicationPeerResponse\022h\n", - "\025EnableReplicationPeer\022&.hbase.pb.Enable" + - "ReplicationPeerRequest\032\'.hbase.pb.Enable" + - "ReplicationPeerResponse\022k\n\026DisableReplic" + - "ationPeer\022\'.hbase.pb.DisableReplicationP" + - "eerRequest\032(.hbase.pb.DisableReplication" + - "PeerResponse\022q\n\030GetReplicationPeerConfig" + - "\022).hbase.pb.GetReplicationPeerConfigRequ" + - "est\032*.hbase.pb.GetReplicationPeerConfigR" + - "esponse\022z\n\033UpdateReplicationPeerConfig\022," + - ".hbase.pb.UpdateReplicationPeerConfigReq", - "uest\032-.hbase.pb.UpdateReplicationPeerCon" + - "figResponse\022e\n\024ListReplicationPeers\022%.hb" + - "ase.pb.ListReplicationPeersRequest\032&.hba" + - "se.pb.ListReplicationPeersResponse\022t\n\031li" + - "stDrainingRegionServers\022*.hbase.pb.ListD" + - "rainingRegionServersRequest\032+.hbase.pb.L" + - "istDrainingRegionServersResponse\022_\n\022drai" + - "nRegionServers\022#.hbase.pb.DrainRegionSer" + - "versRequest\032$.hbase.pb.DrainRegionServer" + - "sResponse\022}\n\034removeDrainFromRegionServer", - "s\022-.hbase.pb.RemoveDrainFromRegionServer" + - "sRequest\032..hbase.pb.RemoveDrainFromRegio" + - "nServersResponseBI\n1org.apache.hadoop.hb" + - "ase.shaded.protobuf.generatedB\014MasterPro" + - "tosH\001\210\001\001\240\001\001" + "ase.pb.ThrottleRequest\0220\n\013space_limit\030\010 " + + "\001(\0132\033.hbase.pb.SpaceLimitRequest\"\022\n\020SetQ" + + "uotaResponse\"J\n\037MajorCompactionTimestamp" + + "Request\022\'\n\ntable_name\030\001 \002(\0132\023.hbase.pb.T" + + "ableName\"U\n(MajorCompactionTimestampForR" + + "egionRequest\022)\n\006region\030\001 \002(\0132\031.hbase.pb." + + "RegionSpecifier\"@\n MajorCompactionTimest" + + "ampResponse\022\034\n\024compaction_timestamp\030\001 \002(", + "\003\"\035\n\033SecurityCapabilitiesRequest\"\354\001\n\034Sec" + + "urityCapabilitiesResponse\022G\n\014capabilitie" + + "s\030\001 \003(\01621.hbase.pb.SecurityCapabilitiesR" + + "esponse.Capability\"\202\001\n\nCapability\022\031\n\025SIM" + + "PLE_AUTHENTICATION\020\000\022\031\n\025SECURE_AUTHENTIC" + + "ATION\020\001\022\021\n\rAUTHORIZATION\020\002\022\026\n\022CELL_AUTHO" + + "RIZATION\020\003\022\023\n\017CELL_VISIBILITY\020\004\"\"\n ListD" + + "rainingRegionServersRequest\"N\n!ListDrain" + + "ingRegionServersResponse\022)\n\013server_name\030" + + "\001 \003(\0132\024.hbase.pb.ServerName\"F\n\031DrainRegi", + "onServersRequest\022)\n\013server_name\030\001 \003(\0132\024." + + "hbase.pb.ServerName\"\034\n\032DrainRegionServer" + + "sResponse\"P\n#RemoveDrainFromRegionServer" + + "sRequest\022)\n\013server_name\030\001 \003(\0132\024.hbase.pb" + + ".ServerName\"&\n$RemoveDrainFromRegionServ" + + "ersResponse*(\n\020MasterSwitchType\022\t\n\005SPLIT" + + "\020\000\022\t\n\005MERGE\020\0012\2221\n\rMasterService\022e\n\024GetSc" + + "hemaAlterStatus\022%.hbase.pb.GetSchemaAlte" + + "rStatusRequest\032&.hbase.pb.GetSchemaAlter" + + "StatusResponse\022b\n\023GetTableDescriptors\022$.", + "hbase.pb.GetTableDescriptorsRequest\032%.hb" + + "ase.pb.GetTableDescriptorsResponse\022P\n\rGe" + + "tTableNames\022\036.hbase.pb.GetTableNamesRequ" + + "est\032\037.hbase.pb.GetTableNamesResponse\022Y\n\020" + + "GetClusterStatus\022!.hbase.pb.GetClusterSt" + + "atusRequest\032\".hbase.pb.GetClusterStatusR" + + "esponse\022V\n\017IsMasterRunning\022 .hbase.pb.Is" + + "MasterRunningRequest\032!.hbase.pb.IsMaster" + + "RunningResponse\022D\n\tAddColumn\022\032.hbase.pb." + + "AddColumnRequest\032\033.hbase.pb.AddColumnRes", + "ponse\022M\n\014DeleteColumn\022\035.hbase.pb.DeleteC" + + "olumnRequest\032\036.hbase.pb.DeleteColumnResp" + + "onse\022M\n\014ModifyColumn\022\035.hbase.pb.ModifyCo" + + "lumnRequest\032\036.hbase.pb.ModifyColumnRespo" + + "nse\022G\n\nMoveRegion\022\033.hbase.pb.MoveRegionR" + + "equest\032\034.hbase.pb.MoveRegionResponse\022\\\n\021" + + "MergeTableRegions\022\".hbase.pb.MergeTableR" + + "egionsRequest\032#.hbase.pb.MergeTableRegio" + + "nsResponse\022M\n\014AssignRegion\022\035.hbase.pb.As" + + "signRegionRequest\032\036.hbase.pb.AssignRegio", + "nResponse\022S\n\016UnassignRegion\022\037.hbase.pb.U" + + "nassignRegionRequest\032 .hbase.pb.Unassign" + + "RegionResponse\022P\n\rOfflineRegion\022\036.hbase." + + "pb.OfflineRegionRequest\032\037.hbase.pb.Offli" + + "neRegionResponse\022J\n\013DeleteTable\022\034.hbase." + + "pb.DeleteTableRequest\032\035.hbase.pb.DeleteT" + + "ableResponse\022P\n\rtruncateTable\022\036.hbase.pb" + + ".TruncateTableRequest\032\037.hbase.pb.Truncat" + + "eTableResponse\022J\n\013EnableTable\022\034.hbase.pb" + + ".EnableTableRequest\032\035.hbase.pb.EnableTab", + "leResponse\022M\n\014DisableTable\022\035.hbase.pb.Di" + + "sableTableRequest\032\036.hbase.pb.DisableTabl" + + "eResponse\022J\n\013ModifyTable\022\034.hbase.pb.Modi" + + "fyTableRequest\032\035.hbase.pb.ModifyTableRes" + + "ponse\022J\n\013CreateTable\022\034.hbase.pb.CreateTa" + + "bleRequest\032\035.hbase.pb.CreateTableRespons" + + "e\022A\n\010Shutdown\022\031.hbase.pb.ShutdownRequest" + + "\032\032.hbase.pb.ShutdownResponse\022G\n\nStopMast" + + "er\022\033.hbase.pb.StopMasterRequest\032\034.hbase." + + "pb.StopMasterResponse\022h\n\031IsMasterInMaint", + "enanceMode\022$.hbase.pb.IsInMaintenanceMod" + + "eRequest\032%.hbase.pb.IsInMaintenanceModeR" + + "esponse\022>\n\007Balance\022\030.hbase.pb.BalanceReq" + + "uest\032\031.hbase.pb.BalanceResponse\022_\n\022SetBa" + + "lancerRunning\022#.hbase.pb.SetBalancerRunn" + + "ingRequest\032$.hbase.pb.SetBalancerRunning" + + "Response\022\\\n\021IsBalancerEnabled\022\".hbase.pb" + + ".IsBalancerEnabledRequest\032#.hbase.pb.IsB" + + "alancerEnabledResponse\022k\n\026SetSplitOrMerg" + + "eEnabled\022\'.hbase.pb.SetSplitOrMergeEnabl", + "edRequest\032(.hbase.pb.SetSplitOrMergeEnab" + + "ledResponse\022h\n\025IsSplitOrMergeEnabled\022&.h" + + "base.pb.IsSplitOrMergeEnabledRequest\032\'.h" + + "base.pb.IsSplitOrMergeEnabledResponse\022D\n" + + "\tNormalize\022\032.hbase.pb.NormalizeRequest\032\033" + + ".hbase.pb.NormalizeResponse\022e\n\024SetNormal" + + "izerRunning\022%.hbase.pb.SetNormalizerRunn" + + "ingRequest\032&.hbase.pb.SetNormalizerRunni" + + "ngResponse\022b\n\023IsNormalizerEnabled\022$.hbas" + + "e.pb.IsNormalizerEnabledRequest\032%.hbase.", + "pb.IsNormalizerEnabledResponse\022S\n\016RunCat" + + "alogScan\022\037.hbase.pb.RunCatalogScanReques" + + "t\032 .hbase.pb.RunCatalogScanResponse\022e\n\024E" + + "nableCatalogJanitor\022%.hbase.pb.EnableCat" + + "alogJanitorRequest\032&.hbase.pb.EnableCata" + + "logJanitorResponse\022n\n\027IsCatalogJanitorEn" + + "abled\022(.hbase.pb.IsCatalogJanitorEnabled" + + "Request\032).hbase.pb.IsCatalogJanitorEnabl" + + "edResponse\022^\n\021ExecMasterService\022#.hbase." + + "pb.CoprocessorServiceRequest\032$.hbase.pb.", + "CoprocessorServiceResponse\022A\n\010Snapshot\022\031" + + ".hbase.pb.SnapshotRequest\032\032.hbase.pb.Sna" + + "pshotResponse\022h\n\025GetCompletedSnapshots\022&" + + ".hbase.pb.GetCompletedSnapshotsRequest\032\'" + + ".hbase.pb.GetCompletedSnapshotsResponse\022" + + "S\n\016DeleteSnapshot\022\037.hbase.pb.DeleteSnaps" + + "hotRequest\032 .hbase.pb.DeleteSnapshotResp" + + "onse\022S\n\016IsSnapshotDone\022\037.hbase.pb.IsSnap" + + "shotDoneRequest\032 .hbase.pb.IsSnapshotDon" + + "eResponse\022V\n\017RestoreSnapshot\022 .hbase.pb.", + "RestoreSnapshotRequest\032!.hbase.pb.Restor" + + "eSnapshotResponse\022P\n\rExecProcedure\022\036.hba" + + "se.pb.ExecProcedureRequest\032\037.hbase.pb.Ex" + + "ecProcedureResponse\022W\n\024ExecProcedureWith" + + "Ret\022\036.hbase.pb.ExecProcedureRequest\032\037.hb" + + "ase.pb.ExecProcedureResponse\022V\n\017IsProced" + + "ureDone\022 .hbase.pb.IsProcedureDoneReques" + + "t\032!.hbase.pb.IsProcedureDoneResponse\022V\n\017" + + "ModifyNamespace\022 .hbase.pb.ModifyNamespa" + + "ceRequest\032!.hbase.pb.ModifyNamespaceResp", + "onse\022V\n\017CreateNamespace\022 .hbase.pb.Creat" + + "eNamespaceRequest\032!.hbase.pb.CreateNames" + + "paceResponse\022V\n\017DeleteNamespace\022 .hbase." + + "pb.DeleteNamespaceRequest\032!.hbase.pb.Del" + + "eteNamespaceResponse\022k\n\026GetNamespaceDesc" + + "riptor\022\'.hbase.pb.GetNamespaceDescriptor" + + "Request\032(.hbase.pb.GetNamespaceDescripto" + + "rResponse\022q\n\030ListNamespaceDescriptors\022)." + + "hbase.pb.ListNamespaceDescriptorsRequest" + + "\032*.hbase.pb.ListNamespaceDescriptorsResp", + "onse\022\206\001\n\037ListTableDescriptorsByNamespace" + + "\0220.hbase.pb.ListTableDescriptorsByNamesp" + + "aceRequest\0321.hbase.pb.ListTableDescripto" + + "rsByNamespaceResponse\022t\n\031ListTableNamesB" + + "yNamespace\022*.hbase.pb.ListTableNamesByNa" + + "mespaceRequest\032+.hbase.pb.ListTableNames" + + "ByNamespaceResponse\022P\n\rGetTableState\022\036.h" + + "base.pb.GetTableStateRequest\032\037.hbase.pb." + + "GetTableStateResponse\022A\n\010SetQuota\022\031.hbas" + + "e.pb.SetQuotaRequest\032\032.hbase.pb.SetQuota", + "Response\022x\n\037getLastMajorCompactionTimest" + + "amp\022).hbase.pb.MajorCompactionTimestampR" + + "equest\032*.hbase.pb.MajorCompactionTimesta" + + "mpResponse\022\212\001\n(getLastMajorCompactionTim" + + "estampForRegion\0222.hbase.pb.MajorCompacti" + + "onTimestampForRegionRequest\032*.hbase.pb.M" + + "ajorCompactionTimestampResponse\022_\n\022getPr" + + "ocedureResult\022#.hbase.pb.GetProcedureRes" + + "ultRequest\032$.hbase.pb.GetProcedureResult" + + "Response\022h\n\027getSecurityCapabilities\022%.hb", + "ase.pb.SecurityCapabilitiesRequest\032&.hba" + + "se.pb.SecurityCapabilitiesResponse\022S\n\016Ab" + + "ortProcedure\022\037.hbase.pb.AbortProcedureRe" + + "quest\032 .hbase.pb.AbortProcedureResponse\022" + + "S\n\016ListProcedures\022\037.hbase.pb.ListProcedu" + + "resRequest\032 .hbase.pb.ListProceduresResp" + + "onse\022_\n\022AddReplicationPeer\022#.hbase.pb.Ad" + + "dReplicationPeerRequest\032$.hbase.pb.AddRe" + + "plicationPeerResponse\022h\n\025RemoveReplicati" + + "onPeer\022&.hbase.pb.RemoveReplicationPeerR", + "equest\032\'.hbase.pb.RemoveReplicationPeerR" + + "esponse\022h\n\025EnableReplicationPeer\022&.hbase" + + ".pb.EnableReplicationPeerRequest\032\'.hbase" + + ".pb.EnableReplicationPeerResponse\022k\n\026Dis" + + "ableReplicationPeer\022\'.hbase.pb.DisableRe" + + "plicationPeerRequest\032(.hbase.pb.DisableR" + + "eplicationPeerResponse\022q\n\030GetReplication" + + "PeerConfig\022).hbase.pb.GetReplicationPeer" + + "ConfigRequest\032*.hbase.pb.GetReplicationP" + + "eerConfigResponse\022z\n\033UpdateReplicationPe", + "erConfig\022,.hbase.pb.UpdateReplicationPee" + + "rConfigRequest\032-.hbase.pb.UpdateReplicat" + + "ionPeerConfigResponse\022e\n\024ListReplication" + + "Peers\022%.hbase.pb.ListReplicationPeersReq" + + "uest\032&.hbase.pb.ListReplicationPeersResp" + + "onse\022t\n\031listDrainingRegionServers\022*.hbas" + + "e.pb.ListDrainingRegionServersRequest\032+." + + "hbase.pb.ListDrainingRegionServersRespon" + + "se\022_\n\022drainRegionServers\022#.hbase.pb.Drai" + + "nRegionServersRequest\032$.hbase.pb.DrainRe", + "gionServersResponse\022}\n\034removeDrainFromRe" + + "gionServers\022-.hbase.pb.RemoveDrainFromRe" + + "gionServersRequest\032..hbase.pb.RemoveDrai" + + "nFromRegionServersResponseBI\n1org.apache" + + ".hadoop.hbase.shaded.protobuf.generatedB" + + "\014MasterProtosH\001\210\001\001\240\001\001" }; org.apache.hadoop.hbase.shaded.com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = new org.apache.hadoop.hbase.shaded.com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { @@ -74566,7 +74766,7 @@ public final class MasterProtos { internal_static_hbase_pb_SetQuotaRequest_fieldAccessorTable = new org.apache.hadoop.hbase.shaded.com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( internal_static_hbase_pb_SetQuotaRequest_descriptor, - new java.lang.String[] { "UserName", "UserGroup", "Namespace", "TableName", "RemoveAll", "BypassGlobals", "Throttle", }); + new java.lang.String[] { "UserName", "UserGroup", "Namespace", "TableName", "RemoveAll", "BypassGlobals", "Throttle", "SpaceLimit", }); internal_static_hbase_pb_SetQuotaResponse_descriptor = getDescriptor().getMessageTypes().get(105); internal_static_hbase_pb_SetQuotaResponse_fieldAccessorTable = new