-
Notifications
You must be signed in to change notification settings - Fork 154
Labels
Priority: MediumThis issue may be useful, and needs some attention.This issue may be useful, and needs some attention.Status: CompletedNothing further to be done with this issue. Awaiting to be closed.Nothing further to be done with this issue. Awaiting to be closed.Type: BugInconsistencies or issues which will cause an issue or problem for users or implementors.Inconsistencies or issues which will cause an issue or problem for users or implementors.
Milestone
Description
Notify version:
% ./notify -version
__ _ ___
___ ___ / /_(_) _/_ __
/ _ \/ _ \/ __/ / _/ // /
/_//_/\___/\__/_/_/ \_, / v1.0.1
/___/
projectdiscovery.io
Use with caution. You are responsible for your actions
Developers assume no liability and are not responsible for any misuse or damage.
[INF] Current Version: 1.0.1
Current Behavior:
Applying -rate-limit=n allows an initial burst of n notifications (at least as quick of a burst as the notification provider allows :^) ) and then immediately slows to one notification per second.
Demo:
% yes | head -n30 | time ./notify -rate-limit=10
__ _ ___
___ ___ / /_(_) _/_ __
/ _ \/ _ \/ __/ / _/ // /
/_//_/\___/\__/_/_/ \_, / v1.0.1
/___/
projectdiscovery.io
Use with caution. You are responsible for your actions
Developers assume no liability and are not responsible for any misuse or damage.
Using default provider config: /home/justin/.config/notify/provider-config.yaml
y
y
y
[... SNIP ...]
y
y
./notify -rate-limit=10 0.10s user 0.07s system 0% cpu 20.266 total
Sending 30 notifications with a -rate-limit of 10 took 20 seconds. This works out to a negligible amount of time for the first 10 notifications, and then approximately one per second for the remaining 20 notifications. I would have expected it to complete in closer to 3 seconds.
Expected Behavior:
--rate-limit=n should allow notifications to consistently be sent at a maximum of n notifications per second, with any limits beyond that being due to the responsiveness of the notification provider.
Steps To Reproduce:
Anything else:
Metadata
Metadata
Assignees
Labels
Priority: MediumThis issue may be useful, and needs some attention.This issue may be useful, and needs some attention.Status: CompletedNothing further to be done with this issue. Awaiting to be closed.Nothing further to be done with this issue. Awaiting to be closed.Type: BugInconsistencies or issues which will cause an issue or problem for users or implementors.Inconsistencies or issues which will cause an issue or problem for users or implementors.