GithubHelp home page GithubHelp logo

Comments (8)

stevezhang-dstring avatar stevezhang-dstring commented on August 17, 2024 1

Thanks for the clarification!

Shifeng

from raft.

freeekanayaka avatar freeekanayaka commented on August 17, 2024 1

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.

willemt avatar willemt commented on August 17, 2024

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.

stevezhang-dstring avatar stevezhang-dstring commented on August 17, 2024

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.

willemt avatar willemt commented on August 17, 2024

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.

freeekanayaka avatar freeekanayaka commented on August 17, 2024

It seems @willemt comprehensively replied to this question. @ShifengZhang can this issue be closed?

from raft.

willemt avatar willemt commented on August 17, 2024

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.

stevezhang-dstring avatar stevezhang-dstring commented on August 17, 2024

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)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo 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.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.