Coder Social home page Coder Social logo

dhaval201279 / cm4sb-card-service Goto Github PK

View Code? Open in Web Editor NEW
1.0 2.0 1.0 334 KB

Source code of my blog on how to perform Chaos Engineering

Java 100.00%
spring-boot chaos-engineering actuator-spring-boot micrometer consul prometheus grafana-prometheus

cm4sb-card-service's Introduction

Source code of my blog on how to perform Chaos Engineering using

  1. Chaos Monkey for Spring Boot
  2. Consul
  3. Prometheus
  4. Grafana

Card Service APIs

Comprises of business flow which allows consumer of this application to view card based on Id or fetch all the cards

Method Path Description
GET /card/{cardId} Gets Card based on card identifier
GET /cards Fetches all cards stored in database

How to enable monitoring of demo application

Start Consul

  1. Go to home of Consul e.g. "C:\consul.io"
  2. Run below command in powershell

    .\consul.exe agent -dev -node machine

  3. Check whether Consul is up and running by accessing URL (http://localhost:8500/ui/dc1/services
    ) in browser

Start Prometheus

  1. Go to home of Prometheus e.g. "C:\prometheus-2.2.1.windows-amd64"
  2. Run below command in powershell

    .\prometheus.exe --config.file=prometheus.yml

  3. Check whether Prometheus is up and running by accessing URL (http://localhost:9090/service-discovery) in browser

Start Grafana

  1. Go to home of Consul e.g. C:\grafana-5.1.3\bin
  2. Run below command in powershell

    .\grafana-server.exe agent -dev -node machine

  3. Check whether Grafana is up and running by accessing URL (http://localhost:7070) in browser

Running load tests using Apache Bench

  1. Go to Apache Bench's bin directory e.g. C:\Apache24\bin
  2. Run below command in powershell to invoke Fetch Cards API 250 times with 4 concurrent threads

    .\ab.exe -n 250 -c 4 http://localhost:8090/cards

cm4sb-card-service's People

Contributors

dhaval201279 avatar

Stargazers

 avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.