reo7sp / tgbot-cpp

C++ library for Telegram bot API

Home Page:http://reo7sp.github.io/tgbot-cpp

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

about performance

okman334 opened this issue · comments

The library tgbot works in single thread blocking mode, so the performance is not so good.
Especially when the tg group has many number. The command maybe also so many, the program is handle command slow. This is a bit sorry for C++, which is known for its performance😂
Do you have any suggestions if I want to run in a multi-threaded or multi-process environment?

I'm not really proficient in C++ but I just use a thread pool and just assign every request to one the threads there. I don't really know if that solves the issue though

I'm not really proficient in C++ but I just use a thread pool and just assign every request to one the threads there. I don't really know if that solves the issue though

that's a good idea.