我有一个简单的CI监控 - 从Bamboo获取数据到InfluxDB并在Grafana中显示各种内容 .

我在Influx中的记录如下:

time          Key            result
---------------------------------------------------
xxxx1         plan-1             "Success"
xxxx2         plan-1             "Failure"
xxxx3         plan-1             "Success"
xxxx4         plan-1             "Success"
xxxx5         plan-1             "Success"
xxxx6         plan-1             "Success"
xxxx7         plan-1             "Failure"

我想测量的是“失败”之前连续多少“成功”记录 . 并做一些最小,最大和其他功能

所以在这个例子中,我希望在它之上看到(1,4)avg,min和max

所以我试图看到像“平均'时间'打破”的指标等等(其中'时间'不是时间,而是构建数量......)

有没有可能从InfluxDB获得这个?或者让它在格拉法纳计算?或者我是否必须通过某些脚本手动添加这些值?