Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
divinity666 committed Nov 4, 2021
2 parents 1299b0a + ae4db7a commit ec77809
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 15 deletions.
30 changes: 17 additions & 13 deletions FUNCTION_CALLS.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ See also: https://grafana.com/docs/grafana/latest/http_api/alerting/#get-alerts
| `column_divider="<divider>"` | Replace the default column divider with another one, when used in conjunction with `table_formatter` set to `adoc_deprecated`. Defaults to ` \| ` for being interpreted as a asciidoctor column. DEPRECATED: switch to `table_formatter` named `adoc_plain`, or implement a custom table formatter.
| `columns="<column_name_1>,<columns_name_2>,..."` | Specifies columns that shall be returned. Valid columns are `id`, `dashboardId`, `dashboardUId`, `dashboardSlug`, `panelId`, `name`, `state`, `newStateDate`, `evalDate`, `evalData` and `executionError`.
| `dashboard="<dashboard_uid>"` | Specifies the dashboard to be used. If `grafana_default_dashboard` is specified in the report template, this value can be overridden with this option. If this option, or the global option `grafana_default_dashboard` is set, the resulting alerts will be limited to this dashboard. To show all alerts in this case, specify `dashboard=""` as option
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand All @@ -92,8 +92,8 @@ See also: https://grafana.com/docs/grafana/latest/http_api/annotations/#find-ann
| `column_divider="<divider>"` | Replace the default column divider with another one, when used in conjunction with `table_formatter` set to `adoc_deprecated`. Defaults to ` \| ` for being interpreted as a asciidoctor column. DEPRECATED: switch to `table_formatter` named `adoc_plain`, or implement a custom table formatter.
| `columns="<column_name_1>,<columns_name_2>,..."` | Specified the columns that shall be returned. Valid columns are `id`, `alertId`, `dashboardId`, `panelId`, `userId`, `userName`, `newState`, `prevState`, `time`, `timeEnd`, `text`, `metric` and `type`.
| `dashboard="<dashboard_uid>"` | Specifies the dashboard to be used. If `grafana_default_dashboard` is specified in the report template, this value can be overridden with this option. If this option, or the global option `grafana_default_dashboard` is set, the resulting alerts will be limited to this dashboard. To show all alerts in this case, specify `dashboard=""` as option
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand All @@ -111,7 +111,11 @@ See also: https://ruby-doc.org/core/Regexp.html#class-Regexp-label-Character+Cla
### `grafana_environment`
Usage: `include::grafana_environment[]`

Shows all available variables in the rendering context which can be used in the asciidoctor template.
Shows all available variables in the rendering context which can be used in the asciidoctor template. If optional `instance` is specified, additional information about the configured grafana instance will be provided. This is especially helpful for debugging.

| Option | Description
| -- | --
| `instance="<instance_name>"` | can be used to override global grafana instance, set in the report with `grafana_default_instance`. If nothing is set, the configured grafana instance with name `default` will be used.

### `grafana_help`
Usage: `include::grafana_help[]`
Expand Down Expand Up @@ -160,8 +164,8 @@ See also: https://grafana.com/docs/grafana/latest/variables/syntax/
| -- | --
| `column_divider="<divider>"` | Replace the default column divider with another one, when used in conjunction with `table_formatter` set to `adoc_deprecated`. Defaults to ` \| ` for being interpreted as a asciidoctor column. DEPRECATED: switch to `table_formatter` named `adoc_plain`, or implement a custom table formatter.
| `dashboard="<dashboard_uid>"` | Specifies the dashboard to be used. If `grafana_default_dashboard` is specified in the report template, this value can be overridden with this option.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand All @@ -186,8 +190,8 @@ See also: https://grafana.com/docs/grafana/latest/variables/syntax/
| Option | Description
| -- | --
| `dashboard="<dashboard_uid>"` | Specifies the dashboard to be used. If `grafana_default_dashboard` is specified in the report template, this value can be overridden with this option.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand All @@ -209,8 +213,8 @@ See also: https://grafana.com/docs/grafana/latest/variables/syntax/
| Option | Description
| -- | --
| `column_divider="<divider>"` | Replace the default column divider with another one, when used in conjunction with `table_formatter` set to `adoc_deprecated`. Defaults to ` \| ` for being interpreted as a asciidoctor column. DEPRECATED: switch to `table_formatter` named `adoc_plain`, or implement a custom table formatter.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand All @@ -233,8 +237,8 @@ See also: https://grafana.com/docs/grafana/latest/variables/syntax/

| Option | Description
| -- | --
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `filter_columns="<column_name_1>,<column_name_2>,..."` | Removes specified columns from result. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
| `format="<format_col1>,<format_col2>,..."` | Specify format in which the results in a specific column shall be returned, e.g. `%.2f` for only two digit decimals of a float. Several column formats are separated by `,`, i.e. `%.2f,%.3f` would apply `%.2f` to the first column and `%.3f` to the second column. All other columns would not be formatted. You may also format time in milliseconds to a time format by specifying e.g. `date:iso`. Commas in format strings are supported, but have to be escaped by useing `_,`. Execution of related functions is applied in the following order `format`, `replace_values`, `filter_columns`, `transpose`.
See also: https://ruby-doc.org/core/Kernel.html#method-i-sprintf
| `from="<timestamp>"` | can be used to override default `from` time
| `from_timezone="<timezone>"` | can be used to override system timezone for `from` time and will also override `grafana_default_from_timezone` option
Expand Down
4 changes: 2 additions & 2 deletions lib/VERSION.rb
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# frozen_string_literal: true

# Version information
GRAFANA_REPORTER_VERSION = [0, 4, 5].freeze
GRAFANA_REPORTER_VERSION = [0, 5, 0].freeze
# Release date
GRAFANA_REPORTER_RELEASE_DATE = '2021-08-26'
GRAFANA_REPORTER_RELEASE_DATE = '2021-11-05'

0 comments on commit ec77809

Please sign in to comment.