Comments (8)
Thanks for the clarification!
Shifeng
from raft.
Perhaps a FAQ file could be added and linked from the README. The conversation from this issue (and other issues marked with the "FAQ" tag) be copied there, so they don't remain open but the information is still reasonably visible.
from raft.
Hi Shifeng
Yes the library will work without raft_recv_entry
.
But please be aware that if you need dynamic membership changes, you MUST append logs.
from raft.
Thanks Willem! I tested with no raft_recv_entry() call / no log maintainance, and the election did work as well.
As for the dynamic membership changes, suppose I have a five servers {A,B,C,D,E} configuration. If any one of those server crashed and rebooted to join again, is it kind of dynamic membership change? In my test, I killed one server, and the rest four servers still can elect a new leader as well (though I did not test the reboot+join, but the leader will send the appendentries to the rebooted server who will become the follower again).
My understanding of the dynamic membership change is the original configuration changed. For example, the {A,B,C,D,E} changed to {A.B,C,D,F}. (from the raft paper, "it will occasionally be necessary to change the configuration, for example to replace servers when they fail or to change the degree of replication")
Thanks,
Shifeng
from raft.
As for the dynamic membership changes, suppose I have a five servers {A,B,C,D,E} configuration. If any one of those server crashed and rebooted to join again, is it kind of dynamic membership change?
No this isn't a dynamic membership change. It's just normal recovery.
For example, the {A,B,C,D,E} changed to {A.B,C,D,F}.
If you change the membership while the servers are online, then yes, this is a dynamic membership change. Please check out https://github.com/willemt/raft#membership-changes. Dynamic membership changes can only be done via raft_recv_entry
. This means dynamic membership changes MUST use the log.
If membership is static (eg. {A,B,C,D,E} never changes), then you don't need to use the log. It's worth pointing out, that if you can change the membership (eg. {A,B,C,D,E} changed to {A.B,C,D,F}) while the servers are offline, then you don't need to use the log!
from raft.
It seems @willemt comprehensively replied to this question. @ShifengZhang can this issue be closed?
from raft.
hi @freeekanayaka, I am following the "label important issues as FAQ and keep them open" style that https://github.com/h2o/h2o does. An FAQ file sounds nice, but I haven't seen projects use them. I'll give this a think. It would be nice to remove some issues
from raft.
Yes, I think this issue is helpful; and I can close it or keep open to follow the "label important issues as FAQ and keep them open" style. Either way works for me.
Thanks.
from raft.
Related Issues (20)
- Possible issues HOT 1
- How to add SOVERSION to libraft.so?
- Not implemented log_clear callback leads to not synchronized logs
- reserved identifier violation
- Unused raft_term_t term in log_load_from_snapshot
- potential race condition in removing/adding same node?
- Should we submit empty log after a new leader elected?
- Allow easy build without coverage symbols and AddressSanitizer
- Errors `undefined reference to raft_new()` and `undefined reference to raft_add_node(void**, void*, int, int)` HOT 1
- disk write and leader timeout HOT 4
- Documents are old HOT 5
- Add PreVote support
- raft_send_appendentries_all logic HOT 1
- Log interface decoupling HOT 5
- Empty AppendEntries requests are sent during non-idle periods
- FSM log entries are applied lazily HOT 1
- Leader goes into infinite send_snapshot loop HOT 4
- Meaning of entry_idx in log_offer
- log_get_from_idx not including entries that have wrapped around? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from raft.