]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/os/seastore: SeaStore::start() into coroutines
authorMatan Breizman <mbreizma@redhat.com>
Tue, 29 Jul 2025 11:13:02 +0000 (11:13 +0000)
committerMatan Breizman <mbreizma@redhat.com>
Thu, 4 Sep 2025 12:39:17 +0000 (12:39 +0000)
Signed-off-by: Matan Breizman <mbreizma@redhat.com>
src/crimson/os/seastore/seastore.cc

index 4ae4da2c92a19a85c1fb59fa6d42ebe4ed0ed942..8a6c4aa0604300508dee00e451f9ba596359da93 100644 (file)
@@ -223,16 +223,12 @@ seastar::future<> SeaStore::start()
          d_type == device_type_t::RANDOM_BLOCK_SSD);
 
   ceph_assert(root != "");
-  return Device::make_device(root, d_type
-  ).then([this](DeviceRef device_obj) {
-    device = std::move(device_obj);
-    return device->start();
-  }).then([this, is_test] {
-    ceph_assert(device);
-    return shard_stores.start(root, device.get(), is_test);
-  }).then([FNAME] {
-    INFO("done");
-  });
+  DeviceRef device_obj = co_await Device::make_device(root, d_type);
+  device = std::move(device_obj);
+  co_await device->start();
+  ceph_assert(device);
+  co_await shard_stores.start(root, device.get(), is_test);
+  INFO("done");
 }
 
 seastar::future<> SeaStore::test_start(DeviceRef device_obj)