web-push-php
web-push-php copied to clipboard
Using Vapid Sending speed Slow Notification (Max 180/ Minute)
Can anyone help me to find out slow notification sending speed?
I have used many servers like VPS, Dedicated, Shared sever. I got 16 GB Ram & 4 CPU. But still, this application sending notification to subscriber 180/Minute highest.
This should change when #228 is merged (~80x~ ~50x faster)
Still it slow. @Spomky Is there any other suggestions.
Do you send notifications one by one or do you use flush method ?
I used flush. I have updated with latest. Whether I increased RAM or CPU, its not sending faster.
On Sun, Aug 30, 2020 at 11:58 PM wisozg [email protected] wrote:
Do you send notifications one by one or do you use flush method ?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/web-push-libs/web-push-php/issues/277#issuecomment-683453889, or unsubscribe https://github.com/notifications/unsubscribe-auth/AO6CIPEJO75ORQZUTPSJVL3SDKK5RANCNFSM4LTSLH7A .
Are you sure that it's related with this library. Because normally you should have sent at least 100 notification / second. Can you isolate db operations and push sending operations. Sometimes db operations (getting endpoints, deleting expire tokens etc..) can affect sending speed.
With the native scalar multiplication function, there is no reason for this lib to be slow. I closed the PR and re-introduced it in #289. If it doesn’t speed it up, there is another problem I don’t understand at the moment…
Yes, I have used this library. But I got your point. Its related to db operation & push sending operation. I have used both getting endpoints, deleting expire tokens. How can I connect you?
On Mon, Aug 31, 2020 at 9:53 PM wisozg [email protected] wrote:
Are you sure that it's related with this library. Because normally you should have sent at least 100 notification / second. Can you isolate db operations and push sending operations. Sometimes db operations (getting endpoints, deleting expire tokens etc..) can affect sending speed.
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/web-push-libs/web-push-php/issues/277#issuecomment-683883645, or unsubscribe https://github.com/notifications/unsubscribe-auth/AO6CIPBR7SMFAFT62IXRBDDSDPE63ANCNFSM4LTSLH7A .
You can connect me using this ticket.
You should measure how long it takes to finish each operations (Getting endpoints from DB, sending pushes, cleaning expired tokens etc..). If you measure each operations, we can help you better.
Ok will send soon.
I have tried with a list of 200 endpoints Time Get 200 endpoints: 0.065155s Time to send ($webPush->flush()): 4.419076s Log update time: 0.187559s Total time: 4.885548s
Upto: Time send: 14.921125 (when send more 2K )
It is too slow, I submitted the 94K endpoint list in 45 minutes.