The good, the bad and the ugly
This repository contains a simplistic sample book webstore project which is only serving the purpose of being a easily comprehensive practical example of a microservice architecture with gRPC and protocol buffers.
./proto # contains protocol buffer files
./server # contains multiple microservices delivering data
Prerequisite is to have Docker installed and its daemon running.
docker-compose up # spins up containers and runs the project
docker-compose up -d # does the same but disattaches from logs (use docker-compose stop to stop the containers)
BloomRPC is a great gRPC
client which you can use to send requests to the services.
If you want to use another GUI or CLI client you can find a pretty complete list
on the awesome-grpc list.
URIs to reach those when started with docker-compose
as described
above are:
localhost:50051
for author-servicelocalhost:50052
for book-service
After running the following commands the generated client libraries
should be available in folder ./proto/generated/node
.
cd ./proto
npm install
npm run compile