From 0c222c4e8c14b11046ce06f43e5e80f479283d51 Mon Sep 17 00:00:00 2001 From: Jimmi Dyson Date: Wed, 30 Sep 2015 16:44:16 +0100 Subject: [PATCH 1/2] Fix Prometheus test connection --- docs/sources/index.md | 2 +- public/app/plugins/datasource/prometheus/datasource.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/sources/index.md b/docs/sources/index.md index 6c1c1ce7837..f595c81ef28 100644 --- a/docs/sources/index.md +++ b/docs/sources/index.md @@ -10,7 +10,7 @@ It provides a powerful and elegant way to create, share, and explore data and da Grafana is most commonly used for Internet infrastructure and application analytics, but many use it in other domains including industrial sensors, home automation, weather, and process control. -Grafana features pluggable panels and data sources allowing easy extensibility. There is currently rich support for [Graphite](http://graphite.readthedocs.org/en/latest/), [InfluxDB](http://influxdb.org) and [OpenTSDB](http://opentsdb.net). There is also experimental support for [KairosDB](https://github.com/kairosdb/kairosdb), and SQL is on the roadmap. Grafana has a variety of panels, including a fully featured graph panel with rich visualization options. +Grafana features pluggable panels and data sources allowing easy extensibility. There is currently rich support for [Graphite](http://graphite.readthedocs.org/en/latest/), [InfluxDB](http://influxdb.org) and [OpenTSDB](http://opentsdb.net). There is also experimental support for [KairosDB](https://github.com/kairosdb/kairosdb), [Prometheus](http://prometheus.io/), and SQL is on the roadmap. Grafana has a variety of panels, including a fully featured graph panel with rich visualization options. Version 2.0 was released in April 2015: Grafana now ships with its own backend server that brings [many changes and features](../guides/whats-new-in-v2/). Version 2.1 was released in July 2015 and added [even more features and enhancements](../guides/whats-new-in-v2-1/). diff --git a/public/app/plugins/datasource/prometheus/datasource.js b/public/app/plugins/datasource/prometheus/datasource.js index 75970636642..7a4316a528e 100644 --- a/public/app/plugins/datasource/prometheus/datasource.js +++ b/public/app/plugins/datasource/prometheus/datasource.js @@ -212,7 +212,7 @@ function (angular, _, moment, dateMath) { }; PrometheusDatasource.prototype.testDatasource = function() { - return this.metricFindQuery('*').then(function() { + return this.metricFindQuery('metrics(.*)').then(function() { return { status: 'success', message: 'Data source is working', title: 'Success' }; }); }; From 7cadb9012a2b6f15a8e38600ae03ed6b7b274e6e Mon Sep 17 00:00:00 2001 From: Jimmi Dyson Date: Wed, 30 Sep 2015 16:45:38 +0100 Subject: [PATCH 2/2] Switch to png image --- docs/sources/datasources/prometheus.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/sources/datasources/prometheus.md b/docs/sources/datasources/prometheus.md index f3069d68a62..e975a5cf8a4 100644 --- a/docs/sources/datasources/prometheus.md +++ b/docs/sources/datasources/prometheus.md @@ -8,7 +8,7 @@ page_keywords: grafana, prometheus, metrics, query, documentation Grafana includes support for Prometheus Datasources. While the process of adding the datasource is similar to adding a Graphite or OpenTSDB datasource type, Prometheus does have a few different options for building queries. ## Adding the data source to Grafana -![](/img/v2/add_Prometheus.jpg) +![](/img/v2/add_Prometheus.png) 1. Open the side menu by clicking the the Grafana icon in the top header. 2. In the side menu under the `Dashboards` link you should find a link named `Data Sources`.