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

Method Reset

store/cluster_node.go:257–262  ·  view source on GitHub ↗
(ctx context.Context)

Source from the content-addressed store, hash-verified

255}
256
257func (n *ClusterNode) Reset(ctx context.Context) error {
258 if n.IsMaster() {
259 _ = n.GetClient().FlushAll(ctx).Err()
260 }
261 return n.GetClient().ClusterResetHard(ctx).Err()
262}
263
264func (n *ClusterNode) MigrateSlot(ctx context.Context, slot SlotRange, targetNodeID string) error {
265 return n.GetClient().Do(ctx, "CLUSTERX", "MIGRATE", slot.String(), targetNodeID).Err()

Callers

nothing calls this directly

Calls 2

IsMasterMethod · 0.95
GetClientMethod · 0.95

Tested by

no test coverage detected