Zones returns the list of zones for which there's at least 1 instance registered in the ring. The returned slice is sorted alphabetically.
()
| 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. |
| 1526 | func (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. |
| 1534 | func (r *Ring) readOnlyInstanceCount() int { |