Coder Social home page Coder Social logo

usernamesalah / backend-microservices Goto Github PK

View Code? Open in Web Editor NEW

This project forked from agungdwiprasetyo/backend-microservices

0.0 0.0 0.0 869 KB

Monorepo for backend microservices golang

Home Page: https://api.agungdp.dev/{{service_name}}}}

Shell 0.70% Go 78.85% Makefile 11.44% Dockerfile 9.00%

backend-microservices's Introduction

Backend Microservices

Made with

golang logo docker logo rest logo graphql logo grpc logo kafka logo

This repository explain implementation of Go for building multiple microservices using a single codebase. Using Standard Golang Project Layout and Clean Architecture

Create new service (for new project)

Please install latest candi CLI first, and then:

$ candi -init

If include GRPC handler, run this command (must install protoc compiler min version libprotoc 3.14.0):

$ make proto service={{service_name}}

If using SQL database, run this command for migration:

$ make migration service={{service_name}} dbconn="{{YOUR DATABASE URL CONNECTION}}"

Run all services

$ candi -run

Run specific service or multiple services

$ candi -run -service {{service_a}},{{service_b}}

Add module(s) in specific service (project)

$ candi -add-module -service {{service_name}}

Run unit test and calculate code coverage

  • Generate mocks first (using mockery):
$ make mocks service={{service_name}}
  • Run test:
$ make test service={{service_name}}

Run sonar scanner

$ make sonar level={{level}} service={{service_name}}

{{level}} is service environment, example: dev, staging, or prod

Create docker image a service

$ make docker service={{service_name}}

Services

backend-microservices's People

Contributors

agungdwiprasetyo 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.