refactors directory and file structure

Signed-off-by: neelanjan00 <neelanjan.manna@harness.io>
This commit is contained in:
neelanjan00
2023-06-05 13:15:56 +05:30
parent 9bf371a651
commit ae8467237a
840 changed files with 6787 additions and 43442 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.0 KiB

View File

@@ -0,0 +1,26 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-app-kill-sa
experiments:
- name: spring-boot-app-kill
spec:
components:
env:
# port of the spring boot application
- name: CM_PORT
value: ''
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,85 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill
kind: ChaosExperiment
metadata:
name: spring-boot-app-kill
labels:
name: spring-boot-app-kill
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-app-kill
command:
- /bin/bash
env:
# port of the spring boot application
- name: CM_PORT
value: ''
#it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-app-kill
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-app-kill
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-app-kill
categoryDescription: |
This experiment allows injecting Chaos Monkey app-kill assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject app-kill. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,35 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-cpu-stress-sa
experiments:
- name: spring-boot-cpu-stress
spec:
components:
env:
# set chaos duration (in sec) as desired
- name: TOTAL_CHAOS_DURATION
value: '30'
# it contains fraction of used cpu. 0.95 equals 95%.
# it supports value in range [0.1,1.0]
- name: CPU_LOAD_FRACTION
value: '0.9'
# port of the spring boot application
- name: CM_PORT
value: ''
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,93 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress
kind: ChaosExperiment
metadata:
name: spring-boot-cpu-stress
labels:
name: spring-boot-cpu-stress
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-cpu-stress
command:
- /bin/bash
env:
# it contains fraction of cpu to be stressed(0.95 equals 95%)
# it supports value in range [0.1,1.0]
- name: CPU_LOAD_FRACTION
value: '0.9'
# port of the spring boot application
- name: CM_PORT
value: ''
#it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
- name: TOTAL_CHAOS_DURATION
value: '30'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-cpu-stress
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-cpu-stress
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-cpu-stress
categoryDescription: |
This experiment allows injecting Chaos Monkey cpu stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject CPU stress. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,38 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-exceptions-sa
experiments:
- name: spring-boot-exceptions
spec:
components:
env:
# set chaos duration (in sec) as desired
- name: TOTAL_CHAOS_DURATION
value: '30'
# Type of raised exception
- name: CM_EXCEPTIONS_TYPE
value: 'java.lang.IllegalArgumentException'
# Argument of raised exception
- name: CM_EXCEPTIONS_ARGUMENTS
value: 'java.lang.String:custom illegal argument exception'
# port of the spring boot application
- name: CM_PORT
value: ''
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,96 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency
kind: ChaosExperiment
metadata:
name: spring-boot-exceptions
labels:
name: spring-boot-exceptions
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-exceptions
command:
- /bin/bash
env:
# Type of raised exception
- name: CM_EXCEPTIONS_TYPE
value: 'java.lang.IllegalArgumentException'
# Argument of raised exception
- name: CM_EXCEPTIONS_ARGUMENTS
value: 'java.lang.String:custom illegal argument exception'
# port of the spring boot application
- name: CM_PORT
value: ''
#it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
- name: TOTAL_CHAOS_DURATION
value: '30'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-exceptions
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-exceptions
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-exceptions
categoryDescription: |
This experiment allows injecting Chaos Monkey exceptions assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject exception. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,77 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-faults-sa
experiments:
- name: spring-boot-faults
spec:
components:
env:
# set chaos duration (in sec) as desired
- name: TOTAL_CHAOS_DURATION
value: '30'
# port of the spring boot application
- name: CM_PORT
value: ''
# it enables spring app-kill fault
- name: CM_KILL_APPLICATION_ACTIVE
value: ''
# it enables spring-boot latency fault
- name: CM_LATENCY_ACTIVE
value: ''
# provide the latency (ms)
# it is applicable when latency is active
- name: LATENCY
value: '2000'
# it enables spring-boot memory stress fault
- name: CM_MEMORY_ACTIVE
value: ''
# it contains fraction of memory to be stressed(0.70 equals 70%)
# it supports value in range [0.01,0.95]
# it is applicable when memory is active
- name: MEMORY_FILL_FRACTION
value: '0.70'
# it enables spring-boot cpu stress fault
- name: CM_CPU_ACTIVE
value: ''
# it contains fraction of cpu to be stressed(0.95 equals 95%)
# it supports value in range [0.1,1.0]
# it is applicable when cpu is active
- name: CPU_LOAD_FRACTION
value: '0.9'
# it enables spring-boot exceptions fault
- name: CM_EXCEPTIONS_ACTIVE
value: ''
# Type of raised exception
# it is applicable when exceptions is active
- name: CM_EXCEPTIONS_TYPE
value: 'java.lang.IllegalArgumentException'
# Argument of raised exception
# it is applicable when exceptions is active
- name: CM_EXCEPTIONS_ARGUMENTS
value: 'java.lang.String:custom illegal argument exception'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,135 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject cpu-stress
kind: ChaosExperiment
metadata:
name: spring-boot-faults
labels:
name: spring-boot-faults
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-faults
command:
- /bin/bash
env:
# it enables spring app-kill fault
- name: CM_KILL_APPLICATION_ACTIVE
value: ''
# it enables spring-boot latency fault
- name: CM_LATENCY_ACTIVE
value: ''
# provide the latency (ms)
# it is applicable when latency is active
- name: LATENCY
value: '2000'
# it enables spring-boot memory stress fault
- name: CM_MEMORY_ACTIVE
value: ''
# it contains fraction of memory to be stressed(0.70 equals 70%)
# it supports value in range [0.01,0.95]
# it is applicable when memory is active
- name: MEMORY_FILL_FRACTION
value: '0.70'
# it enables spring-boot cpu stress fault
- name: CM_CPU_ACTIVE
value: ''
# it contains fraction of cpu to be stressed(0.95 equals 95%)
# it supports value in range [0.1,1.0]
# it is applicable when cpu is active
- name: CPU_LOAD_FRACTION
value: '0.9'
# it enables spring-boot exceptions fault
- name: CM_EXCEPTIONS_ACTIVE
value: ''
# Type of raised exception
# it is applicable when exceptions is active
- name: CM_EXCEPTIONS_TYPE
value: 'java.lang.IllegalArgumentException'
# Argument of raised exception
# it is applicable when exceptions is active
- name: CM_EXCEPTIONS_ARGUMENTS
value: 'java.lang.String:custom illegal argument exception'
# port of the spring boot application
- name: CM_PORT
value: ''
#it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
- name: TOTAL_CHAOS_DURATION
value: '30'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-faults
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-faults
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-faults
categoryDescription: |
This experiment allows injecting Chaos Monkey assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject Spring Boot faults. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,34 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-latency-sa
experiments:
- name: spring-boot-latency
spec:
components:
env:
# set chaos duration (in sec) as desired
- name: TOTAL_CHAOS_DURATION
value: '30'
# provide the latency (ms)
- name: LATENCY
value: '2000'
# port of the spring boot application
- name: CM_PORT
value: ''
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,92 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject network latency
kind: ChaosExperiment
metadata:
name: spring-boot-latency
labels:
name: spring-boot-latency
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-latency
command:
- /bin/bash
env:
# provide the latency (ms)
- name: LATENCY
value: '2000'
# port of the spring boot application
- name: CM_PORT
value: ''
# it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
- name: TOTAL_CHAOS_DURATION
value: '30'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-latency
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-latency
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-latency
categoryDescription: |
This experiment allows injecting Chaos Monkey network latency assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject latency. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,35 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChaosEngine
metadata:
name: spring-boot-chaos
namespace: default
spec:
appinfo:
appns: ''
applabel: ''
appkind: ''
# It can be active/stop
engineState: 'active'
chaosServiceAccount: spring-boot-memory-stress-sa
experiments:
- name: spring-boot-memory-stress
spec:
components:
env:
# set chaos duration (in sec) as desired
- name: TOTAL_CHAOS_DURATION
value: '30'
# it contains fraction of used cpu. 0.70 equals 70%.
# it supports value in range [0.01,0.95]
- name: MEMORY_FILL_FRACTION
value: '0.70'
# port of the spring boot application
- name: CM_PORT
value: ''
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''

View File

@@ -0,0 +1,93 @@
---
apiVersion: litmuschaos.io/v1alpha1
description:
message: |
It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress
kind: ChaosExperiment
metadata:
name: spring-boot-memory-stress
labels:
name: spring-boot-memory-stress
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: chaosexperiment
app.kubernetes.io/version: ci
spec:
definition:
scope: Namespaced
permissions:
# Create and monitor the experiment & helper pods
- apiGroups: [""]
resources: ["pods"]
verbs: ["create", "delete", "get", "list", "patch", "update", "deletecollection"]
# Performs CRUD operations on the events inside chaosengine and chaosresult
- apiGroups: [""]
resources: ["events"]
verbs: ["create", "get", "list", "patch", "update"]
# Track and get the runner, experiment, and helper pods log
- apiGroups: [""]
resources: ["pods/log"]
verbs: ["get", "list", "watch"]
# for creating and managing to execute commands inside target container
- apiGroups: [""]
resources: ["pods/exec"]
verbs: ["get", "list", "create"]
# for configuring and monitor the experiment job by the chaos-runner pod
- apiGroups: ["batch"]
resources: ["jobs"]
verbs: ["create", "list", "get", "delete", "deletecollection"]
# for creation, status polling and deletion of litmus chaos resources used within a chaos workflow
- apiGroups: ["litmuschaos.io"]
resources: ["chaosengines", "chaosexperiments", "chaosresults"]
verbs: ["create", "list", "get", "patch", "update", "delete"]
image: "chaosnative/go-runner:ci"
imagePullPolicy: Always
args:
- -c
- ./experiments -name spring-boot-memory-stress
command:
- /bin/bash
env:
# it contains fraction of memory to be stressed(0.70 equals 70%)
# it supports value in range [0.01,0.95]
- name: MEMORY_FILL_FRACTION
value: '0.70'
# port of the spring boot application
- name: CM_PORT
value: ''
# it contains number of requests are to be attacked
# n value means nth request will be affected
- name: CM_LEVEL
value: '1'
# it limits watched packages/classes/methods
- name: CM_WATCHED_CUSTOM_SERVICES
value: ''
# provide name of watcher
# it supports controller, restController, service, repository, component, webClient
- name: CM_WATCHERS
value: 'restController'
- name: TOTAL_CHAOS_DURATION
value: '30'
## percentage of total pods to target
- name: PODS_AFFECTED_PERC
value: ''
## Period to wait before and after injection of chaos
- name: RAMP_TIME
value: ''
## it defines the sequence of chaos execution for multiple target pods
## supported values: serial, parallel
- name: SEQUENCE
value: 'parallel'
labels:
name: spring-boot-memory-stress
app.kubernetes.io/part-of: litmus
app.kubernetes.io/component: experiment-job
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,27 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot-memory-stress
version: 0.1.0
annotations:
categories: Spring Boot
vendor: Harness
spec:
displayName: spring-boot-memory-stress
categoryDescription: |
This experiment allows injecting Chaos Monkey memory-stress assaults on Spring Boot applications, which have the [Chaos Monkey for Spring Boot](https://codecentric.github.io/chaos-monkey-spring-boot/) in their classpath.
It can target random pods with a Spring Boot application and allows configuring the assaults to inject memory-stress. It tests the resiliency of the system when some applications are having unexpected faulty behavior.
keywords:
- Spring Boot
platforms:
- GKE
- Konvoy
- Packet(Kubeadm)
- Minikube
- EKS
maturity: alpha
minKubeVersion: 1.12.0
labels:
app.kubernetes.io/component: chartserviceversion
app.kubernetes.io/version: ci

View File

@@ -0,0 +1,44 @@
---
apiVersion: litmuschaos.io/v1alpha1
kind: ChartServiceVersion
metadata:
name: spring-boot
version: 0.1.0
annotations:
categories: Spring Boot
chartDescription: Injects spring boot chaos
spec:
displayName: Spring Boot
categoryDescription: >
It contains chaos to disrupt state of spring-boot application.
faults:
- name: spring-boot-app-kill
description: It injects app-kill chaos in a spring-boot application.
displayName: "Spring Boot App Kill"
- name: spring-boot-cpu-stress
description: It injects cpu-stress chaos in a spring-boot application.
displayName: "Spring Boot CPU Stress"
- name: spring-boot-memory-stress
description: It injects memory-stress chaos in a spring-boot application.
displayName: "Spring Boot Memory Stress"
- name: spring-boot-latency
description: It injects network-latency chaos in a spring-boot application.
displayName: "Spring Boot Latency"
- name: spring-boot-exceptions
description: It injects exceptions chaos in a spring-boot application.
displayName: "Spring Boot Exceptions"
- name: spring-boot-faults
description: It injects faults in a spring-boot application.
displayName: "Spring Boot Faults"
keywords:
- Kubernetes
- Spring Boot
- K8S
- Pod
minKubeVersion: 1.12.0
links:
- name: Documentation
url: https://spring.io/projects/spring-boot
icon:
- url: https://raw.githubusercontent.com/litmuschaos/chaos-charts/master/charts/spring-boot/icons/spring-boot.png
mediatype: image/png

View File

@@ -0,0 +1,21 @@
---
packageName: spring-boot
experiments:
- name: spring-boot-app-kill
CSV: spring-boot-app-kill.chartserviceversion.yaml
desc: "spring-boot-app-kill"
- name: spring-boot-cpu-stress
CSV: spring-boot-cpu-stress.chartserviceversion.yaml
desc: "spring-boot-cpu-stress"
- name: spring-boot-memory-stress
CSV: spring-boot-memory-stress.chartserviceversion.yaml
desc: "spring-boot-memory-stress"
- name: spring-boot-latency
CSV: spring-boot-latency.chartserviceversion.yaml
desc: "spring-boot-latency"
- name: spring-boot-exceptions
CSV: spring-boot-exceptions.chartserviceversion.yaml
desc: "spring-boot-exceptions"
- name: spring-boot-faults
CSV: spring-boot-faults.chartserviceversion.yaml
desc: "spring-boot-faults"