Documentation ¶
Index ¶
- type Aggregation
- type AggregationType
- type Option
- func AsAnnotations() Option
- func AsJSON() Option
- func AsTable() Option
- func AsTimeSeriesAggregations(aggregations []Aggregation) Option
- func DataSource(source string) Option
- func Description(content string) Option
- func Height(height string) Option
- func HideColumn(columnLabelPattern string) Option
- func Links(panelLinks ...links.Link) Option
- func Span(span float32) Option
- func TimeSeriesToColumns() Option
- func TimeSeriesToRows() Option
- func Transparent() Option
- func WithGraphiteTarget(query string, options ...graphite.Option) Option
- func WithInfluxDBTarget(query string, options ...influxdb.Option) Option
- func WithPrometheusTarget(query string, options ...prometheus.Option) Option
- type Table
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Aggregation ¶
type Aggregation struct { Label string Type AggregationType }
Aggregation configures how to display an aggregate in the table.
type AggregationType ¶
type AggregationType string
AggregationType represents an aggregation function used on values returned by the query.
const ( // AVG aggregates results by computing the average. AVG AggregationType = "avg" // Count aggregates results by counting them. Count AggregationType = "count" // Current aggregates results by keeping only the current value. Current AggregationType = "current" // Min aggregates results by keeping only the smallest value. Min AggregationType = "min" // Max aggregates results by keeping only the largest value. Max AggregationType = "max" )
type Option ¶
Option represents an option that can be used to configure a table panel.
func AsTimeSeriesAggregations ¶
func AsTimeSeriesAggregations(aggregations []Aggregation) Option
AsTimeSeriesAggregations displays the data according to the given aggregation methods.
func DataSource ¶
DataSource sets the data source to be used by the table.
func Description ¶
Description annotates the current visualization with a human-readable description.
func HideColumn ¶
HideColumn hides the column having a label matching the given pattern.
func Span ¶
Span sets the width of the panel, in grid units. Should be a positive number between 1 and 12. Example: 6.
func TimeSeriesToColumns ¶
func TimeSeriesToColumns() Option
TimeSeriesToColumns displays the data in columns.
func WithGraphiteTarget ¶
WithGraphiteTarget adds a Graphite target to the table.
func WithInfluxDBTarget ¶
WithInfluxDBTarget adds an InfluxDB target to the table.
func WithPrometheusTarget ¶
func WithPrometheusTarget(query string, options ...prometheus.Option) Option
WithPrometheusTarget adds a prometheus target to the table.