Code used to test the utilization of the fastapi as a BFF for Méliuz.
In this POC, I have included:
- multiple HTTP requests with aggregation.
- multiple gRPC requests with aggregation.
- multiple gRPC servers using the libraries gRPC, and homi
- query, header, and JWT authorization.
- password hashing.
- memory cache with cache invalidation.
- Docker (version used
20.10.5
). - docker-compose (version used
1.27.4
). - Makefile (version used
4.1
).
- Use
make build
to build the image. - Use
make up
to up the container.- Alternatively, use
make up-silent
to up the container in the background. You can usemake logs
to view the container logs. - You can use
make up-grpc
to up the gRPC server. You can make requests to it using the hostlocahost:50051
. - You can use
make up-grpc-homi
to up the gRPC server using the homi libary. You can make requests to it using the hostlocahost:50052
.
- Alternatively, use
- Access http://127.0.0.1:3021/docs and make requests.
- Use
make down
to stop the container.