Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Controller ¶
type Controller struct {
// contains filtered or unexported fields
}
Controller is responsible for managing a set of loggers.
func NewLoggingController ¶
func NewLoggingController(listener *events.InternalListener) *Controller
NewLoggingController instantiates a new LoggerController object.
func (*Controller) Reconfigure ¶
func (c *Controller) Reconfigure(s *state.State, config map[string]struct{}) error
Reconfigure handles the reinitialization of loggers after configuration changes.
func (*Controller) RemoveLogger ¶
func (c *Controller) RemoveLogger(name string)
RemoveLogger removes a logger from the controller.
type Entry ¶
Entry represents a log entry. It includes a log message and the time it occurred at.
func (Entry) MarshalJSON ¶
MarshalJSON returns the JSON encoding of Entry.
type LokiLogger ¶
type LokiLogger struct {
// contains filtered or unexported fields
}
LokiLogger represents a Loki client.
func NewLokiLogger ¶
func NewLokiLogger(s *state.State, name string) (*LokiLogger, error)
NewLokiLogger returns a logger of loki type.
func (*LokiLogger) HandleEvent ¶
func (l *LokiLogger) HandleEvent(event api.Event)
HandleEvent handles the event received from the internal event listener.
func (*LokiLogger) Validate ¶
func (l *LokiLogger) Validate() error
Validate checks whether the logger configuration is correct.
type PushRequest ¶
type PushRequest struct {
Streams []*Stream `json:"streams"`
}
PushRequest models a log stream push.
type SyslogLogger ¶
type SyslogLogger struct {
// contains filtered or unexported fields
}
SyslogLogger represents a syslog logger.
func NewSyslogLogger ¶
func NewSyslogLogger(s *state.State, name string) (*SyslogLogger, error)
NewSyslogLogger instantiates a new syslog logger.
func (*SyslogLogger) HandleEvent ¶
func (c *SyslogLogger) HandleEvent(event api.Event)
HandleEvent handles the event received from the internal event listener.
func (*SyslogLogger) Validate ¶
func (c *SyslogLogger) Validate() error
Validate checks whether the logger configuration is correct.