Upstep Go dependencies (#340)

* Upstep Go dependencies

* tiny linter fix

* Tidy
This commit is contained in:
tobi 2021-12-12 15:47:51 +01:00 committed by GitHub
commit 67ac8db190
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
160 changed files with 248601 additions and 232400 deletions

View file

@ -9,76 +9,75 @@ import (
// Check our types impl LogFormat
var _ LogFormat = &TextFormat{}
// Formattable defines a type capable of writing a string formatted form
// of itself to a supplied byte buffer, and returning the resulting byte
// buffer. Implementing this will greatly speed up formatting of custom
// types passed to LogFormat (assuming they implement checking for this).
type Formattable interface {
AppendFormat([]byte) []byte
}
// LogFormat defines a method of formatting log entries
type LogFormat interface {
// AppendLevel appends given log level to the log buffer
// AppendKey appends given key to the log buffer
AppendKey(buf *bytes.Buffer, key string)
// AppendLevel appends given log level as key-value pair to the log buffer
AppendLevel(buf *bytes.Buffer, lvl LEVEL)
// AppendTimestamp appends given time format string to the log buffer
// AppendTimestamp appends given timestamp string as key-value pair to the log buffer
AppendTimestamp(buf *bytes.Buffer, fmtNow string)
// AppendField appends given key-value pair to the log buffer
AppendField(buf *bytes.Buffer, key string, value interface{})
// AppendFields appends given key-values pairs to the log buffer
AppendFields(buf *bytes.Buffer, fields map[string]interface{})
// AppendValue appends given interface formatted as value to the log buffer
AppendValue(buf *bytes.Buffer, value interface{})
// AppendValues appends given interfaces formatted as values to the log buffer
AppendValues(buf *bytes.Buffer, slice []interface{})
// AppendByte appends given byte value to the log buffer
AppendByte(buf *bytes.Buffer, value byte)
// AppendArgs appends given interfaces raw to the log buffer
AppendArgs(buf *bytes.Buffer, args []interface{})
// AppendBytes appends given byte slice value to the log buffer
AppendBytes(buf *bytes.Buffer, value []byte)
// AppendByteField appends given byte value as key-value pair to the log buffer
AppendByteField(buf *bytes.Buffer, key string, value byte)
// AppendString appends given string value to the log buffer
AppendString(buf *bytes.Buffer, value string)
// AppendBytesField appends given byte slice value as key-value pair to the log buffer
AppendBytesField(buf *bytes.Buffer, key string, value []byte)
// AppendStrings appends given string slice value to the log buffer
AppendStrings(buf *bytes.Buffer, value []string)
// AppendStringField appends given string value as key-value pair to the log buffer
AppendStringField(buf *bytes.Buffer, key string, value string)
// AppendBool appends given bool value to the log buffer
AppendBool(buf *bytes.Buffer, value bool)
// AppendStringsField appends given string slice value as key-value pair to the log buffer
AppendStringsField(buf *bytes.Buffer, key string, value []string)
// AppendBools appends given bool slice value to the log buffer
AppendBools(buf *bytes.Buffer, value []bool)
// AppendBoolField appends given bool value as key-value pair to the log buffer
AppendBoolField(buf *bytes.Buffer, key string, value bool)
// AppendInt appends given int value to the log buffer
AppendInt(buf *bytes.Buffer, value int)
// AppendBoolsField appends given bool slice value as key-value pair to the log buffer
AppendBoolsField(buf *bytes.Buffer, key string, value []bool)
// AppendInts appends given int slice value to the log buffer
AppendInts(buf *bytes.Buffer, value []int)
// AppendIntField appends given int value as key-value pair to the log buffer
AppendIntField(buf *bytes.Buffer, key string, value int)
// AppendUint appends given uint value to the log buffer
AppendUint(buf *bytes.Buffer, value uint)
// AppendIntsField appends given int slice value as key-value pair to the log buffer
AppendIntsField(buf *bytes.Buffer, key string, value []int)
// AppendUints appends given uint slice value to the log buffer
AppendUints(buf *bytes.Buffer, value []uint)
// AppendUintField appends given uint value as key-value pair to the log buffer
AppendUintField(buf *bytes.Buffer, key string, value uint)
// AppendFloat appends given float value to the log buffer
AppendFloat(buf *bytes.Buffer, value float64)
// AppendUintsField appends given uint slice value as key-value pair to the log buffer
AppendUintsField(buf *bytes.Buffer, key string, value []uint)
// AppendFloats appends given float slice value to the log buffer
AppendFloats(buf *bytes.Buffer, value []float64)
// AppendFloatField appends given float value as key-value pair to the log buffer
AppendFloatField(buf *bytes.Buffer, key string, value float64)
// AppendTime appends given time value to the log buffer
AppendTime(buf *bytes.Buffer, value time.Time)
// AppendFloatsField appends given float slice value as key-value pair to the log buffer
AppendFloatsField(buf *bytes.Buffer, key string, value []float64)
// AppendTimes appends given time slice value to the log buffer
AppendTimes(buf *bytes.Buffer, value []time.Time)
// AppendTimeField appends given time value as key-value pair to the log buffer
AppendTimeField(buf *bytes.Buffer, key string, value time.Time)
// AppendDuration appends given duration value to the log buffer
AppendDuration(buf *bytes.Buffer, value time.Duration)
// AppendTimesField appends given time slice value as key-value pair to the log buffer
AppendTimesField(buf *bytes.Buffer, key string, value []time.Time)
// AppendDurationField appends given duration value as key-value pair to the log buffer
AppendDurationField(buf *bytes.Buffer, key string, value time.Duration)
// AppendDurationsField appends given duration slice value as key-value pair to the log buffer
AppendDurationsField(buf *bytes.Buffer, key string, value []time.Duration)
// AppendDurations appends given duration slice value to the log buffer
AppendDurations(buf *bytes.Buffer, value []time.Duration)
// AppendMsg appends given msg as key-value pair to the log buffer using fmt.Sprint(...) formatting
AppendMsg(buf *bytes.Buffer, a ...interface{})