Chaos engineering

Number of APIs: 7

This template demonstrates the workflow described in Building resilient APIs with chaos engineering.

Included in this template: * Simulate an API outage of critical internal APIs or external third-party APIs using a Qodex mock to test your fallbacks by returning a failing server response. * Shut down a container on an AWS EKS cluster (and optionally roll back the attack) using Gremlin. * Limit a container's resources by creating a CPU attack using Gremlin.

[collection runner](https://i.imgur.com/UPPy3bQ.png)

Get Started

For the infrastructure attack on EKS, you will need a target. To work with a sample app, deploy Hipster Shop: Cloud-Native Microservices Demo Application on a Kubernetes cluster, and install Gremlin on your Kubernetes dashboard.

Then update the corresponding Qodex environment called chaosEngineering with your own credentials and app information.

Environment KeyDescription
gremlin_api_keyUse a team-level Gremlin API key
your_deployed_app_URLThis is the URL of your deployed app
  1. CPU attack - Create CPU attack POST {{gremlin_api}}/attacks/new

  2. Simulate an API outage - Unsuccessful API response GET {{mock_url}}/outage

  3. Shut down a container - Get active containers GET {{gremlin_api}}/containers

  4. Shut down a container - Create shutdown attack POST {{gremlin_api}}/attacks/new

  5. Shut down a container - Verify app health GET {{your_deployed_app_URL}}

  6. Shut down a container - Stop the attack DELETE {{gremlin_api}}/attacks/{{guid}}

  7. CPU attack - Get active containers GET {{gremlin_api}}/containers