Commit Graph

58 Commits (272f855d815189eb4fd326569372d165da9d7cb4)

Author SHA1 Message Date
Ben Johnson 3d71d45cf6 Return term from vote, add term logging. 2015-04-04 10:59:50 -06:00
Ben Johnson bc444821b9 Add raft term logging. 2015-04-01 15:42:16 -06:00
Ben Johnson 947c776dc8 Fix comments. 2015-03-30 08:13:13 -06:00
Ben Johnson 189aaa0d82 Remove debug statements. 2015-03-29 15:36:55 -06:00
Ben Johnson 27f4a3efec Fix raft transition and reader edge cases. 2015-03-29 15:04:11 -06:00
Ben Johnson 3d03602fa7 Raft documentation, read from index fix. 2015-03-29 09:08:44 -06:00
Ben Johnson 057309fc8e Simplify raft snapshotting, entry apply. 2015-03-26 20:32:39 -06:00
Philip O'Toole c461c7e7b4 Remove logging to specific file 2015-03-25 17:41:39 -07:00
Ben Johnson 11c808f55f Add restore and bootstrap.
This commit adds the "influxd restore" command to the CLI. This allows
a snapshot that has been produced by "influxd backup" to be restored
to a config location and the broker and raft directories will be
bootstrapped based on the state of the snapshot.
2015-03-22 15:31:49 -06:00
Ben Johnson 75450466a6 Fix leader id initialization. 2015-03-16 11:27:57 -06:00
Ben Johnson 96748cb217 Update file permissions. 2015-03-14 13:49:25 -06:00
Ben Johnson 53dbec8232 Add config notifications and increased test coverage. 2015-03-14 13:36:06 -06:00
Ben Johnson 5f6bcf523f Fix broker integration bugs. 2015-03-11 12:00:45 -06:00
Ben Johnson 66115f95ca Merge branch 'master' of https://github.com/influxdb/influxdb into stateless-broker
Conflicts:
	cmd/influxd/run.go
	messaging/broker.go
	messaging/client.go
	messaging/client_test.go
	messaging/intg_test.go
	server.go
	tx_test.go
2015-03-10 16:27:37 -06:00
Ben Johnson 27e9132796 Integrate stateless broker into remaining packages. 2015-03-10 14:53:45 -06:00
Joseph Rothrock 9b63eed767 Merge branch 'master' of github.com:influxdb/influxdb into 1753
Conflicts:
	CHANGELOG.md
2015-03-06 12:37:15 -08:00
Joseph Rothrock 771ef1cec3 Don't Panic on Missing Dirs
Issue: 1753
Figure out what's missing, create it, and keep going.
2015-03-06 12:11:02 -08:00
dgnorton 3454523bae Merge pull request #1864 from influxdb/fix-1180
fix #1180: race in startStateLoop
2015-03-06 13:21:05 -05:00
Ben Johnson cae0e85ed7 Update higher term on leader during stream request.
This commit adds a check for newer terms in the streaming endpoint.
2015-03-06 11:12:54 -07:00
David Norton cb780d82d5 fix #1180: race in startStateLoop 2015-03-06 13:09:46 -05:00
Todd Persen 11fce7cb33 Seed the random Int63 generator. 2015-02-23 23:19:56 -08:00
Ben Johnson 9dd299fe80 Add small delay for single node heartbeat.
This commit adds a small 10ms delay to the heartbeat when there is only
one node in the cluster. This code needs a larger fix to avoid heartbeats
with a single node cluster but this should work well in the short term.
2015-02-23 16:18:19 -07:00
Ben Johnson 64cc1fb0f6 Lower wait interval to speed up tests. 2015-02-21 08:19:28 -07:00
Ben Johnson a7a8e0bba4 Fix candidate heartbeat step down. 2015-02-20 13:52:45 -07:00
Ben Johnson 9ff2969d38 Add set up code for raft internal tests. 2015-02-20 13:52:12 -07:00
Ben Johnson 02764a8a12 Fix raft last log index. 2015-02-20 11:02:30 -07:00
Ben Johnson 88ef9948c5 minor raft fixes 2015-02-19 11:24:23 -07:00
Ben Johnson be22933c49 Additional raft fixes. 2015-02-18 15:37:42 -07:00
Ben Johnson f6ceb9bd32 Refactor raft state handling.
This commit changes the state handling of the raft log. The actions
for related to each raft state are strictly confined within that state's
loop. To transition between states, the raft log now much clean up all
its actions before moving on.

This fixes issues where goroutines were kicked off for one state but
were delayed in their scheduling so they would begin after the log
had already changed to another state.
2015-02-16 15:45:37 -07:00
Ben Johnson d2fb16e901 Clarify quorum code. 2015-02-06 17:50:03 -07:00
Ben Johnson 57c14987a6 Raft package fixes.
This commit includes various fixes to improve the stability of the raft package tests and benchmarks.
2015-02-06 12:46:50 -07:00
Ben Johnson 9c66efa015 Clarify raft trace logging. 2015-02-05 07:35:08 -07:00
Ben Johnson 6c14371df4 Refactor raft package.
This commit refactors the raft package to more loosely couple the individual parts. The clock is now broken into
an interface that signals individual actions in the log. The transport has been mocked to allow more control over
the log tests. The handler's log has been mocked to separate its testing from the log itself.
2015-02-04 18:59:06 -07:00
Philip O'Toole 9943f86cf4 Enable module-level logging 2015-01-29 15:07:58 -08:00
Ben Johnson 3601c3c79f Fix restarts and broker redirection. 2015-01-28 01:09:50 -05:00
Cory LaNou 639ee30d79 WriteEntryTo -> WriteEntriesTo 2015-01-13 11:27:49 -07:00
Cory LaNou b815cb5689 go vet without arguments will now pass cleanly 2015-01-13 11:15:45 -07:00
Ben Johnson 50a0826026 Add broker snapshot/restore and CLI join. 2015-01-06 17:21:32 -07:00
Philip O'Toole 3ab0c5b270 Add logging of Raft initialization 2014-12-19 16:18:01 -05:00
Philip O'Toole 72d73b800c Use existing config variable, not a new one
Without this, log remained closed. Always.
2014-12-19 13:08:09 -05:00
Ben Johnson 5fe566466e Add messaging and raft test coverage. 2014-11-12 22:32:42 -07:00
Ben Johnson ab0efbe677 Config encoding fixes. 2014-11-11 21:14:32 -07:00
Ben Johnson 4ac988b483 Improve test coverage, elections. 2014-09-28 11:38:08 -06:00
Ben Johnson a90622bf04 Refactor election code. 2014-09-27 17:28:03 -06:00
Ben Johnson 3a1b8b1a22 Replace simulation test coverage. 2014-09-27 16:24:59 -06:00
Ben Johnson a175bcce34 Simulation testing changes. 2014-09-26 14:50:41 -06:00
Ben Johnson 87499cab1b Move config and encoding into different files. 2014-09-24 17:47:10 -06:00
Ben Johnson 3a7ef7684f Refactor simulation testing framework. 2014-09-24 17:15:21 -06:00
Ben Johnson 425bd0aa2e Fix race conditions, tests. 2014-09-22 19:43:15 -06:00
Ben Johnson 04a7ea32ae Refactor in-memory entries, add snapshotting. 2014-09-19 18:32:53 -06:00