* Remove TODO
* Remove Cookie::set_ setters
* Do not expose SameSite enum, provide getters on Cookie instead
* Simplify Response::cookies signature (now ignores errors)
This commit introduces a cookie store / session support
for both the async and the sync client.
Functionality is based on the cookie crate,
which provides a HTTP cookie abstraction,
and the cookie_store crate which provides a
store that handles cookie storage and url/expiration
based cookie resolution for requests.
Changes:
* adds new private dependencies: time, cookie, cookie_store
* a new cookie module which provides wrapper types around
the dependency crates
* a Response::cookies() accessor for iterating over response cookies
* a ClientBuilder::cookie_store() method that enables session functionality
* addition of a cookie_store member to the async client
* injecting request cookies and persisting response cookies
* cookie tests
NOTE: this commit DOES NOT expose the CookieStore itself,
limiting available functionality.
This is desirable, but omitted for now due to API considerations that should be fleshed out in the future.
This means users do not have direct access to the cookie session for now.
Some web servers (if IIS is a web server) may close their request
stream early when they consider the input is complete. That leads to
poll_ready returning an error of kind "Closed" which is legitimate as
the receiver disappeared. So this change ignores the case when the body
has been fully transmitted.
Some implementations of multipart/form parsing don't support alternate
encodings, but do allow unicode in 'standard' parameter values. This
change allows users to specify that they do not want to encode
parameters.
(See also: #419, #420.)