tidis
tidis copied to clipboard
What is the use of this checkLeader?
https://github.com/yongman/tidis/blob/8da5613fe14cd93d4d16ccd8d522747c943c969c/tidis/leader.go#L32 I am confuse in this code.why does tidis need to checkLeader? if checkLeader fail ,it also does not do something. Isn't Tidis stateless?
Tidis is stateless indeed, but tidis need do something like requesting TIKV do GC which only execute in one instance.
thanks, I understand.BTW in this document GC Overview,i found Starting with TiDB 5.0, the Do GC step will always use the DISTRIBUTED gc mode. This replaces the earlier CENTRAL gc mode, which was implemented by TiDB servers sending GC requests to each Region.
will Tidis change gc mode to DISTRIBUTED gc mode?
Please refer to https://github.com/tidb-incubator/tidis