finalizing logging and multierror

This commit is contained in:
2022-01-05 05:15:38 -05:00
parent 3975f8b11f
commit 0e01306637
24 changed files with 1057 additions and 60 deletions

18
logging/errs_linux.go Normal file
View File

@@ -0,0 +1,18 @@
package logging
import (
`errors`
`fmt`
)
var (
// ErrNoSysD indicates that the user attempted to add a SystemDLogger to a MultiLogger but systemd is unavailable.
ErrNoSysD error = errors.New("a systemd (journald) Logger was requested but systemd is unavailable on this system")
// ErrNoSyslog indicates that the user attempted to add a SyslogLogger to a MultiLogger but syslog's logger device is unavailable.
ErrNoSyslog error = errors.New("a Syslog Logger was requested but Syslog is unavailable on this system")
/*
ErrInvalidDevLog indicates that the user attempted to add a SyslogLogger to a MultiLogger but
the Syslog char device file is... not actually a char device file.
*/
ErrInvalidDevLog error = errors.New(fmt.Sprintf("a Syslog Logger was requested but %v is not a valid logger handle", devlog))
)