Versions in this module Expand all Collapse all v1 v1.0.1 Mar 26, 2019 v1.0.0 Mar 26, 2019 Changes in this version + const FileRenamePolicy + const FlushingTimeIntervalSecs + const Gzip + const LoggingActiveFileName + const LoggingDirectory + const LoggingWriteOutput + const MACRO + const MaxAge + const MaxCount + const PrependValue + const RotationMaxFileSizeBytes + const RotationMaxLines + const Target + var ErrInvalidFileRenamePolicy = errors.New(FileRenamePolicy + " can only be timestamp or serial") + var ErrInvalidMaxAge = errors.New(MaxAge + " must end with either d or h and start with a number") + func GetConfig(v *viper.Viper, logger *syslog.Writer, confpath string) (*Config, chan *Config, OutputWriter, error) + func RegisterNewWriter(name string, factory OutputFactory) + type ByModTime []os.FileInfo + func (a ByModTime) Len() int + func (a ByModTime) Less(i, j int) bool + func (a ByModTime) Swap(i, j int) + type Config struct + ActiveFileName string + DirName string + FileRenamePolicy string + FlushingTimeIntervalSecs int + Gzip bool + MaxAge int64 + MaxCount int + PrependValue string + RotationMaxBytes uint64 + RotationMaxLines int + Target string + WriteOutput bool + type ConfigValueError struct + Key string + func (e *ConfigValueError) Error() string + type Consumer struct + Config *Config + LineProcessor LineProcessor + Logger *syslog.Writer + ReloadChan chan *Config + Writer OutputWriter + func (c *Consumer) HandleSignal(s os.Signal) + func (c *Consumer) Start(inputStream io.Reader) error + type FileOutput struct + func (f *FileOutput) Close() error + type LineProcessor interface + Write func(io.Writer, string) error + func GetLineProcessor(cfg *Config) LineProcessor + type NoProcessor struct + func (*NoProcessor) Write(w io.Writer, line string) error + type OutputFactory func(v *viper.Viper, logger *syslog.Writer) (OutputWriter, error) + type OutputWriter interface + Close func() error + Flush func() error + func GetOutputWriter(v *viper.Viper, logger *syslog.Writer) (OutputWriter, error) + type SimpleLineProcessor struct + func (lp *SimpleLineProcessor) Write(w io.Writer, line string) error + type TemplateLineProcessor struct + func (lp *TemplateLineProcessor) Write(w io.Writer, line string) error + type UnregisteredOutputError struct + func (e *UnregisteredOutputError) Error() string