]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
test_alien_echo: convert Condition to use readable_eventfd
authorSamuel Just <sjust@redhat.com>
Sat, 15 Feb 2020 00:35:29 +0000 (16:35 -0800)
committerSamuel Just <sjust@redhat.com>
Sat, 15 Feb 2020 00:47:06 +0000 (16:47 -0800)
Should have been included in 5f05a50bae8bb4889dba0d249ed5fc3a2fcdcfa5.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/test/crimson/test_alien_echo.cc

index abccc5034ecc9629f5f9d3c94a15867998d2a35e..876d5490ed4c6a799d24329a595fae8d7ffc106b 100644 (file)
@@ -7,7 +7,6 @@
 #include "crimson/net/Dispatcher.h"
 #include "crimson/net/Messenger.h"
 #include "crimson/net/Config.h"
-#include "crimson/thread/Condition.h"
 #include "crimson/thread/Throttle.h"
 
 #include <seastar/core/alien.hh>
@@ -95,7 +94,7 @@ struct Client {
 
 class SeastarContext {
   seastar::file_desc begin_fd;
-  crimson::thread::Condition on_end;
+  seastar::readable_eventfd on_end;
 
 public:
   SeastarContext()
@@ -112,7 +111,7 @@ public:
         // alien: i've sent my request. have you replied it?
         // wait_for_seastar();
         // alien: you are free to go!
-        on_end.notify();
+        on_end.write_side().signal(1);
       }};
   }
 
@@ -122,7 +121,7 @@ public:
         return set_seastar_ready();
       }).then([this] {
         // seastar: let me know once i am free to leave.
-        return on_end.wait();
+        return on_end.wait().then([](size_t){});
       }).handle_exception([](auto ep) {
         std::cerr << "Error: " << ep << std::endl;
       }).finally([] {