This project is a learning exercise focusing on implementing a Back-End For Front-End (BFF) with Circuit Breaker and Cache mechanisms using Typescript, Node.js + Fastify, Opossum, and Redis.
This project aims to deepen understanding of fault-tolerance strategies and caching mechanisms in distributed systems.
It serves as a practical exploration of building resilient and performant applications, particularly in a microservices architecture.
Circuit Breaker: Prevents cascading failures by monitoring downstream services and opening the circuit if failures exceed a threshold.
Cache with Redis: Improves performance by storing frequently accessed data in memory and serving it quickly without hitting the upstream services unnecessarily.
$ npm run start
$ make products
$ make users
$ make reviews
Get Users: $ curl http://localhost:3000/users
Get User by ID: $ curl http://localhost:3000/users/1
Get Products: $ curl http://localhost:3000/products
Get Product by ID: $ curl http://localhost:3000/Product/1
Clone the repository.
Install dependencies with npm install.
Configure Redis connection settings.
Run the application with npm start.
ignore probability and potential errors, i am too shy >.<