disable anti-entropy if not using replication (there will never be anything to sync)

This commit is contained in:
Matt Jaffee 2019-01-07 16:52:43 -06:00
parent 8c4b1548bc
commit af26473f77
No known key found for this signature in database
GPG key ID: 08A3DFFF987B11BF

View file

@ -428,7 +428,7 @@ func (s *Server) SyncData() error {
}
func (s *Server) monitorAntiEntropy() {
if s.antiEntropyInterval == 0 {
if s.antiEntropyInterval == 0 || s.cluster.ReplicaN <= 1 {
return // anti entropy disabled
}
s.cluster.initializeAntiEntropy()