Skip to content

Commit 45dbe3c

Browse files
authored
Merge pull request #21161 from ahrtr/20260119_max_snapshots_3.6
[release-3.6] Remove flag --max-snapshots in 3.8 rather than 3.7
2 parents fb02473 + a889244 commit 45dbe3c

4 files changed

Lines changed: 6 additions & 6 deletions

File tree

server/embed/config.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -219,8 +219,8 @@ type Config struct {
219219
SnapshotCatchUpEntries uint64 `json:"snapshot-catchup-entries"`
220220

221221
// MaxSnapFiles is the maximum number of snapshot files.
222-
// TODO: remove it in 3.7.
223-
// Deprecated: Will be removed in v3.7.
222+
// TODO: remove it in 3.8.
223+
// Deprecated: Will be removed in v3.8.
224224
MaxSnapFiles uint `json:"max-snapshots"`
225225
//revive:disable-next-line:var-naming
226226
MaxWalFiles uint `json:"max-wals"`
@@ -771,7 +771,7 @@ func (cfg *Config) AddFlags(fs *flag.FlagSet) {
771771
"listen-metrics-urls",
772772
"List of URLs to listen on for the metrics and health endpoints.",
773773
)
774-
fs.UintVar(&cfg.MaxSnapFiles, "max-snapshots", cfg.MaxSnapFiles, "Maximum number of snapshot files to retain (0 is unlimited). Deprecated in v3.6 and will be decommissioned in v3.7.")
774+
fs.UintVar(&cfg.MaxSnapFiles, "max-snapshots", cfg.MaxSnapFiles, "Maximum number of snapshot files to retain (0 is unlimited). Deprecated in v3.6 and will be decommissioned in v3.8.")
775775
fs.UintVar(&cfg.MaxWalFiles, "max-wals", cfg.MaxWalFiles, "Maximum number of wal files to retain (0 is unlimited).")
776776
fs.StringVar(&cfg.Name, "name", cfg.Name, "Human-readable name for this member.")
777777
fs.Uint64Var(&cfg.SnapshotCount, "snapshot-count", cfg.SnapshotCount, "Number of committed transactions to trigger a snapshot to disk. Deprecated in v3.6 and will be decommissioned in v3.7.")

server/etcdmain/config.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ var (
6060
deprecatedFlags = map[string]string{
6161
// TODO: remove in 3.7.
6262
"snapshot-count": "--snapshot-count is deprecated in 3.6 and will be decommissioned in 3.7.",
63-
"max-snapshots": "--max-snapshots is deprecated in 3.6 and will be decommissioned in 3.7.",
63+
"max-snapshots": "--max-snapshots is deprecated in 3.6 and will be decommissioned in 3.8.",
6464
"v2-deprecation": "--v2-deprecation is deprecated and scheduled for removal in v3.8. The default value is enforced, ignoring user input.",
6565
"experimental-compact-hash-check-enabled": "--experimental-compact-hash-check-enabled is deprecated in 3.6 and will be decommissioned in 3.7. Use '--feature-gates=CompactHashCheck=true' instead.",
6666
"experimental-compact-hash-check-time": "--experimental-compact-hash-check-time is deprecated in 3.6 and will be decommissioned in 3.7. Use '--compact-hash-check-time' instead.",

server/etcdmain/help.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ Member:
7272
--listen-client-http-urls ''
7373
List of URLs to listen on for http only client traffic. Enabling this flag removes http services from --listen-client-urls.
7474
--max-snapshots '` + strconv.Itoa(embed.DefaultMaxSnapshots) + `'
75-
Maximum number of snapshot files to retain (0 is unlimited). Deprecated in v3.6 and will be decommissioned in v3.7.
75+
Maximum number of snapshot files to retain (0 is unlimited). Deprecated in v3.6 and will be decommissioned in v3.8.
7676
--max-wals '` + strconv.Itoa(embed.DefaultMaxWALs) + `'
7777
Maximum number of wal files to retain (0 is unlimited).
7878
--memory-mlock

tests/e2e/etcd_config_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -684,7 +684,7 @@ func TestEtcdDeprecatedFlags(t *testing.T) {
684684
{
685685
name: "max-snapshots",
686686
args: append(commonArgs, "--max-snapshots=10"),
687-
expectedMsg: "--max-snapshots is deprecated in 3.6 and will be decommissioned in 3.7",
687+
expectedMsg: "--max-snapshots is deprecated in 3.6 and will be decommissioned in 3.8",
688688
},
689689
{
690690
name: "v2-deprecation",

0 commit comments

Comments
 (0)