Skip to content
This repository has been archived by the owner on Nov 15, 2019. It is now read-only.

Solve head of line blocking #1135

Closed
povilasb opened this issue Feb 25, 2019 · 1 comment
Closed

Solve head of line blocking #1135

povilasb opened this issue Feb 25, 2019 · 1 comment
Labels

Comments

@povilasb
Copy link
Contributor

The Problem

Currently the maximum message size Crust allows to send is 2 MB. The limit is there for a reason: we don't want upper layers to put too big TCP packets on the stream because it would simply clog the line. Basically this is head-of-line blocking problem. Crust users might and should not be aware of it - we strive for simplicity.

Design the changes so that Service::send(msg_100mb) would not delay Service::send(msg_10kb) delivery for too long.

Solution

  1. Crust should fragment the data it's given before sending over TCP.
  2. Then on the other side packets should be defragmented, buffered and proper crust events dispatched when a full packet arrives.
  3. See if this multiplexer library could help: https://github.com/paritytech/yamux
@povilasb povilasb added the feat label Feb 25, 2019
@douglascaetano
Copy link
Contributor

Closed in favor of #1145.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants