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

Struct clusterStateHolder

osscluster.go:1062–1069  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

1060//------------------------------------------------------------------------------
1061
1062type clusterStateHolder struct {
1063 load func(ctx context.Context) (*clusterState, error)
1064
1065 reloadInterval time.Duration
1066 state atomic.Value
1067 reloading uint32 // atomic
1068 reloadPending uint32 // atomic - set to 1 when reload is requested during active reload
1069}
1070
1071func newClusterStateHolder(load func(ctx context.Context) (*clusterState, error), reloadInterval time.Duration) *clusterStateHolder {
1072 return &clusterStateHolder{

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected