-
Notifications
You must be signed in to change notification settings - Fork 55
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 the cortex-mixin work on non-k8s deployments. #43
Conversation
- Put all the mixin config in one place. - Make dashboardWithTagsAndLinks just an override on the dashboard constructor. - Factor out the helper functions. Signed-off-by: Tom Wilkie <tom@grafana.com>
- Move the dashboards to separate files and namespace them off so they only have access to the config. - Add a AddRowIf helper to massively rationalise the inclusion / exclusion of rates. - Alter how we conditionally include dashboards themselves. Should be a no-op change to the dashboards themselve. Signed-off-by: Tom Wilkie <tom@grafana.com>
Signed-off-by: Tom Wilkie <tom@grafana.com>
…le process mode. Signed-off-by: Tom Wilkie <tom@grafana.com>
…ary. Signed-off-by: Tom Wilkie <tom@grafana.com>
Signed-off-by: Tom Wilkie <tom@grafana.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I took a quick look and had a few questions. I noticed some dashboards and the recording rules still have cluster hardcoded but I assume that will come later.
I really like the new style of using functions to generate these things.
|
||
// The ,ixin allow specialism of the job selector depending on if its a single binary | ||
// deployment or a namespaced one. | ||
jobMatcher(job):: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How are you going differentiate the metrics from each module using a Job? Is it going to be magic in the scrape config or are we going to allow cortex to run with component specific registries upstream?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure this is actually much of a problem - redundant metrics exported by jobs (ie ingester metrics from the distributor) don't influence the final results (ie qps or latency). For almost all cases, we can target specific eg methods to get the qps/latency of a specific component. In some cases (kv stores) the metrics aren't broken out like that yet[1], but for eg caches they are. So I think we'll be okay.
Do you have a specific case in mind?
Co-Authored-By: Jacob Lisi <jacob.t.lisi@gmail.com>
Thanks for the feedback Jacob!
I think we can get away with still having the |
Signed-off-by: Tom Wilkie <tom@grafana.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Result looks good to me, new organization makes lot of sense. I don't appreciate monster PR – these changes would be easy to split into smaller PRs.
Also, in my Grafana I have datasources pointing to single-binary Cortex and multi-service Cortex as well. Do you think it would be possible to handle such deployments by your dashboards somehow?
Signed-off-by: Tom Wilkie <tom@grafana.com>
Signed-off-by: Tom Wilkie <tom@grafana.com>
Make the cortex-mixin work on non-k8s deployments.
But first, a bunch of refactoring to tidy the dashboards up:
AddRowIf
helper to massively rationalise the inclusion / exclusion of rows.