package promtail
import "github.com/afiskon/promtail-client/promtail"
Index ¶
- Constants
- type Client
- func NewClientJson(conf ClientConfig) (Client, error)
- func NewClientProto(conf ClientConfig) (Client, error)
- type ClientConfig
- type LogLevel
Constants ¶
const LOG_ENTRIES_CHAN_SIZE = 5000
Types ¶
type Client ¶
type Client interface { Debugf(format string, args ...interface{}) Infof(format string, args ...interface{}) Warnf(format string, args ...interface{}) Errorf(format string, args ...interface{}) Shutdown() }
func NewClientJson ¶
func NewClientJson(conf ClientConfig) (Client, error)
func NewClientProto ¶
func NewClientProto(conf ClientConfig) (Client, error)
type ClientConfig ¶
type ClientConfig struct { // E.g. http://localhost:3100/api/prom/push PushURL string // E.g. "{job=\"somejob\"}" Labels string BatchWait time.Duration BatchEntriesNumber int // Logs are sent to Promtail if the entry level is >= SendLevel SendLevel LogLevel // Logs are printed to stdout if the entry level is >= PrintLevel PrintLevel LogLevel }
type LogLevel ¶
type LogLevel int
const ( DEBUG LogLevel = iota INFO LogLevel = iota WARN LogLevel = iota ERROR LogLevel = iota // Maximum level, disables sending or printing DISABLE LogLevel = iota )
Source Files ¶
common.go jsonclient.go protoclient.go
- Version
- v0.0.0-20190305142237-506f3f921e9c (latest)
- Published
- Mar 5, 2019
- Platform
- windows/amd64
- Imports
- 12 packages
- Last checked
- now –
Tools for package owners.