hook

package
v0.0.21 Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CLSHook

func CLSHook() *cls

func NewCLS

func NewCLS(topic string, opts ...Option) *cls

func NewKafka

func NewKafka(user, password, endpoint, topic string) *kafka

Types

type Credential added in v0.0.21

type Credential struct {
	SecretID  string `json:"SecretID"`
	SecretKey string `json:"SecretKey"`
}

Credential is the ticket for accessing the log service at QCloud

type Hook

type Hook interface {
	// Establish for making connections
	Establish() error
	Fire(entry *logrus.Entry) error
	Levels() []logrus.Level
}

Hook 日志上传器

type Option added in v0.0.21

type Option func(*Options)

func WithEndpoint added in v0.0.21

func WithEndpoint(endpoint string) Option

type Options added in v0.0.21

type Options struct {
	// contains filtered or unexported fields
}

Jump to

Keyboard shortcuts

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