-
Notifications
You must be signed in to change notification settings - Fork 6
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: Addressing comments on the descritpion of DOS protection configuration #222
fix: Addressing comments on the descritpion of DOS protection configuration #222
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
docs/guides/nwaku/config-options.md
Outdated
| `rate-limit` | | This is a repeatable option. Each one of them can describe spefic rate limit configuration for a particular protocol.<br />\<protocol\>:volume/period\<time-unit\><br />- if protocol is not given, settings will be taken as default for un-set protocols. Ex: `80/2s`<br />-Supported protocols are: `lightpush`\|`filter`\|`px`\|`store`\|`storev2`\|`storev3`<br />-volume must be an integer value, representing number of requests over the period of time allowed.<br />-period\<time-unit\> must be an integer with defined unit as one of `h`\|`m`\|`s`\|`ms`<br />- `storev2` and `storev3` takes precedence over `store` which can easy set both store protocols at once.<br />- In case of multiple set of the same protocol limit, last one will take place.<br />- if config is not set it means unlimited requests are allowed.<br />-filter has a bit different approach. It has a default setting applied if not overridden. Rate limit setting for filter will be applied per subscriber-peers, not globally - it must be considered when changing the setting.<br /><br />Examples:<br />- `100/1s` - default for all protocols if not set otherwise.<br />-`lightpush:0/0s` - lightpush protocol will be not rate limited.<br />-`store:130/1500ms` - both store-v3 and store-v2 will apply 130 request per each 1500ms separately.<br />-`px:10/1h` PeerExchange will serve only 10 requests in every hour.<br />-`filter:8/5m` - will allow 8 subs/unsubs/ping requests for each subscribers within every 5 min. | | ||
| `rate-limit` | | This is a repeatable option. Each can describe a specific rate limit configuration for a particular protocol.<br />Formatted as:`<protocol>:volume/period<time-unit>`<br />- if protocol is not given, settings will be taken as default for un-set protocols. Ex: `80/2s`<br />-Supported protocols are: `lightpush`\|`filter`\|`px`\|`store`\|`storev2`\|`storev3`<br />-volume must be an integer value, representing number of requests over the period of time allowed.<br />-period\<time-unit\> must be an integer with defined unit as one of `h`\|`m`\|`s`\|`ms`<br />- `storev2` and `storev3` takes precedence over `store` which can easy set both store protocols at once.<br />- In case of multiple set of the same protocol limit, last one will take place.<br />- if config is not set, - which is the default - means unlimited requests are allowed.<br />-filter has a bit different approach. It has a default setting applied if not overridden. Rate limit setting for filter will be applied per subscriber-peers, not globally - it must be considered when changing the setting.<br /><br />Examples:<br />- `100/1s` - default for all protocols if not set otherwise.<br />-`lightpush:0/0s` - lightpush protocol will be not rate limited.<br />-`store:130/1500ms` - both store-v3 and store-v2 will apply 130 request per each 1500ms separately.<br />-`px:10/1h` PeerExchange will serve only 10 requests in every hour.<br />-`filter:8/5m` - will allow 8 subs/unsubs/ping requests for each subscribers within every 5 min. | |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe the examples can contain the parameter name too: --rate-limit="80/2s"
(Notice that I'm also suggesting minor change in some descriptions)
--rate-limit="100/1s"
- default for all protocols if not set otherwise.
--rate-limit="lightpush:0/0s"
- lightpush protocol will be not rate-limited.
--rate-limit="store:130/1500ms"
- both store-v3 and store-v2 will apply 130 request per each 1500ms separately.
--rate-limit=px:10/1h
PeerExchange will serve only 10 requests every hour.
--rate-limit=filter:8/5m
- will allow 8 subs/unsubs/ping requests for each subscriber within every 5 min. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for it, I added them. I appreciate.
@fryorcraken observations addressed within this PR.
#216 (review)