Skip to content

Commit

Permalink
Release version 1.2.0
Browse files Browse the repository at this point in the history
  • Loading branch information
sileht committed May 30, 2017
1 parent 6122f1f commit ab9f8e6
Show file tree
Hide file tree
Showing 12 changed files with 149 additions and 72 deletions.
4 changes: 3 additions & 1 deletion dist/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -90,9 +90,11 @@ Gnocchi Datasource Plugin provides following functions in `Variables values quer

Name | Description
| ------- | --------|
`metrics(resource_id)` | Returns a list of metrics avialable for the resource identified by ‘resource_id’
`metrics(resource_id)` | Returns a list of metrics available for the resource identified by ‘resource_id’
`resources(resource_type, `attribute`, query)` | Returns a list of resource `attribute` matching `query`.

![](https://raw.githubusercontent.com/gnocchixyz/grafana-gnocchi-datasource/master/docs/gnocchi_templating.png)

For details of `Query` format, please refer to the Gnocchi and Gnocchi client documentations.

- [Search for resource - Gnocchi client Documentation](http://gnocchi.xyz/gnocchiclient/shell.html#gnocchi-resource-search) for expression format
Expand Down
114 changes: 72 additions & 42 deletions dist/datasource.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/datasource.js.map

Large diffs are not rendered by default.

24 changes: 12 additions & 12 deletions dist/docs/example_dashboard.json
Original file line number Diff line number Diff line change
Expand Up @@ -88,12 +88,12 @@
{
"aggregator": "mean",
"hide": false,
"label": "",
"label": "display_name",
"metric_name": "cpu_util",
"queryMode": "resource_search",
"refId": "A",
"resource_id": "",
"resource_search": "{\"like\": {\"original_resource_id\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance",
"validQuery": true
}
Expand Down Expand Up @@ -184,11 +184,11 @@
{
"aggregator": "mean",
"hide": false,
"label": "",
"label": "display_name",
"metric_name": "memory.usage",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"display_name\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance",
"validQuery": true
}
Expand Down Expand Up @@ -283,7 +283,7 @@
"metric_name": "disk.device.write.bytes.rate",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_disk",
"validQuery": true
}
Expand Down Expand Up @@ -370,7 +370,7 @@
"metric_name": "disk.device.write.bytes",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_disk",
"validQuery": true
}
Expand Down Expand Up @@ -464,7 +464,7 @@
"metric_name": "disk.device.read.bytes.rate",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_disk",
"validQuery": true
}
Expand Down Expand Up @@ -550,7 +550,7 @@
"metric_name": "disk.device.read.bytes",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_disk",
"validQuery": true
}
Expand Down Expand Up @@ -644,7 +644,7 @@
"metric_name": "network.outgoing.bytes.rate",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"instance-%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_network_interface",
"validQuery": true
}
Expand Down Expand Up @@ -730,7 +730,7 @@
"metric_name": "network.outgoing.bytes",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"instance-%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_network_interface",
"validQuery": true
}
Expand Down Expand Up @@ -824,7 +824,7 @@
"metric_name": "network.incoming.bytes.rate",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"instance-%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_network_interface",
"validQuery": true
}
Expand Down Expand Up @@ -910,7 +910,7 @@
"metric_name": "network.incoming.bytes",
"queryMode": "resource_search",
"refId": "A",
"resource_search": "{\"like\": {\"original_resource_id\": \"instance-%\"}}",
"resource_search": "original_resource_id like '%'",
"resource_type": "instance_network_interface",
"validQuery": true
}
Expand Down
Binary file added dist/docs/gnocchi_templating.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
5 changes: 3 additions & 2 deletions dist/partials/config.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,10 @@
</datasource-http-settings>

<div class="gf-info-box" style="margin: 10px 0 30px 0" ng-if="ctrl.current.access == 'direct'">
When "direct" access is used, Gnocchi and Keystone MUST have CORS configured correctly on the server side.<br />
When "direct" access is used, Gnocchi and Keystone MUST have CORS configured correctly on the server side.<br /><br />
</div>
<h3>Gnocchi Details</h3>
<div class="gf-form-group">
<div class="gf-form-group" ng-if="!ctrl.current.basicAuth">
<div class="gf-form-inline">
<div class="gf-form max-width-30">
<span class="gf-form-label width-7">Auth Mode</span>
Expand All @@ -20,6 +20,7 @@ <h3>Gnocchi Details</h3>
</div>
</div>
<div style="padding:5px">
<span ng-if="ctrl.current.jsonData.mode == 'noauth'">noauth is deprecated</span>
<span ng-if="ctrl.current.access == 'direct' && ctrl.current.jsonData.mode == 'keystone'">The Keystone URL is expected in Http settings</span>
<span ng-if="ctrl.current.access == 'proxy' && ctrl.current.jsonData.mode == 'keystone'">This configuration can't works, select another 'Access' or 'Auth Mode'</span>
<span ng-if="ctrl.current.jsonData.mode != 'keystone'">The Gnocchi URL is expected in Http settings</span>
Expand Down
3 changes: 2 additions & 1 deletion dist/partials/query.editor.html
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@
<select ng-model="ctrl.target.aggregator" class="gf-form-input input-small" ng-options="a for a in ctrl.aggregators" ng-change="ctrl.queryUpdated()"> </select>
</div>
<div class="gf-form max-width-20" ng-if="['resource', 'resource_search', 'resource_aggregation'].indexOf(ctrl.target.queryMode) >= 0" >
<label class="gf-form-label query-keyword width-8">Label <span ng-if="target.queryMode !== 'resource_aggregation'">attribute</span></label>
<label class="gf-form-label query-keyword width-8" ng-if="target.queryMode !== 'resource_aggregation'">Label</label>
<label class="gf-form-label query-keyword width-8" ng-if="target.queryMode === 'resource_aggregation'">Resource attribute or label</label>
<input type="text" class="gf-form-input" ng-model="ctrl.target.label" spellcheck='false' placeholder="id" data-min-length=0 ng-model-onblur ng-blur="ctrl.queryUpdated()">
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion dist/plugin.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
],
"screenshots": [
],
"version": "1.1.0",
"version": "1.2.0",
"updated": "2016-07-04"
},

Expand Down
8 changes: 4 additions & 4 deletions dist/query_ctrl.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit ab9f8e6

Please sign in to comment.