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

Method Zones

ring/ring.go:1526–1531  ·  view source on GitHub ↗

Zones returns the list of zones for which there's at least 1 instance registered in the ring. The returned slice is sorted alphabetically.

()

Source from the content-addressed store, hash-verified

1524// Zones returns the list of zones for which there's at least 1 instance registered in the ring.
1525// The returned slice is sorted alphabetically.
1526func (r *Ring) Zones() []string {
1527 r.mtx.RLock()
1528 defer r.mtx.RUnlock()
1529
1530 return slices.Clone(r.ringZones)
1531}
1532
1533// readOnlyInstanceCount returns the number of read only instances in the ring.
1534func (r *Ring) readOnlyInstanceCount() int {

Callers

nothing calls this directly

Calls 1

CloneMethod · 0.65

Tested by

no test coverage detected