]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson: remove unused OperationThrottler::with_throttle 62837/head
authorSamuel Just <sjust@redhat.com>
Tue, 15 Apr 2025 22:56:09 +0000 (15:56 -0700)
committerSamuel Just <sjust@redhat.com>
Mon, 21 Apr 2025 16:30:28 +0000 (09:30 -0700)
It's now unused, and these combinator style wrappers are easy to
misuse and hard to read compared with RAII and coroutines.

Signed-off-by: Samuel Just <sjust@redhat.com>
src/crimson/osd/osd_operation.h
src/crimson/osd/shard_services.h

index cee9bf2974f69fd5039d2960a709ab442f7d5078..167ceac463f3a0c9c4d61eb45b74c356d5e76141 100644 (file)
@@ -334,17 +334,6 @@ public:
     });
   }
 
-  template <typename F>
-  auto with_throttle(
-    crimson::osd::scheduler::params_t params,
-    F &&f) {
-    return acquire_throttle(params)
-      .then(std::forward<F>(f))
-      .finally([this] {
-       release_throttle();
-      });
-  }
-
 private:
   void dump_detail(Formatter *f) const final;
 
index df9ecc1c35fc3c6ccd4ba84e96efd90c5505591d..61880909bcddd69b7cef9aad8925e55d3da69aff 100644 (file)
@@ -593,7 +593,6 @@ public:
   }
 
   FORWARD_TO_OSD_SINGLETON(get_pool_info)
-  FORWARD(with_throttle, with_throttle, local_state.throttler)
   FORWARD(get_throttle, get_throttle, local_state.throttler)
 
   FORWARD_TO_OSD_SINGLETON(build_incremental_map_msg)