From: Samuel Just Date: Thu, 26 Sep 2024 22:43:35 +0000 (+0000) Subject: crimson: convert InternalClientRequest::do_request to use *_executer rather than... X-Git-Tag: v20.0.0~812^2~4 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=c091f3b2ab6a89762e6fcf5ccaa49b65c9ab6fca;p=ceph.git crimson: convert InternalClientRequest::do_request to use *_executer rather than do_osd_ops* Signed-off-by: Samuel Just --- diff --git a/src/crimson/osd/osd_operations/internal_client_request.cc b/src/crimson/osd/osd_operations/internal_client_request.cc index d0ee392ecb638..6ad447cf32ee4 100644 --- a/src/crimson/osd/osd_operations/internal_client_request.cc +++ b/src/crimson/osd/osd_operations/internal_client_request.cc @@ -55,23 +55,26 @@ InternalClientRequest::do_process( crimson::osd::ObjectContextRef obc, std::vector &osd_ops) { - return pg->do_osd_ops( - std::move(obc), - osd_ops, - std::as_const(op_info), - get_do_osd_ops_params() - ).safe_then_unpack_interruptible( - [](auto submitted, auto all_completed) { - return all_completed.handle_error_interruptible( - crimson::ct_error::eagain::handle([] { - ceph_assert(0 == "not handled"); - return seastar::now(); - })); - }, crimson::ct_error::eagain::handle([] { - ceph_assert(0 == "not handled"); - return interruptor::now(); - }) + LOG_PREFIX(InternalClientRequest::do_process); + auto params = get_do_osd_ops_params(); + auto ox = seastar::make_lw_shared( + pg, obc, op_info, params, params.get_connection(), SnapContext{}); + co_await pg->run_executer( + ox, obc, op_info, osd_ops + ).handle_error_interruptible( + crimson::ct_error::all_same_way( + [this, FNAME](auto e) { + ERRORDPPI("{}: got unexpected error {}", *pg, *this, e); + ceph_assert(0 == "should not return an error"); + return interruptor::now(); + }) ); + + auto [submitted, completed] = co_await pg->submit_executer( + std::move(ox), osd_ops); + + co_await std::move(submitted); + co_await std::move(completed); } InternalClientRequest::interruptible_future<>