package
1.7.0
Repository: https://github.com/acronis/go-appkit.git
Documentation: pkg.go.dev

# Packages

Package logtest provides implementation of log.FieldLogger that allows writing tests for logging functionality.

# Functions

DurationIn returns a new Field with the "duration" as key and received duration in unit as value (int64).
NewConfig creates a new instance of the Config.
NewConfigWithKeyPrefix creates a new instance of the Config.
NewDisabledLogger returns a new logger that logs nothing.
No description provided by the author
NewLogger returns a new logger.
No description provided by the author
NewMasker creates a new Masker instance.
No description provided by the author
NewPrefixedLogger returns a new PrefixedLogger instance.

# Constants

Default and restriction values.
Default and restriction values.
No description provided by the author
No description provided by the author
No description provided by the author
Logging formats.
Logging formats.
Logging levels.
Logging levels.
Logging levels.
Logging levels.
Default and restriction values.
Default and restriction values.
Logging outputs.
Logging outputs.
Logging outputs.

# Variables

Any returns a new Filed with the given key and value of any type.
Bool returns a new Field with the given key and bool.
Bytes returns a new Field with the given key and slice of bytes.
No description provided by the author
Duration returns a new Field with the given key and time.Duration.
Error returns a new Field with the given error.
Float32 returns a new Field with the given key and float32.
Float64 returns a new Field with the given key and float64.
Int returns a new Field with the given key and int.
Int16 returns a new Field with the given key and int16.
Int32 returns a new Field with the given key and int32.
Int64 returns a new Field with the given key and int64.
Int8 returns a new Field with the given key and int8.
NamedError returns a new Field with the given key and error.
String returns a new Field with the given key and string.
Strings returns a new Field with the given key and slice of strings.
Time returns a new Field with the given key and time.Time.
Uint16 returns a new Field with the given key and uint16.
Uint32 returns a new Field with the given key and uint32.
Uint64 returns a new Field with the given key and uint64.
Uint8 returns a new Field with the given key and uint8.

# Structs

Config represents a set of configuration parameters for logging.
FieldMasker is used to mask a field in different formats.
FileOutputConfig is a configuration for file log output.
FileRotationConfig is a configuration for file log rotation.
LogfAdapter adapts logf.Logger to FieldLogger interface.
Mask is used to mask a secret in strings.
No description provided by the author
Masker uses the Aho-Corasick algorithm to simultaneously search for all patterns in a string.
No description provided by the author
MaskingLogger is a logger that masks secrets in log fields.
No description provided by the author
PrefixedLogger represents a logger that prefixes all logging messages with a specific text.

# Interfaces

FieldLogger is an interface for loggers which writes logs in structured format.
No description provided by the author

# Type aliases

CloseFunc allows to close channel writer.
Field hold data of a specific field.
No description provided by the author
Format defines possible values for log formats.
Level defines possible values for log levels.
LogFunc allows logging a message with a bound level.
Output defines possible values for log outputs.