Skip to content
Prometheus Exporter for Litmus Chaos Metrics
Go Makefile Shell Dockerfile
Branch: master
Clone or download
chandankumar4 (license): Update license field in the required files (#37)
Signed-off-by: chandan kumar <chandan.kr404@gmail.com>
Latest commit 3d5ae66 Nov 21, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
buildscripts add ci for chaos exporter May 30, 2019
cmd/exporter (license): Update license field in the required files (#37) Nov 21, 2019
controller (license): Update license field in the required files (#37) Nov 21, 2019
deploy (feat)exporter: introduce the litmus chaos exporter May 20, 2019
pkg/version (license): Update license field in the required files (#37) Nov 21, 2019
prometheus (feat)exporter: introduce the litmus chaos exporter May 20, 2019
tests/bdd (license): Update license field in the required files (#37) Nov 21, 2019
vendor
.gitignore
.travis.yml adding build script to travis (#35) Nov 7, 2019
Dockerfile add ci for chaos exporter May 30, 2019
Gopkg.lock Add test cases for OpenebsVersion func (#32) Oct 14, 2019
Gopkg.toml Update the vendor library (#29) Oct 11, 2019
LICENSE
Makefile (refactor)BCH: Refactor the exporter logic a/c BCH (#22) Oct 6, 2019
README.md Add travis ci build status (#27) Oct 11, 2019
contributing.md Issues Solved: Sep 3, 2019

README.md

Litmus Chaos Exporter

BUILD STATUS BCH compliance

  • This is a custom prometheus exporter to expose Litmus Chaos metrics. To learn more about Litmus Chaos Experiments & the Litmus Chaos Operator, visit this link: Litmus Docs

  • The exporter is tied to a Chaosengine custom resource, which, in-turn is associated with a given application deployment.

  • The exporter is typically deployed as a to to the Litmus Experiment Runner container in the engine-runner pod, but can be launched as a separate deployment as well.

  • Two types of metrics are exposed:

    • Fixed: TotalExperimentCount, TotalPassedTests, TotalFailedTests which are derived from the ChaosEngine specification upfront

    • Dymanic: Individual Experiment Run Status. The list of experiments may vary across ChaosEngines (or newer tests may be patched into it. The exporter reports experiment status as per list in the chaosengine

  • The metrics are of type Gauge, w/ each of the status metrics mapped to a numeric value(not-executed:0, running:1, fail:2, pass:3)

  • The metrics carry the application_uuid as label (this has to be passed as ENV)

Steps to build & deploy:

Local Machine

On Kubernetes Cluster

  • Install the RBAC (serviceaccount, role, rolebinding) as per deploy/rbac.md

  • Deploy the chaos-exporter.yaml

  • From a cluster node, execute curl <exporter-service-ip>:8080/metrics

Example Metrics

c_engine_experiment_count{app_uid="3f2092f8-6400-11e9-905f-42010a800131"} 2
# HELP c_engine_failed_experiments Total number of failed experiments
# TYPE c_engine_failed_experiments gauge
c_engine_failed_experiments{app_uid="3f2092f8-6400-11e9-905f-42010a800131"} 1
# HELP c_engine_passed_experiments Total number of passed experiments
# TYPE c_engine_passed_experiments gauge
c_engine_passed_experiments{app_uid="3f2092f8-6400-11e9-905f-42010a800131"} 1
# HELP c_exp_engine_nginx_container_kill 
# TYPE c_exp_engine_nginx_container_kill gauge
c_exp_engine_nginx_container_kill{app_uid="3f2092f8-6400-11e9-905f-42010a800131"} 2
# HELP c_exp_engine_nginx_pod_failure 
# TYPE c_exp_engine_nginx_pod_failure gauge
c_exp_engine_nginx_pod_failure{app_uid="3f2092f8-6400-11e9-905f-42010a800131"} 3
You can’t perform that action at this time.