uber-node / ringpop-node

Scalable, fault-tolerant application-layer sharding for Node.js applications
http://uber.github.io/ringpop/
MIT License
1.18k stars 146 forks source link

Make sure incarnation number is increased when bumped #298

Open mennopruijssers opened 8 years ago

mennopruijssers commented 8 years ago

When reincarnating, the incarnation number is always "bumped" to the current time in ms. If we reincarnate twice in one ms, the incarnation number is not really bumped. By can make sure it's always increasing by using max(currentIncarnationNumber + 1, Date.now()).

(go: uber/ringpop-go#163)