On Wed, 17 Apr 2019 09:50:00 -0400 Casey Bodley <cbodley@xxxxxxxxxx> wrote: > That's good to know, thanks for testing! This one is documented as a > breaking change in > https://www.boost.org/doc/libs/1_70_0/doc/html/boost_asio/history.html: > > > Note: One potential source of breakage in existing user code is > > when > reusing an I/O object's |io_context| for constructing another I/O > object, as in... > > When we fix this, we'll also want to update cmake to require boost > 1.70 so that we don't need a bunch of #ifdefs to support previous > versions. The local patch I am using to test does this already. It gets further with that patch, but does eventually fail with this: > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc: In instantiation of 'void {anonymous}::handle_connection(RGWProcessEnv&, Stream&, boost::beast::flat_buffer&, bool, {anonymous}::SharedMutex&, rgw::dmclock::Scheduler*, boost::system::error_code&, boost::asio::yield_context) [with Stream = boost::asio::ssl::stream<boost::asio::basic_stream_socket<boost::asio::ip::tcp>&>; boost::beast::flat_buffer = boost::beast::basic_flat_buffer<std::allocator<char> >; {anonymous}::SharedMutex = ceph::async::SharedMutex<boost::asio::io_context::executor_type>; boost::asio::yield_context = boost::asio::basic_yield_context<boost::asio::executor_binder<void (*)(), boost::asio::executor> >]': > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:550:53: required from here > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:155:38: error: 'class boost::asio::basic_socket<boost::asio::ip::tcp, boost::asio::executor>' has no member named 'get_io_context'; did you mean 'io_control'? > auto y = optional_yield{socket.get_io_context(), yield}; > ~~~~~~~^~~~~~~~~~~~~~ > io_control > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:155:12: error: no matching function for call to 'optional_yield::optional_yield(<brace-enclosed initializer list>)' > auto y = optional_yield{socket.get_io_context(), yield}; > ^ > In file included from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_common.h:31, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_client_io.h:17, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_client.h:12, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:16: > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:52:3: note: candidate: 'optional_yield::optional_yield(optional_yield::empty_t)' > optional_yield(empty_t) noexcept {} > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:52:3: note: candidate expects 1 argument, 2 provided > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:46:12: note: candidate: 'optional_yield::optional_yield(boost::asio::io_context&, boost::asio::yield_context&)' > explicit optional_yield(boost::asio::io_context& c, > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:46:12: note: conversion of argument 1 would be ill-formed: > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate: 'constexpr optional_yield::optional_yield(const optional_yield&)' > class optional_yield { > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate expects 1 argument, 2 provided > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate: 'constexpr optional_yield::optional_yield(optional_yield&&)' > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate expects 1 argument, 2 provided > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc: In instantiation of 'void {anonymous}::handle_connection(RGWProcessEnv&, Stream&, boost::beast::flat_buffer&, bool, {anonymous}::SharedMutex&, rgw::dmclock::Scheduler*, boost::system::error_code&, boost::asio::yield_context) [with Stream = boost::asio::basic_stream_socket<boost::asio::ip::tcp>; boost::beast::flat_buffer = boost::beast::basic_flat_buffer<std::allocator<char> >; {anonymous}::SharedMutex = ceph::async::SharedMutex<boost::asio::io_context::executor_type>; boost::asio::yield_context = boost::asio::basic_yield_context<boost::asio::executor_binder<void (*)(), boost::asio::executor> >]': > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:568:53: required from here > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:155:38: error: 'class boost::asio::basic_socket<boost::asio::ip::tcp, boost::asio::executor>' has no member named 'get_io_context'; did you mean 'io_control'? > auto y = optional_yield{socket.get_io_context(), yield}; > ~~~~~~~^~~~~~~~~~~~~~ > io_control > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:155:12: error: no matching function for call to 'optional_yield::optional_yield(<brace-enclosed initializer list>)' > auto y = optional_yield{socket.get_io_context(), yield}; > ^ > In file included from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_common.h:31, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_client_io.h:17, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_client.h:12, > from /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/rgw/rgw_asio_frontend.cc:16: > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:52:3: note: candidate: 'optional_yield::optional_yield(optional_yield::empty_t)' > optional_yield(empty_t) noexcept {} > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:52:3: note: candidate expects 1 argument, 2 provided > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:46:12: note: candidate: 'optional_yield::optional_yield(boost::asio::io_context&, boost::asio::yield_context&)' > explicit optional_yield(boost::asio::io_context& c, > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:46:12: note: conversion of argument 1 would be ill-formed: > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate: 'constexpr optional_yield::optional_yield(const optional_yield&)' > class optional_yield { > ^~~~~~~~~~~~~~ > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate expects 1 argument, 2 provided > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate: 'constexpr optional_yield::optional_yield(optional_yield&&)' > /var/tmp/portage/sys-cluster/ceph-14.2.0-r5/work/ceph-14.2.0/src/common/async/yield_context.h:41:7: note: candidate expects 1 argument, 2 provided > make[2]: *** [src/rgw/CMakeFiles/radosgw_a.dir/build.make:128: src/rgw/CMakeFiles/radosgw_a.dir/rgw_asio_frontend.cc.o] Error 1 > make[1]: *** [CMakeFiles/Makefile2:7562: src/rgw/CMakeFiles/radosgw_a.dir/all] Error 2 > make: *** [Makefile:141: all] Error 2