Giter VIP home page Giter VIP logo

temporal-polyglot-snake's Introduction

Temporal Polyglot Example - Snake Game

Temporal Snake Game

This demo uses the following Temporal SDKs:

This demo shows how Temporal can be used to orchestrate multiple polyglot services responsible for different parts of a snake game.

Running the demo

Start the Temporal Server:

git clone https://github.com/temporalio/docker-compose.git
cd  docker-compose
docker compose up

Start the Game Services

Game Controller Service

The Game Controller Service is a Java App that uses the Temporal Java SDK

cd game-controller
mvn compile exec:java -Dexec.mainClass="io.temporal.snakegame.controller.ControllerStarter"
Game Info Service

The Game Info Service is a Go App that uses the Temporal Go SDK

cd game-info
go run worker/main.go
Game Movement Rules Service

The Game Movement Rules Services is a PHP App that uses the Temporal PHP SDK

cd game-rules
./rr serve

Start the Game

Snake Game

The Snake game is a Java app which uses the three started services for overall game control, game info such as images, text, fonts background, etc as well as movement controls.

cd game
mvn compile exec:java -Dexec.mainClass="io.temporal.snakegame.SnakeGameStarter"

Playing The Demo

Once the game starts you can use your keyboard LEFT RIGHT UP DOWN keys to move the snake across the board. The goal is to eat the apples. Once you eat an apple your snake will increase and another apple icon will get displayed on the board. If you run into any of the edges of the board, or into your snake itself the game is over.

temporal-polyglot-snake's People

Contributors

tsurdilo avatar

Stargazers

 avatar Eric Sessions avatar  avatar Michael Nelson avatar  avatar  avatar Flynn Wang avatar Leslie A avatar Tsyupryk Roman avatar Michal Srb avatar Joe Bowbeer avatar Daniel Pous Montardit avatar

Watchers

Joe Bowbeer avatar  avatar James Cloos 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.