Skip to content

Commit

Permalink
roachtest: turn on DistSender circuit breakers for failover chaos tests
Browse files Browse the repository at this point in the history
Failover chaos tests create assymetric partitions, where DistSender
circuit breakers are useful. It prevents failure modes such as
cockroachdb#123736 (comment).

Fixes cockroachdb#123736

Release note: None
  • Loading branch information
arulajmani committed May 8, 2024
1 parent 7756496 commit 099bc4a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion pkg/cmd/roachtest/tests/failover.go
Original file line number Diff line number Diff line change
Expand Up @@ -208,11 +208,14 @@ func runFailoverChaos(ctx context.Context, t test.Test, c cluster.Cluster, readO

rng, _ := randutil.NewTestRand()

// Create cluster, and set up failers for all failure modes.
// Create cluster, and set up failures for all failure modes.
settings := install.MakeClusterSettings()
settings.Env = append(settings.Env, "COCKROACH_ENABLE_UNSAFE_TEST_BUILTINS=true")
settings.Env = append(settings.Env, "COCKROACH_SCAN_MAX_IDLE_TIME=100ms") // speed up replication

// DistSender circuit breakers are useful for these chaos tests. Turn them on.
settings.ClusterSettings["kv.dist_sender.circuit_breakers.mode"] = "all ranges"

m := c.NewMonitor(ctx, c.Range(1, 9))

failers := []Failer{}
Expand Down

0 comments on commit 099bc4a

Please sign in to comment.