Documentation
¶
Index ¶
- func CLIColorEnabled() bool
- func CLIFormat() string
- func EmitCLIEventf(fn func(level int, format string, args ...any) error, level int, ...) error
- func FormatCLIJSON(event CLIEvent) ([]byte, error)
- func FormatCLIText(event CLIEvent) string
- func FormatLogText(record LogRecord) string
- func MatchesLogFilters(record LogRecord, filters LogFilters) bool
- func RenderCLI(event CLIEvent, format string) (string, error)
- func RenderCLIOrFallback(event CLIEvent) string
- func RenderDefaultCLI(event CLIEvent) (string, error)
- func SetCLIColorEnabled(enabled bool)
- func SetCLIFormat(format string)
- func WrapCLISubprocessWriter(command string, writer io.Writer) io.Writer
- func WrapCLISubprocessWriters(command string, stdout io.Writer, stderr io.Writer) (io.Writer, io.Writer)
- func WriteCLIEvent(w io.Writer, event CLIEvent) error
- func WriterSupportsANSI(w io.Writer) bool
- type CLIEvent
- type LogFilters
- type LogRecord
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CLIColorEnabled ¶ added in v0.2.2
func CLIColorEnabled() bool
func EmitCLIEventf ¶ added in v0.2.2
func FormatCLIJSON ¶ added in v0.2.1
func FormatCLIText ¶ added in v0.2.1
func FormatLogText ¶
func MatchesLogFilters ¶
func MatchesLogFilters(record LogRecord, filters LogFilters) bool
func RenderCLIOrFallback ¶ added in v0.2.2
func RenderDefaultCLI ¶ added in v0.2.1
func SetCLIColorEnabled ¶ added in v0.2.2
func SetCLIColorEnabled(enabled bool)
func SetCLIFormat ¶ added in v0.2.1
func SetCLIFormat(format string)
func WrapCLISubprocessWriter ¶ added in v0.2.2
func WrapCLISubprocessWriters ¶ added in v0.2.2
func WriterSupportsANSI ¶ added in v0.2.2
Types ¶
type LogFilters ¶
type LogRecord ¶
type LogRecord struct {
TS string `json:"ts"`
Source string `json:"source,omitempty"`
EventType string `json:"event_type"`
Level string `json:"level"`
Message string `json:"message"`
JobID string `json:"job_id,omitempty"`
Status string `json:"status,omitempty"`
Extra map[string]any `json:"extra,omitempty"`
}
func NormalizeAuditRecord ¶
func NormalizeJSONLine ¶
func NormalizeJournalRecord ¶
func (LogRecord) ExtraValue ¶
Click to show internal directories.
Click to hide internal directories.