Commit Graph

66 Commits

Author SHA1 Message Date
Clark Boylan 7f9c7fdee2 Fix default handling with newer voluptious
It seems newer voluptuous passes the specified default value into the
verification method. Previously if data wasn't supplied it seems to have
not validated anything and returend the default. Anyway this means we
need to use a default value that matches our input type and manipulate
it on the output end the same way we would normal input.

We make this update in order to use newer voluptuous which will be
required when we switch to python3.10.

Change-Id: I64d9c8ac1334971f2d1c82f19ea675022635dc37
2022-10-14 16:35:05 -07:00
James E. Blair b89ec19088 Build docker images
This builds and publishes docker images to opendevorg/grafyaml
so that users can run this with "docker run ...".

Also, appease the pep8 gods.

Change-Id: Ia30438953e5c73a01ae0cd32afb660442e0e6e39
2021-03-11 14:15:37 -08:00
Ian Wienand 92ef419c01 Remove query variable refresh deprecation
Added with dd6582e9cc, we have found
that setting a bool here means the query variable no longer refreshes
at all.  Thus it's dangerous to accept it, force it to be an int.

For reference, the values seem to be

 0 = never refresh
 1 = on load
 2 = on timeseries change

Change-Id: Ia96f0166a80ece0b307acdca20eeca045a2e4a75
2020-06-24 20:36:09 +00:00
Ian Wienand 53fea97346 Update valueName values
Over time there are more possible valueName options; this is taken
directly from the current list [1]

[1] 67d0bca3cb/public/app/plugins/panel/singlestat/module.ts (L24)

Change-Id: I010d5360ea7704af376a384330e1fc2e512e4c9a
2019-02-22 09:13:11 +11:00
Ian Wienand e6c7095c6b Add valueMaps and rangeMaps support
These allow you to specify custom text instead of displayed values

Change-Id: I7e5c6067c0b0d26edc18120283bad30887df0663
2019-02-21 10:06:35 +11:00
William Huang 60a4c15c9b Add prometheus data source
Change-Id: Ia56aa4e8015eacf8e21f78d3aba7f9822515b364
2019-02-12 16:45:23 +08:00
Ian Wienand 5463ff095e Add tooltip sort
You can sort the tooltips in descending (1) or ascending (2) order.

Change-Id: I931419f832b6fd4a537431e34c099e5f2884d4c2
2018-09-14 16:21:25 +10:00
Quique Llorente 2ffded73e9 Add panel type 'row'
Change-Id: I47ea73eab779fa311d22a930acdc33ac2a9230f8
2018-07-11 08:53:04 +02:00
Zuul 2ff186cae7 Merge "Add 'database' to the datasource schema" 2018-07-10 17:04:21 +00:00
Quique Llorente e36f4ef99e Add adhoc template variables
Change-Id: I884d9d54dedaaab586fa3c2e8228f40a2bd39d79
2018-07-10 16:19:58 +02:00
Zuul 0969e906f3 Merge "Add transparent" 2018-07-03 00:15:42 +00:00
Ian Wienand c82c2b8ef7 Add alerts to graphs
Graphs can setup alerts.  Add a basic framework for them.

Change-Id: I6a80041eaaa03a3b3ff3e3de76401bbc77f42e96
2018-06-12 13:04:25 +10:00
Ian Wienand a5d14a2faf Add transparent
Graphs can have a "transparent" attribute to make them
... transparent.

Change-Id: I7772943b92a0c46bc8d7cd5ae7255f4de774bdcf
2018-06-08 15:31:22 +10:00
Enrique Llorente abbef4e6b5 Add 'database' to the datasource schema
The database option is supported by influxdb type
but missing in the schema

Change-Id: Id993a8e31e6df4d6374ecccd16dfb6c70ea54c45
2018-06-04 07:55:58 +02:00
Eldad Marciano 2da2da1a9a Add datasource to template schema.
the following patch will allow us to use datasource type in template schema.

Change-Id: I15cce5f8f97d1837b94eaa7067d7ebe8e449f8f4
Signed-off-by: Eldad Marciano <emarcian@redhat.com>
2018-03-26 18:02:45 +03:00
Zuul e86eb350b3 Merge "Add Custom Template Type" 2018-03-20 21:01:16 +00:00
akrzos dd6582e9cc Add Custom Template Type
Allow custom templated vars.  Custom templated vars are similiar to
interval templated vars in that they have "options" however they can be
multi-selected vs just a singular selection as with an interval var.

Change-Id: Ic89c5d192f87890da950a9d2d5f9bc4a96a3e174
2018-03-16 12:44:22 +00:00
Zuul 8f729842b3 Merge "Add gauge caps for singlestat panel." 2018-03-15 02:56:39 +00:00
Eldad Marciano 08b4520efb Add gauge caps for singlestat panel.
Change-Id: Ic87e610cff0f2389464f8d744d7853a369939dc6
2018-03-12 19:03:01 +02:00
Eldad Marciano f1c684c1c2 Support formatting.
Adding format to schema base panel, in order to use graph unit e.g
bytes, precent, deckbytes etc.

Change-Id: I754596738970177bb70c5425d38e1291c56c84a9
2018-03-12 18:07:12 +02:00
Zuul ca98fba97f Merge "Add links to GrafYaml" 2018-02-16 20:09:40 +00:00
Zuul 8a525a916e Merge "Add more units for graph panel" 2018-02-16 20:05:31 +00:00
Zuul 9cf5fb52a9 Merge "Allow hidden templated vars" 2018-02-16 20:05:28 +00:00
Zuul 07e6ff97a2 Merge "Allow decimals to be specificed to limit decimals graphs" 2018-02-16 20:05:26 +00:00
Zuul e951216fc6 Merge "Allow repeating panels and to set minspan" 2018-02-16 20:05:24 +00:00
akrzos af54eb4eb1 Allow repeating panels and to set minspan
This allows dashboards that expand a templated var to multi-graphs

Change-Id: I9b78958d836bbd4f73b06d6c302124857863c3d2
2018-02-16 09:50:37 -05:00
akrzos 2c68efbb69 Allow decimals to be specificed to limit decimals graphs
This allows graphs tool tips to be limited by a decimal count.
Also fix forgotten validation on decimals setting specific to legends.

Change-Id: I5840b0081dbb17ead0c49fa7d6d6ba1a2e82bb7c
2018-02-16 09:50:00 -05:00
akrzos caad52ae85 Allow hidden templated vars
Change-Id: Id74fe2a8a7b7156e045fd0b1d3f232ac05964f53
2018-02-16 09:49:35 -05:00
akrzos 9faec6b923 Add more units for graph panel
* data (Metric) decimal units - decbits - decgbytes
* More data rate units
* More thoughput units

See this Grafana Source:
https://git.io/vAOKi

Change-Id: I24dc028ae67d95ed82ee6908b668cbaa37bf8d9b
2018-02-16 09:48:24 -05:00
akrzos 89e71ad53d Add links to GrafYaml
Allow dashboards with links to be created.

Change-Id: Ie6e27808e465d98fd6694a60b31aa78b883e7ed3
2018-02-16 09:47:44 -05:00
Fabien Boucher 28bbece7ae Unlock yaxes min limit and allow free value
Change-Id: Id942bfc9e06ad2b78bb8243ac06a089f6f2ab074
2018-02-16 14:27:31 +00:00
akrzos 4711e038ae Allow dashboards to be tagged
Change-Id: Ie1a7db10726a9de924a2a8fe262d2c9550d42fd5
2018-02-09 10:04:02 -05:00
Zuul 1f7fcdd161 Merge "Add yaxes format for newer versions of Grafana" 2018-02-09 14:11:40 +00:00
akrzos f4b52386cc Add yaxes format for newer versions of Grafana
y_formats has moved to yaxes, but still support y_formats

Change-Id: Iabd1302352c77dc82c543412596e21550e4c0579
2018-02-08 09:15:09 -05:00
akrzos a53ce0ed3b Add support to change the default time filter range
Default is 6h it seems.  This change allows adjusting the default
to/from range in the time filter.

Change-Id: I567b9cc5cd8c753f852066c9e6868dd0f1b30b60
2018-02-07 20:23:07 -05:00
Zuul f56133eafc Merge "Add support for influxdb datasource" 2018-01-12 20:45:31 +00:00
akrzos 96cf8f97d4 Add legend for graphs
Simple support for a legend on graphs.

Change-Id: I3dc96a1463a8e765b9c97fa2fd1550872d7a285f
2018-01-09 11:33:48 -05:00
Tristan Cacqueray 1af7a4e010 Add support for influxdb datasource
Change-Id: I8d4b073cdc3fec4e55d10fac014874003d3739b6
2017-12-08 01:55:46 +00:00
Ye Na Rhee f89102bbf9 Add datasource option to more elements
This change adds support for datasource option to:
* graph panel
* singlestat panel
* templating

This enables the user to use other datasource than the default datasource
for graph/singlestat panels and templating. It is useful when more
than one datasource are available in Grafana.

Change-Id: I2e81a2dc4658c530bf82c4b349e2991dad348b01
2016-08-11 20:19:12 -04:00
Ye Na Rhee 3b01b4df7d Add support for time range
This commit adds the ability to configure the options in Time Range panel: time override, time shift and hide time override info.

Change-Id: I1d8c527ef1a377de6e34b94621f3060706356008
2016-04-20 21:18:54 +02:00
Ye Na Rhee a38798a292 Enable no fill in seriesOverrides
This allows fill to take the minimum value of 0.

Change-Id: I4c3a37fcfd6de24332ee05ca0d897e6d4973c525
2016-04-17 22:04:45 +02:00
James E. Blair ffa9e89794 Add support for interval template type
This performs some significant coercion because without it, the
interval template type, which should be very easy to use, would
require a substantial amount of yaml boilerplate.

Change-Id: I66ffe944af1b6794089dc536bfd99a1adf5d268e
2016-01-09 10:27:26 -08:00
Paul Belanger f95956b3e2 Add support for template query
A cool feature grafana has is the ability to template dashboards with
variables. This code now provides that ability to the user.

Change-Id: Ib2f565e3d39523105b2c07d29d5257494a8bae67
Signed-off-by: Paul Belanger <pabelanger@redhat.com>
2016-01-09 10:27:18 -08:00
James E. Blair 187caf92d7 Add support for seriesOverrides
Reference: https://github.com/grafana/grafana/blob/master/public/app/plugins/panels/graph/seriesOverridesCtrl.js#L94

Change-Id: I22743f566b32aaa5527237dd023551a8f3a3dbc4
2016-01-08 14:46:21 -08:00
James E. Blair cdc1df0e27 Add tooltip customization support
This is important for stacked graphs so that the tooltip can show
individual, rather than cumulative values (which makes the most
sense for our node graphs).

Also, sort the elements in the schema.  I think keeping them all
in order makes more sense than required/optional sections.

Change-Id: Ie542dc4d0e151a00e84cc970c2cfa8c02377d7bf
2016-01-07 14:15:47 -08:00
James E. Blair 36682378fc Add support for nullPointMode
Change-Id: Iedc5eec1ad06498a191b342cc70ce4424741e16f
2016-01-07 14:07:26 -08:00
James E. Blair 17e53a824d Add support for Y axis formats
The list of valid formats is taken from:
  https://github.com/grafana/grafana/blob/master/public/app/core/utils/kbn.js

(grep "value:" in that file).

Change-Id: Ibe7317847beba3db3205d759fbf6492e005b128f
2016-01-06 11:54:48 -08:00
James E. Blair ff88ef29e2 Add support for Y axis labels
Change-Id: I42ff3fa12fbb792b2544e0697c3ab87b0768e82d
2016-01-06 11:16:08 -08:00
Jenkins fd09f80b1e Merge "Add unit test coverage for panels" 2015-11-19 22:05:17 +00:00
Jenkins d1135dea79 Merge "Refactor Panel class" 2015-11-19 22:05:03 +00:00