@InterfaceAudience.Public public abstract class QuotaSettings extends Object
| Modifier and Type | Field and Description | 
|---|---|
private String | 
namespace  | 
private String | 
regionServer  | 
private TableName | 
tableName  | 
private String | 
userName  | 
| Modifier | Constructor and Description | 
|---|---|
protected  | 
QuotaSettings(String userName,
             TableName tableName,
             String namespace,
             String regionServer)  | 
| Modifier and Type | Method and Description | 
|---|---|
static QuotaSettings | 
buildFromProto(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest request)
Converts the protocol buffer request into a QuotaSetting POJO. 
 | 
static org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest | 
buildSetQuotaRequestProto(QuotaSettings settings)
Convert a QuotaSettings to a protocol buffer SetQuotaRequest. 
 | 
String | 
getNamespace()  | 
abstract QuotaType | 
getQuotaType()  | 
String | 
getRegionServer()  | 
TableName | 
getTableName()  | 
String | 
getUserName()  | 
(package private) abstract QuotaSettings | 
merge(QuotaSettings newSettings)
Merges the provided settings with  
this and returns a new settings
 object to the caller if the merged settings differ from the original. | 
protected String | 
ownerToString()  | 
protected abstract void | 
setupSetQuotaRequest(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest.Builder builder)
Called by toSetQuotaRequestProto()
 the subclass should implement this method to set the specific SetQuotaRequest
 properties. 
 | 
protected static String | 
sizeToString(long size)  | 
protected static String | 
timeToString(TimeUnit timeUnit)  | 
(package private) void | 
validateQuotaTarget(QuotaSettings mergee)
Validates that settings being merged into  
this is targeting the same "subject", e.g. | 
private final String regionServer
protected QuotaSettings(String userName, TableName tableName, String namespace, String regionServer)
public abstract QuotaType getQuotaType()
public String getUserName()
public TableName getTableName()
public String getNamespace()
public String getRegionServer()
@InterfaceAudience.Private public static QuotaSettings buildFromProto(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest request)
request - The protocol buffer request.QuotaSettings POJO.@InterfaceAudience.Private public static org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest buildSetQuotaRequestProto(QuotaSettings settings)
@InterfaceAudience.Private protected abstract void setupSetQuotaRequest(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProtos.SetQuotaRequest.Builder builder)
protected String ownerToString()
protected static String sizeToString(long size)
protected static String timeToString(TimeUnit timeUnit)
abstract QuotaSettings merge(QuotaSettings newSettings) throws IOException
this and returns a new settings
 object to the caller if the merged settings differ from the original.newSettings - The new settings to merge in.QuotaSettings object or null if the quota should be deleted.IOExceptionvoid validateQuotaTarget(QuotaSettings mergee)
this is targeting the same "subject", e.g.
 user, table, namespace.mergee - The quota settings to be merged into this.IllegalArgumentException - if the subjects are not equal.Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.