elasticsearch-newrelic-plugin

New Relic monitoring plugin for Elasticsearch - Ported from Graphite Original

License

License

Categories

Categories

Search Business Logic Libraries Elasticsearch
GroupId

GroupId

io.ingenieux
ArtifactId

ArtifactId

elasticsearch-newrelic-plugin
Last Version

Last Version

0.2
Release Date

Release Date

Type

Type

jar
Description

Description

elasticsearch-newrelic-plugin
New Relic monitoring plugin for Elasticsearch - Ported from Graphite Original
Project URL

Project URL

https://github.com/ingenieux/elasticsearch-newrelic-plugin/
Project Organization

Project Organization

ingenieux
Source Code Management

Source Code Management

http://github.com/ingenieux/elasticsearch-newrelic-plugin

Download elasticsearch-newrelic-plugin

How to add to project

<!-- https://jarcasting.com/artifacts/io.ingenieux/elasticsearch-newrelic-plugin/ -->
<dependency>
    <groupId>io.ingenieux</groupId>
    <artifactId>elasticsearch-newrelic-plugin</artifactId>
    <version>0.2</version>
</dependency>
// https://jarcasting.com/artifacts/io.ingenieux/elasticsearch-newrelic-plugin/
implementation 'io.ingenieux:elasticsearch-newrelic-plugin:0.2'
// https://jarcasting.com/artifacts/io.ingenieux/elasticsearch-newrelic-plugin/
implementation ("io.ingenieux:elasticsearch-newrelic-plugin:0.2")
'io.ingenieux:elasticsearch-newrelic-plugin:jar:0.2'
<dependency org="io.ingenieux" name="elasticsearch-newrelic-plugin" rev="0.2">
  <artifact name="elasticsearch-newrelic-plugin" type="jar" />
</dependency>
@Grapes(
@Grab(group='io.ingenieux', module='elasticsearch-newrelic-plugin', version='0.2')
)
libraryDependencies += "io.ingenieux" % "elasticsearch-newrelic-plugin" % "0.2"
[io.ingenieux/elasticsearch-newrelic-plugin "0.2"]

Dependencies

compile (2)

Group / Artifact Type Version
com.newrelic.agent.java : newrelic-api jar 3.12.1
org.elasticsearch : elasticsearch jar 1.3.2

test (4)

Group / Artifact Type Version
log4j : log4j jar 1.2.17
junit : junit jar 4.11
org.hamcrest : hamcrest-core jar 1.3
org.hamcrest : hamcrest-library jar 1.3

Project Modules

There are no modules declared in this project.

Elasticsearch New Relic plugin

This is a port of the Elasticsearch Graphite Plugin from spinscale.

This plugin creates a little push service, which regularly updates a graphite host with indices stats and nodes stats. In case you are running a cluster, these datas are always only pushed from the master node.

The data sent to the graphite server tries to be roughly equivalent to Indices Stats API and Nodes Stats Api

Installation

  • From New Relic console, create a new app, and grab a copy of its jar for your app.

  • Unpack into $ES_HOME so you end up with this directory structure:

vagrant@precise64:/usr/share/elasticsearch$ find newrelic/
newrelic/
newrelic/newrelic-api-sources.jar
newrelic/newrelic-api-javadoc.jar
newrelic/extension-example.xml
newrelic/extension.xsd
newrelic/nrcerts
newrelic/CHANGELOG
newrelic/newrelic.yml
newrelic/LICENSE
newrelic/newrelic-api.jar
newrelic/README.txt
newrelic/newrelic.jar
  • sudo bin/plugin install io.ingenieux/elasticsearch-newrelic-plugin/0.2

  • Then, tweak /etc/default/elasticsearch, adding:

ES_JAVA_OPTS=-javaagent:/$ES_HOME/newrelic/newrelic.jar
  • And set up /etc/elasticsearch/elasticsearch.yml as well:
  metrics.newrelic.enabled: true
  metrics.newrelic.prefix: elasticsearch.dev
  • Start and enjoy

Configuration

Configuration is possible via these parameters:

  • metrics.newrelic.enabled: Should we push to new relic? (default: false)
  • metrics.newrelic.every: The interval to push data (default: 1m)
  • metrics.newrelic.prefix: The metric prefix that's sent with metric names (default: elasticsearch.your_cluster_name)
  • metrics.newrelic.exclude: A regular expression allowing you to exclude certain metrics (note that the node does not start if the regex does not compile)
  • metrics.newrelic.include: A regular expression to explicitely include certain metrics even though they matched the exclude (note that the node does not start if the regex does not compile)

Check your elasticsearch log file for a line like this after adding the configuration parameters below to the configuration file

[2013-02-08 16:01:49,153][INFO ][service.newrelic         ] [Sea Urchin] New Relic  reporting triggered every [1m]

Bugs/TODO

Unless otherwise specified, all bugs are theirs, except that:

  • Tests are disabled

Credits

Quoted from original:

| Heavily inspired by the excellent metrics library by Coda Hale and its GraphiteReporter add-on.

License

See LICENSE

io.ingenieux

ingenieux Brasil

Versions

Version
0.2