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

Add module for cockroachdb #12467

Merged
merged 18 commits into from
Jun 28, 2019
Merged

Conversation

jsoriano
Copy link
Member

@jsoriano jsoriano commented Jun 6, 2019

Depends on #12465, module implemented as light module (#12270).

Collect metrics from cochroachdb, from its Prometheus endpoint.
All metrics are collected as they are and stored under prometheus.metrics.

An overview dashboard is added:
Captura de pantalla de 2019-06-25 21-18-14

Pending:

@jsoriano jsoriano added in progress Pull request is currently in progress. module Metricbeat Metricbeat [zube]: In Progress Team:Integrations Label for the Integrations team labels Jun 6, 2019
@jsoriano jsoriano self-assigned this Jun 6, 2019
@exekias
Copy link
Contributor

exekias commented Jun 6, 2019

I see the pending point of fields.yml. This one is interesting, as already present Prometheus fields.yml gives us the right mapping already, still, there are no docs for the fields that we will get from the module. Is that why it's on the list?

@jsoriano
Copy link
Member Author

jsoriano commented Jun 6, 2019

I see the pending point of fields.yml. This one is interesting, as already present Prometheus fields.yml gives us the right mapping already, still, there are no docs for the fields that we will get from the module. Is that why it's on the list?

Yeah, I'd like to explore the possibility of getting the documentation for these fields automatically. If not it will require at least an empty fields.yml to pass our tests (or we have to change the tests).

@ruflin
Copy link
Member

ruflin commented Jun 7, 2019

@jsoriano Is there a way to also have generated files for these light modules? This would be nice for testing, docs but also for us to see if the generated events outside the prometheus metrics contain the correct values (for example event.dataset).

@jsoriano
Copy link
Member Author

jsoriano commented Jun 7, 2019

@jsoriano Is there a way to also have generated files for these light modules? This would be nice for testing, docs but also for us to see if the generated events outside the prometheus metrics contain the correct values (for example event.dataset).

I would use by now the tools we already have, it should be possible to use current prometheus helpers to test this module and generate the data.json file. I wrote a bit about testing and tooling in the proposal.

@ruflin
Copy link
Member

ruflin commented Jun 7, 2019

@jsoriano Would be great to have the generated file directly as part of this PR to make sure we generate the right data. Great if the current tools already work.

@kaiyan-sheng
Copy link
Contributor

Just curious, when there are changes made in prometheus module, for example Pablo's le change on histogram, will tests fail in modules like cockroachdb?

@jsoriano
Copy link
Member Author

Just curious, when there are changes made in prometheus module, for example Pablo's le change on histogram, will tests fail in modules like cockroachdb?

Yes, tests will fail and affected files will need to be regenerated. This would be similar to other changes we do in the framework that require regenerating golden files.

@jsoriano
Copy link
Member Author

Dashboard added, screenshot uploaded to issue description.

@jsoriano
Copy link
Member Author

@exekias I have been playing with the possibility of generating fields.yml and docs for fields from the prometheus response, find here the changes over this PR: jsoriano#3
I think that using these fields for the mapping can be a bit excesive as they are hundreds of new fields and we already have the wildcards, but it could be nice for the documentation. But this would require more changes in the doc generator.
What do you think? Does it worth it? or I leave the fields undocumented by now?

@exekias
Copy link
Contributor

exekias commented Jun 27, 2019

Leaving them for another PR sounds reasonable to me, will comment there!

Is this one ready for review?

@jsoriano jsoriano marked this pull request as ready for review June 27, 2019 11:58
@jsoriano jsoriano requested review from a team as code owners June 27, 2019 11:58
@jsoriano
Copy link
Member Author

Opening for review, there are some things pending but they are mostly for tests and docs, we can do them in future PRs.

@jsoriano jsoriano added [zube]: In Review review and removed [zube]: In Progress in progress Pull request is currently in progress. labels Jun 27, 2019
@jsoriano jsoriano merged commit a1e3539 into elastic:master Jun 28, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Metricbeat Metricbeat module review Team:Integrations Label for the Integrations team v7.3.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants