]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
crimson/osd/object_context_loader: add comment to with_head_obc
authorMatan Breizman <mbreizma@redhat.com>
Mon, 1 Apr 2024 08:20:14 +0000 (08:20 +0000)
committerMatan Breizman <mbreizma@redhat.com>
Mon, 22 Apr 2024 08:33:28 +0000 (08:33 +0000)
Signed-off-by: Matan Breizman <mbreizma@redhat.com>
src/crimson/osd/object_context_loader.cc

index 4f0e2aeff0a4b1cb4a659ac168bdab9181e08427..885231decda946ddc5910c8af59f92d4fbfbf990 100644 (file)
@@ -22,6 +22,10 @@ using crimson::common::local_conf;
       return get_or_load_obc<State>(obc, existed)
       .safe_then_interruptible(
         [func = std::move(func)](auto obc) {
+        // The template with_obc_func_t wrapper supports two obcs (head and clone).
+        // In the 'with_head_obc' case, however, only the head is in use.
+        // Pass the same head obc twice in order to
+        // to support the generic with_obc sturcture.
         return std::move(func)(obc, obc);
       });
     }).finally([FNAME, this, obc=std::move(obc)] {