MCPcopy Create free account
hub / github.com/apache/kvrocks-controller / SyncToNodes

Method SyncToNodes

store/cluster.go:149–158  ·  view source on GitHub ↗
(ctx context.Context)

Source from the content-addressed store, hash-verified

147}
148
149func (cluster *Cluster) SyncToNodes(ctx context.Context) error {
150 for i := 0; i < len(cluster.Shards); i++ {
151 for _, node := range cluster.Shards[i].Nodes {
152 if err := node.SyncClusterInfo(ctx, cluster); err != nil {
153 return err
154 }
155 }
156 }
157 return nil
158}
159
160func (cluster *Cluster) GetNodes() []Node {
161 nodes := make([]Node, 0)

Callers 3

TestCluster_MigrateSlotFunction · 0.95
TestClusterFailoverFunction · 0.95
TestClusterMigrateDataFunction · 0.95

Calls 1

SyncClusterInfoMethod · 0.65

Tested by 3

TestCluster_MigrateSlotFunction · 0.76
TestClusterFailoverFunction · 0.76
TestClusterMigrateDataFunction · 0.76