This is a sample application demonstrating the use of a few different libraries and tools for resilience and chaos engineering.
The features are introduced gradually using the following branches:
- 01_SimpleService
- 02_WireMock
- 03_ChaosToolkit
- 04_Resilience4j_Faults
- 05_Resilience4j_Faults_And_Delays
- 06_ChaosMonkey
Each branch contains a Spring Boot application with progressively more fleshed out app code and configuration to handle faults and simulate faults for testing.
If you have questions reach out to me here or connect on LinkedIn.
The following tools and libraries are used. Installation and getting started with this tools is not covered in detail here, so please see the links below for more information on the respective projects:
- WireMock
- ChaosToolkit
- ChaosToolkit WireMock driver
- Resilience4J / Resilience4J Spring Boot 2
- Chaos Monkey For Spring Boot (inspired by Chaos Monkey)
The app consists of 1 REST controller that returns a stock price. To retrieve stock prices two different free services are used.
- AlphaVantage: https://www.alphavantage.co/
- WorldTradingData: https://www.worldtradingdata.com/
To execute the samples you will need to register for a free account on both sites and pass the following environment variables to the app:
- ALPHAVANTAGE_API_KEY
- WORLDTRADINGDATA_API_KEY
Continue to 01_SimpleService