Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrCannotCreateIndex = fmt.Errorf("cannot create index")
)
Functions ¶
This section is empty.
Types ¶
type ElasticHook ¶
type ElasticHook struct {
// contains filtered or unexported fields
}
func NewElasticHook ¶
func NewElasticHook(client *elasticsearch.Client, host string, levels []logrus.Level, index string) (*ElasticHook, error)
NewElasticHook creates new hook. client - ElasticSearch client host - host of system levels - log levels to log index - name of the index in ElasticSearch
func (*ElasticHook) Levels ¶
func (hook *ElasticHook) Levels() []logrus.Level
Levels Required for logrus hook implementation
type IndexNameFunc ¶
type IndexNameFunc func() string
Click to show internal directories.
Click to hide internal directories.