Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EntryHandler ¶
type EntryHandler interface { Chan() chan<- Entry Stop() }
EntryHandler is something that can "handle" entries via a channel. Stop must be called to gracefully shutdown the EntryHandler
func NewEntryHandler ¶
func NewEntryHandler(entries chan<- Entry, stop func()) EntryHandler
NewEntryHandler creates a new EntryHandler using a input channel and a stop function.
func NewEntryMutatorHandler ¶
func NewEntryMutatorHandler(next EntryHandler, f EntryMutatorFunc) EntryHandler
NewEntryMutatorHandler creates a EntryHandler that mutates incoming entries from another EntryHandler.
type EntryMiddleware ¶
type EntryMiddleware interface {
Wrap(EntryHandler) EntryHandler
}
EntryMiddleware takes an EntryHandler and returns another one that will intercept and forward entries. The newly created EntryHandler should be Stopped independently from the original one.
func AddLabelsMiddleware ¶
func AddLabelsMiddleware(additionalLabels model.LabelSet) EntryMiddleware
AddLabelsMiddleware is an EntryMiddleware that adds some labels.
type EntryMiddlewareFunc ¶
type EntryMiddlewareFunc func(EntryHandler) EntryHandler
EntryMiddlewareFunc allows to create EntryMiddleware via a function.
func (EntryMiddlewareFunc) Wrap ¶
func (e EntryMiddlewareFunc) Wrap(next EntryHandler) EntryHandler
type EntryMutatorFunc ¶
EntryMutatorFunc is a function that can mutate an entry
type InstrumentedEntryHandler ¶
type InstrumentedEntryHandler interface { EntryHandler UnregisterLatencyMetric(prometheus.Labels) }