Commit Graph

15100 Commits (71881a423fa58b8a37536e47ce82c8e3da61e9a0)

Author SHA1 Message Date
caoming e7b5f2de26 embed: add test cases in TestAutoCompactionModeParse. 2019-01-02 17:08:15 +08:00
Gyuho Lee 400b568fd6
Merge pull request #10360 from yaojingguo/ignore-file
gitignore: ignore build result and runtime files of raftexample
2019-01-01 09:31:38 -08:00
Jingguo Yao e86a12bad0 gitignore: ignore build result and runtime files 2019-01-01 19:14:48 +08:00
Rob Day 959d004bcc docs: install etcdctl with `go get` as well
The documentation recommends using `etcdctl` to verify that etcd has
been built correctly, but the `go get` command provided does not install
it. This changes it so that it does, and also clarifies terminology
('using `go get`', referring to the command used to install it, rather
than 'using `$GOPATH`').
2018-12-30 12:10:32 +00:00
Xiang Li cc8d446a6e
Merge pull request #8334 from lishuai87/shawnsli/reset-leader-when-become-pre-candidate
raft: introduce/fix TestPreVoteWithCheckQuorum
2018-12-28 09:51:06 -08:00
shawnli 23731bf9ba raft: set lead to none when becomePreCandidate 2018-12-28 19:57:26 +08:00
Gyuho Lee 6937b77232 README: remove "you" in "Community Meeting"
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-23 21:53:36 -08:00
Gyuho Lee deeb16c9e8
Merge pull request #10346 from lsytj0413/fix-golint
refactor(*): fix golint warning
2018-12-23 20:26:09 -08:00
lsytj0413 792aad932f refactor(*): fix golint warning 2018-12-24 11:43:10 +08:00
Wenjia 9113019936
Update README.md with community meeting info 2018-12-21 15:53:59 -08:00
Sam Batschelet f3fbedc88f client: update generated ugorji codec, manual remove "yynn2=0"
Signed-off-by: Sam Batschelet <sbatsche@redhat.com>
2018-12-21 18:16:55 -05:00
Gyuho Lee a580ec4547 CHANGELOG: add patch release, gRPC proxy fix
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-17 21:22:37 -08:00
Gyuho Lee 7c7141550d
docs/README: highlight new documentation website 2018-12-17 18:15:26 -08:00
Gyuho Lee 1bbe6bd7d3
Merge pull request #10332 from gyuho/update
*: update Go versions
2018-12-17 15:19:49 -08:00
Gyuho Lee c58f5cfeda test: disable "unparam" for now
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-17 11:30:28 -08:00
Dmitry Verkhoturov 0929080834 doc: exclude 404 error because kubelet generating false positive 2018-12-17 11:57:12 +03:00
Dmitry Verkhoturov 830d064903 doc: convert etcd to lower-case everywhere 2018-12-17 11:57:12 +03:00
Dmitry Verkhoturov 358cc1a8fa doc: sync prometheus rules with prometheus-operator version
(and remove non-etcd specific FdExhaustionClose)
https://github.com/coreos/prometheus-operator/blob/master/helm/exporter-kube-etcd/templates/etcd3.rules.yaml
sync etcd alert rules with libsonnet

Signed-off-by: Dmitry Verkhoturov <paskal.07@gmail.com>
2018-12-17 11:57:12 +03:00
Gyuho Lee 6f0ba5fa06 *: update Go versions
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-16 23:13:11 -08:00
Xiang Li abb57363ba
Merge pull request #10327 from namreg/fix-grpcproxy-memory-leak
grpcproxy: fix memory leak
2018-12-16 17:32:27 -08:00
Igor German d88f686a91 grpcproxy: fix memory leak
use set instead of slice as interval value

fixes #10326
2018-12-15 17:00:51 +03:00
Gyuho Lee e57f4f420d
docs/requirements: update to urllib3>=1.23 2018-12-12 08:57:45 -08:00
Gyuho Lee 15b6a17be4
Merge pull request #10313 from lsytj0413/fix-getlogger
refactor(*): remove duplicate GetLogger
2018-12-10 06:48:02 -08:00
lsytj0413 23862b5d64 refactor(*): remove duplicate GetLogger 2018-12-10 17:58:47 +08:00
Xiang Li 1900a8e26f
Merge pull request #10308 from tbg/fix/progress-after-snap
raft: enter ProgressStateReplica immediately after snapshot
2018-12-06 10:58:22 -08:00
Xiang Li 8a9a2a1a5a
Merge pull request #10309 from tbg/fix/raft-status-allocs
raft: add (*RawNode).WithProgress
2018-12-06 10:56:40 -08:00
Tobias Schottdorf bd332b318e raft: add (*RawNode).WithProgress
Calls to Status can be frequent and currently incur three heap
allocations, but often the caller has no intention to hold on to the
returned status.

Add StatusWithoutProgress and WithProgress to allow avoiding heap
allocations altogether. StatusWithoutProgress does what's on the
tin and additionally returns a value (instead of a pointer) to
avoid the associated heap allocation. By not returning a Progress
map, it avoids all other allocations that Status incurs.

To still introspect the Progress map, add WithProgress, which
uses a simple visitor pattern.

Add benchmarks to verify that this is indeed allocation free.

```
BenchmarkStatusProgress/members=1/Status-8                  5000000    353 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=1/Status-example-8          5000000    372 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=1/StatusWithoutProgress-8   100000000  17.6 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=1/WithProgress-8            30000000   48.6 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=1/WithProgress-example-8    30000000   42.9 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=3/Status-8                  5000000    395 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=3/Status-example-8          3000000    449 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=3/StatusWithoutProgress-8   100000000  18.7 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=3/WithProgress-8            20000000   78.1 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=3/WithProgress-example-8    20000000   70.7 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=5/Status-8                  3000000    470 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=5/Status-example-8          3000000    544 ns/op        784 B/op    3 allocs/op
BenchmarkStatusProgress/members=5/StatusWithoutProgress-8   100000000  19.7 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=5/WithProgress-8            20000000   105 ns/op          0 B/op    0 allocs/op
BenchmarkStatusProgress/members=5/WithProgress-example-8    20000000   94.0 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=100/Status-8                100000     11903 ns/op    22663 B/op   12 allocs/op
BenchmarkStatusProgress/members=100/Status-example-8        100000     13330 ns/op    22669 B/op   12 allocs/op
BenchmarkStatusProgress/members=100/StatusWithoutProgress-8 50000000   20.9 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=100/WithProgress-8          1000000    1731 ns/op         0 B/op    0 allocs/op
BenchmarkStatusProgress/members=100/WithProgress-example-8  1000000    1571 ns/op         0 B/op    0 allocs/op
```
2018-12-06 19:02:48 +01:00
Gyuho Lee bfa2c15c55
Merge pull request #10307 from gyuho/update-image
docs/img: clarify "network partition + membership reconfiguration"
2018-12-06 09:28:36 -08:00
Tobias Schottdorf bfaae1ba46 raft: enter ProgressStateReplica immediately after snapshot
When a follower requires a snapshot and the snapshot is sent at the
committed (and last) index in an otherwise idle Raft group, the follower
would previously remain in ProgressStateProbe even though it had been
caught up completely.

In a busy Raft group this wouldn't be an issue since the next round of
MsgApp would update the state, but in an idle group there's nothing
that rectifies the status (since there's nothing to append or update).

The reason this matters is that the state is exposed through
`RaftStatus()`. Concretely, in CockroachDB, we use the Raft status to
make sharding decisions (since it's dangerous to make rapid changes
to a fragile Raft group), and had to work around this problem[1].

[1]: 91b11dae41/pkg/storage/split_delay_helper.go (L138-L141)
2018-12-06 11:09:59 +01:00
Gyuho Lee 0b5a3d8080 docs/img: clarify "network partition + membership reconfiguration"
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-05 19:05:26 -08:00
Gyuho Lee 510ae3d2a2 clientv3/concurrency: fix govet errors
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-05 18:28:13 -08:00
Gyuho Lee 12b19ff5ea
Merge pull request #10306 from johncming/zap_logger
embed: set log-outputs 'default' to 'stderr' config when zap mode
2018-12-05 18:25:43 -08:00
caoming 6744c57de3 embed: set log-outputs 'default' to 'stderr' config when zap mode 2018-12-06 09:33:51 +08:00
Gyuho Lee 1124ccf4f9
Merge pull request #10305 from johncming/doc
Documentation/op-guide: fix typo.
2018-12-05 16:55:15 -08:00
caoming e4ac8db4ae Documentation/op-guide: fix typo. 2018-12-06 08:48:30 +08:00
Xiang Li 83696d95c9
Merge pull request #10297 from thrawn01/election-resume
concurrency: set keyPrefix when calling ResumeElection()
2018-12-05 13:25:39 -08:00
Derrick J. Wippler 7d7266d3c9 concurrency: set keyPrefix when calling ResumeElection()
This change allows users to use Observe() after resuming an election as
Observe() requires a valid keyPrefix to function properly.
2018-12-05 14:50:56 -06:00
Xiang Li 3f01426712
Merge pull request #10301 from jingyih/add_timeout_to_etcdctl_snapshot_save
etcdctl: add timeout to snapshot save command
2018-12-04 21:23:15 -08:00
Xiang Li ce3e127d0b
Merge pull request #10302 from jingyih/update_changelog_3p4_from_pr10301
CHANGELOG-3.4: update from #10301
2018-12-04 21:19:50 -08:00
Jingyi Hu 9db21117d1 CHANGELOG-3.4: update from #10301 2018-12-04 21:06:46 -08:00
Jingyi Hu 5b6b03d081 etcdctl: add timeout to snapshot save command
snapshot save command by default has no timeout, but respects user
specified command timeout.
2018-12-04 20:36:48 -08:00
Gyuho Lee 7f450bf696
Merge pull request #10296 from gyuho/learner
docs: rename to "learner" (from "non-voting member")
2018-12-03 11:17:26 -08:00
Gyuho Lee bfd9596352 docs: rename to "learner" (from "non-voting member")
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-03 10:38:40 -08:00
Gyuho Lee 99c933b7bc
Merge pull request #10295 from gyuho/non-voting-member-design
docs: add "Non-voting member" design doc
2018-12-03 10:27:24 -08:00
Gyuho Lee 1f559736ef docs: add authors to client architecture doc
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-03 09:12:51 -08:00
Gyuho Lee 285a3acda6 docs: add "Non-voting member" design doc
By gyuho and jpbetz.

Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-12-03 09:00:08 -08:00
Gyuho Lee dedae6eb7c CHANGELOG-3.4: add backend batch limit/interval fields
Signed-off-by: Gyuho Lee <leegyuho@amazon.com>
2018-11-28 14:03:05 -08:00
Xiang Li 829c9b2129
Merge pull request #10283 from xiang90/more_flags
*: add flags to setup backend related config
2018-11-27 18:58:43 -08:00
Xiang Li 3faed211e5 *: add flags to setup backend related config 2018-11-26 15:50:26 -08:00
Xiang Li 6c649de36e
Merge pull request #10281 from tbg/print-hint-reject-app-resp
raft: print RejectHint of zero on MsgAppResp
2018-11-24 11:48:16 +08:00