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

raft: implements appendEntriesResponse #129

Merged
merged 18 commits into from
May 26, 2020

Conversation

Abby3017
Copy link
Collaborator

When appendEntry RPC is sent by leader to other nodes, this function generate response for the leader and handles the entries that should be stored in node logs.

@Abby3017 Abby3017 requested a review from SUMUKHA-PK May 19, 2020 04:33
@Abby3017 Abby3017 self-assigned this May 19, 2020
@SUMUKHA-PK SUMUKHA-PK changed the title implemented appendEntriesResponse Implements appendEntriesResponse May 19, 2020
Copy link
Collaborator

@SUMUKHA-PK SUMUKHA-PK left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Im guessing you followed Figure 2 from https://raft.github.io/raft.pdf
Can you please add comments over the lines which do anything?
For example if nodeTerm > leaderTerm, you must write Reply false if term < currentTerm or something justifying it. Makes reviewing and reading later easier.

internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
@Abby3017
Copy link
Collaborator Author

nodeTerm

This kind of things are already mentioned in the design doc, that's why I didn't commented about that due to writing same thing two times.

@SUMUKHA-PK
Copy link
Collaborator

Yes but please do.

@Abby3017 Abby3017 requested a review from SUMUKHA-PK May 22, 2020 04:07
@Abby3017 Abby3017 added this to the v0.0.1 milestone May 22, 2020
internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
@SUMUKHA-PK SUMUKHA-PK marked this pull request as ready for review May 22, 2020 06:28
@SUMUKHA-PK SUMUKHA-PK self-requested a review May 22, 2020 06:28
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries.go Outdated Show resolved Hide resolved
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries_test.go Outdated Show resolved Hide resolved
internal/raft/append_entries_test.go Outdated Show resolved Hide resolved
internal/raft/append_entries_test.go Show resolved Hide resolved
internal/raft/append_entries_test.go Outdated Show resolved Hide resolved
internal/raft/append_entries_test.go Show resolved Hide resolved
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries_test.go Outdated Show resolved Hide resolved
internal/raft/append_entries_test.go Show resolved Hide resolved
internal/raft/append_entries.go Show resolved Hide resolved
internal/raft/append_entries_test.go Outdated Show resolved Hide resolved
internal/raft/raft.go Outdated Show resolved Hide resolved
@tsatke tsatke requested a review from SUMUKHA-PK May 25, 2020 15:01
@tsatke tsatke changed the title Implements appendEntriesResponse raft: implements appendEntriesResponse May 25, 2020
@SUMUKHA-PK SUMUKHA-PK merged commit f04fb20 into tomarrell:raft May 26, 2020
@Abby3017 Abby3017 deleted the appendEntriesResponse branch May 27, 2020 08:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants