frostruan commented on code in PR #5319:
URL: https://github.com/apache/hbase/pull/5319#discussion_r1262562111
##########
hbase-client/src/main/java/org/apache/hadoop/hbase/util/JvmPauseMonitor.java:
##########
@@ -62,28 +66,47 @@ public class JvmPauseMonitor {
public static final String INFO_THRESHOLD_KEY =
"jvm.pause.info-threshold.ms";
private static final long INFO_THRESHOLD_DEFAULT = 1000;
+ public static final String PAUSE_MONITOR_ENABLE_KEY =
"hbase.client.pause.monitor.enable";
+
+ public static final boolean PAUSE_MONITOR_ENABLE_DEFAULT = false;
+
private Thread monitorThread;
private volatile boolean shouldRun = true;
- private JvmPauseMonitorSource metricsSource;
+ private final JvmPauseMonitorSource metricsSource;
+
+ public static synchronized JvmPauseMonitor getInstance(Configuration conf) {
Review Comment:
There are two reasons.
@wchevreuil mentioned that our user may open multiple connections, however
only one pause monitor is enough for a process. More details please see
[here](https://github.com/apache/hbase/pull/5319#discussion_r1258120860)
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]