Q
Q
QWATRIX2019-02-08 22:58:27
API
QWATRIX, 2019-02-08 22:58:27

CallBack API bot is dumb, how to optimize?

In general, the fact is that I made a bot. He replies everything is fine.
But there are moments when he does not answer for 30 seconds, sometimes more.
As far as I understand, the bot has a limit of 20 requests per second, which is not a little.
1200 requests per minute. As a matter of fact it is 1200 messages.
So, the server on which the script is loaded by 1% By the
way, everything happens in waves. The type seems to be postponing responding to messages and then sharply again to blunt everyone reads.
The script has a bunch of conditions. Everything is in 1 file.
What do you think, what could be the problem?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
Q
QWATRIX, 2019-02-08
@QWATRIX

I looked, in general, events in the group come with a delay.

R
Roman Morozov, 2021-03-15
@Q_BASIC

This is VKontakte itself stupid.
I have a bot, I use it only for myself, 1-3 commands per day, the server is not loaded at all. And the bot sometimes does not answer for 5-10 minutes.
It turned out that VK does not always immediately send requests to the server according to events. The message came, but the callback api did not work

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question