MCPcopy
hub / github.com/redis/go-redis / Random

Method Random

ring.go:488–490  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

486}
487
488func (c *ringSharding) Random() (*ringShard, error) {
489 return c.GetByKey(strconv.Itoa(rand.Int()))
490}
491
492// Heartbeat monitors state of each shard in the ring.
493func (c *ringSharding) Heartbeat(ctx context.Context, frequency time.Duration) {

Callers 2

GetByNameMethod · 0.95
cmdShardMethod · 0.45

Calls 2

GetByKeyMethod · 0.95
IntMethod · 0.45

Tested by

no test coverage detected