quickwit-oss / quickwit-oss/quickwit

Test TCP No delay in our Http client

Open
#1,582 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Rust
Stars
11.7k
Forks
597
Avg merge
2d 22h
Merged PRs (30d)
37

Description

The http client used by rusoto S3 is https://docs.rs/hyper/0.14.19/hyper/

I think it comes with the default conf.
In our case, we might want to set up the TCP_NO_DELAY setting
https://docs.rs/hyper/0.14.19/hyper/client/struct.HttpConnector.html#method.set_nodelay

Explanation:
By default: The OS wait up to 40ms to see if more TCP data is to be sent out before emitting a packet.
The goal is to reduce bandwidth by making sure most packet are no quasi-empty.

In Quickwit we send several tiny requests in salves. The last of the salves is likely to be delayed by 40ms.
I have observed some request to be delayed like this. It may or may not be related to this TCP_NO_DELAY.
https://en.wikipedia.org/wiki/Nagle%27s_algorithm

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the rusoto S3 HTTP client configuration and inspect Hyper 0.14's HttpConnector::set_nodelay documentation. Determine whether enabling TCP_NODELAY affects the small requests described here, then add a focused test or measurement showing the resulting behavior and run the relevant client tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
networking
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.