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

Method SetGeneration

osscluster.go:575–582  ·  view source on GitHub ↗
(gen uint32)

Source from the content-addressed store, hash-verified

573}
574
575func (n *clusterNode) SetGeneration(gen uint32) {
576 for {
577 v := atomic.LoadUint32(&n.generation)
578 if gen < v || atomic.CompareAndSwapUint32(&n.generation, v, gen) {
579 break
580 }
581 }
582}
583
584func (n *clusterNode) SetLastLatencyMeasurement(t time.Time) {
585 for {

Callers 1

newClusterStateFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected