This is web service that will allow us to manage and search for laptop configurations
The web service has the following services:
- LaptopService
RPC | REQUEST TYPE | RESPONSE TYPE | DESCRIPTION |
---|---|---|---|
CreateLaptop | CreateLaptopRequest | CreateLaptopResponse | Creates and stores a new laptop |
SearchLaptop | SearchLaptopRequest | SearchLaptopResponse | Searches for a laptop using the provided Filter |
UploadImage | UploadImageRequest | UploadImageResponse | Uploads and stores a laptop image |
RateLaptop | RateLaptopRequest | RateLaptopResponse | Rates a laptop |
- AuthService
RPC | REQUEST TYPE | RESPONSE TYPE | DESCRIPTION |
---|---|---|---|
Login | LoginRequest | LoginResponse | Attempts to login a user using the provided credentials |
To run the client and the server on TLS mode [enable-tls
], you need to generate the certificates.
make gen-cert
By default, all servers run with the enable-tls
flag enabled.
To run the client, run the following command:
make run-client
The app supports two types of servers:
- gRPC
- REST (HTTP) using GRPC Gateway
To run the gRPC server, run the following command:
make run-grpc-server
To run the REST server, run the following command:
make run-rest-server
To run tests, run the following command
make test