lokiclient

package module
v0.1.4 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 29, 2024 License: MIT Imports: 11 Imported by: 1

README

lokiclient

loki client via Loki api

Documentation

Index

Constants

View Source
const (
	LokiPushURI = "/loki/api/v1/push"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type PushBody

type PushBody struct {
	Streams []*PushItem `json:"streams"`
}

type PushConfig

type PushConfig struct {
	URL      string
	User     string
	Password string
	Interval string
	Batch    uint //Batch Size
	Retry    uint
	Gzip     bool
}

func (PushConfig) NewClient

func (c PushConfig) NewClient(ctx context.Context) (chan interface{}, error)

type PushItem

type PushItem struct {
	Stream map[string]string `json:"stream"`
	Values [][]string        `json:"values"`
}

func NewPushItem

func NewPushItem(labs map[string]string, lines ...string) *PushItem

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL