mirror of
https://gitee.com/iresty/apisix.git
synced 2024-12-04 21:17:36 +08:00
docs: update prometheus docs (#3293)
Signed-off-by: spacewander <spacewanderlzx@gmail.com>
This commit is contained in:
parent
ff60e57996
commit
122cdf72ce
@ -127,11 +127,13 @@ Or you can goto [Grafana official](https://grafana.com/grafana/dashboards/11719)
|
||||
* `etcd reachability`: A gauge type with a value of 0 or 1, representing if etcd can be reached by a apisix or not.
|
||||
* `Connections`: Various Nginx connection metrics like active, reading, writing, and number of accepted connections.
|
||||
* `Batch process entries`: A gauge type, when we use plugins and the plugin used batch process to send data, such as: sys logger, http logger, sls logger, tcp logger, udp logger and zipkin, then the entries which hasn't been sent in batch process will be counted in the metrics.
|
||||
* `Latency`: The per service histogram of request time and the overhead added by APISIX (request time - upstream response time).
|
||||
* `Info`: the information of APISIX node.
|
||||
|
||||
Here is the original metric data of apisix:
|
||||
|
||||
```
|
||||
$ curl http://127.0.0.2:9080/apisix/prometheus/metrics
|
||||
$ curl http://127.0.0.1:9080/apisix/prometheus/metrics
|
||||
# HELP apisix_bandwidth Total bandwidth in bytes consumed per service in Apisix
|
||||
# TYPE apisix_bandwidth counter
|
||||
apisix_bandwidth{type="egress",service="127.0.0.2"} 183
|
||||
@ -168,6 +170,19 @@ apisix_nginx_http_current_connections{state="writing"} 1
|
||||
# HELP apisix_nginx_metric_errors_total Number of nginx-lua-prometheus errors
|
||||
# TYPE apisix_nginx_metric_errors_total counter
|
||||
apisix_nginx_metric_errors_total 0
|
||||
# HELP apisix_http_latency HTTP request latency in milliseconds per service in APISIX
|
||||
# TYPE apisix_http_latency histogram
|
||||
apisix_http_latency_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00001.0"} 1
|
||||
apisix_http_latency_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00002.0"} 1
|
||||
...
|
||||
# HELP apisix_http_overhead HTTP request overhead added by APISIX in milliseconds per service in APISIX
|
||||
# TYPE apisix_http_overhead histogram
|
||||
apisix_http_overhead_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00001.0"} 1
|
||||
apisix_http_overhead_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00002.0"} 1
|
||||
...
|
||||
# HELP apisix_node_info Info of APISIX node
|
||||
# TYPE apisix_node_info gauge
|
||||
apisix_node_info{hostname="desktop-2022q8f-wsl"} 1
|
||||
```
|
||||
|
||||
## Disable Plugin
|
||||
|
@ -125,6 +125,9 @@ plugin_attr:
|
||||
* `etcd reachability`: apisix 连接 etcd 的可用性,用 0 和 1来表示。
|
||||
* `Connections`: 各种的 Nginx 连接指标,如 active(正处理的活动连接数),reading(nginx 读取到客户端的 Header 信息数),writing(nginx 返回给客户端的 Header 信息数),已建立的连接数。.
|
||||
* `Batch process entries`: 批处理未发送数据计数器,当你使用了批处理发送插件,比如:sys logger, http logger, sls logger, tcp logger, udp logger and zipkin, 那么你将会在此指标中看到批处理当前尚未发送的数据的数量。
|
||||
* `Latency`: 每个服务的请求用时和 APISIX 处理耗时的直方图。
|
||||
* `Info`: 当前 APISIX 节点信息。
|
||||
|
||||
这里是apisix的原始的指标数据集:
|
||||
|
||||
```
|
||||
@ -165,6 +168,19 @@ apisix_nginx_http_current_connections{state="writing"} 1
|
||||
# HELP apisix_nginx_metric_errors_total Number of nginx-lua-prometheus errors
|
||||
# TYPE apisix_nginx_metric_errors_total counter
|
||||
apisix_nginx_metric_errors_total 0
|
||||
# HELP apisix_http_latency HTTP request latency in milliseconds per service in APISIX
|
||||
# TYPE apisix_http_latency histogram
|
||||
apisix_http_latency_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00001.0"} 1
|
||||
apisix_http_latency_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00002.0"} 1
|
||||
...
|
||||
# HELP apisix_http_overhead HTTP request overhead added by APISIX in milliseconds per service in APISIX
|
||||
# TYPE apisix_http_overhead histogram
|
||||
apisix_http_overhead_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00001.0"} 1
|
||||
apisix_http_overhead_bucket{type="request",service="",consumer="",node="127.0.0.1",le="00002.0"} 1
|
||||
...
|
||||
# HELP apisix_node_info Info of APISIX node
|
||||
# TYPE apisix_node_info gauge
|
||||
apisix_node_info{hostname="desktop-2022q8f-wsl"} 1
|
||||
```
|
||||
|
||||
## 禁用插件
|
||||
|
Loading…
Reference in New Issue
Block a user