public class HTTPMetricsServer extends Object implements MonitorService
Optional parameters:
port : The port on which the server should listen to.
Returns metrics in the following format:
{
"componentName1":{"metric1" : "metricValue1","metric2":"metricValue2"}
"componentName1":{"metric3" : "metricValue3","metric4":"metricValue4"}
}
Modifier and Type | Field and Description |
---|---|
static String |
CONFIG_PORT |
static int |
DEFAULT_PORT |
Constructor and Description |
---|
HTTPMetricsServer() |
public static int DEFAULT_PORT
public static String CONFIG_PORT
public void start()
start
in interface MonitorService
public void stop()
stop
in interface MonitorService
public void configure(Context context)
Configurable
Request the implementing class to (re)configure itself.
When configuration parameters are changed, they must be reflected by the component asap.
There are no thread safety guarantees on when configure might be called.
configure
in interface Configurable
Copyright © 2009-2016 Apache Software Foundation. All Rights Reserved.