mirror of
https://github.com/gogrlx/nats-server.git
synced 2026-04-02 03:38:42 -07:00
Merge branch 'main' into dev
This commit is contained in:
@@ -8,8 +8,7 @@ language: go
|
||||
go:
|
||||
# This should be quoted or use .x, but should not be unquoted.
|
||||
# Remember that a YAML bare float drops trailing zeroes.
|
||||
- '1.19.9'
|
||||
|
||||
- '1.19.10'
|
||||
addons:
|
||||
apt:
|
||||
packages:
|
||||
|
||||
@@ -1474,12 +1474,6 @@ func (n *raft) Peers() []*Peer {
|
||||
// Update our known set of peers.
|
||||
func (n *raft) UpdateKnownPeers(knownPeers []string) {
|
||||
n.Lock()
|
||||
// If this is a scale up, let the normal add peer logic take precedence.
|
||||
// Otherwise if the new peers are slow to start we stall ourselves.
|
||||
if len(knownPeers) > len(n.peers) {
|
||||
n.Unlock()
|
||||
return
|
||||
}
|
||||
// Process like peer state update.
|
||||
ps := &peerState{knownPeers, len(knownPeers), n.extSt}
|
||||
n.processPeerState(ps)
|
||||
|
||||
Reference in New Issue
Block a user