Skip to content
Discussion options

You must be logged in to vote

The measured 77-280 ms includes DNS/TCP/TLS, network routing, Telegram processing and the response transfer, so it does not isolate language or JSON performance. Current CurlHttpClient keeps one libcurl handle per thread, which allows connection reuse on repeated requests from the same thread.

For a meaningful comparison:

  1. Run both bots on the same machine and network.
  2. Warm up both clients before measuring.
  3. Send the same Bot API method with the same payload sequentially.
  4. Record hundreds of requests and compare median, p95 and p99, not one or two samples.
  5. Log libcurl timing or measure the HTTP call separately from update handling.

If the difference remains, include the benchmark code, sam…

Replies: 3 comments

Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Comment options

You must be logged in to vote
0 replies
Answer selected by reo7sp
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants