MCPcopy
hub / github.com/grafana/dskit / ZonesCount

Method ZonesCount

ring/lifecycler.go:525–530  ·  view source on GitHub ↗

ZonesCount returns the number of zones for which there's at least 1 instance registered in the ring.

()

Source from the content-addressed store, hash-verified

523// ZonesCount returns the number of zones for which there's at least 1 instance registered
524// in the ring.
525func (i *Lifecycler) ZonesCount() int {
526 i.countersLock.RLock()
527 defer i.countersLock.RUnlock()
528
529 return i.zonesCount
530}
531
532// Zones return the list of zones for which there's at least 1 instance registered
533// in the ring. They are guaranteed to be sorted alphabetically.

Callers 3

TestLifecycler_ZonesFunction · 0.95

Calls

no outgoing calls

Tested by 3

TestLifecycler_ZonesFunction · 0.76