Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/ikwattro/neo4j-extra-metrics
Neo4j extension providing additional extra metrics
https://github.com/ikwattro/neo4j-extra-metrics
java neo4j observability prometheus
Last synced: about 1 month ago
JSON representation
Neo4j extension providing additional extra metrics
- Host: GitHub
- URL: https://github.com/ikwattro/neo4j-extra-metrics
- Owner: ikwattro
- License: apache-2.0
- Created: 2023-04-05T23:02:52.000Z (almost 2 years ago)
- Default Branch: main
- Last Pushed: 2023-05-20T22:23:28.000Z (over 1 year ago)
- Last Synced: 2024-10-30T09:27:00.319Z (3 months ago)
- Topics: java, neo4j, observability, prometheus
- Language: Java
- Homepage:
- Size: 14.6 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Neo4j Extra Metrics extension
Extension providing additional metrics for database labels and relationship type counts.
## Installation
Clone this repository
```bash
git clone [email protected]:ikwattro/neo4j-extra-metrics
```Build the package
```bash
mvn clean package -DskipTests
```Install the produced jar file to the `plugins` directory of your Neo4j instance
Add the following setting to your `neo4j.conf`
```
server.metrics.enabled=true
server.metrics.prometheus.enable=true
server.metrics.prometheus.endpoint=0.0.0.0:2004
server.metrics.filter=*
```or in your docker compose neo4j service environment
```
- NEO4J_server_metrics_enabled=true
- NEO4J_server_metrics_prometheus_enabled=true
- NEO4J_server_metrics_prometheus_endpoint=0.0.0.0:2004
- NEO4J_server_metrics_filter=*
```Note that this enables all metrics, refer to the [`server.metrics.filter`](https://neo4j.com/docs/operations-manual/current/reference/configuration-settings/#config_server.metrics.filter) setting ,
this plugin metrics are registered under the `extra` label.Restart your neo4j server
Once restarted, you can inspect metrics on http://localhost:2004/metrics
```
# HELP neo4j_database_neo4j_extra_label_Person_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.label.Person, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_label_Person_total counter
neo4j_database_neo4j_extra_label_Person_total 399.0
# HELP neo4j_database_neo4j_extra_relationshipType_ACTED_IN_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.ACTED_IN, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_ACTED_IN_total counter
neo4j_database_neo4j_extra_relationshipType_ACTED_IN_total 516.0
# HELP neo4j_database_neo4j_extra_relationshipType_PRODUCED_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.PRODUCED, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_PRODUCED_total counter
neo4j_database_neo4j_extra_relationshipType_PRODUCED_total 45.0
# HELP neo4j_database_neo4j_extra_relationshipType_WROTE_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.WROTE, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_WROTE_total counter
neo4j_database_neo4j_extra_relationshipType_WROTE_total 30.0
# HELP neo4j_database_neo4j_extra_relationshipType_REVIEWED_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.REVIEWED, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_REVIEWED_total counter
neo4j_database_neo4j_extra_relationshipType_REVIEWED_total 27.0
# HELP neo4j_database_neo4j_extra_label_Movie_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.label.Movie, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_label_Movie_total counter
neo4j_database_neo4j_extra_label_Movie_total 114.0
# HELP neo4j_database_neo4j_extra_relationshipType_FOLLOWS_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.FOLLOWS, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_FOLLOWS_total counter
neo4j_database_neo4j_extra_relationshipType_FOLLOWS_total 9.0
# HELP neo4j_database_neo4j_extra_relationshipType_DIRECTED_total Generated from Dropwizard metric import (metric=neo4j.database.neo4j.extra.relationshipType.DIRECTED, type=com.neo4j.metrics.metric.MetricsCounter)
# TYPE neo4j_database_neo4j_extra_relationshipType_DIRECTED_total counter
neo4j_database_neo4j_extra_relationshipType_DIRECTED_total 132.0
```