damn MI (cont'd)
Let's say, you use inheritance like
class A: public B, public RTTI<A, B>{
};
ok, good, users have getTypeName, getSuperType functions.
then you give this lib to your coworkers.
three months later, you realized that "hey, wouldn't it be a good idea to add getNamespace() into the RTTI?" so, you work and work and work, finally RTTI has another virtual function
virtual const char* getNamespace();
But, you did not know what a guy, already used this function in his class B.
So actually if he says
class B: A, RTTI<A, B>{......};
he will not get the expected behavior for getNamespace() because he used this function for some other purpose.
In that case, I would suggest you to summon a meeting with all the developers and say "hey, does any one of you used the name getNamespace() in your class?"
相关推荐
blackbox_exporter监控模板.zip
包含http监控模板,端口监控模板,证书监控模板,真实可靠
用Prometheus对业务服务进行监控
这里分享一个用于黑盒监控的blackbox_exporter, 可以用于对http,https,tcp,dns以及ICMP协议进行探测,从而抓取数据进行监控。但是,这些对于我们来说究竟能解决什么用处。 我们可以通过blackbox_exporter对服务进行状态码监测,我们可以在代码中查看返回成功的状态码是哪些,状态码监测规则可以通过下图看出。 这样的话,我们就可以判断服务是否还在正常的工作,网...
Prometheus黑盒监控实战:Blackbox Exporter多协议探测配置详解
本文详细介绍了Prometheus黑盒监控工具Blackbox Exporter的多协议探测配置与实践。通过HTTP/HTTPS、TCP、ICMP和DNS等多种协议探测,帮助用户从外部视角验证服务可用性,提升监控效率。文章包含部署安装、配置文件解析、实战配置及Prometheus集成等核心内容,是构建高效监控系统的实用指南。
黑盒监控blackbox_exporter[项目源码]
本文详细介绍了Prometheus社区提供的官方黑盒监控解决方案——Blackbox Exporter。该工具支持通过HTTP、HTTPS、DNS、TCP和ICMP等方式对网络进行探测,用于监控服务的可用性、端口监听状态、主机存活情况等。与node_exporter等工具不同,Blackbox Exporter更关注服务已发生的异常,如接口返回码异常或机器无法连通等。文章还提供了Blackbox Exporter的部署步骤,包括下载、解压、配置和启动服务,并详细说明了如何通过修改blackbox.yml文件来配置不同的探测模块(如HTTP、TCP、ICMP等)。此外,还介绍了如何在Prometheus中配置相应的job来监控目标,并支持动态获取监控目标。通过本文,读者可以全面了解Blackbox Exporter的功能、部署和配置方法,以及如何将其与Prometheus集成以实现高效的黑盒监控。
blackbox-exporter公版 linux安装包
blackbox-exporter公版 linux安装包


