]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-ci.git/commitdiff
librbd: fix RequestLockPayload log message in ImageWatcher
authorIlya Dryomov <idryomov@gmail.com>
Mon, 22 Dec 2025 18:07:27 +0000 (19:07 +0100)
committerIlya Dryomov <idryomov@gmail.com>
Thu, 12 Feb 2026 17:04:09 +0000 (18:04 +0100)
exclusive_lock::Policy::lock_requested() isn't guaranteed to queue
the release of exclusive lock (and in fact only one of the two existing
implementations does that).  Instead of talking about the lock, log the
response to the notification.

Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
(cherry picked from commit ff89abf5ddcca91c34cfd46d288d41fe93ec38b0)

src/librbd/ImageWatcher.cc

index 69e8403af83837a4e7de8fa7fa7355a1b68a4fc2..a9908efb2a9db6c9bbce7e4e904e88e8ae89e1b7 100644 (file)
@@ -1065,11 +1065,11 @@ bool ImageWatcher<I>::handle_payload(const RequestLockPayload &payload,
         return true;
       }
 
-      ldout(m_image_ctx.cct, 10) << this << " queuing release of exclusive lock"
-                                 << dendl;
+      // potentially queue release of exclusive lock
       r = m_image_ctx.get_exclusive_lock_policy()->lock_requested(
         payload.force);
     }
+    ldout(m_image_ctx.cct, 10) << this << " responding with r=" << r << dendl;
     encode(ResponseMessage(r), ack_ctx->out);
   }
   return true;