1 Star 0 Fork 0

sqos/beats

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
data.go 1.12 KB
一键复制 编辑 原始数据 按行查看 历史
package database
import (
"time"
s "github.com/elastic/beats/metricbeat/schema"
c "github.com/elastic/beats/metricbeat/schema/mapstrstr"
)
// Based on https://www.postgresql.org/docs/9.2/static/monitoring-stats.html#PG-STAT-DATABASE-VIEW
var schema = s.Schema{
"oid": c.Int("datid"),
"name": c.Str("datname"),
"number_of_backends": c.Int("numbackends"),
"transactions": s.Object{
"commit": c.Int("xact_commit"),
"rollback": c.Int("xact_rollback"),
},
"blocks": s.Object{
"read": c.Int("blks_read"),
"hit": c.Int("blks_hit"),
"time": s.Object{
"read": s.Object{"ms": c.Int("blk_read_time")},
"write": s.Object{"ms": c.Int("blk_write_time")},
},
},
"rows": s.Object{
"returned": c.Int("tup_returned"),
"fetched": c.Int("tup_fetched"),
"inserted": c.Int("tup_inserted"),
"updated": c.Int("tup_updated"),
"deleted": c.Int("tup_deleted"),
},
"conflicts": c.Int("conflicts"),
"temporary": s.Object{
"files": c.Int("temp_files"),
"bytes": c.Int("temp_bytes"),
},
"deadlocks": c.Int("deadlocks"),
"stats_reset": c.Time(time.RFC3339Nano, "stats_reset", s.Optional),
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/sqos/beats.git
git@gitee.com:sqos/beats.git
sqos
beats
beats
v6.0.0-alpha1

搜索帮助

0d507c66 1850385 C8b1a773 1850385