Skip to content

Commit 560b635

Browse files
craig[bot]shailendra-patel
andcommitted
Merge #155589
155589: roachprod: add chaos CLI for failure injection r=DarrylWong a=shailendra-patel This commit introduces the `roachprod chaos` command tree, providing CLI support for the failure injection library to test cluster resilience under various failure scenarios. Changes: - Add `chaos` root command with global flags for controlling failure duration and cleanup behavior - Implement network failure commands: - `chaos network-partition`: bidirectional and asymmetric network splits - `chaos network-latency`: artificial network delay injection Example usage: ```shell roachprod chaos network-partition $CLUSTER --src 1 --dest 2,3 --type asymmetric ``` Epic: none Release note: None Fixes: #140634 Co-authored-by: Shailendra Patel <[email protected]>
2 parents 4600cd3 + 3e13101 commit 560b635

File tree

5 files changed

+670
-0
lines changed

5 files changed

+670
-0
lines changed

pkg/cmd/roachprod/cli/BUILD.bazel

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ go_library(
44
name = "cli",
55
srcs = [
66
"bash_completion.go",
7+
"chaos.go",
8+
"chaos_network.go",
79
"commands.go",
810
"flags.go",
911
"handlers.go",
@@ -22,7 +24,9 @@ go_library(
2224
"//pkg/roachprod/cloud",
2325
"//pkg/roachprod/config",
2426
"//pkg/roachprod/errors",
27+
"//pkg/roachprod/failureinjection/failures",
2528
"//pkg/roachprod/install",
29+
"//pkg/roachprod/logger",
2630
"//pkg/roachprod/roachprodutil",
2731
"//pkg/roachprod/ssh",
2832
"//pkg/roachprod/ui",

0 commit comments

Comments
 (0)