Package org.apache.solr.util.stats
Class InstrumentedPoolingHttpClientConnectionManager
- java.lang.Object
-
- org.apache.http.impl.conn.PoolingHttpClientConnectionManager
-
- org.apache.solr.util.stats.InstrumentedPoolingHttpClientConnectionManager
-
- All Implemented Interfaces:
Closeable
,AutoCloseable
,org.apache.http.conn.HttpClientConnectionManager
,org.apache.http.pool.ConnPoolControl<org.apache.http.conn.routing.HttpRoute>
,SolrMetricProducer
public class InstrumentedPoolingHttpClientConnectionManager extends org.apache.http.impl.conn.PoolingHttpClientConnectionManager implements SolrMetricProducer
Sub-class of PoolingHttpClientConnectionManager which tracks metrics interesting to Solr. Inspired by dropwizard metrics-httpclient library implementation.
-
-
Constructor Summary
Constructors Constructor Description InstrumentedPoolingHttpClientConnectionManager(org.apache.http.config.Registry<org.apache.http.conn.socket.ConnectionSocketFactory> socketFactoryRegistry)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
initializeMetrics(SolrMetricManager manager, String registry, String tag, String scope)
Initializes metrics specific to this producer.-
Methods inherited from class org.apache.http.impl.conn.PoolingHttpClientConnectionManager
close, closeExpiredConnections, closeIdleConnections, connect, enumAvailable, enumLeased, finalize, getConnectionConfig, getDefaultConnectionConfig, getDefaultMaxPerRoute, getDefaultSocketConfig, getMaxPerRoute, getMaxTotal, getRoutes, getSocketConfig, getStats, getTotalStats, getValidateAfterInactivity, leaseConnection, releaseConnection, requestConnection, routeComplete, setConnectionConfig, setDefaultConnectionConfig, setDefaultMaxPerRoute, setDefaultSocketConfig, setMaxPerRoute, setMaxTotal, setSocketConfig, setValidateAfterInactivity, shutdown, upgrade
-
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.solr.metrics.SolrMetricProducer
initializeMetrics
-
-
-
-
Method Detail
-
initializeMetrics
public void initializeMetrics(SolrMetricManager manager, String registry, String tag, String scope)
Description copied from interface:SolrMetricProducer
Initializes metrics specific to this producer.Note: for back-compatibility this method by default calls
SolrMetricProducer.initializeMetrics(SolrMetricManager, String, String)
.- Specified by:
initializeMetrics
in interfaceSolrMetricProducer
- Parameters:
manager
- an instance ofSolrMetricManager
registry
- registry name where metrics are registeredtag
- symbolic tag that represents a group of related instances that have the same life-cycle. Parent component can use thetag
when callingSolrMetricManager.unregisterGauges(String, String)
to unregister metrics created by this instance of the producer.scope
- scope of the metrics (eg. handler name) to separate metrics of instances of the same component executing in different contexts
-
-