HBASE-24381 The Size metrics in Master Webui is wrong if the size is 0 (#1723)
This commit is contained in:
parent
15627bb722
commit
61efb6d5ad
|
@ -171,10 +171,10 @@ if (master.getServerManager() != null) {
|
|||
</tr>
|
||||
<%java>
|
||||
final String ZEROMB = "0 MB";
|
||||
for (RSGroupInfo rsGroupInfo: rsGroupInfos) {
|
||||
String usedHeapStr = ZEROMB;
|
||||
String maxHeapStr = ZEROMB;
|
||||
String memstoreSizeStr = ZEROMB;
|
||||
for (RSGroupInfo rsGroupInfo: rsGroupInfos) {
|
||||
String rsGroupName = rsGroupInfo.getName();
|
||||
long usedHeap = 0;
|
||||
long maxHeap = 0;
|
||||
|
@ -275,11 +275,11 @@ if (master.getServerManager() != null) {
|
|||
<%java>
|
||||
final String ZEROKB = "0 KB";
|
||||
final String ZEROMB = "0 MB";
|
||||
for (RSGroupInfo rsGroupInfo: rsGroupInfos) {
|
||||
String uncompressedStorefileSizeStr = ZEROMB;
|
||||
String storefileSizeStr = ZEROMB;
|
||||
String indexSizeStr = ZEROKB;
|
||||
String bloomSizeStr = ZEROKB;
|
||||
for (RSGroupInfo rsGroupInfo: rsGroupInfos) {
|
||||
String rsGroupName = rsGroupInfo.getName();
|
||||
int numStores = 0;
|
||||
long numStorefiles = 0;
|
||||
|
|
|
@ -162,10 +162,10 @@ Arrays.sort(serverNames);
|
|||
<tbody>
|
||||
<%java>
|
||||
final String ZEROMB = "0 MB";
|
||||
for (ServerName serverName: serverNames) {
|
||||
String usedHeapStr = ZEROMB;
|
||||
String maxHeapStr = ZEROMB;
|
||||
String memStoreSizeMBStr = ZEROMB;
|
||||
for (ServerName serverName: serverNames) {
|
||||
ServerMetrics sl = master.getServerManager().getLoad(serverName);
|
||||
if (sl != null) {
|
||||
long memStoreSizeMB = 0;
|
||||
|
@ -276,12 +276,12 @@ if (sl != null) {
|
|||
<%java>
|
||||
final String ZEROKB = "0 KB";
|
||||
final String ZEROMB = "0 MB";
|
||||
for (ServerName serverName: serverNames) {
|
||||
|
||||
String storeUncompressedSizeMBStr = ZEROMB;
|
||||
String storeFileSizeMBStr = ZEROMB;
|
||||
String totalStaticIndexSizeKBStr = ZEROKB;
|
||||
String totalStaticBloomSizeKBStr = ZEROKB;
|
||||
for (ServerName serverName: serverNames) {
|
||||
|
||||
ServerMetrics sl = master.getServerManager().getLoad(serverName);
|
||||
if (sl != null) {
|
||||
long storeCount = 0;
|
||||
|
|
|
@ -213,11 +213,10 @@
|
|||
<th>Memstore Size</th>
|
||||
</tr>
|
||||
<%
|
||||
for (Address server: rsGroupServers) {
|
||||
String usedHeapSizeMBStr = ZEROMB;
|
||||
String maxHeapSizeMBStr = ZEROMB;
|
||||
String memStoreSizeMBStr = ZEROMB;
|
||||
|
||||
for (Address server: rsGroupServers) {
|
||||
ServerName serverName = serverMaping.get(server);
|
||||
ServerMetrics sl = onlineServers.get(server);
|
||||
if (sl != null && serverName != null) {
|
||||
|
@ -309,11 +308,11 @@
|
|||
<th>Bloom Size</th>
|
||||
</tr>
|
||||
<%
|
||||
for (Address server: rsGroupServers) {
|
||||
String storeUncompressedSizeMBStr = ZEROMB;
|
||||
String storeFileSizeMBStr = ZEROMB;
|
||||
String totalStaticIndexSizeKBStr = ZEROKB;
|
||||
String totalStaticBloomSizeKBStr = ZEROKB;
|
||||
for (Address server: rsGroupServers) {
|
||||
ServerName serverName = serverMaping.get(server);
|
||||
ServerMetrics sl = onlineServers.get(server);
|
||||
if (sl != null && serverName != null) {
|
||||
|
|
Loading…
Reference in New Issue