From 76c586c467dfba810acbcc6c6778745c9b9f1a00 Mon Sep 17 00:00:00 2001 From: vargburz Date: Thu, 9 Jun 2022 13:27:02 +0300 Subject: [PATCH 01/17] add checks and errors --- src/components/editors/UseMetricEditor.tsx | 16 +++++++++------- src/models/options.ts | 10 ++++++++-- src/models/series.ts | 2 +- 3 files changed, 18 insertions(+), 10 deletions(-) diff --git a/src/components/editors/UseMetricEditor.tsx b/src/components/editors/UseMetricEditor.tsx index 4018e26..d91d1cc 100644 --- a/src/components/editors/UseMetricEditor.tsx +++ b/src/components/editors/UseMetricEditor.tsx @@ -8,7 +8,7 @@ import React from 'react'; import * as _ from 'lodash'; type UseMetricConfig = { - useMetric: boolean; + useMetric?: boolean; value?: number; metricName?: string; }; @@ -18,10 +18,12 @@ const fieldNamePickerSettings = { } as any; export function UseMetricEditor({ onChange, value, context }: StandardEditorProps) { - const config = value; + let config = value; const onFieldChange = (field: keyof UseMetricConfig, value: any) => { - // @ts-ignore + if(_.isNil(config)) { + config = {}; + } config[field] = value; onChange(config); @@ -31,22 +33,22 @@ export function UseMetricEditor({ onChange, value, context }: StandardEditorProp onFieldChange('useMetric', (evt.target as any).checked)} /> - {config.useMetric ? ( + {config?.useMetric ? ( onFieldChange('metricName', newVal)} item={fieldNamePickerSettings} /> ) : ( onFieldChange('value', (evt.target as any).value)} /> diff --git a/src/models/options.ts b/src/models/options.ts index f150d29..f63a74b 100644 --- a/src/models/options.ts +++ b/src/models/options.ts @@ -21,7 +21,10 @@ export class Options { } private _setMin(): void { - if (!this.grafanaOptions.gauge.min.useMetric) { + if (!this.grafanaOptions.gauge.min) { + throw new Error(`Min Config is not selected: [See options: Extremum -> Min]`); + } + if (!this.grafanaOptions.gauge.min?.useMetric) { this.minValue = this.grafanaOptions.gauge.min.value; return; } @@ -30,7 +33,10 @@ export class Options { } private _setMax(): void { - if (!this.grafanaOptions.gauge.max.useMetric) { + if (!this.grafanaOptions.gauge.max) { + throw new Error(`Max Config is not selected: [See options: Extremum -> Max]`); + } + if (!this.grafanaOptions.gauge.max?.useMetric) { this.maxValue = this.grafanaOptions.gauge.max.value; return; } diff --git a/src/models/series.ts b/src/models/series.ts index 3155a82..30a22cb 100644 --- a/src/models/series.ts +++ b/src/models/series.ts @@ -10,7 +10,7 @@ export class Series { private _selectedSerieName; constructor(grafanaSeriesList: any, private gaugeValueOptions: ValueOptions) { - if (_.isEmpty(this.gaugeValueOptions.metricName)) { + if (_.isEmpty(this.gaugeValueOptions?.metricName)) { throw new Error(`Value: metric is not selected. [See options: Value -> Metric]`); } this._selectedSerieName = this.gaugeValueOptions.metricName; From 1fcad48a2ad37b6920cf411f1de3bb0a1328b453 Mon Sep 17 00:00:00 2001 From: vargburz Date: Thu, 9 Jun 2022 13:29:59 +0300 Subject: [PATCH 02/17] linter --- src/components/editors/UseMetricEditor.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/editors/UseMetricEditor.tsx b/src/components/editors/UseMetricEditor.tsx index d91d1cc..183b635 100644 --- a/src/components/editors/UseMetricEditor.tsx +++ b/src/components/editors/UseMetricEditor.tsx @@ -21,7 +21,7 @@ export function UseMetricEditor({ onChange, value, context }: StandardEditorProp let config = value; const onFieldChange = (field: keyof UseMetricConfig, value: any) => { - if(_.isNil(config)) { + if (_.isNil(config)) { config = {}; } config[field] = value; From 3bab6996e7df5f36791314b2c0b4c8b3617c203d Mon Sep 17 00:00:00 2001 From: vargburz Date: Thu, 9 Jun 2022 14:32:12 +0300 Subject: [PATCH 03/17] add default values --- src/components/editors/UseMetricEditor.tsx | 8 +++----- src/module.ts | 3 ++- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/src/components/editors/UseMetricEditor.tsx b/src/components/editors/UseMetricEditor.tsx index 183b635..d35b375 100644 --- a/src/components/editors/UseMetricEditor.tsx +++ b/src/components/editors/UseMetricEditor.tsx @@ -8,7 +8,7 @@ import React from 'react'; import * as _ from 'lodash'; type UseMetricConfig = { - useMetric?: boolean; + useMetric: boolean; value?: number; metricName?: string; }; @@ -18,12 +18,10 @@ const fieldNamePickerSettings = { } as any; export function UseMetricEditor({ onChange, value, context }: StandardEditorProps) { - let config = value; + let config: UseMetricConfig = value; const onFieldChange = (field: keyof UseMetricConfig, value: any) => { - if (_.isNil(config)) { - config = {}; - } + // @ts-ignore config[field] = value; onChange(config); diff --git a/src/module.ts b/src/module.ts index a67da81..de92132 100644 --- a/src/module.ts +++ b/src/module.ts @@ -49,12 +49,12 @@ export const plugin = new PanelPlugin(Panel).setPanelOptions((buil category: ['Value'], showIf: (config) => config.visualizationType === Pod.GAUGE, }) - // TODO: defaults? .addCustomEditor({ id: 'min', name: 'Min', path: 'gauge.min', category: ['Extremum'], + defaultValue: { useMetric: false, value: 0 }, showIf: (config) => config.visualizationType === Pod.GAUGE, editor: UseMetricEditor as any, }) @@ -63,6 +63,7 @@ export const plugin = new PanelPlugin(Panel).setPanelOptions((buil name: 'Max', path: 'gauge.max', category: ['Extremum'], + defaultValue: { useMetric: false }, showIf: (config) => config.visualizationType === Pod.GAUGE, editor: UseMetricEditor as any, }) From 405fec293b68580835fa58e578cf10f8f16a88a0 Mon Sep 17 00:00:00 2001 From: vargburz Date: Thu, 9 Jun 2022 14:36:54 +0300 Subject: [PATCH 04/17] upd version --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 8c56f20..c28797d 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "grafana-chartwerk-panel", - "version": "0.4.0", + "version": "0.4.1", "description": "Chartwerk Panel", "scripts": { "build": "grafana-toolkit plugin:build", From de33416c3df5a4e12b1b8ae5f709e366d6820434 Mon Sep 17 00:00:00 2001 From: rozetko Date: Thu, 9 Jun 2022 15:46:53 +0400 Subject: [PATCH 05/17] upd download links --- README.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 8cb519f..3f294a0 100644 --- a/README.md +++ b/README.md @@ -27,13 +27,13 @@ - Download Chartwerk panel ``` -wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/117d957cd20276826cd092becb62dd30/corpglory-chartwerk-panel-0.4.0.zip +wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/5e1ea7ae608436d589230129313e6969/corpglory-chartwerk-panel-0.4.1.zip ``` - Unpack downloaded files ``` -unzip -u corpglory-chartwerk-panel-0.4.0.zip -d corpglory-chartwerk-panel +unzip -u corpglory-chartwerk-panel-0.4.1.zip -d corpglory-chartwerk-panel ``` - Restart grafana-server @@ -51,6 +51,6 @@ You can install Chartwerk panel to Grafana in Docker passing it as environment v ```bash docker run \ -p 3000:3000 \ - -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/117d957cd20276826cd092becb62dd30/corpglory-chartwerk-panel-0.4.0.zip;corpglory-chartwerk-panel" \ + -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/5e1ea7ae608436d589230129313e6969/corpglory-chartwerk-panel-0.4.1.zip;corpglory-chartwerk-panel" \ grafana/grafana ``` From e254bc29281f4368ed8707e4e94ceeb8f599ab51 Mon Sep 17 00:00:00 2001 From: rozetko Date: Tue, 14 Jun 2022 16:22:47 +0400 Subject: [PATCH 06/17] readme: upd download link (signed) --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 3f294a0..15f32be 100644 --- a/README.md +++ b/README.md @@ -27,7 +27,7 @@ - Download Chartwerk panel ``` -wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/5e1ea7ae608436d589230129313e6969/corpglory-chartwerk-panel-0.4.1.zip +wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/e8782155489bec4c216048e4d4e1f618/corpglory-chartwerk-panel-0.4.1.zip ``` - Unpack downloaded files @@ -51,6 +51,6 @@ You can install Chartwerk panel to Grafana in Docker passing it as environment v ```bash docker run \ -p 3000:3000 \ - -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/5e1ea7ae608436d589230129313e6969/corpglory-chartwerk-panel-0.4.1.zip;corpglory-chartwerk-panel" \ + -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/e8782155489bec4c216048e4d4e1f618/corpglory-chartwerk-panel-0.4.1.zip;corpglory-chartwerk-panel" \ grafana/grafana ``` From 27c2eaba4a68356a47166fc5f528ee264eff5fc0 Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 1 Jul 2022 19:37:40 +0300 Subject: [PATCH 07/17] ux improve: the first metric is selected by default --- package.json | 4 +-- src/components/Panel.tsx | 3 -- src/models/series.ts | 9 ++++-- src/plugin.json | 2 +- yarn.lock | 59 ++++++++++++++++++++++++++++++++++------ 5 files changed, 60 insertions(+), 17 deletions(-) diff --git a/package.json b/package.json index c28797d..ee6164b 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "grafana-chartwerk-panel", - "version": "0.4.1", + "version": "0.4.2", "description": "Chartwerk Panel", "scripts": { "build": "grafana-toolkit plugin:build", @@ -14,7 +14,7 @@ "author": "CorpGlory Inc.", "license": "GPL V3", "devDependencies": { - "@chartwerk/gauge-pod": "0.4.1", + "@chartwerk/gauge-pod": "0.6.2", "@grafana/data": "latest", "@grafana/toolkit": "latest", "@grafana/ui": "latest", diff --git a/src/components/Panel.tsx b/src/components/Panel.tsx index 50213a2..ef72dd7 100644 --- a/src/components/Panel.tsx +++ b/src/components/Panel.tsx @@ -16,12 +16,9 @@ import * as _ from 'lodash'; interface Props extends PanelProps {} export function Panel({ options, data, width, height, timeZone, timeRange, onChangeTimeRange }: Props) { - console.log('options', options); const grafanaSeriesList = getGrafanaSeriesList(data, timeRange); const series = new Series(grafanaSeriesList, options.gauge.value).getChartwerkSeries(); - console.log('series', series); const chartwerkOptions = new Options(grafanaSeriesList, options).getChartwerkOptions(); - let chartContainer = useRef(null); // we request animation frame here because we need an existing DOM-element at the moment we render the pod window.requestAnimationFrame(() => { diff --git a/src/models/series.ts b/src/models/series.ts index 30a22cb..d426763 100644 --- a/src/models/series.ts +++ b/src/models/series.ts @@ -9,9 +9,14 @@ export class Series { private _seriesList; private _selectedSerieName; - constructor(grafanaSeriesList: any, private gaugeValueOptions: ValueOptions) { + constructor(grafanaSeriesList: any[], private gaugeValueOptions: ValueOptions) { + if (_.isEmpty(grafanaSeriesList)) { + throw new Error(`No metrics has been provided`); + } if (_.isEmpty(this.gaugeValueOptions?.metricName)) { - throw new Error(`Value: metric is not selected. [See options: Value -> Metric]`); + const serie = _.first(grafanaSeriesList); + this._seriesList = this._updateSeriesListWithChartwerkParams([serie]); + return; } this._selectedSerieName = this.gaugeValueOptions.metricName; diff --git a/src/plugin.json b/src/plugin.json index a5440c2..4a22419 100644 --- a/src/plugin.json +++ b/src/plugin.json @@ -34,7 +34,7 @@ "updated": "%TODAY%" }, "dependencies": { - "grafanaDependency": ">=7.0.0", + "grafanaDependency": ">=8.0.0", "plugins": [] } } diff --git a/yarn.lock b/yarn.lock index acc72c5..40fb6fa 100644 --- a/yarn.lock +++ b/yarn.lock @@ -902,16 +902,20 @@ resolved "https://registry.yarnpkg.com/@braintree/sanitize-url/-/sanitize-url-6.0.0.tgz#fe364f025ba74f6de6c837a84ef44bdb1d61e68f" integrity sha512-mgmE7XBYY/21erpzhexk4Cj1cyTQ9LzvnTxtzM17BJ7ERMNE6W72mQRo0I1Ud8eFJ+RVVIcBNhLFZ3GX4XFz5w== -"@chartwerk/core@github:chartwerk/core#a30ca83842247c79969deaaacfc7fb444a60cefb": - version "0.1.0" - resolved "https://codeload.github.com/chartwerk/core/tar.gz/a30ca83842247c79969deaaacfc7fb444a60cefb" +"@chartwerk/core@latest": + version "0.6.9" + resolved "https://registry.yarnpkg.com/@chartwerk/core/-/core-0.6.9.tgz#9d63844b5935de8362f6f3440159d85040116c60" + integrity sha512-9vv1LDAoR64iS2Nxdc2YqCmWNEf3tC2bULk20K8KFA6oVQmA1imdgFJSUv4cvm7Y9VVtPxlL1wDzIjGiLzeVcw== + dependencies: + d3 "^5.7.2" + lodash "^4.14.149" -"@chartwerk/gauge-pod@0.4.1": - version "0.4.1" - resolved "https://registry.yarnpkg.com/@chartwerk/gauge-pod/-/gauge-pod-0.4.1.tgz#ac346d777f72ec855e51f5f7c8c01e12a1e1cb5c" - integrity sha512-Ik6Dr4AJP/L+7YjZVJ9W19ujXXB5/b5A3Qxboi491hrXYlqMrfAx/LoyfDAtSEmGNhK5qpT8XLluzuHVcgTY4g== +"@chartwerk/gauge-pod@0.6.2": + version "0.6.2" + resolved "https://registry.yarnpkg.com/@chartwerk/gauge-pod/-/gauge-pod-0.6.2.tgz#7725394cd65acaaaa81cabb93a0b03e146c10362" + integrity sha512-L26hsvHCJruxfIJjXBsgcw2vszKMcMYcsXLGLy9Gy02hETpHR1pTKosgXPEpQqvQBRz+5WX+aL3x6yao/Elg/Q== dependencies: - "@chartwerk/core" "github:chartwerk/core#a30ca83842247c79969deaaacfc7fb444a60cefb" + "@chartwerk/core" latest "@cnakazawa/watch@^1.0.3": version "1.0.4" @@ -4811,6 +4815,43 @@ d3@5.15.0: d3-voronoi "1" d3-zoom "1" +d3@^5.7.2: + version "5.16.0" + resolved "https://registry.yarnpkg.com/d3/-/d3-5.16.0.tgz#9c5e8d3b56403c79d4ed42fbd62f6113f199c877" + integrity sha512-4PL5hHaHwX4m7Zr1UapXW23apo6pexCgdetdJ5kTmADpG/7T9Gkxw0M0tf/pjoB63ezCCm0u5UaFYy2aMt0Mcw== + dependencies: + d3-array "1" + d3-axis "1" + d3-brush "1" + d3-chord "1" + d3-collection "1" + d3-color "1" + d3-contour "1" + d3-dispatch "1" + d3-drag "1" + d3-dsv "1" + d3-ease "1" + d3-fetch "1" + d3-force "1" + d3-format "1" + d3-geo "1" + d3-hierarchy "1" + d3-interpolate "1" + d3-path "1" + d3-polygon "1" + d3-quadtree "1" + d3-random "1" + d3-scale "2" + d3-scale-chromatic "1" + d3-selection "1" + d3-shape "1" + d3-time "1" + d3-time-format "2" + d3-timer "1" + d3-transition "1" + d3-voronoi "1" + d3-zoom "1" + dashdash@^1.12.0: version "1.14.1" resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" @@ -8030,7 +8071,7 @@ lodash.uniq@^4.5.0: resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773" integrity sha1-0CJTc662Uq3BvILklFM5qEJ1R3M= -lodash@4.17.21, lodash@^4.1.1, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.17.3, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.7.0: +lodash@4.17.21, lodash@^4.1.1, lodash@^4.14.149, lodash@^4.17.19, lodash@^4.17.20, lodash@^4.17.21, lodash@^4.17.3, lodash@^4.17.4, lodash@^4.17.5, lodash@^4.7.0: version "4.17.21" resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.21.tgz#679591c564c3bffaae8454cf0b3df370c3d6911c" integrity sha512-v2kDEe57lecTulaDIuNTPy3Ry4gLGJ6Z1O3vE1krgXZNrsQ+LFTGHVxVjcXPs17LhbZVGedAJv8XZ1tvj5FvSg== From 6f199663cc99b8e00ae435622a5aef0fb2465624 Mon Sep 17 00:00:00 2001 From: vargburz Date: Tue, 5 Jul 2022 12:57:07 +0300 Subject: [PATCH 08/17] fix import conflit for grafana 9 --- src/grafana/data_processor.ts | 13 ++----------- 1 file changed, 2 insertions(+), 11 deletions(-) diff --git a/src/grafana/data_processor.ts b/src/grafana/data_processor.ts index 530bb6b..2be8ab0 100644 --- a/src/grafana/data_processor.ts +++ b/src/grafana/data_processor.ts @@ -2,16 +2,7 @@ import { applyNullInsertThreshold } from './null_insert'; import { find } from 'lodash'; -import { - DataFrame, - dateTime, - Field, - FieldType, - getColorForTheme, - getFieldDisplayName, - getTimeField, - TimeRange, -} from '@grafana/data'; +import { DataFrame, dateTime, Field, FieldType, getFieldDisplayName, getTimeField, TimeRange } from '@grafana/data'; import { colors } from '@grafana/ui'; import config from 'grafana/app/core/config'; import TimeSeries from 'grafana/app/core/time_series2'; @@ -91,7 +82,7 @@ export class DataProcessor { const series = new TimeSeries({ datapoints: datapoints || [], alias: alias, - color: getColorForTheme(color, config.theme), + color: config.theme.visualization.getColorByName(color), unit: field.config ? field.config.unit : undefined, dataFrameIndex, fieldIndex, From eef52e29aebf3afd530440d3b5c693e7d493edf0 Mon Sep 17 00:00:00 2001 From: vargburz Date: Tue, 5 Jul 2022 13:22:48 +0300 Subject: [PATCH 09/17] update version 0.4.1 -> 0.5.0 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index ee6164b..4a21acb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "grafana-chartwerk-panel", - "version": "0.4.2", + "version": "0.5.0", "description": "Chartwerk Panel", "scripts": { "build": "grafana-toolkit plugin:build", From c559ed8a2fca42dc16d7359b2b79fd21d2478cea Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 15:11:47 +0300 Subject: [PATCH 10/17] update grafana version; --- src/plugin.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugin.json b/src/plugin.json index 4a22419..18804ac 100644 --- a/src/plugin.json +++ b/src/plugin.json @@ -34,7 +34,7 @@ "updated": "%TODAY%" }, "dependencies": { - "grafanaDependency": ">=8.0.0", + "grafanaDependency": ">=8.3.0", "plugins": [] } } From e221551ac99ec15ab4d3b00b7c285bd69135a906 Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:00:47 +0300 Subject: [PATCH 11/17] update docs --- README.md | 30 +++++++++++++++++++++++++++++- 1 file changed, 29 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 15f32be..a0b760a 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,35 @@ - Bar Chart (coming soon) - Gauge: dynamic thresholds and min / max - Gauge: conditional icons displaying - +- Gauge: reversed direction + +## How to use + +1. Create a new panel and select Chartwerk as the visualization +2. Add multiple queries with a unique alias +3. Go to the Options Tab and setup panel: + - Choose visualization type (Gauge is the only available option for now) + - Select metric in the Value -> Metric dropdown (the first query metric will be used as a default one) + +## Demo + +see [demo](https://grafana.corpglory.com/d/8vGyMypGz/demo-home?orgId=4) + +## Options [Gauge] + +- Visualization: + - Pod: option to select chart type +- Value: + - Metric: select metric query from dropdown +- Extemum: + - Min: + - type number for static minimum value OR + - enable "Use metric" toggle switch to select metric as minimun + - default value: 0 + - Max: + - type number for static maximum OR + - enable "Use metric" toggle switch to select metric as maximum + - default value: maximum of metric query ## Installation ### Linux / Mac OS X From dc7b2fe6e33fc10b53b4b1133cefe5fba3f8d0be Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:11:52 +0300 Subject: [PATCH 12/17] update plugin.json --- README.md | 1 + src/plugin.json | 8 ++++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index a0b760a..5641574 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,7 @@ see [demo](https://grafana.corpglory.com/d/8vGyMypGz/demo-home?orgId=4) - type number for static maximum OR - enable "Use metric" toggle switch to select metric as maximum - default value: maximum of metric query + ## Installation ### Linux / Mac OS X diff --git a/src/plugin.json b/src/plugin.json index 18804ac..665a62f 100644 --- a/src/plugin.json +++ b/src/plugin.json @@ -4,7 +4,7 @@ "name": "Chartwerk", "id": "corpglory-chartwerk-panel", "info": { - "description": "", + "description": "Chartwerk panel for Grafana", "author": { "name": "CorpGlory Inc.", "url": "https://corpglory.com" @@ -17,11 +17,15 @@ "links": [ { "name": "Website", - "url": "https://gitlab.com/chartwerk/grafana-chartwerk-panel" + "url": "https://https://chartwerk.io/" }, { "name": "License", "url": "https://gitlab.com/chartwerk/grafana-chartwerk-panel/blob/main/LICENSE" + }, + { + "name": "Gitlab", + "url": "https://gitlab.com/chartwerk/grafana-chartwerk-panel/" } ], "screenshots": [ From b1fe84131a84278f81325d83e11500323b39d9f6 Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:22:18 +0300 Subject: [PATCH 13/17] fix --- README.md | 2 +- src/plugin.json | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 5641574..f27c22e 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ ## How to use 1. Create a new panel and select Chartwerk as the visualization -2. Add multiple queries with a unique alias +2. Add queries with a unique alias 3. Go to the Options Tab and setup panel: - Choose visualization type (Gauge is the only available option for now) - Select metric in the Value -> Metric dropdown (the first query metric will be used as a default one) diff --git a/src/plugin.json b/src/plugin.json index 665a62f..56e2a86 100644 --- a/src/plugin.json +++ b/src/plugin.json @@ -4,7 +4,7 @@ "name": "Chartwerk", "id": "corpglory-chartwerk-panel", "info": { - "description": "Chartwerk panel for Grafana", + "description": "Chartwerk panel with extended chart customization", "author": { "name": "CorpGlory Inc.", "url": "https://corpglory.com" @@ -17,7 +17,7 @@ "links": [ { "name": "Website", - "url": "https://https://chartwerk.io/" + "url": "https://chartwerk.io/" }, { "name": "License", From 7a056a57e4ddcb521bf68025f2481c5024782f5a Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:55:02 +0300 Subject: [PATCH 14/17] fix --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f27c22e..b5d093c 100644 --- a/README.md +++ b/README.md @@ -19,7 +19,7 @@ ## How to use 1. Create a new panel and select Chartwerk as the visualization -2. Add queries with a unique alias +2. Add queries with unique aliases 3. Go to the Options Tab and setup panel: - Choose visualization type (Gauge is the only available option for now) - Select metric in the Value -> Metric dropdown (the first query metric will be used as a default one) From 58ccf3097620fbcc7dbaf5fe09ecf0f141f620cc Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:55:23 +0300 Subject: [PATCH 15/17] fix --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index b5d093c..f806d64 100644 --- a/README.md +++ b/README.md @@ -21,7 +21,7 @@ 1. Create a new panel and select Chartwerk as the visualization 2. Add queries with unique aliases 3. Go to the Options Tab and setup panel: - - Choose visualization type (Gauge is the only available option for now) + - Choose visualization type - Select metric in the Value -> Metric dropdown (the first query metric will be used as a default one) ## Demo From 8b80470e748779b38dbf545baa6d092095ad3979 Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 17:56:11 +0300 Subject: [PATCH 16/17] fix --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index f806d64..243d7ac 100644 --- a/README.md +++ b/README.md @@ -22,7 +22,7 @@ 2. Add queries with unique aliases 3. Go to the Options Tab and setup panel: - Choose visualization type - - Select metric in the Value -> Metric dropdown (the first query metric will be used as a default one) + - Select metric in the Value -> Metric dropdown (by default, the first metric is used) ## Demo From 82568639fea8c7a06de9e5b8fac3c214280d03b6 Mon Sep 17 00:00:00 2001 From: vargburz Date: Fri, 8 Jul 2022 18:13:30 +0300 Subject: [PATCH 17/17] fix --- README.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 243d7ac..8424396 100644 --- a/README.md +++ b/README.md @@ -56,7 +56,7 @@ see [demo](https://grafana.corpglory.com/d/8vGyMypGz/demo-home?orgId=4) - Download Chartwerk panel ``` -wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/e8782155489bec4c216048e4d4e1f618/corpglory-chartwerk-panel-0.4.1.zip +wget https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/2284215a4dc8fb3bde1fd3b51bd99d3e/corpglory-chartwerk-panel-0.5.0.zip ``` - Unpack downloaded files @@ -80,6 +80,6 @@ You can install Chartwerk panel to Grafana in Docker passing it as environment v ```bash docker run \ -p 3000:3000 \ - -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/e8782155489bec4c216048e4d4e1f618/corpglory-chartwerk-panel-0.4.1.zip;corpglory-chartwerk-panel" \ + -e "GF_INSTALL_PLUGINS=https://gitlab.com/chartwerk/grafana-chartwerk-panel/uploads/2284215a4dc8fb3bde1fd3b51bd99d3e/corpglory-chartwerk-panel-0.5.0.zip;corpglory-chartwerk-panel" \ grafana/grafana ```