Basic todo app built with MERN stack.
Build with:
React
,Redux
,Redux Thunk
- Initial read request is handled by
Redux Thunk
. - When all todos are fetched into Redux, future reads and updates are made through Redux.
- There is a client rate-limit on update. (ex: if client spams the checkbox, there is a time limit to handle the process).
- Used axios to handle API requests.
NodeJS, Express, MongoDB (MongoDB Atlas & connection with mongoose), ...
These specs are additions to CRUD operations.
- Made an in-memory cache that has 30 seconds of lifespan. After each
post
,put
ordelete
request, cache's lifespan resets. That way, API response times reduced are down to ~5ms. (if cache is available.) - Built a rate-limit middleware using
express-rate-limit
. Any client makes 100 requests per 30 seconds, gets temporary IP ban. - Built a rate-limit middleware using
express-slow-down
. After 50 requests in 30 seconds, each request's response time gets slower +500ms.
API server's repo is todo-server
If everything set correctly, you should be able to hit a request to
localhost:6565/api/v1/todos
All CRUD operations are handled by this router.
You can check backend repo at: todo-server