From 374f4cef4d2bae0711dc9bfb5f52516bba7b4076 Mon Sep 17 00:00:00 2001 From: Gyuho Lee Date: Fri, 18 May 2018 14:28:26 -0700 Subject: [PATCH] *: document "SnapshotCount" field change Signed-off-by: Gyuho Lee --- CHANGELOG-3.4.md | 3 +++ Documentation/upgrades/upgrade_3_4.md | 24 ++++++++++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/CHANGELOG-3.4.md b/CHANGELOG-3.4.md index b09da3c65..003128727 100644 --- a/CHANGELOG-3.4.md +++ b/CHANGELOG-3.4.md @@ -58,6 +58,8 @@ See [code changes](https://github.com/coreos/etcd/compare/v3.3.0...v3.4.0) and [ - e.g. exit with error on `ETCD_INITIAL_CLUSTER_TOKEN=abc etcd --initial-cluster-token=def`. - e.g. exit with error on `ETCDCTL_ENDPOINTS=abc.com ETCDCTL_API=3 etcdctl endpoint health --endpoints=def.com`. - Change [`etcdserverpb.AuthRoleRevokePermissionRequest/key,range_end` fields type from `string` to `bytes`](https://github.com/coreos/etcd/pull/9433). +- Rename `etcdserver.ServerConfig.SnapCount` field to `etcdserver.ServerConfig.SnapshotCount`, to be consistent with the flag name `etcd --snapshot-count`. +- Rename `embed.Config.SnapCount` field to [`embed.Config.SnapshotCount`](https://github.com/coreos/etcd/pull/9745), to be consistent with the flag name `etcd --snapshot-count`. - Change [`embed.Config.CorsInfo` in `*cors.CORSInfo` type to `embed.Config.CORS` in `map[string]struct{}` type](https://github.com/coreos/etcd/pull/9490). - Remove [`embed.Config.SetupLogging`](https://github.com/coreos/etcd/pull/9572). - Now logger is set up automatically based on [`embed.Config.Logger`, `embed.Config.LogOutputs`, `embed.Config.Debug` fields](https://github.com/coreos/etcd/pull/9572). @@ -231,6 +233,7 @@ Note: **v3.5 will deprecate `etcd --log-package-levels` flag for `capnslog`**; ` - Remove [`embed.Config.SetupLogging`](https://github.com/coreos/etcd/pull/9572). - Now logger is set up automatically based on [`embed.Config.Logger`, `embed.Config.LogOutputs`, `embed.Config.Debug` fields](https://github.com/coreos/etcd/pull/9572). - Add [`embed.Config.Logger`](https://github.com/coreos/etcd/pull/9518) to support [structured logger `zap`](https://github.com/uber-go/zap) in server-side. +- Rename `embed.Config.SnapCount` field to [`embed.Config.SnapshotCount`](https://github.com/coreos/etcd/pull/9745), to be consistent with the flag name `etcd --snapshot-count`. - Rename [**`embed.Config.LogOutput`** to **`embed.Config.LogOutputs`**](https://github.com/coreos/etcd/pull/9624) to support multiple log outputs. - Change [**`embed.Config.LogOutputs`** type from `string` to `[]string`](https://github.com/coreos/etcd/pull/9579) to support multiple log outputs. diff --git a/Documentation/upgrades/upgrade_3_4.md b/Documentation/upgrades/upgrade_3_4.md index 90f24da10..f40a4a8bb 100644 --- a/Documentation/upgrades/upgrade_3_4.md +++ b/Documentation/upgrades/upgrade_3_4.md @@ -90,6 +90,30 @@ if err != nil { } ``` +#### Changed `embed.Config.SnapCount` to `embed.Config.SnapshotCount` + +To be consistent with the flag name `etcd --snapshot-count`, `embed.Config.SnapCount` field has been renamed to `embed.Config.SnapshotCount`: + +```diff +import "github.com/coreos/etcd/embed" + +cfg := embed.NewConfig() +-cfg.SnapCount = 100000 ++cfg.SnapshotCount = 100000 +``` + +#### Changed `etcdserver.ServerConfig.SnapCount` to `etcdserver.ServerConfig.SnapshotCount` + +To be consistent with the flag name `etcd --snapshot-count`, `etcdserver.ServerConfig.SnapCount` field has been renamed to `etcdserver.ServerConfig.SnapshotCount`: + +```diff +import "github.com/coreos/etcd/etcdserver" + +srvcfg := etcdserver.ServerConfig{ +- SnapCount: 100000, ++ SnapshotCount: 100000, +``` + #### Changed function signature in package `wal` Changed `wal` function signatures to support structured logger.