Options become a bunch of session and connection level parameters, and requests do not need to maintain a separate Options object when they contain a body anymore, instead, objects is shared with the session, while request-only parameters get passed downwards to the request and its body. This reduces allocations of Options, currently the heaviest object to manage.
buffering more chunks after decoding response payload leads to dubious results in ruby 3.3, and is, from a usability perspective, not even something httpx should allow
most of the code was moved to the transcoder layer.
The `compression_threshold_size` option has been removed.
The `:compression/brotli` plugin becomes only ´:brotli`, and depends on
the new transcoding APIs.
options to skip compression and decompression were added.
These internnal registries were a bit magical to use, difficult to
debug, not thread-safe, and overall a nuisance when it came to type
checking. So long.
The reference for a request verb is now the string which is used
everywhere else, instead of the symbol corresponding to it. This was an
artifact from the import from httprb, and there is no advantage in it,
since these strings are frozen in most use cases, and the
transformations from symbol to strings being performed everywhere are
prooof that keeping the atom isn't really bringing any benefit.
This returns the filename advertised in the content-disposition header.
It reuses the same logic which existed for parsing multipart responses,
which itself was based on `rack`'s.
* `Response#error`, which, coupled with `ErrorResponse#error`, allows
for `if response.error` kind of conditional;
* `Response#raise_for_status` now returns the response when no error is
raise (for method chaining);
Closes#153
for most cases, this didn't make sense, i.e. response bodies were so
small, and the user is fine with keeping it all in mem, whereas
clearing the string is more confusing. And it breaks pattern
matching when matching body multiple times.