mirror of https://github.com/hashicorp/consul
serf: monkey patch https://github.com/hashicorp/serf/pull/486
parent
48ebc241bb
commit
2567a94a81
|
@ -1654,6 +1654,8 @@ func (s *Serf) Stats() map[string]string {
|
|||
toString := func(v uint64) string {
|
||||
return strconv.FormatUint(v, 10)
|
||||
}
|
||||
s.memberLock.RLock()
|
||||
defer s.memberLock.RUnlock()
|
||||
stats := map[string]string{
|
||||
"members": toString(uint64(len(s.members))),
|
||||
"failed": toString(uint64(len(s.failedMembers))),
|
||||
|
|
Loading…
Reference in New Issue