跳转到主要内容

Riemann的Python3客户端

项目描述

Bernhard

Bernhard是一个简单的Python3客户端,用于Riemann。用法

import bernhard

c = bernhard.Client()
c.send({'host': 'myhost.foobar.com', 'service': 'myservice', 'metric': 12})
q = c.query('true')

Bernhard支持使用以下语法自定义属性

import bernhard

c = bernhard.Client()

c.send({'host': 'awesome.host.com', 'attributes': {'sky': 'sunny', 'sea': 'agitated'}})

查询索引就像这样简单

import bernhard

c = bernhard.Client()
q = c.query('true')
for e in q:
    print "Host:", e.host, "State:", e.state

安装

pip install bernhard-py3

项目详情


下载文件

为您的平台下载文件。如果您不确定要选择哪个,请了解有关安装包的更多信息。

源代码发行版

bernhard-py3-1.0.1.tar.gz (10.1 kB 查看哈希值)

上传时间: 源代码

支持者

AWS AWS 云计算和安全赞助商 Datadog Datadog 监控 Fastly Fastly CDN Google Google 下载分析 Microsoft Microsoft PSF 赞助商 Pingdom Pingdom 监控 Sentry Sentry 错误记录 StatusPage StatusPage 状态页面