dnck / circonus-irondb-datasource

Circonus IRONdb datasource plugin for Grafana.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

IRONdb Datasource

This is the plugin for IRONdb 0.17.1 and newer. It is evolving and we continue to track its API.

Read more about IRONdb here:

https://www.circonus.com/irondb/

Installation

From Releases

  1. Download the desired release version.

  2. Unzip into plugins directory.

  3. Restart Grafana.

From GitHub

  1. git clone https://github.com/circonus-labs/circonus-irondb-datasource.git into plugins directory.

  2. Restart Grafana.

Alerts & Plugin Signing

To use Grafana's alerting functionality, additional build & configuration steps are required. Read more here.

Configuration

  1. Create a new datasource and select IRONdb from the Type drop down.

  2. Change the IRONdb configuration options at the bottom of the datasource configuration page.

IRONdb Type

  • Standalone: An IRONdb cluster accessible directly, requires entry of Account ID.
  • Hosted: An IRONdb instance hosted by Circonus, requires entry of API token.

Account ID

The Account ID associated with the account to pull metrics from.

API Token

The API Token associated with the account to pull metrics from. This can be found on your API Tokens page after logging in at https://www.circonus.com/ in the "User Profile" section.

Usage

  1. Create a new panel and set the datasource to name selected in the IRONdb datasource configuration.

Normal Queries

For normal queries, use the metric browser to navigate the metric hierarchy of your IRONdb instance or type queries manually using the Toggle Edit Mode menu item to the right.

CAQL Queries

CAQL queries must be entered manually by selecting the CAQL checkbox or switching manually to the editor mode.

Histograms

Histograms currently require a special checkbox to be selected in order for the returned data to be processed correctly. Once selected, histogram data processing will be utilized for any returned data related to the specific metric.

Heatmaps

Using the histogram checkbox to process returned data allows for histograms to be displayed on the heatmap panel type.

For this processed data to be displayed on the heatmap panel as the sample above, select Time Series Buckets as the Data Format to be used on the Heatmap panel.

Template Variables

How to configure a template variable for IRONdb

  1. From a dashboard, click Settings in the top right.

  2. On the left hand side, select the Variables section.

  3. Click +New and choose a name for your new variable.

  4. Select the proper data source: IRONdb.

  5. Under Query, enter the metric you wish to use in this variable (without tags), or enter the fully formed tag query, ala: and(__name:foo,or(bar:baz,quux:*)). Note that this query can contain references to other variables (see example below)

  6. If you enable Include All Option, enter * for the Custom all value.

  7. Click Enabled under Value groups/tags to enable tags support.

  8. Enter the tag category you wish to use in your variable under Tag values query. See example below.

  9. If you successfully completed the prior steps, Preview of values should now auto-complete the tag values.

  10. Finish setup by clicking Add and then Save.

Example:

In this example, we are creating a variable called namespace using the query and(__name:used,cluster:$cluster) which contains a reference to another variable (not pictured). We are then pulling the values out of a tag also called namespace (you can see the preview values).

In this way you can make dependent variables that change in a hierarchy based on prior chosen variables.

Your new template variable should now appear in the query builder!

Development

The build process requires node, npm, yarn, typescrypt, and tslint

On Cent7 setup:

# One time setup
sudo yum install node bzip2
sudo npm install -g typescript tslint
yarn

# Build
yarn build

# Test
yarn test

About

Circonus IRONdb datasource plugin for Grafana.

License:BSD 3-Clause "New" or "Revised" License


Languages

Language:TypeScript 75.3%Language:HTML 9.7%Language:Go 8.1%Language:Shell 2.2%Language:JavaScript 2.0%Language:CSS 1.8%Language:PowerShell 0.9%