Open kabakan opened 5 years ago
Hi Kanat,
Just to give my two cents, as far as I know, the library has no limits on requests rate. As you describe it, it seems that you are hitting Telegram Bots API limits: https://core.telegram.org/bots/faq#my-bot-is-hitting-limits-how-do-i-avoid-this
This is not a large mailing for the distribution of the message, it is a load testing of intents of 1000 threads from the Server Docker to the Telegram Server via WebSocket
Telegram servers only allow one request opened at a time and each request only allow up to 100 updates. So it is not possible to have 1000 threads running at the same time.
Could using Webhook solve that problem, because updates are send more frequently?
Telegram servers only allow one request opened at a time
Are you sure? I have to send one different message every 5 second, for about 2 minutes, at the same user. Can i do it?
@siamoInPochi You can send more than one message at the same time, but only can have one getUpdates request at a time running.
Hi Ruben
My name is Kanat, developer VEON LTD, Almaty, Kazakhstan.
We use the telegram library 4.1 and found a problem in the load testing of 1000 threads in 180 seconds, the response waiting time is from 5 to 20 seconds for one thread when the library tries to connect to the telegram server. At the same time, the communication channel rate is not used 1 megabit, there is no load on the communication channel.
Problems: a. In 1 second only 4 or 5 users are processed, the response time is 0.2 seconds. b. If you use the number of users over 10 per second in 1 second, then the time of the answer is more than 5 to 20 seconds
Question:
I will be very happy if you provide advice for solving the problem.