@InterfaceAudience.Private public final class ClusterMetricsBuilder extends Object
Modifier and Type | Class and Description |
---|---|
private static class |
ClusterMetricsBuilder.ClusterMetricsImpl |
Modifier and Type | Field and Description |
---|---|
private List<ServerName> |
backupMasterNames |
private Boolean |
balancerOn |
private String |
clusterId |
private List<ServerName> |
deadServerNames |
private String |
hbaseVersion |
private Map<ServerName,ServerMetrics> |
liveServerMetrics |
private List<String> |
masterCoprocessorNames |
private int |
masterInfoPort |
private ServerName |
masterName |
private List<RegionState> |
regionsInTransition |
private List<ServerName> |
serversName |
private Map<TableName,RegionStatesCount> |
tableRegionStatesCount |
Modifier | Constructor and Description |
---|---|
private |
ClusterMetricsBuilder() |
Modifier and Type | Method and Description |
---|---|
ClusterMetrics |
build() |
static ClusterMetricsBuilder |
newBuilder() |
ClusterMetricsBuilder |
setBackerMasterNames(List<ServerName> value) |
ClusterMetricsBuilder |
setBalancerOn(Boolean value) |
ClusterMetricsBuilder |
setClusterId(String value) |
ClusterMetricsBuilder |
setDeadServerNames(List<ServerName> value) |
ClusterMetricsBuilder |
setHBaseVersion(String value) |
ClusterMetricsBuilder |
setLiveServerMetrics(Map<ServerName,ServerMetrics> value) |
ClusterMetricsBuilder |
setMasterCoprocessorNames(List<String> value) |
ClusterMetricsBuilder |
setMasterInfoPort(int value) |
ClusterMetricsBuilder |
setMasterName(ServerName value) |
ClusterMetricsBuilder |
setRegionsInTransition(List<RegionState> value) |
ClusterMetricsBuilder |
setServerNames(List<ServerName> serversName) |
ClusterMetricsBuilder |
setTableRegionStatesCount(Map<TableName,RegionStatesCount> tableRegionStatesCount) |
static ClusterMetrics |
toClusterMetrics(org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.ClusterStatus proto) |
static org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.ClusterStatus |
toClusterStatus(ClusterMetrics metrics) |
static org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option |
toOption(ClusterMetrics.Option option)
Convert ClusterMetrics.Option to ClusterStatusProtos.Option
|
static ClusterMetrics.Option |
toOption(org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option option)
Convert ClusterStatusProtos.Option to ClusterMetrics.Option
|
static List<org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option> |
toOptions(EnumSet<ClusterMetrics.Option> options)
Convert an enum set of ClusterMetrics.Option to a list of ClusterStatusProtos.Option
|
static EnumSet<ClusterMetrics.Option> |
toOptions(List<org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option> options)
Convert a list of ClusterStatusProtos.Option to an enum set of ClusterMetrics.Option
|
@Nullable private String hbaseVersion
private List<ServerName> deadServerNames
private Map<ServerName,ServerMetrics> liveServerMetrics
@Nullable private ServerName masterName
private List<ServerName> backupMasterNames
private List<RegionState> regionsInTransition
private List<String> masterCoprocessorNames
@Nullable private Boolean balancerOn
private int masterInfoPort
private List<ServerName> serversName
private Map<TableName,RegionStatesCount> tableRegionStatesCount
private ClusterMetricsBuilder()
public static org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.ClusterStatus toClusterStatus(ClusterMetrics metrics)
public static ClusterMetrics toClusterMetrics(org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.ClusterStatus proto)
public static ClusterMetrics.Option toOption(org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option option)
option
- a ClusterStatusProtos.Optionpublic static org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option toOption(ClusterMetrics.Option option)
option
- a ClusterMetrics.Optionpublic static EnumSet<ClusterMetrics.Option> toOptions(List<org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option> options)
options
- the pb optionspublic static List<org.apache.hadoop.hbase.shaded.protobuf.generated.ClusterStatusProtos.Option> toOptions(EnumSet<ClusterMetrics.Option> options)
options
- the ClusterMetrics optionspublic static ClusterMetricsBuilder newBuilder()
public ClusterMetricsBuilder setHBaseVersion(String value)
public ClusterMetricsBuilder setDeadServerNames(List<ServerName> value)
public ClusterMetricsBuilder setLiveServerMetrics(Map<ServerName,ServerMetrics> value)
public ClusterMetricsBuilder setMasterName(ServerName value)
public ClusterMetricsBuilder setBackerMasterNames(List<ServerName> value)
public ClusterMetricsBuilder setRegionsInTransition(List<RegionState> value)
public ClusterMetricsBuilder setClusterId(String value)
public ClusterMetricsBuilder setMasterCoprocessorNames(List<String> value)
public ClusterMetricsBuilder setBalancerOn(@Nullable Boolean value)
public ClusterMetricsBuilder setMasterInfoPort(int value)
public ClusterMetricsBuilder setServerNames(List<ServerName> serversName)
public ClusterMetricsBuilder setTableRegionStatesCount(Map<TableName,RegionStatesCount> tableRegionStatesCount)
public ClusterMetrics build()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.