From c0df9435a625df99a1b6d5d43d3fb6ab4c109e34 Mon Sep 17 00:00:00 2001 From: Peter Somogyi Date: Tue, 27 Jun 2023 17:45:15 +0200 Subject: [PATCH] Revert "HBASE-27892 Report memstore on-heap and off-heap size as jmx metrics (#5308)" (#5311) This reverts commit 7c493002123d01b69ef8c0b86f1ca206cb1ab227. --- .../hadoop/hbase/regionserver/MetricsRegionServerSource.java | 4 ---- .../hbase/regionserver/MetricsRegionServerSourceImpl.java | 4 ---- .../hadoop/hbase/regionserver/TestMetricsRegionServer.java | 2 -- 3 files changed, 10 deletions(-) diff --git a/hbase-hadoop-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSource.java b/hbase-hadoop-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSource.java index 1360a5ef858f..95b272c6b662 100644 --- a/hbase-hadoop-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSource.java +++ b/hbase-hadoop-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSource.java @@ -233,10 +233,6 @@ public interface MetricsRegionServerSource extends BaseSource, JvmPauseMonitorSo String MAX_COMPACTED_STORE_FILE_REF_COUNT = "maxCompactedStoreFileRefCount"; String MEMSTORE_SIZE = "memStoreSize"; String MEMSTORE_SIZE_DESC = "Size of the memstore"; - String MEMSTORE_HEAP_SIZE = "memStoreHeapSize"; - String MEMSTORE_HEAP_SIZE_DESC = "On-heap Size of the memstore"; - String MEMSTORE_OFFHEAP_SIZE = "memStoreOffHeapSize"; - String MEMSTORE_OFFHEAP_SIZE_DESC = "Off-heap Size of the memstore"; String STOREFILE_SIZE = "storeFileSize"; String MAX_STORE_FILE_AGE = "maxStoreFileAge"; String MIN_STORE_FILE_AGE = "minStoreFileAge"; diff --git a/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSourceImpl.java b/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSourceImpl.java index 042eff59b8d9..6c01436d5234 100644 --- a/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSourceImpl.java +++ b/hbase-hadoop2-compat/src/main/java/org/apache/hadoop/hbase/regionserver/MetricsRegionServerSourceImpl.java @@ -479,10 +479,6 @@ private MetricsRecordBuilder addGaugesToMetricsRecordBuilder(MetricsRecordBuilde .addGauge(Interns.info(MAX_STOREFILE_COUNT, MAX_STOREFILE_COUNT_DESC), rsWrap.getMaxStoreFiles()) .addGauge(Interns.info(MEMSTORE_SIZE, MEMSTORE_SIZE_DESC), rsWrap.getMemStoreSize()) - .addGauge(Interns.info(MEMSTORE_HEAP_SIZE, MEMSTORE_HEAP_SIZE_DESC), - rsWrap.getOnHeapMemStoreSize()) - .addGauge(Interns.info(MEMSTORE_OFFHEAP_SIZE, MEMSTORE_OFFHEAP_SIZE_DESC), - rsWrap.getOffHeapMemStoreSize()) .addGauge(Interns.info(STOREFILE_SIZE, STOREFILE_SIZE_DESC), rsWrap.getStoreFileSize()) .addGauge(Interns.info(MAX_STORE_FILE_AGE, MAX_STORE_FILE_AGE_DESC), rsWrap.getMaxStoreFileAge()) diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMetricsRegionServer.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMetricsRegionServer.java index 64743e99b7e6..922b16630e34 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMetricsRegionServer.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/regionserver/TestMetricsRegionServer.java @@ -83,8 +83,6 @@ public void testWrapperSource() { HELPER.assertGauge("hlogFileSize", 1024000, serverSource); HELPER.assertGauge("storeFileCount", 300, serverSource); HELPER.assertGauge("memstoreSize", 1025, serverSource); - HELPER.assertGauge("memstoreHeapSize", 500, serverSource); - HELPER.assertGauge("memstoreOffHeapSize", 600, serverSource); HELPER.assertGauge("storeFileSize", 1900, serverSource); HELPER.assertCounter("totalRequestCount", 899, serverSource); HELPER.assertCounter("totalRowActionRequestCount",