MAPREDUCE-4666. JVM metrics for history server. (jlowe via jeagles)
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1407669 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
e8d7891e78
commit
3ccc76c29b
|
@ -589,6 +589,8 @@ Release 0.23.5 - UNRELEASED
|
|||
|
||||
MAPREDUCE-4266. remove Ant remnants from MR (tgraves via bobby)
|
||||
|
||||
MAPREDUCE-4666. JVM metrics for history server (jlowe via jeagles)
|
||||
|
||||
OPTIMIZATIONS
|
||||
|
||||
BUG FIXES
|
||||
|
|
|
@ -27,6 +27,8 @@ import org.apache.hadoop.conf.Configuration;
|
|||
import org.apache.hadoop.mapred.JobConf;
|
||||
import org.apache.hadoop.mapreduce.MRConfig;
|
||||
import org.apache.hadoop.mapreduce.v2.jobhistory.JHAdminConfig;
|
||||
import org.apache.hadoop.metrics2.lib.DefaultMetricsSystem;
|
||||
import org.apache.hadoop.metrics2.source.JvmMetrics;
|
||||
import org.apache.hadoop.security.SecurityUtil;
|
||||
import org.apache.hadoop.util.ShutdownHookManager;
|
||||
import org.apache.hadoop.util.StringUtils;
|
||||
|
@ -106,6 +108,8 @@ public class JobHistoryServer extends CompositeService {
|
|||
|
||||
@Override
|
||||
public void start() {
|
||||
DefaultMetricsSystem.initialize("JobHistoryServer");
|
||||
JvmMetrics.initSingleton("JobHistoryServer", null);
|
||||
try {
|
||||
jhsDTSecretManager.startThreads();
|
||||
} catch(IOException io) {
|
||||
|
@ -118,6 +122,7 @@ public class JobHistoryServer extends CompositeService {
|
|||
@Override
|
||||
public void stop() {
|
||||
jhsDTSecretManager.stopThreads();
|
||||
DefaultMetricsSystem.shutdown();
|
||||
super.stop();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue