]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
crimson/.../snaptrim_event: remove remaining SnapTrimEvent pipeline stages
authorSamuel Just <sjust@redhat.com>
Tue, 28 May 2024 20:37:56 +0000 (13:37 -0700)
committerSamuel Just <sjust@redhat.com>
Thu, 13 Jun 2024 18:44:55 +0000 (11:44 -0700)
SnapTrimEvent doesn't actually do or block on GetOBC or Process --
remove those stages entirely.  Entering Process, in particular, causes
problems unless we immediately leave it as SnapTrimObjSubEvent needs to
enter and leave it to complete.  Entering one of the stages removed in
a prior commit had a side effect of exiting Process -- without that
exit SnapTrimEvent and SnapTrimObjSubEvent mutually block preventing
snap trim or client io from making progress.

This leaves no actual pipeline stages on SnapTrimEvent, which makes
sense as only SnapTrimObjSubEvent actually does IO.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/crimson/osd/osd_operations/snaptrim_event.cc
src/crimson/osd/osd_operations/snaptrim_event.h

index 561d0a7cd928c9d2757746a13dbb21182b7a3fc5..185af88c1158926aece600824f7b16727280ab23 100644 (file)
@@ -67,26 +67,15 @@ SnapTrimEvent::start()
 {
   ceph_assert(pg->is_active_clean());
 
-  auto exit_handle = seastar::defer([this] {
-    logger().debug("{}: exit", *this);
-    handle.exit();
-  });
-
   /* TODO: add a way to expose progress via the optracker without misusing
    * pipeline stages. https://tracker.ceph.com/issues/66473 */
   ShardServices &shard_services = pg->get_shard_services();
-  co_await enter_stage<interruptor>(
-    client_pp().get_obc);
-
   {
     co_await pg->background_process_lock.lock_with_op(*this);
     auto unlocker = seastar::defer([this] {
       pg->background_process_lock.unlock();
     });
 
-    co_await enter_stage<interruptor>(
-      client_pp().process);
-
     auto to_trim_fut = interruptor::async([this] {
       using crimson::common::local_conf;
       const auto max =
@@ -135,9 +124,6 @@ SnapTrimEvent::start()
        std::chrono::milliseconds(std::lround(time_to_sleep * 1000))));
   }
 
-  logger().debug("{}: completed", *this);
-  co_await interruptor::make_interruptible(handle.complete());
-
   logger().debug("{}: all completed", *this);
   co_return seastar::stop_iteration::no;
 }
index f389943b83329b62302c181319f59dd8e6773dff..c516769114e184f221b3e26227819d8600440046 100644 (file)
@@ -72,8 +72,6 @@ public:
 
   std::tuple<
     StartEvent,
-    CommonPGPipeline::GetOBC::BlockingEvent,
-    CommonPGPipeline::Process::BlockingEvent,
     PG::BackgroundProcessLock::Wait::BlockingEvent,
     CompletionEvent
   > tracking_events;