Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[elasticsearch module] serialize shards properties #30408

Merged
merged 4 commits into from
Feb 16, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -30340,6 +30340,13 @@ type: long

--

*`elasticsearch.index.shards.primaries`*::
+
--
type: long

--

*`elasticsearch.index.uuid`*::
+
--
Expand Down
2 changes: 1 addition & 1 deletion metricbeat/module/elasticsearch/fields.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions metricbeat/module/elasticsearch/index/_meta/data.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
}
},
"shards": {
"total": 1
"total": 1,
"primaries": 1
},
"status": "green",
"total": {
Expand Down Expand Up @@ -89,4 +90,4 @@
"address": "172.19.0.2:9200",
"type": "elasticsearch"
}
}
}
2 changes: 2 additions & 0 deletions metricbeat/module/elasticsearch/index/_meta/fields.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@
fields:
- name: total
type: long
- name: primaries
type: long
- name: uuid
type: keyword
- name: status
Expand Down
2 changes: 1 addition & 1 deletion metricbeat/module/elasticsearch/index/data.go
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ type total struct {

type shardStats struct {
Total int `json:"total"`
Primaries int `json:"-"`
Primaries int `json:"primaries"`
Replicas int `json:"-"`

ActiveTotal int `json:"-"`
Expand Down