solution: docs for monitoring with Prometheus
This commit is contained in:
@@ -71,4 +71,24 @@ The access log contains the JSON lines similar to:
|
|||||||
** `id` request id provided in the original request
|
** `id` request id provided in the original request
|
||||||
** `payloadSizeBytes` size of the original _individual_ request (for JSON RPC it's size of the `params` value)
|
** `payloadSizeBytes` size of the original _individual_ request (for JSON RPC it's size of the `params` value)
|
||||||
|
|
||||||
|
== Prometheus Metrics
|
||||||
|
|
||||||
|
By default, Dshackle provides Prometheus metrics on `http://127.0.0.1:8081/metrics`.
|
||||||
|
|
||||||
|
To configure the metrics use:
|
||||||
|
|
||||||
|
[source,yaml]
|
||||||
|
----
|
||||||
|
monitoring:
|
||||||
|
enabled: true
|
||||||
|
jvm: false
|
||||||
|
extended: false
|
||||||
|
prometheus:
|
||||||
|
enabled: true
|
||||||
|
bind: 192.168.0.1
|
||||||
|
port: 8000
|
||||||
|
path: /status/prometheus
|
||||||
|
----
|
||||||
|
|
||||||
|
Where `jvm` options enabled monitoring of the JVM internals, such as memory, GC, threads, etc.
|
||||||
|
And `extended` enables additional metrics for query selectors, etc.
|
||||||
@@ -21,6 +21,16 @@ tls:
|
|||||||
require: true
|
require: true
|
||||||
ca: "/path/ca.dshackle.test.crt"
|
ca: "/path/ca.dshackle.test.crt"
|
||||||
|
|
||||||
|
monitoring:
|
||||||
|
enabled: true
|
||||||
|
jvm: false
|
||||||
|
extended: false
|
||||||
|
prometheus:
|
||||||
|
enabled: true
|
||||||
|
bind: 127.0.0.1
|
||||||
|
port: 8081
|
||||||
|
path: /metrics
|
||||||
|
|
||||||
cache:
|
cache:
|
||||||
redis:
|
redis:
|
||||||
enabled: true
|
enabled: true
|
||||||
@@ -149,6 +159,11 @@ cluster:
|
|||||||
| Setup TLS configuration for the gRPC server.
|
| Setup TLS configuration for the gRPC server.
|
||||||
See <<tls>> section
|
See <<tls>> section
|
||||||
|
|
||||||
|
| `monitoring`
|
||||||
|
|
|
||||||
|
| Setup Prometheus monitoring.
|
||||||
|
See <<monitoring>> section
|
||||||
|
|
||||||
| `proxy`
|
| `proxy`
|
||||||
|
|
|
|
||||||
| Setup HTTP proxy that emulates all standard JSON RPC requests.
|
| Setup HTTP proxy that emulates all standard JSON RPC requests.
|
||||||
@@ -205,7 +220,7 @@ a| `true` if any value is set
|
|||||||
|
|
||||||
| `server.key`
|
| `server.key`
|
||||||
|
|
|
|
||||||
| Path to a private key to the certificate. The key _MUST BE_ in PKCS 8 format
|
| Path to a private key to the certificate.The key _MUST BE_ in PKCS 8 format
|
||||||
|
|
||||||
| `client.require`
|
| `client.require`
|
||||||
|
|
|
|
||||||
@@ -217,6 +232,59 @@ a| `true` if any value is set
|
|||||||
|
|
||||||
|===
|
|===
|
||||||
|
|
||||||
|
[#monitoring]
|
||||||
|
== Monitoring
|
||||||
|
|
||||||
|
Configure Prometheus monitoring
|
||||||
|
|
||||||
|
[source,yaml]
|
||||||
|
----
|
||||||
|
monitoring:
|
||||||
|
enabled: true
|
||||||
|
jvm: false
|
||||||
|
extended: false
|
||||||
|
prometheus:
|
||||||
|
enabled: true
|
||||||
|
bind: 127.0.0.1
|
||||||
|
port: 8081
|
||||||
|
path: /metrics
|
||||||
|
----
|
||||||
|
|
||||||
|
[cols="2a,2a,5"]
|
||||||
|
|===
|
||||||
|
| Option | Default Value | Description
|
||||||
|
|
||||||
|
| `enabled`
|
||||||
|
| `true`
|
||||||
|
| Enable/Disable monitoring endpoint
|
||||||
|
|
||||||
|
| `jvm`
|
||||||
|
| `false`
|
||||||
|
| Enable/Disable JVM metrics (threads, GC, memory, etc)
|
||||||
|
|
||||||
|
| `extended`
|
||||||
|
| `false`
|
||||||
|
| Enable/Disable additional metrics (query selectors, etc)
|
||||||
|
|
||||||
|
| `prometheus.enabled`
|
||||||
|
| `true`
|
||||||
|
| Enable/Disable monitoring endpoint.
|
||||||
|
_Reserved for future use_, in case of multiple different types of endpoints.
|
||||||
|
|
||||||
|
| `prometheus.bind`
|
||||||
|
| `127.0.0.1`
|
||||||
|
| Host to bind the server
|
||||||
|
|
||||||
|
| `prometheus.port`
|
||||||
|
| `8081`
|
||||||
|
| Port to bind the server
|
||||||
|
|
||||||
|
| `prometheus.path`
|
||||||
|
| `/metrics`
|
||||||
|
| HTTP path to bind the server
|
||||||
|
|
||||||
|
|===
|
||||||
|
|
||||||
[#proxy]
|
[#proxy]
|
||||||
== Proxy config
|
== Proxy config
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user