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

Method Reset

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

Source from the content-addressed store, hash-verified

166}
167
168func (cluster *Cluster) Reset(ctx context.Context) error {
169 for i := 0; i < len(cluster.Shards); i++ {
170 for _, node := range cluster.Shards[i].Nodes {
171 if err := node.Reset(ctx); err != nil {
172 return err
173 }
174 }
175 }
176 return nil
177}
178
179func (cluster *Cluster) findShardIndexBySlot(slot SlotRange) (int, error) {
180 sourceShardIdx := -1

Callers 5

TestCluster_LoadAndProbeFunction · 0.95
TestCluster_MigrateSlotFunction · 0.95
TestClusterFailoverFunction · 0.95
TestClusterImportFunction · 0.95
TestClusterMigrateDataFunction · 0.95

Calls 1

ResetMethod · 0.65

Tested by 5

TestCluster_LoadAndProbeFunction · 0.76
TestCluster_MigrateSlotFunction · 0.76
TestClusterFailoverFunction · 0.76
TestClusterImportFunction · 0.76
TestClusterMigrateDataFunction · 0.76