如何限制测井频率? [英] How to limit logging frequency?

查看:66
本文介绍了如何限制测井频率?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

任何日志记录库是否包含限制日志消息频率的任何手段?

Does any logging library contain any means to limit logging message frequency?

我的意思是假设我有一个等待循环,它记录为未完成".如何使下一条什么都没做"消息仅在说1秒钟后记录下来?

I mean suppose I have a waiting loop and it logs "Nothing done". How to make next "Nothing done" message would logged only after say 1 second?

我知道我可以自己编程.

I know I can program it myself.

推荐答案

您必须在代码中进行管理,或者需要编写一个自定义附加程序(取决于您使用的日志记录库)

You have to manage this in your code, or you need to write a custom appender (this depends on the logging library you are using)

这篇关于如何限制测井频率?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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