Documentation
¶
Index ¶
Constants ¶
View Source
const ( // JSONFormat represents json format for log line JSONFormat Format = iota // KvPairFormat represents key-value format for log line KvPairFormat // DefaultKubernetesMetadataTagExpression for extracting the kubernetes metadata from tag DefaultKubernetesMetadataTagExpression = "\\.([^_]+)_([^_]+)_(.+)-([a-z0-9]{64})\\.log$" // DefaultKubernetesMetadataTagKey represents the key for the tag in the entry DefaultKubernetesMetadataTagKey = "tag" // DefaultKubernetesMetadataTagPrefix represents the prefix of the entry's tag DefaultKubernetesMetadataTagPrefix = "kubernetes\\.var\\.log\\.containers" )
Variables ¶
View Source
var DefaultBufferConfig = BufferConfig{ Buffer: false, BufferType: "dque", DqueConfig: DefaultDqueConfig, }
DefaultBufferConfig holds the configurations for using output buffer
View Source
var DefaultDqueConfig = DqueConfig{ QueueDir: "/tmp/flb-storage/loki", QueueSegmentSize: 500, QueueSync: false, QueueName: "dque", }
DefaultDqueConfig holds dque configurations for the buffer
Functions ¶
This section is empty.
Types ¶
type BufferConfig ¶
type BufferConfig struct {
Buffer bool
BufferType string
DqueConfig DqueConfig
}
BufferConfig contains the buffer settings
type Config ¶
type Config struct {
ClientConfig client.Config
BufferConfig BufferConfig
LogLevel logging.Level
CtlSyncTimeout time.Duration
AutoKubernetesLabels bool
SortByTimestamp bool
NumberOfBatchIDs uint64
RemoveKeys []string
LabelKeys []string
LineFormat Format
DropSingleKey bool
LabelMap map[string]interface{}
DynamicHostPath map[string]interface{}
DynamicHostPrefix string
DynamicHostSuffix string
DynamicHostRegex string
KubernetesMetadata KubernetesMetadataExtraction
}
Config holds all of the needet properties of the loki output plugin
func ParseConfig ¶
ParseConfig parse a Loki plugin configuration
type DqueConfig ¶
DqueConfig contains the dqueue settings
type KubernetesMetadataExtraction ¶
type KubernetesMetadataExtraction struct {
FallbackToTagWhenMetadataIsMissing bool
DropLogEntryWithoutK8sMetadata bool
TagKey string
TagPrefix string
TagExpression string
}
KubernetesMetadataExtraction holds the configurations for retrieving the meta data from a tag
Click to show internal directories.
Click to hide internal directories.