You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: documentation/packages/monitoring/README.md
+17-3Lines changed: 17 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,14 +4,15 @@ description: A package for monitoring the platform services
4
4
5
5
# Monitoring
6
6
7
-
The monitoring package sets up services to monitor the entire deployed stack. This includes the state of the servers involved in the docker swarm, the docker containers themselves and particular applications such as Kafka.
7
+
The monitoring package sets up services to monitor the entire deployed stack. This includes the state of the servers involved in the docker swarm, the docker containers themselves and particular applications such as Kafka. It also captures the logs from the various services.
8
8
9
9
This monitoring package uses: 
10
10
11
11
* Grafana: for dashboards
12
12
* Prometheus: for recording metrics
13
13
* Cadvisor: for reading docker container metrics 
14
-
* Kafka: for saving a backup of metrics data
14
+
* Loki: for storing logs
15
+
* Node Exporter: for monitoring host machine metrics like CPU, memory etc
15
16
16
17
To use the monitoring services, include the `monitoring` package id to your list of package ids when standing up the platform.
17
18
@@ -31,7 +32,20 @@ To use custom metrics for an application, first configure that application to pr
`prometheus-job` lets Prometheus know to enable monitoring for this container and `prometheus-address` give the endpoint that the monitoring can access the metrics on. By default this is assumed to be at the path `/metrics` by Prometheus.
35
+
`prometheus-job-service` lets Prometheus know to enable monitoring for this container and `prometheus-address` gives the endpoint that Prometheus can access the metrics on. By default this is assumed to be at the path `/metrics` by Prometheus.
36
+
37
+
By using the `prometheus-job-service` label prometheus will only create a single target for your application even if it is replicated via service config in docker swarm. If you would like to monitor each replica separately (i.e. if metrics are only captured for that replica and not shared to some central location in the application cluster) you can instead used the `prometheus-job-task` label and Prometheus will create a target for each replica.
38
+
39
+
A full list od supported labels are listed below:
40
+
41
+
*`prometheus-job-service` - indicates this service should be monitored
42
+
*`prometheus-job-task` - indicates each task in the replicated service should be monitored separately
43
+
*`prometheus-address` - the service address Prometheus can scrape metrics from, can only be used with `prometheus-job-service`
44
+
*`prometheus-scheme` - the scheme to use when scaping a task or service (e.g. http or https), defaults to http
45
+
*`prometheus-metrics-path` - the path to the metrics endpoint on the target (defaults to /metrics)
46
+
*`prometheus-port` - the port of the metrics endpoint. Only usable with `prometheus-job-task`, defaults to all exposed ports for the container if no label is present
47
+
48
+
All services must also be on the `prometheus_public` network to be able to be seen by Prometheus for metrics scraping.
0 commit comments