简体   繁体   English

Kubernetes 中的 apiserver_request_duration_seconds prometheus 指标是什么意思?

[英]What does apiserver_request_duration_seconds prometheus metric in Kubernetes mean?

I want to know if the apiserver_request_duration_seconds accounts the time needed to transfer the request (and/or response) from the clients (eg kubelets) to the server (and vice-versa) or it is just the time needed to process the request internally (apiserver + etcd) and no communication time is accounted for?我想知道 apiserver_request_duration_seconds 是否考虑了将请求(和/或响应)从客户端(例如 kubelets)传输到服务器(反之亦然)所需的时间,或者它只是在内部处理请求所需的时间( apiserver + etcd)并且没有考虑通信时间?

As a plus, I also want to know where this metric is updated in the apiserver's HTTP handler chains?另外,我还想知道该指标在 apiserver 的 HTTP 处理程序链中的更新位置?

How long API requests are taking to run. API 请求需要多长时间才能运行。 Whole thing, from when it starts the HTTP handler to when it returns a response.整个事情,从它启动 HTTP 处理程序到它返回响应。

As an addition to the confirmation of @coderanger in the accepted answer.作为在接受的答案中确认@coderanger 的补充。 The metric is defined here and it is called from the function MonitorRequest which is defined here .该指标在此处定义,并从此处定义的 function MonitorRequest 调用。 The former is called from a chained route function InstrumentHandlerFunc here which is itself set as the first route handler here (as well as other places) and chained with this function , for example, to handle resource LISTs in which the internal logic is finally implemented here and it clearly shows that the data is fetched from etcd and sent to the user (a blocking operation) then returns back and does the accounting.前者是从链式路由 function InstrumentHandlerFunc 这里调用的,它本身被设置为这里(以及其他地方)的第一个路由处理程序,并与此 function链式,例如,用于处理内部逻辑最终在此处实现的资源 LIST它清楚地表明数据是从etcd获取并发送给用户(阻塞操作)然后返回并进行记帐。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 普罗米修斯查询语言中 somestring1_somestring2:metric_name:some_operation 是什么意思 - What does somestring1_somestring2:metric_name:some_operation mean in prometheus query language 用 kubectl 获取 kubernetes apiserver prometheus 指标? - Get kubernetes apiserver prometheus metrics with kubectl? 普罗米修斯自定义指标未出现在 custom.metrics kubernetes - Prometheus custom metric does not appear in custom.metrics kubernetes Prometheus找不到自托管的Kubernetes集群的Apiserver - Prometheus cannot find Apiserver of self-hosted Kubernetes cluster Prometheus statsd-exporter - 如何在请求持续时间指标(直方图)中标记状态代码 - Prometheus statsd-exporter - how to tag status code in request duration metric (histogram) 用于水平自动缩放的 kubernetes / prometheus 自定义指标 - kubernetes / prometheus custom metric for horizontal autoscaling 如何在 Prometheus/Grafana 中配置 Rabbitmq Metric Kubernetes - How to configure Rabbitmq Metric in Prometheus/Grafana Kubernetes 使用 Prometheus 的平均请求持续时间 - Average request duration using Prometheus Kubernetes - 做什么<unset>意味着在服务的端口? - Kubernetes - what does <unset> mean in port in a service? Kubernetes cronjobs`startingDeadlineSeconds&#39;究竟意味着什么? - What does Kubernetes cronjobs `startingDeadlineSeconds` exactly mean?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM