valeriansaliou / node-fast-ratelimit

:umbrella: Fast and efficient in-memory rate-limit for Node, used to alleviate most common DOS attacks.
https://www.npmjs.com/package/fast-ratelimit
MIT License
108 stars 19 forks source link

Does not work with node 12 #15

Closed KidkArolis closed 3 years ago

KidkArolis commented 5 years ago

The native hashtable code does not compile in Node 12. For anyone bumping into that issue, I've published a functionally equivalent fork that uses ES Map instead of the hashtable package under:

npm install @kidkarolis/not-so-fast

https://github.com/KidkArolis/not-so-fast

valeriansaliou commented 5 years ago

Thanks, I'll backport this to node-fast-ratelimit. Reason for me not fixing anything so far is that we use the library for Crisp (crisp.chat), which is running Node LTS versions (v10).

electic commented 5 years ago

Great component. I am having the same issue. Appreciate a backport.

rdewolff commented 4 years ago

Facing the same issue with Node 12.

Any update on porting this on the repo @valeriansaliou ?

KidkArolis commented 4 years ago

For what it's worth, I'm still using the fork linked above in production. Although, the way I forked it doesn't make it easy to diff the two packages easily 🤔.

valeriansaliou commented 3 years ago

Hello there! I've fixed that in v3.0.0, using the JS-native Map object, which has as well be measured in my tests to be faster anyway. Note that support for NodeJS older than 6.0.0 has been dropped though.