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

Index kibana_settings docs for Kibana X-Pack Monitoring #7621

Closed
ycombinator opened this issue Jul 17, 2018 · 4 comments · Fixed by #7664
Closed

Index kibana_settings docs for Kibana X-Pack Monitoring #7621

ycombinator opened this issue Jul 17, 2018 · 4 comments · Fixed by #7664
Assignees
Labels

Comments

@ycombinator
Copy link
Contributor

As a follow up to elastic/kibana#20577 and as a part of making progress on #7035, we need a settings metricset in the kibana metricbeat module. This metricset would poll the Kibana settings API and ship its results into .kibana-monitoring-6-* indices provided xpack.enabled: true is set in the module's configuration.

@ycombinator
Copy link
Contributor Author

@ruflin I would like to make this metricset xpack-only (i.e. it only fetches and ships if xpack.enabled: true), since this information is only really needed by X-Pack Monitoring to make Cluster Alerts work today.

In the mid/long term Cluster Alerts will be driven entirely from within Kibana and will not rely on settings documents in .monitoring-kibana-6-* indices. At that time we can remove this metricset (and the associated settings API in Kibana).

Thoughts?

@ruflin
Copy link
Member

ruflin commented Jul 18, 2018

To not have to create a metricset which is X-Pack only I wonder if we could merge it into the x-pack stats metricset. Meaning we by default it sends 2 events.

@ycombinator
Copy link
Contributor Author

I think we could do that but the stats metricset would need to make two API calls to Kibana when xpack.enabled: true: one to <kibana host:port>/api/stats and one to <kibana host:port>/api/settings.

I'm not entirely sure how to make this happen, given how we create a http helper from a metricset object by calling helper.NewHTTP in stats.New. Do we create two http helpers in stats.New? Or do we keep just the one helper but set/reset its URL in stats.Fetch? Or something else? Maybe there an existing metricset that does this sort of thing (makes two API calls) I could look at?

@ruflin
Copy link
Member

ruflin commented Jul 19, 2018

I would opt for the two request. We do this trick also for Elasticsearch where we need to fetch additional info for the event. It's a bit hacky but it works.

@ycombinator ycombinator changed the title Kibana settings metricset for Kibana X-Pack Monitoring Index kibana_settings docs for Kibana X-Pack Monitoring Jul 20, 2018
ruflin pushed a commit that referenced this issue Aug 9, 2018
Resolves #7621.

Depends on elastic/kibana#21100.

X-Pack Monitoring of Kibana requires two types of documents in the `.monitoring-kibana-*` indices: `kibana_stats` and `kibana_settings`. We made Metricbeat's `kibana/stats` metricset index `kibana_stats` documents into `.monitoring-kibana-*` in #7525. This PR makes the same metricset index `kibana_settings` documents into `.monitoring-kibana-*`.
ycombinator added a commit to ycombinator/beats that referenced this issue Aug 10, 2018
Resolves elastic#7621.

Depends on elastic/kibana#21100.

X-Pack Monitoring of Kibana requires two types of documents in the `.monitoring-kibana-*` indices: `kibana_stats` and `kibana_settings`. We made Metricbeat's `kibana/stats` metricset index `kibana_stats` documents into `.monitoring-kibana-*` in elastic#7525. This PR makes the same metricset index `kibana_settings` documents into `.monitoring-kibana-*`.

(cherry picked from commit 2af5ab9)
ruflin pushed a commit that referenced this issue Aug 13, 2018
Resolves #7621.

Depends on elastic/kibana#21100.

X-Pack Monitoring of Kibana requires two types of documents in the `.monitoring-kibana-*` indices: `kibana_stats` and `kibana_settings`. We made Metricbeat's `kibana/stats` metricset index `kibana_stats` documents into `.monitoring-kibana-*` in #7525. This PR makes the same metricset index `kibana_settings` documents into `.monitoring-kibana-*`.

(cherry picked from commit 2af5ab9)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants