]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
rgw: add executor type for basic_waitable_timers 27730/head
authorCasey Bodley <cbodley@redhat.com>
Tue, 23 Apr 2019 19:41:45 +0000 (15:41 -0400)
committerCasey Bodley <cbodley@redhat.com>
Thu, 25 Apr 2019 20:27:31 +0000 (16:27 -0400)
as of boost 1.70, the timer no longer depends on io_context directly,
so we have to specify its executor as a template parameter

Signed-off-by: Casey Bodley <cbodley@redhat.com>
src/rgw/rgw_dmclock_async_scheduler.h
src/rgw/rgw_reshard.h

index 70487a5253734029edb79e20e3af5dc28050f7c4..1d454acd2ea6c08adafb95ec3a56b6fbcf7da3e5 100644 (file)
@@ -82,7 +82,12 @@ class AsyncScheduler : public md_config_obs_t, public Scheduler {
   using Completion = async::Completion<Signature, async::AsBase<Request>>;
 
   using Clock = ceph::coarse_real_clock;
+#if BOOST_VERSION < 107000
   using Timer = boost::asio::basic_waitable_timer<Clock>;
+#else
+  using Timer = boost::asio::basic_waitable_timer<Clock,
+        boost::asio::wait_traits<Clock>, executor_type>;
+#endif
   Timer timer; //< timer for the next scheduled request
 
   CephContext *const cct;
index d99a6ff68d5fcb438de4aed7dca7a1eff064606b..213fc238d2eeaf1a3ae1039773c9cd47a1900624 100644 (file)
@@ -183,7 +183,14 @@ class RGWReshardWait {
   ceph::condition_variable cond;
 
   struct Waiter : boost::intrusive::list_base_hook<> {
-    boost::asio::basic_waitable_timer<Clock> timer;
+#if BOOST_VERSION < 107000
+    using Timer = boost::asio::basic_waitable_timer<Clock>;
+#else
+    using Executor = boost::asio::io_context::executor_type;
+    using Timer = boost::asio::basic_waitable_timer<Clock,
+          boost::asio::wait_traits<Clock>, Executor>;
+#endif
+    Timer timer;
     explicit Waiter(boost::asio::io_context& ioc) : timer(ioc) {}
   };
   boost::intrusive::list<Waiter> waiters;