Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Arguments ¶
type Arguments struct { Endpoints []EndpointOptions `river:"endpoint,block,optional"` ExternalLabels map[string]string `river:"external_labels,attr,optional"` MaxStreams int `river:"max_streams,attr,optional"` }
Arguments holds values which are used to configure the loki.write component.
type Component ¶
type Component struct {
// contains filtered or unexported fields
}
Component implements the loki.write component.
type EndpointOptions ¶
type EndpointOptions struct { Name string `river:"name,attr,optional"` URL string `river:"url,attr"` BatchWait time.Duration `river:"batch_wait,attr,optional"` BatchSize units.Base2Bytes `river:"batch_size,attr,optional"` RemoteTimeout time.Duration `river:"remote_timeout,attr,optional"` Headers map[string]string `river:"headers,attr,optional"` MinBackoff time.Duration `river:"min_backoff_period,attr,optional"` // start backoff at this level MaxBackoff time.Duration `river:"max_backoff_period,attr,optional"` // increase exponentially to this level MaxBackoffRetries int `river:"max_backoff_retries,attr,optional"` // give up after this many; zero means infinite retries TenantID string `river:"tenant_id,attr,optional"` HTTPClientConfig *types.HTTPClientConfig `river:",squash"` }
EndpointOptions describes an individual location to send logs to.
func GetDefaultEndpointOptions ¶ added in v0.32.0
func GetDefaultEndpointOptions() EndpointOptions
GetDefaultEndpointOptions defines the default settings for sending logs to a remote endpoint. The backoff schedule with the default parameters: 0.5s, 1s, 2s, 4s, 8s, 16s, 32s, 64s, 128s, 256s(4.267m) For a total time of 511.5s (8.5m) before logs are lost.
func (*EndpointOptions) SetToDefault ¶ added in v0.35.0
func (r *EndpointOptions) SetToDefault()
SetToDefault implements river.Defaulter.
func (*EndpointOptions) Validate ¶ added in v0.35.0
func (r *EndpointOptions) Validate() error
Validate implements river.Validator.
type Exports ¶
type Exports struct {
Receiver loki.LogsReceiver `river:"receiver,attr"`
}
Exports holds the receiver that is used to send log entries to the loki.write component.
Click to show internal directories.
Click to hide internal directories.