akka / akka-http

The Streaming-first HTTP server/module of Akka
https://doc.akka.io/docs/akka-http
Other
1.34k stars 594 forks source link

Introduce `auto-to-strict` config setting on client- and server-side #117

Open ktoso opened 7 years ago

ktoso commented 7 years ago

Issue by sirthias Wednesday Sep 23, 2015 at 10:27 GMT Originally opened as https://github.com/akka/akka/issues/18540


Currently the core layer only strictifies incoming message entities if the response bytes are fully contained in the chunk of bytes that have currently been read from the receive buffer. Since this is non-deterministic the user always has the responsibility for "draining" the entity bytes from the connection in order to free it up for subsequent messages.

The proposal is to introduce a new config setting called akka.http.parsing.auto-to-strict which increases user convenience for the standard case (when the entity is "small") and at the same time removes all non-determinism.

Possible values for the setting:

ktoso commented 7 years ago

Comment by jrudolph Thursday Sep 24, 2015 at 08:59 GMT


This ties in with the proposals in (17694) https://github.com/akka/akka-http/issues/105 and should probably approached "holistically".

In general, several parsing modes are possible that would determine what kind of entities the user can expect when receiving an HttpMessage:

ktoso commented 7 years ago

Comment by ktoso Thursday Sep 24, 2015 at 12:03 GMT


Thanks a lot for reporting this and the insights, makes a lot of sense, marking triaged for now.

ktoso commented 7 years ago

Comment by ktoso Thursday May 19, 2016 at 01:15 GMT


Triaged. Also, one of the things which might impact our behaviour in raw throughput benchmarks I think.

stefanasseg commented 7 years ago

Any progress on this?

ktoso commented 7 years ago

No comments / markers means no progress, as simple as that. We have more urgent things to ship on our plates sadly right now - finishing 10.0 stable as well as HTTP/2 work.

We'd be thrilled to see a community contribution, e.g. from yourself since you seem interested, of this feature. Happy to provide guidance how to start working on it but won't have the time to do so myself in the next weeks.

ktoso commented 7 years ago

Related ticket https://github.com/akka/akka-http/issues/105

yeryomenkom commented 4 years ago

Any progress on this?