Hi :
I am new to the zookeeper , I have just begin to read some code of
zookeeper , but I don't quiet undestanding the quorm/lead.java 's
getEpochToPropose method, In this function there is a statement
if (lastAcceptedEpoch > epoch) {
epoch = lastAcceptedEpoch+1;
}
My doubt is :
why use "lastAcceptedEpoch > epoch" but not "lastAcceptedEpoch >= epoch"
here?
In my undestanding the lastAcceptedEpoch is the max epoch of a follower
may have accepted so when the lead have receive a accepted epoch from the
follower it should always make it's own epoch larger than this one
Thanks .