Documentation ¶
Index ¶
- Constants
- func AsJSON(v interface{}) []byte
- func BurstSampler(burst uint32, interval time.Duration, opts ...BurstSamplerOption) *zerolog.BurstSampler
- func Entity(entity flow.Entity) []byte
- func ID(id flow.Identifier) []byte
- func IDs(ids []flow.Identifier) []string
- func Type(obj interface{}) string
- type BurstSamplerOption
Constants ¶
View Source
const ( // KeySuspicious is a logging label that is used to flag the log event as suspicious behavior // This is used to add an easily searchable label to the log event KeySuspicious = "suspicious" // KeyNetworkingSecurity is a logging label that is used to flag the log event as a networking security issue. // This is used to add an easily searchable label to the log events. KeyNetworkingSecurity = "networking-security" // KeyLoad is a logging label that is used to flag the log event as a load issue. KeyLoad = "load" )
Variables ¶
This section is empty.
Functions ¶
func BurstSampler ¶ added in v0.29.0
func BurstSampler(burst uint32, interval time.Duration, opts ...BurstSamplerOption) *zerolog.BurstSampler
BurstSampler returns a zerolog.BurstSampler with the provided burst and interval. Logs emitted beyond the burst limit are dropped
func ID ¶
func ID(id flow.Identifier) []byte
func IDs ¶
func IDs(ids []flow.Identifier) []string
Types ¶
type BurstSamplerOption ¶ added in v0.29.0
type BurstSamplerOption func(*zerolog.BurstSampler)
func WithNextSampler ¶ added in v0.29.0
func WithNextSampler(sampler zerolog.Sampler) BurstSamplerOption
WithNextSampler adds a sampler that is applied after exceeding the burst limit
Click to show internal directories.
Click to hide internal directories.