summaryrefslogtreecommitdiffstats
path: root/src/crimson
diff options
context:
space:
mode:
authorSamuel Just <sjust@redhat.com>2024-10-01 22:11:31 +0200
committerSamuel Just <sjust@redhat.com>2024-10-15 05:37:26 +0200
commit2b562b64a64777b1428e9ad3187b50619cbf1a4d (patch)
treece934c5b4a7717bb88ef22a9b86e577aece14c3c /src/crimson
parentcrimson: OpsExecuter no longer needs to be a lw shared ptr (diff)
downloadceph-2b562b64a64777b1428e9ad3187b50619cbf1a4d.tar.xz
ceph-2b562b64a64777b1428e9ad3187b50619cbf1a4d.zip
crimson: remove unused OpsExecuter::rollback_obc_if_modified overload
Signed-off-by: Samuel Just <sjust@redhat.com>
Diffstat (limited to 'src/crimson')
-rw-r--r--src/crimson/osd/ops_executer.h31
1 files changed, 0 insertions, 31 deletions
diff --git a/src/crimson/osd/ops_executer.h b/src/crimson/osd/ops_executer.h
index 068f510d1ef..e770e825b32 100644
--- a/src/crimson/osd/ops_executer.h
+++ b/src/crimson/osd/ops_executer.h
@@ -548,7 +548,6 @@ OpsExecuter::flush_changes_n_do_ops_effects(
template <class Func>
struct OpsExecuter::RollbackHelper {
void rollback_obc_if_modified();
- void rollback_obc_if_modified(const std::error_code& e);
OpsExecuter *ox;
Func func;
};
@@ -587,36 +586,6 @@ void OpsExecuter::RollbackHelper<Func>::rollback_obc_if_modified()
}
}
-template <class Func>
-void OpsExecuter::RollbackHelper<Func>::rollback_obc_if_modified(
- const std::error_code& e)
-{
- // Oops, an operation had failed. do_osd_ops() altogether with
- // OpsExecuter already dropped the ObjectStore::Transaction if
- // there was any. However, this is not enough to completely
- // rollback as we gave OpsExecuter the very single copy of `obc`
- // we maintain and we did it for both reading and writing.
- // Now all modifications must be reverted.
- //
- // The conditional's purpose is to efficiently handle hot errors
- // which may appear as a result of e.g. CEPH_OSD_OP_CMPXATTR or
- // CEPH_OSD_OP_OMAP_CMP. These are read-like ops and clients
- // typically append them before any write. If OpsExecuter hasn't
- // seen any modifying operation, `obc` is supposed to be kept
- // unchanged.
- assert(ox);
- const auto need_rollback = ox->has_seen_write();
- crimson::get_logger(ceph_subsys_osd).debug(
- "{}: object {} got error {}, need_rollback={}",
- __func__,
- ox->obc->get_oid(),
- e,
- need_rollback);
- if (need_rollback) {
- func(ox->obc);
- }
-}
-
// PgOpsExecuter -- a class for executing ops targeting a certain PG.
class PgOpsExecuter {
template <typename T = void>