检索猫鼬查询队列时间指标 [英] Retrieve Mongoose Query Queue Time Metrics

查看:85
本文介绍了检索猫鼬查询队列时间指标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

为了优化连接池大小,我认为对查询队列时间进行图形化将很有意义.是否可以从猫鼬中检索该指标?

In order to optimize the connection pool size, I thought it would make sense to graph query queue times. Is it possible to retrieve this metric from Mongoose?

推荐答案

请参见此处用于节点监视.您需要那里显然没有记录的cmap事件,请参阅

See here for node monitoring. You need cmap events that apparently aren't documented there, see Ruby docs for example but they should be published by the node driver also.

跟踪ConnectionCheckOutStarted和ConnectionCheckOutSucceeded并减去时间以获取等待时间.

Track ConnectionCheckOutStarted and ConnectionCheckOutSucceeded and subtract the times to get the wait time.

这篇关于检索猫鼬查询队列时间指标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆