GithubHelp home page GithubHelp logo

angelnikolov / nestjs-microservice-architecture Goto Github PK

View Code? Open in Web Editor NEW

This project forked from wonderpanda/nestjs-microservice-architecture

0.0 1.0 0.0 207 KB

A reference architecture for building microservices with Nest

TypeScript 74.10% JavaScript 12.17% Dockerfile 12.46% Makefile 1.27%

nestjs-microservice-architecture's Introduction

Nest Logo

A progressive Node.js framework for building efficient and scalable server-side applications, heavily inspired by Angular.

NPM Version Package License NPM Downloads Travis Linux Coverage Gitter Backers on Open Collective Sponsors on Open Collective

Nestjs Microservice Architecture

Project Goals

This project aims to demonstrate a real world example application of a microservice architecture leveraging best of class Node and Typescript tooling.

Running the Project

Docker

Docker is awesome.

Just use docker-compose up -d at the root of the repository. Once the services are running you the API can be viewed at localhost:4200/graphql

If you'd prefer to only run the backend data services (currently Redis and RabbitMQ) so you can hack on the Nest services, just use the data only compose file. docker-compose -f docker-compose.data-only.yml up -d

Locally

Make sure that you've copied over the .env.example file for each service into .env so that the services can be configured properly.

Making changes to Services

If you've made a change to a service and want to redeploy it with docker compose without bringing down the other services, just use docker-compose up -d --no-deps --build <serviceName> where serviceName is one of the named services from the docker-compose.yml file.

GraphQL

GraphQL is a query language for your API, and a server-side runtime for executing queries by using a type system you define for your data. GraphQL isn't tied to any specific database or storage engine and is instead backed by your existing code and data.

This project uses GraphQL as the glue between microservices and is therefore agnostic to the datastores used be the individual services.

An example query that can be executed in the playground at http://localhost:4200/graphql is

{
  getCatalogItems {
    id
    name
    description
    price
  }
}

nestjs-microservice-architecture's People

Contributors

wonderpanda avatar

Watchers

 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.