docs: update README.md
parent
c2af9ec878
commit
5acdde1026
10
README.md
10
README.md
|
@ -1,20 +1,26 @@
|
||||||
## Just tinkering with grpc
|
## Just tinkering with grpc
|
||||||
|
|
||||||
|
|
||||||
### Setup
|
### Setup
|
||||||
|
|
||||||
```
|
```
|
||||||
docker-compose up
|
docker-compose up
|
||||||
|
|
||||||
|
# add two numbers and get the result
|
||||||
curl localhost:3001/add/3/2
|
curl localhost:3001/add/3/2
|
||||||
```
|
```
|
||||||
|
|
||||||
### Test mock server
|
### Test mock server
|
||||||
|
|
||||||
|
Actually mocking the server for testing...
|
||||||
|
|
||||||
```
|
```
|
||||||
cd ./server
|
cd ./server
|
||||||
go test
|
go test
|
||||||
```
|
```
|
||||||
|
|
||||||
### To generate grpc code using protobuf compiler
|
### To generate grpc code using protobuf compiler
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
cd ./pd
|
cd ./pb
|
||||||
protoc --go_out=. --go-grpc_out=. calc_service.proto
|
protoc --go_out=. --go-grpc_out=. calc_service.proto
|
||||||
```
|
```
|
||||||
|
|
Loading…
Reference in New Issue