{"id":28420899,"url":"https://github.com/steventobin/kas-fault-tests","last_synced_at":"2026-02-19T13:03:02.100Z","repository":{"id":92051799,"uuid":"378855958","full_name":"StevenTobin/kas-fault-tests","owner":"StevenTobin","description":"Central location for all fault and chaos test resources used to test managed Kafka.","archived":false,"fork":false,"pushed_at":"2021-06-17T10:30:47.000Z","size":23,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":0,"default_branch":"main","last_synced_at":"2025-10-19T19:56:50.345Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":false,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/StevenTobin.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2021-06-21T08:13:15.000Z","updated_at":"2021-09-14T07:31:30.000Z","dependencies_parsed_at":"2023-05-04T15:33:09.353Z","dependency_job_id":null,"html_url":"https://github.com/StevenTobin/kas-fault-tests","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/StevenTobin/kas-fault-tests","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StevenTobin%2Fkas-fault-tests","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StevenTobin%2Fkas-fault-tests/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StevenTobin%2Fkas-fault-tests/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StevenTobin%2Fkas-fault-tests/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/StevenTobin","download_url":"https://codeload.github.com/StevenTobin/kas-fault-tests/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/StevenTobin%2Fkas-fault-tests/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29614592,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-19T10:52:55.328Z","status":"ssl_error","status_checked_at":"2026-02-19T10:52:26.323Z","response_time":117,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-06-05T03:50:23.598Z","updated_at":"2026-02-19T13:03:02.093Z","avatar_url":"https://github.com/StevenTobin.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# Litmus Fault Injection Testing\n\nThis directory contains the resources required to get up and running for fault injection testing using Litmus. \n\n\n## Resources\n\n### Litmus operator\n\nAll required resources to deploy the Litmus operator are included in the `./litmus` directory.\n\n### ChaosExperiments\n\nChaosExperiment CRDs for all generic Litmus experiments and some kafka-specific ones are in the `./chaosexperiments` directory.\n\n### ChaosEngines\n\nPrebuilt ChaosEngine CRs and associated ServiceAccount resoures are located in the `./chaosengines` directory.\n\n### ChaosScheduler\n\nAll required resources to deploy the ChaosScheduler operator are included in the `./chaosscheduler` directory.\n\n### ChaosSchedules\n\nPrebuilt ChaosSchedule CRs are located in the `./chaosschedules` directory.\n\n### AlertScenarios\n\nAutomated scenarios to recreate the conditions for an alert to be triggered. It consists on a set of Python scripts from `./alertscenarios` with steps. The output from every scenario is SUCCESS when the alert is triggered or FAILED if not.\n\n## Setup\n\nThe Litmus operator and ChaosExperiment CRs for the experiments you wish to run are required. Optionally, if you wish to use Litmus to schedule experiments the ChaosScheduler operator will be required.\n\n### [Required] Litmus operator\n\n```sh\nmake create/operator/litmus\n```\n\n### [Required] ChaosExperiment definitions\n\n```sh\nmake create/chaosexperiments\n```\n\n### [Optional] Chaosscheduler operator\n\n```sh\nmake create/operator/chaosscheduler\n```\n\n\n## Running Experiments\n\nSingle-execution experiments can be run by deploying a `chaosengine` with the experiment configuration. For regular, scheduled experiments a `chaosschedule` containing the experiment can be deployed.\n\n### ChaosEngines\n\nA ChaosEngine will specify the experiment(s) to be executed. The ChaosEngine will require a ServiceAccount with the required permissions to run the experiment(s). \n\nSample ChaosEngines are located in subdirectories in the `./chaosengines` directory; to deploy these ChaosEngines:\n\n```sh\n#  engine to randomly delete kafka-broker pods\nmake create/chaosengines/pod-delete-brokers\n```\n\n### ChaosSchedules\n\nA ChaosSchedule will specify the experiment(s) to be executed and the schedule on which it will run. The ChaosEngine will require a ServiceAccount with the required permissions to run the experiment(s).\n\nSample ChaosSchedules be are located in subdirectories in the `./chaosschedules` directory. To deploy these ChaosSchedules:\n\n```sh\n#  schedule to randomly delete kafka-broker pods\nmake create/chaosschedules/pod-delete-brokers\n\n#  schedule to randomly delete zookeeper pods\nmake create/chaosschedules/pod-delete-zookeeper\n```\n\n\n## Evaluating Experiments\n\nTo evaluate the success or failure of chaos experiments you can check the `chaosresult` or whether alerts in prometheus have fired. \n\n### Chaosresult\n\nA `chaosresult` for each experiment will be created by Litmus. After an experiment completes the status block can be queried for success/ failure of the experiment:\n\n```sh\n# get all chaosresults\noc get chaosresult -n litmus\n\n# check status of chaosresult\noc get chaosresult \u003cchaosresult-name\u003e -o json | jq '.status.experimentstatus'\n```\n## Running Alert testing scenarios\n\n```sh\nmake test/alertscenarios/under_replicated_partition\n```\n\n## Prometheus alerts\n\n### Get critical alerts\nAn automated test and make target exist to monitor prometheus for any critical alerts that fire during chaos experiments:\n\n```sh\nmake test/critical-alerts\n```\n\n### Get all alerts\nAn automated script to get all the current Prometheus alerts\n\n```sh\nmake test/all-alerts\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsteventobin%2Fkas-fault-tests","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fsteventobin%2Fkas-fault-tests","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fsteventobin%2Fkas-fault-tests/lists"}