Added Webclient, refactored Webserver to share streamed body sending and receiving logic.#2771
Added Webclient, refactored Webserver to share streamed body sending and receiving logic.#2771jurgenvinju wants to merge 45 commits into
Conversation
…he same Response and Request encodings
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2771 +/- ##
========================================
- Coverage 46% 46% -1%
+ Complexity 6718 6714 -4
========================================
Files 794 795 +1
Lines 65937 66220 +283
Branches 9889 9918 +29
========================================
+ Hits 30760 30761 +1
- Misses 32797 33079 +282
Partials 2380 2380 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
DavyLandman
left a comment
There was a problem hiding this comment.
I think this is a nice idea but not ready yet, I've written down my concerns.
I think this needs tests.
|
Great review @DavyLandman I'll try and improve this PR and let's have a look together later again. I've tested this client so far with a couple of web APIs and some very large test downloads. It seems very natural apart from the host/path/query separation. I think some shorthands where a full URL can be used which is split up internally would be nice. Also there is no support for fragments yet. |
… body in a POST and PUT ina Request, the same way as on the Response side. So support for text, json and file content. HTML is for later.
…nd receive, and also enabled all body kinds for the server side now, also with POST and PUT requests. This also introduces streaming to the JSON and string responses, and post/put requests are also streamed now.
…is missing. Also added query parameters to the client.
…o WebBody for use in both Webserver and Webclient. Code specific for server or client has been removed
|
…ll the internal conversions to and from the HTTP socket



Response fetch(Request)RequestandResponsedata-typesendandreceivekind:sendis used for serverresponseand clientputandgetreceiveis used for serverputandgetand clientresponse