Giter VIP home page Giter VIP logo

goworkshop's Introduction

diagram

"TODO List" experiment project

This repository is an example project which demonstrates the use of microservices for a fictional TODO list application. The TODO backend is powered by 3 microservices, all of which happen to be written in Go, using MongoDB for manage the database and Docker to isolate and deploy the ecosystem.

In real world each service should live in a separate repository, so teams can work separately and don't overlap each other, however in this demo project they just located in separate folders for easy use.

Services organization

The application consists of the following application services:

Service Port Description Methods
users 50000 Provides users information CreateUser
list 50001 Manages items in todo lists CreateItem, GetUserItems, DeleteItem
notifier 50002 Send email notifications Email

Client web application is working on http://localhost:3030.

diagram2

Requirements

Run

docker-compose pull
docker-compose up

Go to http://localhost:3030 to test gRPC from webapp.

Generate source code for the gRPC client from .proto files

  • Install Go
  • Install Protocol Buffers
  • Install protoc plugin: go get github.com/golang/protobuf/proto github.com/golang/protobuf/protoc-gen-go
protoc --go_out=plugins=grpc:. proto/users/service.proto
protoc --go_out=plugins=grpc:. proto/list/service.proto
protoc --go_out=plugins=grpc:. proto/notifier/service.proto

goworkshop's People

Contributors

plutov avatar mbonell avatar

Watchers

Tin Trinh 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.