mirror of
https://github.com/ceph/ceph-csi.git
synced 2024-11-09 16:00:22 +00:00
rebase: bump k8s.io/klog/v2 from 2.70.1 to 2.80.1
Bumps [k8s.io/klog/v2](https://github.com/kubernetes/klog) from 2.70.1 to 2.80.1. - [Release notes](https://github.com/kubernetes/klog/releases) - [Changelog](https://github.com/kubernetes/klog/blob/main/RELEASE.md) - [Commits](https://github.com/kubernetes/klog/compare/v2.70.1...v2.80.1) --- updated-dependencies: - dependency-name: k8s.io/klog/v2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
This commit is contained in:
parent
2a6487cbf5
commit
3d04065d00
2
go.mod
2
go.mod
@ -34,7 +34,7 @@ require (
|
|||||||
k8s.io/apimachinery v0.25.0
|
k8s.io/apimachinery v0.25.0
|
||||||
k8s.io/client-go v12.0.0+incompatible
|
k8s.io/client-go v12.0.0+incompatible
|
||||||
k8s.io/cloud-provider v0.25.0
|
k8s.io/cloud-provider v0.25.0
|
||||||
k8s.io/klog/v2 v2.70.1
|
k8s.io/klog/v2 v2.80.1
|
||||||
//
|
//
|
||||||
// when updating k8s.io/kubernetes, make sure to update the replace section too
|
// when updating k8s.io/kubernetes, make sure to update the replace section too
|
||||||
//
|
//
|
||||||
|
3
go.sum
3
go.sum
@ -1867,8 +1867,9 @@ k8s.io/klog/v2 v2.2.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
|
|||||||
k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
|
k8s.io/klog/v2 v2.4.0/go.mod h1:Od+F08eJP+W3HUb4pSrPpgp9DGU4GzlpG/TmITuYh/Y=
|
||||||
k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
|
k8s.io/klog/v2 v2.9.0/go.mod h1:hy9LJ/NvuK+iVyP4Ehqva4HxZG/oXyIS3n3Jmire4Ec=
|
||||||
k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
|
k8s.io/klog/v2 v2.30.0/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
|
||||||
k8s.io/klog/v2 v2.70.1 h1:7aaoSdahviPmR+XkS7FyxlkkXs6tHISSG03RxleQAVQ=
|
|
||||||
k8s.io/klog/v2 v2.70.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
|
k8s.io/klog/v2 v2.70.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
|
||||||
|
k8s.io/klog/v2 v2.80.1 h1:atnLQ121W371wYYFawwYx1aEY2eUfs4l3J72wtgAwV4=
|
||||||
|
k8s.io/klog/v2 v2.80.1/go.mod h1:y1WjHnz7Dj687irZUWR/WLkLc5N1YHtjLdmgWjndZn0=
|
||||||
k8s.io/kube-aggregator v0.25.0/go.mod h1:dfdl4aQkleiWK/U++UDLdDC8g2rsonhkB23zzUeBCgM=
|
k8s.io/kube-aggregator v0.25.0/go.mod h1:dfdl4aQkleiWK/U++UDLdDC8g2rsonhkB23zzUeBCgM=
|
||||||
k8s.io/kube-controller-manager v0.25.0/go.mod h1:SjL1hKSG2z9wajnvjRHZv1zOsdDHjmbZd1ykmaYO6J8=
|
k8s.io/kube-controller-manager v0.25.0/go.mod h1:SjL1hKSG2z9wajnvjRHZv1zOsdDHjmbZd1ykmaYO6J8=
|
||||||
k8s.io/kube-openapi v0.0.0-20180731170545-e3762e86a74c/go.mod h1:BXM9ceUBTj2QnfH2MK1odQs778ajze1RxcmP6S8RVVc=
|
k8s.io/kube-openapi v0.0.0-20180731170545-e3762e86a74c/go.mod h1:BXM9ceUBTj2QnfH2MK1odQs778ajze1RxcmP6S8RVVc=
|
||||||
|
1
vendor/k8s.io/klog/v2/OWNERS
generated
vendored
1
vendor/k8s.io/klog/v2/OWNERS
generated
vendored
@ -1,5 +1,6 @@
|
|||||||
# See the OWNERS docs at https://go.k8s.io/owners
|
# See the OWNERS docs at https://go.k8s.io/owners
|
||||||
reviewers:
|
reviewers:
|
||||||
|
- harshanarayana
|
||||||
- pohly
|
- pohly
|
||||||
approvers:
|
approvers:
|
||||||
- dims
|
- dims
|
||||||
|
5
vendor/k8s.io/klog/v2/contextual.go
generated
vendored
5
vendor/k8s.io/klog/v2/contextual.go
generated
vendored
@ -47,8 +47,9 @@ var (
|
|||||||
// If set, all log lines will be suppressed from the regular output, and
|
// If set, all log lines will be suppressed from the regular output, and
|
||||||
// redirected to the logr implementation.
|
// redirected to the logr implementation.
|
||||||
// Use as:
|
// Use as:
|
||||||
// ...
|
//
|
||||||
// klog.SetLogger(zapr.NewLogger(zapLog))
|
// ...
|
||||||
|
// klog.SetLogger(zapr.NewLogger(zapLog))
|
||||||
//
|
//
|
||||||
// To remove a backing logr implemention, use ClearLogger. Setting an
|
// To remove a backing logr implemention, use ClearLogger. Setting an
|
||||||
// empty logger with SetLogger(logr.Logger{}) does not work.
|
// empty logger with SetLogger(logr.Logger{}) does not work.
|
||||||
|
2
vendor/k8s.io/klog/v2/internal/serialize/keyvalues.go
generated
vendored
2
vendor/k8s.io/klog/v2/internal/serialize/keyvalues.go
generated
vendored
@ -145,7 +145,7 @@ func KVListFormat(b *bytes.Buffer, keysAndValues ...interface{}) {
|
|||||||
case string:
|
case string:
|
||||||
writeStringValue(b, true, value)
|
writeStringValue(b, true, value)
|
||||||
default:
|
default:
|
||||||
writeStringValue(b, false, fmt.Sprintf("%+v", v))
|
writeStringValue(b, false, fmt.Sprintf("%+v", value))
|
||||||
}
|
}
|
||||||
case []byte:
|
case []byte:
|
||||||
// In https://github.com/kubernetes/klog/pull/237 it was decided
|
// In https://github.com/kubernetes/klog/pull/237 it was decided
|
||||||
|
137
vendor/k8s.io/klog/v2/klog.go
generated
vendored
137
vendor/k8s.io/klog/v2/klog.go
generated
vendored
@ -39,39 +39,38 @@
|
|||||||
// This package provides several flags that modify this behavior.
|
// This package provides several flags that modify this behavior.
|
||||||
// As a result, flag.Parse must be called before any logging is done.
|
// As a result, flag.Parse must be called before any logging is done.
|
||||||
//
|
//
|
||||||
// -logtostderr=true
|
// -logtostderr=true
|
||||||
// Logs are written to standard error instead of to files.
|
// Logs are written to standard error instead of to files.
|
||||||
// This shortcuts most of the usual output routing:
|
// This shortcuts most of the usual output routing:
|
||||||
// -alsologtostderr, -stderrthreshold and -log_dir have no
|
// -alsologtostderr, -stderrthreshold and -log_dir have no
|
||||||
// effect and output redirection at runtime with SetOutput is
|
// effect and output redirection at runtime with SetOutput is
|
||||||
// ignored.
|
// ignored.
|
||||||
// -alsologtostderr=false
|
// -alsologtostderr=false
|
||||||
// Logs are written to standard error as well as to files.
|
// Logs are written to standard error as well as to files.
|
||||||
// -stderrthreshold=ERROR
|
// -stderrthreshold=ERROR
|
||||||
// Log events at or above this severity are logged to standard
|
// Log events at or above this severity are logged to standard
|
||||||
// error as well as to files.
|
// error as well as to files.
|
||||||
// -log_dir=""
|
// -log_dir=""
|
||||||
// Log files will be written to this directory instead of the
|
// Log files will be written to this directory instead of the
|
||||||
// default temporary directory.
|
// default temporary directory.
|
||||||
//
|
//
|
||||||
// Other flags provide aids to debugging.
|
// Other flags provide aids to debugging.
|
||||||
//
|
|
||||||
// -log_backtrace_at=""
|
|
||||||
// When set to a file and line number holding a logging statement,
|
|
||||||
// such as
|
|
||||||
// -log_backtrace_at=gopherflakes.go:234
|
|
||||||
// a stack trace will be written to the Info log whenever execution
|
|
||||||
// hits that statement. (Unlike with -vmodule, the ".go" must be
|
|
||||||
// present.)
|
|
||||||
// -v=0
|
|
||||||
// Enable V-leveled logging at the specified level.
|
|
||||||
// -vmodule=""
|
|
||||||
// The syntax of the argument is a comma-separated list of pattern=N,
|
|
||||||
// where pattern is a literal file name (minus the ".go" suffix) or
|
|
||||||
// "glob" pattern and N is a V level. For instance,
|
|
||||||
// -vmodule=gopher*=3
|
|
||||||
// sets the V level to 3 in all Go files whose names begin "gopher".
|
|
||||||
//
|
//
|
||||||
|
// -log_backtrace_at=""
|
||||||
|
// When set to a file and line number holding a logging statement,
|
||||||
|
// such as
|
||||||
|
// -log_backtrace_at=gopherflakes.go:234
|
||||||
|
// a stack trace will be written to the Info log whenever execution
|
||||||
|
// hits that statement. (Unlike with -vmodule, the ".go" must be
|
||||||
|
// present.)
|
||||||
|
// -v=0
|
||||||
|
// Enable V-leveled logging at the specified level.
|
||||||
|
// -vmodule=""
|
||||||
|
// The syntax of the argument is a comma-separated list of pattern=N,
|
||||||
|
// where pattern is a literal file name (minus the ".go" suffix) or
|
||||||
|
// "glob" pattern and N is a V level. For instance,
|
||||||
|
// -vmodule=gopher*=3
|
||||||
|
// sets the V level to 3 in all Go files whose names begin "gopher".
|
||||||
package klog
|
package klog
|
||||||
|
|
||||||
import (
|
import (
|
||||||
@ -397,45 +396,48 @@ type flushSyncWriter interface {
|
|||||||
io.Writer
|
io.Writer
|
||||||
}
|
}
|
||||||
|
|
||||||
// init sets up the defaults.
|
var logging loggingT
|
||||||
|
var commandLine flag.FlagSet
|
||||||
|
|
||||||
|
// init sets up the defaults and creates command line flags.
|
||||||
func init() {
|
func init() {
|
||||||
|
commandLine.StringVar(&logging.logDir, "log_dir", "", "If non-empty, write log files in this directory (no effect when -logtostderr=true)")
|
||||||
|
commandLine.StringVar(&logging.logFile, "log_file", "", "If non-empty, use this log file (no effect when -logtostderr=true)")
|
||||||
|
commandLine.Uint64Var(&logging.logFileMaxSizeMB, "log_file_max_size", 1800,
|
||||||
|
"Defines the maximum size a log file can grow to (no effect when -logtostderr=true). Unit is megabytes. "+
|
||||||
|
"If the value is 0, the maximum file size is unlimited.")
|
||||||
|
commandLine.BoolVar(&logging.toStderr, "logtostderr", true, "log to standard error instead of files")
|
||||||
|
commandLine.BoolVar(&logging.alsoToStderr, "alsologtostderr", false, "log to standard error as well as files (no effect when -logtostderr=true)")
|
||||||
|
logging.setVState(0, nil, false)
|
||||||
|
commandLine.Var(&logging.verbosity, "v", "number for the log level verbosity")
|
||||||
|
commandLine.BoolVar(&logging.addDirHeader, "add_dir_header", false, "If true, adds the file directory to the header of the log messages")
|
||||||
|
commandLine.BoolVar(&logging.skipHeaders, "skip_headers", false, "If true, avoid header prefixes in the log messages")
|
||||||
|
commandLine.BoolVar(&logging.oneOutput, "one_output", false, "If true, only write logs to their native severity level (vs also writing to each lower severity level; no effect when -logtostderr=true)")
|
||||||
|
commandLine.BoolVar(&logging.skipLogHeaders, "skip_log_headers", false, "If true, avoid headers when opening log files (no effect when -logtostderr=true)")
|
||||||
logging.stderrThreshold = severityValue{
|
logging.stderrThreshold = severityValue{
|
||||||
Severity: severity.ErrorLog, // Default stderrThreshold is ERROR.
|
Severity: severity.ErrorLog, // Default stderrThreshold is ERROR.
|
||||||
}
|
}
|
||||||
logging.setVState(0, nil, false)
|
commandLine.Var(&logging.stderrThreshold, "stderrthreshold", "logs at or above this threshold go to stderr when writing to files and stderr (no effect when -logtostderr=true or -alsologtostderr=false)")
|
||||||
logging.logDir = ""
|
commandLine.Var(&logging.vmodule, "vmodule", "comma-separated list of pattern=N settings for file-filtered logging")
|
||||||
logging.logFile = ""
|
commandLine.Var(&logging.traceLocation, "log_backtrace_at", "when logging hits line file:N, emit a stack trace")
|
||||||
logging.logFileMaxSizeMB = 1800
|
|
||||||
logging.toStderr = true
|
logging.settings.contextualLoggingEnabled = true
|
||||||
logging.alsoToStderr = false
|
|
||||||
logging.skipHeaders = false
|
|
||||||
logging.addDirHeader = false
|
|
||||||
logging.skipLogHeaders = false
|
|
||||||
logging.oneOutput = false
|
|
||||||
logging.flushD = newFlushDaemon(logging.lockAndFlushAll, nil)
|
logging.flushD = newFlushDaemon(logging.lockAndFlushAll, nil)
|
||||||
}
|
}
|
||||||
|
|
||||||
// InitFlags is for explicitly initializing the flags.
|
// InitFlags is for explicitly initializing the flags.
|
||||||
|
// It may get called repeatedly for different flagsets, but not
|
||||||
|
// twice for the same one. May get called concurrently
|
||||||
|
// to other goroutines using klog. However, only some flags
|
||||||
|
// may get set concurrently (see implementation).
|
||||||
func InitFlags(flagset *flag.FlagSet) {
|
func InitFlags(flagset *flag.FlagSet) {
|
||||||
if flagset == nil {
|
if flagset == nil {
|
||||||
flagset = flag.CommandLine
|
flagset = flag.CommandLine
|
||||||
}
|
}
|
||||||
|
|
||||||
flagset.StringVar(&logging.logDir, "log_dir", logging.logDir, "If non-empty, write log files in this directory (no effect when -logtostderr=true)")
|
commandLine.VisitAll(func(f *flag.Flag) {
|
||||||
flagset.StringVar(&logging.logFile, "log_file", logging.logFile, "If non-empty, use this log file (no effect when -logtostderr=true)")
|
flagset.Var(f.Value, f.Name, f.Usage)
|
||||||
flagset.Uint64Var(&logging.logFileMaxSizeMB, "log_file_max_size", logging.logFileMaxSizeMB,
|
})
|
||||||
"Defines the maximum size a log file can grow to (no effect when -logtostderr=true). Unit is megabytes. "+
|
|
||||||
"If the value is 0, the maximum file size is unlimited.")
|
|
||||||
flagset.BoolVar(&logging.toStderr, "logtostderr", logging.toStderr, "log to standard error instead of files")
|
|
||||||
flagset.BoolVar(&logging.alsoToStderr, "alsologtostderr", logging.alsoToStderr, "log to standard error as well as files (no effect when -logtostderr=true)")
|
|
||||||
flagset.Var(&logging.verbosity, "v", "number for the log level verbosity")
|
|
||||||
flagset.BoolVar(&logging.addDirHeader, "add_dir_header", logging.addDirHeader, "If true, adds the file directory to the header of the log messages")
|
|
||||||
flagset.BoolVar(&logging.skipHeaders, "skip_headers", logging.skipHeaders, "If true, avoid header prefixes in the log messages")
|
|
||||||
flagset.BoolVar(&logging.oneOutput, "one_output", logging.oneOutput, "If true, only write logs to their native severity level (vs also writing to each lower severity level; no effect when -logtostderr=true)")
|
|
||||||
flagset.BoolVar(&logging.skipLogHeaders, "skip_log_headers", logging.skipLogHeaders, "If true, avoid headers when opening log files (no effect when -logtostderr=true)")
|
|
||||||
flagset.Var(&logging.stderrThreshold, "stderrthreshold", "logs at or above this threshold go to stderr when writing to files and stderr (no effect when -logtostderr=true or -alsologtostderr=false)")
|
|
||||||
flagset.Var(&logging.vmodule, "vmodule", "comma-separated list of pattern=N settings for file-filtered logging")
|
|
||||||
flagset.Var(&logging.traceLocation, "log_backtrace_at", "when logging hits line file:N, emit a stack trace")
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Flush flushes all pending log I/O.
|
// Flush flushes all pending log I/O.
|
||||||
@ -550,12 +552,6 @@ type loggingT struct {
|
|||||||
vmap map[uintptr]Level
|
vmap map[uintptr]Level
|
||||||
}
|
}
|
||||||
|
|
||||||
var logging = loggingT{
|
|
||||||
settings: settings{
|
|
||||||
contextualLoggingEnabled: true,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
// setVState sets a consistent state for V logging.
|
// setVState sets a consistent state for V logging.
|
||||||
// l.mu is held.
|
// l.mu is held.
|
||||||
func (l *loggingT) setVState(verbosity Level, filter []modulePat, setFilter bool) {
|
func (l *loggingT) setVState(verbosity Level, filter []modulePat, setFilter bool) {
|
||||||
@ -633,8 +629,11 @@ It returns a buffer containing the formatted header and the user's file and line
|
|||||||
The depth specifies how many stack frames above lives the source line to be identified in the log message.
|
The depth specifies how many stack frames above lives the source line to be identified in the log message.
|
||||||
|
|
||||||
Log lines have this form:
|
Log lines have this form:
|
||||||
|
|
||||||
Lmmdd hh:mm:ss.uuuuuu threadid file:line] msg...
|
Lmmdd hh:mm:ss.uuuuuu threadid file:line] msg...
|
||||||
|
|
||||||
where the fields are defined as follows:
|
where the fields are defined as follows:
|
||||||
|
|
||||||
L A single character, representing the log level (eg 'I' for INFO)
|
L A single character, representing the log level (eg 'I' for INFO)
|
||||||
mm The month (zero padded; ie May is '05')
|
mm The month (zero padded; ie May is '05')
|
||||||
dd The day (zero padded)
|
dd The day (zero padded)
|
||||||
@ -1298,9 +1297,13 @@ func newVerbose(level Level, b bool) Verbose {
|
|||||||
// The returned value is a struct of type Verbose, which implements Info, Infoln
|
// The returned value is a struct of type Verbose, which implements Info, Infoln
|
||||||
// and Infof. These methods will write to the Info log if called.
|
// and Infof. These methods will write to the Info log if called.
|
||||||
// Thus, one may write either
|
// Thus, one may write either
|
||||||
|
//
|
||||||
// if klog.V(2).Enabled() { klog.Info("log this") }
|
// if klog.V(2).Enabled() { klog.Info("log this") }
|
||||||
|
//
|
||||||
// or
|
// or
|
||||||
|
//
|
||||||
// klog.V(2).Info("log this")
|
// klog.V(2).Info("log this")
|
||||||
|
//
|
||||||
// The second form is shorter but the first is cheaper if logging is off because it does
|
// The second form is shorter but the first is cheaper if logging is off because it does
|
||||||
// not evaluate its arguments.
|
// not evaluate its arguments.
|
||||||
//
|
//
|
||||||
@ -1582,10 +1585,10 @@ func ErrorSDepth(depth int, err error, msg string, keysAndValues ...interface{})
|
|||||||
//
|
//
|
||||||
// Callers who want more control over handling of fatal events may instead use a
|
// Callers who want more control over handling of fatal events may instead use a
|
||||||
// combination of different functions:
|
// combination of different functions:
|
||||||
// - some info or error logging function, optionally with a stack trace
|
// - some info or error logging function, optionally with a stack trace
|
||||||
// value generated by github.com/go-logr/lib/dbg.Backtrace
|
// value generated by github.com/go-logr/lib/dbg.Backtrace
|
||||||
// - Flush to flush pending log data
|
// - Flush to flush pending log data
|
||||||
// - panic, os.Exit or returning to the caller with an error
|
// - panic, os.Exit or returning to the caller with an error
|
||||||
//
|
//
|
||||||
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
|
// Arguments are handled in the manner of fmt.Print; a newline is appended if missing.
|
||||||
func Fatal(args ...interface{}) {
|
func Fatal(args ...interface{}) {
|
||||||
|
2
vendor/modules.txt
vendored
2
vendor/modules.txt
vendored
@ -1207,7 +1207,7 @@ k8s.io/component-helpers/node/util/sysctl
|
|||||||
k8s.io/component-helpers/scheduling/corev1
|
k8s.io/component-helpers/scheduling/corev1
|
||||||
k8s.io/component-helpers/scheduling/corev1/nodeaffinity
|
k8s.io/component-helpers/scheduling/corev1/nodeaffinity
|
||||||
k8s.io/component-helpers/storage/volume
|
k8s.io/component-helpers/storage/volume
|
||||||
# k8s.io/klog/v2 v2.70.1
|
# k8s.io/klog/v2 v2.80.1
|
||||||
## explicit; go 1.13
|
## explicit; go 1.13
|
||||||
k8s.io/klog/v2
|
k8s.io/klog/v2
|
||||||
k8s.io/klog/v2/internal/buffer
|
k8s.io/klog/v2/internal/buffer
|
||||||
|
Loading…
Reference in New Issue
Block a user