When using `beast::tcp_stream`, the user must make sure that async operations
are initiated from within the strand associated with the stream.
Signed-off-by: Damian Jarek <damian.jarek93@gmail.com>
`asio::coroutine` is an extension, which is not part of
the Networking TS, so the `net` alias is not appropriate in this case.
Signed-off-by: Damian Jarek <damian.jarek93@gmail.com>
fix#38
This improves the behavior when encountering a short read:
* Any stream error encountered during a read is converting into
`http::error::partial_message` if some data was received but
the message is incomplete.
* Examples squelch SSL short read errors from the logs.
fix#1435, fix#1438
* Example and test can be built on msvc v141 15.9.6
using /std:c++17 and BOOST_BEAST_USE_STD_STRING_VIEW.
* changed string_view.to_string() to std:string(string_view),
awaiting availability of Library Fundamentals TS here.
* Reactivated relevant tests to param_list. #ifdef 0 test
exhibited same assertion failed error in debug mode.
Now fixed in DEBUG on msvc v141 15.9.6 with
BOOST_BEAST_USE_STD_STRING_VIEW and /std:c++17.
* Looked up http paramters (transfer-encoding, etc.)
and changed tests as well as fixing comment to
match specs.
fix#769
The following classes are removed:
* handler_type
* async_result
* async_completion
* is_dynamic_buffer
* is_const_buffer_sequence
* is_mutable_buffer_sequence
* handler_alloc
Actions Required:
* Use BOOST_ASIO_HANDLER_TYPE instead of handler_type
* Use BOOST_ASIO_INITFN_RESULT_TYPE instead of async_result
* Use boost::asio::async_completion
* Use boost::asio::is_dynamic_buffer
* Use boost::asio::is_const_buffer_sequence
* Use boost::asio::is_mutable_buffer_sequence
* boost::asio::associated_allocator_t replaces handler_alloc
fix#767
The write family of HTTP stream algorithms no longer returns
error::end_of_stream when the message indicates that the connection
should be closed.
Actions Required:
* Add code to servers to close the connection after successfully
writing a message where `message::keep_alive()` would return `false`.
fix#778
* The version data member is replaced with accessor
member functions.
Actions Required:
* Call member function message::version instead of accessing
the version member at call sites.
fix#778
* The body data member is replaced with accessor
member functions.
Actions Required:
* Call member function message::body instead of accessing
the data member at call sites.
* HTTP read and write operations now return the
number of bytes transferred to or from the stream.
Actions Required:
* Modify HTTP read and/or write completion handlers to receive
the extra std::size_t bytes_transferred parameter.
fix#575, fix#604, fix#608, fix#634, fix#712
All examples are rewritten:
* Using Best Practices
* Mostly self-contained
* New examples to complete the feature matrix
* The server-framework example is removed