From 53c0353425063685a25c527c3f4c1d8fe5a7b49d Mon Sep 17 00:00:00 2001 From: Avinash Lokhande Date: Wed, 1 Dec 2021 12:07:05 -0800 Subject: [PATCH 1/2] Cloudwatch - Add matchExact parameter --- grafonnet/cloudwatch.libsonnet | 3 +++ 1 file changed, 3 insertions(+) diff --git a/grafonnet/cloudwatch.libsonnet b/grafonnet/cloudwatch.libsonnet index f56056f4..85efe37b 100644 --- a/grafonnet/cloudwatch.libsonnet +++ b/grafonnet/cloudwatch.libsonnet @@ -14,6 +14,7 @@ * @param period (default: `'auto'`) * @param dimensions (optional) * @param id (optional) + * @param matchExact (default: `false`) (optional) * @param expression (optional) * @param hide (optional) @@ -31,6 +32,7 @@ period='auto', dimensions={}, id=null, + matchExact=false, expression=null, hide=null ):: { @@ -44,6 +46,7 @@ period: period, dimensions: dimensions, [if id != null then 'id']: id, + matchExact: matchExact, [if expression != null then 'expression']: expression, [if hide != null then 'hide']: hide, From f4f5710398eae796c5d8cf9a96ac755f04194a46 Mon Sep 17 00:00:00 2001 From: Avinash Lokhande Date: Wed, 1 Dec 2021 12:17:43 -0800 Subject: [PATCH 2/2] stat_panel: Add span and height --- grafonnet/stat_panel.libsonnet | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/grafonnet/stat_panel.libsonnet b/grafonnet/stat_panel.libsonnet index 5d1e5e7f..46bec662 100644 --- a/grafonnet/stat_panel.libsonnet +++ b/grafonnet/stat_panel.libsonnet @@ -6,12 +6,14 @@ * * @param title Panel title. * @param description (optional) Panel description. + * @param span (optional) Width of the panel * @param transparent (default `false`) Whether to display the panel without a background. * @param datasource (optional) Panel datasource. * @param allValues (default `false`) Show all values instead of reducing to one. * @param valueLimit (optional) Limit of values in all values mode. * @param reducerFunction (default `'mean'`) Function to use to reduce values to when using single value. * @param fields (default `''`) Fields that should be included in the panel. + * @param height (default `''`) Defines height of the panel. * @param orientation (default `'auto'`) Stacking direction in case of multiple series or fields. * @param colorMode (default `'value'`) 'value' or 'background'. * @param graphMode (default `'area'`) 'none' or 'area' to enable sparkline mode. @@ -43,6 +45,7 @@ */ new( title, + span=null, description=null, transparent=false, datasource=null, @@ -50,6 +53,7 @@ valueLimit=null, reducerFunction='mean', fields='', + height=null, orientation='auto', colorMode='value', graphMode='area', @@ -71,6 +75,8 @@ type: 'stat', title: title, + [if span != null then 'span']: span, + [if height != null then 'height']: height, [if description != null then 'description']: description, transparent: transparent, datasource: datasource,