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

Make elasticsearch/index_summary metricset work for Stack Monitoring without xpack.enabled flag #20615

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
260 changes: 260 additions & 0 deletions metricbeat/docs/fields.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -18134,6 +18134,58 @@ alias to: elasticsearch.node.stats.thread_pool.write.rejected.count

--





*`indices_stats._all.primaries.indexing.index_total`*::
+
--
type: alias

alias to: elasticsearch.index.summary.primaries.indexing.index.count

--

*`indices_stats._all.primaries.indexing.index_time_in_millis`*::
+
--
type: alias

alias to: elasticsearch.index.summary.primaries.indexing.index.time.ms

--



*`indices_stats._all.total.search.query_total`*::
+
--
type: alias

alias to: elasticsearch.index.summary.total.search.query.count

--

*`indices_stats._all.total.search.query_time_in_millis`*::
+
--
type: alias

alias to: elasticsearch.index.summary.total.search.query.time.ms

--


*`indices_stats._all.total.indexing.index_total`*::
+
--
type: alias

alias to: elasticsearch.index.summary.total.indexing.index.count

--

[float]
=== elasticsearch

Expand Down Expand Up @@ -18688,6 +18740,110 @@ format: bytes
--


*`elasticsearch.index.summary.primaries.indexing.index.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.indexing.index.time.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.indexing.is_throttled`*::
+
--
TODO

type: boolean

--

*`elasticsearch.index.summary.primaries.indexing.throttle_time.ms`*::
+
--
TODO

type: long

--



*`elasticsearch.index.summary.primaries.search.query.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.search.query.time.ms`*::
+
--
TODO

type: long

--


*`elasticsearch.index.summary.primaries.bulk.operations.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.bulk.size.bytes`*::
+
--
TODO

type: long

--


*`elasticsearch.index.summary.primaries.bulk.time.count.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.bulk.time.avg.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.primaries.bulk.time.avg.bytes`*::
+
--
TODO

type: long

--


*`elasticsearch.index.summary.total.docs.count`*::
+
--
Expand Down Expand Up @@ -18742,6 +18898,110 @@ format: bytes

--


*`elasticsearch.index.summary.total.indexing.index.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.indexing.index.time.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.indexing.is_throttled`*::
+
--
TODO

type: boolean

--

*`elasticsearch.index.summary.total.indexing.throttle_time.ms`*::
+
--
TODO

type: long

--



*`elasticsearch.index.summary.total.search.query.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.search.query.time.ms`*::
+
--
TODO

type: long

--


*`elasticsearch.index.summary.total.bulk.operations.count`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.bulk.size.bytes`*::
+
--
TODO

type: long

--


*`elasticsearch.index.summary.total.bulk.time.count.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.bulk.time.avg.ms`*::
+
--
TODO

type: long

--

*`elasticsearch.index.summary.total.bulk.time.avg.bytes`*::
+
--
TODO

type: long

--

[float]
=== ml.job

Expand Down
36 changes: 36 additions & 0 deletions metricbeat/module/elasticsearch/_meta/fields.yml
Original file line number Diff line number Diff line change
Expand Up @@ -276,6 +276,42 @@
- name: rejected
path: elasticsearch.node.stats.thread_pool.write.rejected.count
type: alias
- name: indices_stats
type: group
fields:
- name: _all
type: group
fields:
- name: primaries
type: group
fields:
- name: indexing
type: group
fields:
- name: index_total
type: alias
path: elasticsearch.index.summary.primaries.indexing.index.count
- name: index_time_in_millis
type: alias
path: elasticsearch.index.summary.primaries.indexing.index.time.ms
- name: total
type: group
fields:
- name: search
type: group
fields:
- name: query_total
type: alias
path: elasticsearch.index.summary.total.search.query.count
- name: query_time_in_millis
type: alias
path: elasticsearch.index.summary.total.search.query.time.ms
- name: indexing
type: group
fields:
- name: index_total
type: alias
path: elasticsearch.index.summary.total.indexing.index.count
- name: elasticsearch
type: group
description: >
Expand Down
10 changes: 0 additions & 10 deletions metricbeat/module/elasticsearch/elasticsearch.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,6 @@ import (
"github.com/pkg/errors"

"github.com/elastic/beats/v7/libbeat/common"
s "github.com/elastic/beats/v7/libbeat/common/schema"
c "github.com/elastic/beats/v7/libbeat/common/schema/mapstriface"
"github.com/elastic/beats/v7/libbeat/logp"
"github.com/elastic/beats/v7/metricbeat/helper"
"github.com/elastic/beats/v7/metricbeat/helper/elastic"
Expand Down Expand Up @@ -119,14 +117,6 @@ type licenseWrapper struct {
License License `json:"license"`
}

var BulkStatsDict = c.Dict("bulk", s.Schema{
"total_operations": c.Int("total_operations"),
"total_time_in_millis": c.Int("total_time_in_millis"),
"total_size_in_bytes": c.Int("total_size_in_bytes"),
"avg_time_in_millis": c.Int("avg_time_in_millis"),
"avg_size_in_bytes": c.Int("avg_size_in_bytes"),
}, c.DictOptional)

// GetClusterID fetches cluster id for given nodeID.
func GetClusterID(http *helper.HTTP, uri string, nodeID string) (string, error) {
// Check if cluster id already cached. If yes, return it.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ func TestXPackEnabled(t *testing.T) {
"cluster_stats": []string{"cluster_stats"},
"enrich": []string{"enrich_coordinator_stats"},
"index_recovery": []string{"index_recovery"},
"index_summary": []string{"indices_stats"},
"index_summary": []string{}, // no longer indexed into .monitoring-es-*
"ml_job": []string{"job_stats"},
"node_stats": []string{}, // no longer indexed into .monitoring-es-*
}
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.

Loading