GithubHelp home page GithubHelp logo

grpcloggerservice's Introduction

gRPC Logger Server

You can use this gRPC server with Evans or implement a real client.

Tools & Libraries used

๐Ÿ—„ Project structure

/app

Folder with business logic only. This directory doesn't care about what database driver you're using.

  • /app/controller folder for functional controller (used in routes)
  • /app/dto Data Transfer Objects(DTO) folder for transform data before sent to API clients
  • /app/model folder for describe business models and methods of your project
  • /app/repository folder for perform database operations for models of your project

/pkg

Folder with project-specific functionality. This directory contains all the project-specific code tailored only for your business use case.

/platform

Folder with platform-level logic. This directory contains all the platform-level logic that will build up the actual project, like setting up the database, logger instance and storing migrations, seeds(demo data).

/logger_pb

Folder with proto file and auto-generated go files. This directory contains all the go auto-generated files and proto file.

โš™๏ธ Configuration

Server Settings:

SERVER_READ_TIMEOUT=60

Jwt settings:

JWT_SECRET_KEY_EXPIRE_MINUTES_COUNT=30 JWT_SECRET_KEY="secret"

Database settings:

MONGO_INITDB_ROOT_USERNAME=admin MONGO_INITDB_ROOT_PASSWORD=password DOCKER_SERVICE=mongo MONGO_PORT=27017

# .env file
# JWT settings:
JWT_SECRET_KEY="super_secret_here"
JWT_SECRET_KEY_EXPIRE_MINUTES_COUNT=120

# Database settings:
MONGO_INITDB_ROOT_USERNAME=admin
MONGO_INITDB_ROOT_PASSWORD=password
DOCKER_SERVICE=mongo
MONGO_PORT=27017

๐Ÿ”จ Docker development

  • Install docker, docker-compose
  • Rename .env.example to .env
  • Start a MongoDB container exposing port 27017

Todo

  • Add new functionalities
  • Implement this gRPC server with a client.

โš ๏ธ License

MIT

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.