1 Star 0 Fork 0

sqos/beats

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
data.go 1.06 KB
一键复制 编辑 原始数据 按行查看 历史
package dbstats
import (
s "github.com/elastic/beats/libbeat/common/schema"
c "github.com/elastic/beats/libbeat/common/schema/mapstriface"
)
var schema = s.Schema{
"db": c.Str("db"),
"collections": c.Int("collections"),
"objects": c.Int("objects"),
"avg_obj_size": s.Object{
"bytes": c.Int("avgObjSize"),
},
"data_size": s.Object{
"bytes": c.Int("dataSize"),
},
"storage_size": s.Object{
"bytes": c.Int("storageSize"),
},
"num_extents": c.Int("numExtents"),
"indexes": c.Int("indexes"),
"index_size": s.Object{
"bytes": c.Int("indexSize"),
},
// mmapv1 only
"ns_size_mb": s.Object{
"mb": c.Int("nsSizeMB", s.Optional),
},
// mmapv1 only
"file_size": s.Object{
"bytes": c.Int("fileSize", s.Optional),
},
// mmapv1 only
"data_file_version": c.Dict("dataFileVersion", s.Schema{
"major": c.Int("major"),
"minor": c.Int("minor"),
}, c.DictOptional),
// mmapv1 only
"extent_free_list": c.Dict("extentFreeList", s.Schema{
"num": c.Int("num"),
"size": s.Object{
"bytes": c.Int("size", s.Optional),
},
}, c.DictOptional),
}
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/sqos/beats.git
git@gitee.com:sqos/beats.git
sqos
beats
beats
v6.1.1

搜索帮助

0d507c66 1850385 C8b1a773 1850385