Giter Site home page Giter Site logo

ia3andy / game-of-stacks Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 2.0 7.75 MB

We try to compare different way of running a Quarkus Java service (GraalVM, Hotspot) using the monitoring power of Kiali. This repository contains the code of a simulation game showing the attack of Winterfell by a group of scary microservices. We’ll try to keep trolls out of the battle. :-)

License: Apache License 2.0

Java 6.95% Dockerfile 7.54% JavaScript 15.98% HTML 11.40% Kotlin 45.24% Makefile 7.89% Shell 2.08% CSS 2.91%

game-of-stacks's Introduction

Game of Stacks

The Game of Stacks shows the power of different stacks and VMs in the Java world (Quarkus, Vert.x ; native versus hotspot/openj9) depending on the business logic, by deploying a set of microservices in several variants and comparing their behaviours.

White walkers are coming! Winterfell is under attack! We'll try to find the best combination of heroes and weapons to defeat them!

Game

Kiali will help us to figure out the interactions between microservices and to compare some metrics.

Graph Metrics

Running locally

Kafka

  • With docker-compose:
make start-kafka
  • From local installation (example)
cd ~/apps/kafka_2.12-2.3.0/
bin/zookeeper-server-start.sh config/zookeeper.properties
# Open new terminal
bin/kafka-server-start.sh config/server.properties 

GoS services

make clean install start-web
# then Open http://localhost:8081
make start

Running on Kubernetes or OpenShift

Assuming Kube or OS is up and running

# Deploy Strimzi/Kafka in namespace "kafka"
make deploy-kafka

# Build GoS
make clean build build-native

# Build docker images & deploy
## For docker:
make docker deploy

## For podman:
make podman deploy

# Expose (port-forward)
make expose
# Then open browser on http://localhost:8081

It starts with all deployments scaled to 0, except the web interface. To start the demo:

# Deploys 5 heroes (native), arrows (native), villains (oj9)
make arrow-scaling-hero-native-vs-hotspot--native

# Redeploys with 5 heroes (hotspot), arrows (native), villains (oj9)
make arrow-scaling-hero-native-vs-hotspot--hotspot

# Redeploys with 4 heroes (mix hotspot/native), arrows (native), villains (oj9)
make start-mixed

# With more villains
make more-villains start-mixed

# MUCH more villains
make much-more-villains start-mixed

TODO

Next steps:

  • Reintroduce catapult
  • Differentiate sprites with text (e.g. graal/hotspot)

Istio

make deploy-istio
make enable-istio
# in new term
make expose-kiali

To disable:

make disable-istio

Resources

game-of-stacks's People

Contributors

ia3andy avatar jotak avatar

Watchers

 avatar  avatar  avatar

Forkers

jotak chris93111

game-of-stacks's Issues

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.