raft: add RawNode.TickQuiesced
raft: add RawNode.TickQuiesced

TickQuiesced allows the caller to support "quiesced" Raft groups which
do not perform periodic heartbeats and elections. This is useful in a
system with thousands of Raft groups where these periodic operations can
be overwhelming in an otherwise idle system.

It might seem possible to avoid advancing the logical clock at all in
such Raft groups, but doing so has an interaction with the CheckQuorum
functionality. If a follower is not quiesced while the leader is the
follower can call an election that will fail because the leader's lease
has not expired (electionElapsed < electionTimeout). The next time the
leader sends a heartbeat to this follower the follower will see that the
heartbeat is from a previous term and respond with a MsgAppResp. This in
turn will cause the leader to step down and become a follower even
though there isn't a leader in the group. By allowing the leader's
logical clock to advance via TickQuiesced, the leader won't reject the
election and there will be a smooth transfer of leadership to the
follower.

handsomesun/etcd,li-ang/etcd,sebrandon1/etcd,CrazyJvm/etcd,ravigadde/etcd,bdarnell/etcd,etcd-io/etcd,sebrandon1/etcd,rnaveiras/etcd,lumjjb/etcd,nekto0n/etcd,coreos/etcd,coreos/etcd,jlamillan/etcd,mickep76/etcd,glevand/coreos--etcd,heyitsanthony/etcd,plasticbox/etcd,cockroachdb/etcd,endocode/etcd,fanminshi/etcd,insequent/etcd,qqsun8819/etcd,a-robinson/etcd,lumjjb/etcd,rchicoli/etcd,mickep76/etcd,gyuho/etcd,visheshnp/etcd,armstrongli/etcd,vimalk78/etcd,tguangch/etcd,jlamillan/etcd,luxas/etcd,handsomesun/etcd,whuwxl/etcd,luxas/etcd,joshix/etcd,ajityagaty/etcd,rnaveiras/etcd,qqsun8819/etcd,rchicoli/etcd,ajityagaty/etcd,visheshnp/etcd,OyTao/etcd_learning,dannysauer/etcd,plasticbox/etcd,akauppi/etcd,yudai/etcd,mqliang/etcd,bdarnell/etcd,akauppi/etcd,mkumatag/etcd,hongchaodeng/etcd,mkumatag/etcd,li-ang/etcd,xiang90/etcd,lorneli/etcd,mqliang/etcd,xiang90/etcd,cockroachdb/etcd,dannysauer/etcd,insequent/etcd,heyitsanthony/etcd,endocode/etcd,joshix/etcd,YuleiXiao/etcd,armstrongli/etcd,bluebreezecf/etcd,sinsharat/etcd,whuwxl/etcd,gyuho/etcd,glevand/coreos--etcd,lorneli/etcd,YuleiXiao/etcd,yudai/etcd,OyTao/etcd_learning,mkumatag/etcd,mqliang/etcd,nekto0n/etcd,etcd-io/etcd,CrazyJvm/etcd,ravigadde/etcd,zaphod-concur/etcd,vimalk78/etcd,bluebreezecf/etcd,a-robinson/etcd,zaphod-concur/etcd,hongchaodeng/etcd,sinsharat/etcd,rnaveiras/etcd,tguangch/etcd,ajityagaty/etcd,fanminshi/etcd,etcd-io/etcd