Skip to content

Latest commit

 

History

History
46 lines (36 loc) · 3.52 KB

README.md

File metadata and controls

46 lines (36 loc) · 3.52 KB

Endframe

This is a framework for building go based applications. Current it supports HTTP REST apis using Chi.

Everything else is bound with interface. Database to handlers to services. Configurable from the outside. This also comes with docker, docker compose. The default docker file also keeps watch for files changes so it can handle the automatic code rebuild.

Checkout the reframe repository that has a working demo for a location based proximity app.

Running the project

Run the following commands to run the project.

  • git clone [email protected]:thearyanahmed/endframe.git
  • cd endframe
  • cp .env.example .env
  • Update proper values with .env. For this demo .env values have be filled in .env.example
  • make start will start the necessary containers.

Running tests

While running the container, run make test to run the tests. Or to run outside of container run go test -v ./...

┌──────────┐    ┌──────────┐    ┌───────────┐    ┌────────────────────────────────────────┐
│          │    │          │    │           │    │           Request Serializer           │
│  Server  ├────►  Router  ├────►  Handler  ├────►────────────────────┬───────────────────┼───┐
│          │    │          │    │           │    │       Serializer   │     Validator     │   │
└──────────┘    └──────────┘    └───────────┘    └────────────────────┴───────────────────┘   │
                                                                                              │
     ┌────────────────────────────────────────────────────────────────────────────────────────┘
     │
┌────▼────┐                                       ┌─────────────────┐
│ Service ├─────────────────────────────────────► │     Response    │
│         │                                       └─────────────────┘
└────↑────┘ ┌──────────────────────┐                 ┌─────────────────────┐
     │      │                      │                 │                     │
     └──────►  Other Service       │←───────│──────► │ Repository (Redis ) │
     │      │                      │        │        │                     │
     │      └──────────────────────┘        │        └─────────────────────┘
     │                                      │
     │ ─────────────────────────────────────│

Special thanks to Tawsif Aqib