Releases: 0xRadioAc7iv/rate-limiter
v2.1.0
Release v2.1.0
Overview
This release introduces several significant enhancements and improvements to the rate limiter library. The key updates include support for additional frameworks, improved code quality through ESLint integration, and expanded test coverage to ensure reliability. This version also enhances HTTP headers for better request handling and introduces support for Fastify and NestJS frameworks.
What's Changed
-
Added Headers Type by @0xRadioAc7iv in #6
- Added support for
"draft-8"
rate-limiting
headers.
- Added support for
-
Added Fastify Middleware by @0xRadioAc7iv in #11
- Introduced native support for Fastify, allowing seamless integration with Fastify applications.
-
Added ESLint by @0xRadioAc7iv in #12
- Implemented ESLint to enforce coding standards and best practices.
- Ensured better code consistency and maintainability.
-
NestJS Support by @0xRadioAc7iv in #15
-
Added Tests by @0xRadioAc7iv in #16
- Introduced comprehensive test cases to improve reliability and catch regressions.
- Enhanced test coverage for core functionalities, ensuring robustness.
Full Changelog
First Stable Release: v1.0.0
v1.0.0
This is the first release of my Rate Limiter package, providing efficient and flexible rate-limiting capabilities for Node.js applications. The package includes the following features:
Key Features
- Basic Rate Limiting: Set request limits per window for individual clients.
- Customizable Configuration:
- Configure limits, time windows, and cleanup intervals.
- Custom response messages and status codes.
- Flexible Identification: Support for multiple types of user keys for rate-limit identification (e.g., IP address or custom headers).
- Skip Rules:
- Option to skip specific requests from rate limiting using a custom
skip
function. skipFailedRequests
: Exclude requests withstatusCode >= 400
from rate counting.
- Option to skip specific requests from rate limiting using a custom
- Dynamic Limits:
- Per-user and per-endpoint limits.
- External Store Support: Easily extendable for Redis, MongoDB and PostgreSQL (not included in this release).
- Rate Limit Headers:
- Support for standard and legacy rate-limit headers (draft version 8 pending).
- Logging:
- Store logs locally or in a database for future analysis (pending).
- Performance: Optimized for minimal memory and CPU usage with efficient cleanup.
Installation
npm install @radioac7iv/rate-limiter
Usage
Refer to the documentation in the repository for a complete guide on how to integrate the package into your project.
Feedback and Contributions
Your feedback is valuable! Feel free to report issues, suggest features, or contribute to the project here.