public class MetricsHistoryHandler extends RequestHandlerBase implements PermissionNameProvider, Closeable
Modifier and Type | Class and Description |
---|---|
static class |
MetricsHistoryHandler.Cmd |
static class |
MetricsHistoryHandler.Format |
PermissionNameProvider.Name
SolrInfoBean.Category, SolrInfoBean.Group
Modifier and Type | Field and Description |
---|---|
static String |
COLLECT_PERIOD_PROP |
static int |
DEFAULT_COLLECT_PERIOD |
static List<String> |
DEFAULT_COLLECTION_GAUGES |
static List<String> |
DEFAULT_CORE_COUNTERS |
static List<String> |
DEFAULT_CORE_GAUGES |
static List<String> |
DEFAULT_JVM_GAUGES |
static List<String> |
DEFAULT_NODE_GAUGES |
static String |
ENABLE_NODES_PROP |
static String |
ENABLE_PROP |
static String |
ENABLE_REPLICAS_PROP |
static String |
NUM_NODES_KEY |
static String |
NUM_REPLICAS_KEY |
static String |
NUM_SHARDS_KEY |
static String |
SYNC_PERIOD_PROP |
static String |
URI_PREFIX |
appends, defaults, httpCaching, initArgs, invariants, solrMetricsContext
ANY, NULL, values
TYPE
Constructor and Description |
---|
MetricsHistoryHandler(String nodeName,
MetricsHandler metricsHandler,
SolrClient solrClient,
SolrCloudManager cloudManager,
Map<String,Object> pluginArgs) |
Modifier and Type | Method and Description |
---|---|
void |
checkSystemCollection() |
void |
close()
Implementations should always call
SolrMetricProducer.super.close() to ensure that
metrics with the same life-cycle as this component are properly unregistered. |
Collection<Api> |
getApis()
It is possible to support multiple v2 apis by a single requesthandler
|
String |
getDescription()
Simple one or two line description
|
SolrRrdBackendFactory |
getFactory() |
PermissionNameProvider.Name |
getPermissionName(AuthorizationContext request) |
SolrClient |
getSolrClient() |
void |
handleRequestBody(SolrQueryRequest req,
SolrQueryResponse rsp) |
Boolean |
registerV2()
Whether this request handler must be made available at the /v2/ path
|
void |
removeHistory(String registry) |
getCategory, getInitArgs, getMetricNames, getName, getPluginInfo, getRequestHandler, getSolrMetricsContext, getSolrParamsFromNamedList, getSubHandler, handleRequest, init, initializeMetrics, setPluginInfo
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
getMetricRegistry, getMetricsSnapshot, registerMetricName
getUniqueMetricTag, initializeMetrics
registerV1
public static final String NUM_SHARDS_KEY
public static final String NUM_REPLICAS_KEY
public static final String NUM_NODES_KEY
public static final String COLLECT_PERIOD_PROP
public static final String SYNC_PERIOD_PROP
public static final String ENABLE_PROP
public static final String ENABLE_REPLICAS_PROP
public static final String ENABLE_NODES_PROP
public static final int DEFAULT_COLLECT_PERIOD
public static final String URI_PREFIX
public MetricsHistoryHandler(String nodeName, MetricsHandler metricsHandler, SolrClient solrClient, SolrCloudManager cloudManager, Map<String,Object> pluginArgs)
public void checkSystemCollection()
public SolrClient getSolrClient()
public void removeHistory(String registry) throws IOException
IOException
public SolrRrdBackendFactory getFactory()
public void close()
SolrMetricProducer
SolrMetricProducer.super.close()
to ensure that
metrics with the same life-cycle as this component are properly unregistered. This prevents
obscure memory leaks.
from: https://docs.oracle.com/javase/8/docs/api/java/lang/AutoCloseable.html
While this interface method is declared to throw Exception, implementers are strongly encouraged
to declare concrete implementations of the close method to throw more specific exceptions, or to
throw no exception at all if the close operation cannot fail.close
in interface Closeable
close
in interface AutoCloseable
close
in interface SolrMetricProducer
public void handleRequestBody(SolrQueryRequest req, SolrQueryResponse rsp) throws Exception
handleRequestBody
in class RequestHandlerBase
Exception
public String getDescription()
SolrInfoBean
getDescription
in interface SolrInfoBean
getDescription
in class RequestHandlerBase
public PermissionNameProvider.Name getPermissionName(AuthorizationContext request)
getPermissionName
in interface PermissionNameProvider
public Boolean registerV2()
ApiSupport
registerV2
in interface ApiSupport
public Collection<Api> getApis()
ApiSupport
getApis
in interface ApiSupport
getApis
in class RequestHandlerBase
Copyright © 2000-2020 Apache Software Foundation. All Rights Reserved.