Documentation
¶
Index ¶
- Constants
- func AlertTable(options ...Option) panel.Option
- type AlertAction
- type Builder
- type ColumnDefinition
- type ColumnSortMode
- type DeduplicationConfig
- type DeduplicationMode
- type LabelColorMapping
- type LabelColorMode
- type LabelColorOverride
- type Option
- func AllowedActions(actions ...AlertAction) Option
- func Columns(columns ...ColumnDefinition) Option
- func Deduplication(config DeduplicationConfig) Option
- func DefaultGroupBy(labels ...string) Option
- func LabelColorMappings(mappings ...LabelColorMapping) Option
- func RunbookAnnotationKey(key string) Option
- type PluginSpec
- type SortDirection
Constants ¶
View Source
const PluginKind = "AlertTable"
Variables ¶
This section is empty.
Functions ¶
func AlertTable ¶
Types ¶
type AlertAction ¶
type AlertAction string
const ( SilenceAction AlertAction = "silence" RunbookAction AlertAction = "runbook" )
type Builder ¶
type Builder struct {
PluginSpec `json:",inline" yaml:",inline"`
}
type ColumnDefinition ¶
type ColumnDefinition struct {
Name string `json:"name" yaml:"name"`
Header string `json:"header,omitempty" yaml:"header,omitempty"`
EnableSorting *bool `json:"enableSorting,omitempty" yaml:"enableSorting,omitempty"`
Sort SortDirection `json:"sort,omitempty" yaml:"sort,omitempty"`
SortMode ColumnSortMode `json:"sortMode,omitempty" yaml:"sortMode,omitempty"`
}
type ColumnSortMode ¶
type ColumnSortMode string
const ( AlphabeticalSort ColumnSortMode = "alphabetical" NumericSort ColumnSortMode = "numeric" SeveritySort ColumnSortMode = "severity" )
type DeduplicationConfig ¶
type DeduplicationConfig struct {
Mode DeduplicationMode `json:"mode" yaml:"mode"`
Labels []string `json:"labels,omitempty" yaml:"labels,omitempty"`
}
type DeduplicationMode ¶
type DeduplicationMode string
const ( DeduplicationNone DeduplicationMode = "none" DeduplicationFingerprint DeduplicationMode = "fingerprint" DeduplicationLabels DeduplicationMode = "labels" )
type LabelColorMapping ¶
type LabelColorMapping struct {
LabelKey string `json:"labelKey" yaml:"labelKey"`
Mode LabelColorMode `json:"mode" yaml:"mode"`
Overrides []LabelColorOverride `json:"overrides,omitempty" yaml:"overrides,omitempty"`
}
type LabelColorMode ¶
type LabelColorMode string
const ( AutoColorMode LabelColorMode = "auto" SeverityColorMode LabelColorMode = "severity" ManualColorMode LabelColorMode = "manual" )
type LabelColorOverride ¶
type Option ¶
func AllowedActions ¶
func AllowedActions(actions ...AlertAction) Option
func Columns ¶
func Columns(columns ...ColumnDefinition) Option
func Deduplication ¶
func Deduplication(config DeduplicationConfig) Option
func DefaultGroupBy ¶
func LabelColorMappings ¶
func LabelColorMappings(mappings ...LabelColorMapping) Option
func RunbookAnnotationKey ¶
type PluginSpec ¶
type PluginSpec struct {
DefaultGroupBy []string `json:"defaultGroupBy,omitempty" yaml:"defaultGroupBy,omitempty"`
Columns []ColumnDefinition `json:"columns,omitempty" yaml:"columns,omitempty"`
Deduplication *DeduplicationConfig `json:"deduplication,omitempty" yaml:"deduplication,omitempty"`
AllowedActions []AlertAction `json:"allowedActions,omitempty" yaml:"allowedActions,omitempty"`
RunbookAnnotationKey string `json:"runbookAnnotationKey,omitempty" yaml:"runbookAnnotationKey,omitempty"`
LabelColorMappings []LabelColorMapping `json:"labelColorMappings,omitempty" yaml:"labelColorMappings,omitempty"`
}
type SortDirection ¶
type SortDirection string
const ( AscSort SortDirection = "asc" DescSort SortDirection = "desc" )
Click to show internal directories.
Click to hide internal directories.