lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jeff Wartes (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (SOLR-4735) Improve Solr metrics reporting
Date Fri, 02 Dec 2016 18:28:58 GMT

    [ https://issues.apache.org/jira/browse/SOLR-4735?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15715880#comment-15715880
] 

Jeff Wartes commented on SOLR-4735:
-----------------------------------

`MetricRegistry` is really just a bunch of convenience methods and thread-safety around a
`MetricSet`. There isn't much overhead difference between the two. But really, when I think
of a MetricRegistry, I think of it as "a set of metrics I want to attach a reporter to", nothing
more. 
It's a bit disappointing that reporters take a Registry instead of a MetricSet, since a Registry
isa MetricSet.

With that in mind, one strategy would be have every logical grouping of metrics use its own
dedicated (probably shared) registry, and then bind the reporter-registry concept together
at reporter definition time. 

That is, create a non-shared registry explicitly for the purpose of attaching a reporter to
it, and only when asked to define a reporter. The reporter definition would then include the
names of the registries to be reported. Under the hood, a new registry would be created as
the union of the requested registries, and the reporter instantiated and attached to that.
We'd have to make sure the namespace of all the metrics in the metric groups is unique, so
that arbitrary groups can be combined without conflict, but that sounds desirable regardless.


> Improve Solr metrics reporting
> ------------------------------
>
>                 Key: SOLR-4735
>                 URL: https://issues.apache.org/jira/browse/SOLR-4735
>             Project: Solr
>          Issue Type: Improvement
>            Reporter: Alan Woodward
>            Assignee: Andrzej Bialecki 
>            Priority: Minor
>         Attachments: SOLR-4735.patch, SOLR-4735.patch, SOLR-4735.patch, SOLR-4735.patch
>
>
> Following on from a discussion on the mailing list:
> http://search-lucene.com/m/IO0EI1qdyJF1/codahale&subj=Solr+metrics+in+Codahale+metrics+and+Graphite+
> It would be good to make Solr play more nicely with existing devops monitoring systems,
such as Graphite or Ganglia.  Stats monitoring at the moment is poll-only, either via JMX
or through the admin stats page.  I'd like to refactor things a bit to make this more pluggable.
> This patch is a start.  It adds a new interface, InstrumentedBean, which extends SolrInfoMBean
to return a [[Metrics|http://metrics.codahale.com/manual/core/]] MetricRegistry, and a couple
of MetricReporters (which basically just duplicate the JMX and admin page reporting that's
there at the moment, but which should be more extensible).  The patch includes a change to
RequestHandlerBase showing how this could work.  The idea would be to eventually replace the
getStatistics() call on SolrInfoMBean with this instead.
> The next step would be to allow more MetricReporters to be defined in solrconfig.xml.
 The Metrics library comes with ganglia and graphite reporting modules, and we can add contrib
plugins for both of those.
> There's some more general cleanup that could be done around SolrInfoMBean (we've got
two plugin handlers at /mbeans and /plugins that basically do the same thing, and the beans
themselves have some weirdly inconsistent data on them - getVersion() returns different things
for different impls, and getSource() seems pretty useless), but maybe that's for another issue.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org


Mime
View raw message