From 90d4d9d618f2964efc7fbd657d2d87ab30a6dfc5 Mon Sep 17 00:00:00 2001 From: Bogdan Kanivets Date: Thu, 1 Sep 2022 11:00:18 -0700 Subject: [PATCH] server: removed 'experimental' from warning-unary-request-duration flag fixes https://github.com/etcd-io/etcd/issues/13783 --- server/embed/config.go | 6 +++--- server/embed/etcd.go | 2 +- server/etcdmain/config.go | 2 +- server/etcdmain/help.go | 6 +++--- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/server/embed/config.go b/server/embed/config.go index af4e2524182a..a282d1f686bb 100644 --- a/server/embed/config.go +++ b/server/embed/config.go @@ -342,9 +342,9 @@ type Config struct { // ExperimentalBootstrapDefragThresholdMegabytes is the minimum number of megabytes needed to be freed for etcd server to // consider running defrag during bootstrap. Needs to be set to non-zero value to take effect. ExperimentalBootstrapDefragThresholdMegabytes uint `json:"experimental-bootstrap-defrag-threshold-megabytes"` - // ExperimentalWarningUnaryRequestDuration is the time duration after which a warning is generated if applying + // WarningUnaryRequestDuration is the time duration after which a warning is generated if applying // unary request takes more time than this value. - ExperimentalWarningUnaryRequestDuration time.Duration `json:"experimental-warning-unary-request-duration"` + WarningUnaryRequestDuration time.Duration `json:"experimental-warning-unary-request-duration"` // ExperimentalMaxLearners sets a limit to the number of learner members that can exist in the cluster membership. ExperimentalMaxLearners int `json:"experimental-max-learners"` @@ -474,7 +474,7 @@ func NewConfig() *Config { MaxConcurrentStreams: DefaultMaxConcurrentStreams, ExperimentalWarningApplyDuration: DefaultWarningApplyDuration, - ExperimentalWarningUnaryRequestDuration: DefaultWarningUnaryRequestDuration, + WarningUnaryRequestDuration: DefaultWarningUnaryRequestDuration, GRPCKeepAliveMinTime: DefaultGRPCKeepAliveMinTime, GRPCKeepAliveInterval: DefaultGRPCKeepAliveInterval, diff --git a/server/embed/etcd.go b/server/embed/etcd.go index 8a9ed897ff10..1c9782558588 100644 --- a/server/embed/etcd.go +++ b/server/embed/etcd.go @@ -217,7 +217,7 @@ func StartEtcd(inCfg *Config) (e *Etcd, err error) { WatchProgressNotifyInterval: cfg.ExperimentalWatchProgressNotifyInterval, DowngradeCheckTime: cfg.ExperimentalDowngradeCheckTime, WarningApplyDuration: cfg.ExperimentalWarningApplyDuration, - WarningUnaryRequestDuration: cfg.ExperimentalWarningUnaryRequestDuration, + WarningUnaryRequestDuration: cfg.WarningUnaryRequestDuration, ExperimentalMemoryMlock: cfg.ExperimentalMemoryMlock, ExperimentalTxnModeWriteWithSharedBuffer: cfg.ExperimentalTxnModeWriteWithSharedBuffer, ExperimentalBootstrapDefragThresholdMegabytes: cfg.ExperimentalBootstrapDefragThresholdMegabytes, diff --git a/server/etcdmain/config.go b/server/etcdmain/config.go index b14191a95cb8..1842d51e49e5 100644 --- a/server/etcdmain/config.go +++ b/server/etcdmain/config.go @@ -270,7 +270,7 @@ func newConfig() *config { fs.DurationVar(&cfg.ec.ExperimentalWatchProgressNotifyInterval, "experimental-watch-progress-notify-interval", cfg.ec.ExperimentalWatchProgressNotifyInterval, "Duration of periodic watch progress notifications.") fs.DurationVar(&cfg.ec.ExperimentalDowngradeCheckTime, "experimental-downgrade-check-time", cfg.ec.ExperimentalDowngradeCheckTime, "Duration of time between two downgrade status check.") fs.DurationVar(&cfg.ec.ExperimentalWarningApplyDuration, "experimental-warning-apply-duration", cfg.ec.ExperimentalWarningApplyDuration, "Time duration after which a warning is generated if request takes more time.") - fs.DurationVar(&cfg.ec.ExperimentalWarningUnaryRequestDuration, "experimental-warning-unary-request-duration", cfg.ec.ExperimentalWarningUnaryRequestDuration, "Time duration after which a warning is generated if a unary request takes more time.") + fs.DurationVar(&cfg.ec.WarningUnaryRequestDuration, "warning-unary-request-duration", cfg.ec.WarningUnaryRequestDuration, "Time duration after which a warning is generated if a unary request takes more time.") fs.BoolVar(&cfg.ec.ExperimentalMemoryMlock, "experimental-memory-mlock", cfg.ec.ExperimentalMemoryMlock, "Enable to enforce etcd pages (in particular bbolt) to stay in RAM.") fs.BoolVar(&cfg.ec.ExperimentalTxnModeWriteWithSharedBuffer, "experimental-txn-mode-write-with-shared-buffer", true, "Enable the write transaction to use a shared buffer in its readonly check operations.") fs.UintVar(&cfg.ec.ExperimentalBootstrapDefragThresholdMegabytes, "experimental-bootstrap-defrag-threshold-megabytes", 0, "Enable the defrag during etcd server bootstrap on condition that it will free at least the provided threshold of disk space. Needs to be set to non-zero value to take effect.") diff --git a/server/etcdmain/help.go b/server/etcdmain/help.go index a7f569a8e668..0ad7693cab71 100644 --- a/server/etcdmain/help.go +++ b/server/etcdmain/help.go @@ -227,7 +227,9 @@ Logging: --enable-log-rotation 'false' Enable log rotation of a single log-outputs file target. --log-rotation-config-json '{"maxsize": 100, "maxage": 0, "maxbackups": 0, "localtime": false, "compress": false}' - Configures log rotation if enabled with a JSON logger config. MaxSize(MB), MaxAge(days,0=no limit), MaxBackups(0=no limit), LocalTime(use computers local time), Compress(gzip)". + Configures log rotation if enabled with a JSON logger config. MaxSize(MB), MaxAge(days,0=no limit), MaxBackups(0=no limit), LocalTime(use computers local time), Compress(gzip)". + --warning-unary-request-duration '300ms' + Set time duration after which a warning is logged if a unary request takes more than this duration. Experimental distributed tracing: --experimental-enable-distributed-tracing 'false' @@ -260,8 +262,6 @@ Experimental feature: Enable the write transaction to use a shared buffer in its readonly check operations. --experimental-bootstrap-defrag-threshold-megabytes Enable the defrag during etcd server bootstrap on condition that it will free at least the provided threshold of disk space. Needs to be set to non-zero value to take effect. - --experimental-warning-unary-request-duration '300ms' - Set time duration after which a warning is generated if a unary request takes more than this duration. --experimental-max-learners '1' Set the max number of learner members allowed in the cluster membership. --experimental-wait-cluster-ready-timeout '5s'