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 buildto build the image. - Use
make upto up the container.- Alternatively, use
make up-silentto up the container in the background. You can usemake logsto view the container logs. - You can use
make up-grpcto up the gRPC server. You can make requests to it using the hostlocahost:50051. - You can use
make up-grpc-homito 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 downto stop the container.