Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Default Raft election timeout to 5 seconds #2549

Merged
merged 1 commit into from
May 12, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ This release has a breaking API change for writes -- the field previously called
- [#2525](https://github.com/influxdb/influxdb/pull/2525): Serve broker diagnostics over HTTP
- [#2186](https://github.com/influxdb/influxdb/pull/2186): The default status code for queries is now `200 OK`
- [#2298](https://github.com/influxdb/influxdb/pull/2298): Successful writes now return a status code of `204 No Content` - thanks @neonstalwart!
- [#2549](https://github.com/influxdb/influxdb/pull/2549): Raft election timeout to 5 seconds, so system is more forgiving of CPU loads.

### Bugfixes
- [#2535](https://github.com/influxdb/influxdb/pull/2535): Return exit status 0 if influxd already running. Thanks @haim0n.
Expand Down
2 changes: 1 addition & 1 deletion etc/config.sample.toml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,7 @@ max-segment-size = 10485760
# Raft configuration. Controls the distributed consensus system.
[raft]
apply-interval = "10ms"
election-timeout = "1s"
election-timeout = "5s"
heartbeat-interval = "100ms"
reconnect-timeout = "10ms"

Expand Down
2 changes: 1 addition & 1 deletion raft/clock.go
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const (
DefaultApplyInterval = 10 * time.Millisecond

// DefaultElectionTimeout is the default time before starting an election.
DefaultElectionTimeout = 1 * time.Second
DefaultElectionTimeout = 5 * time.Second

// DefaultHeartbeatInterval is the default time to wait between heartbeats.
DefaultHeartbeatInterval = 100 * time.Millisecond
Expand Down