Skip to content

Commit 7e08760

Browse files
committed
mds: add the event when creating the batch head
This could help us the debug the slow request or deadlock bugs and we could know which stage the request has been in. Fixes: https://tracker.ceph.com/issues/67280 Signed-off-by: Xiubo Li <[email protected]>
1 parent 5d8aa52 commit 7e08760

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/mds/Server.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4135,6 +4135,7 @@ void Server::handle_client_getattr(const MDRequestRef& mdr, bool is_lookup)
41354135
auto em = dn->batch_ops.emplace(std::piecewise_construct, std::forward_as_tuple(mask), std::forward_as_tuple());
41364136
if (em.second) {
41374137
em.first->second = std::make_unique<Batch_Getattr_Lookup>(this, mdr);
4138+
mdr->mark_event("creating lookup batch head");
41384139
} else {
41394140
dout(20) << __func__ << ": LOOKUP op, wait for previous same getattr ops to respond. " << *mdr << dendl;
41404141
em.first->second->add_request(mdr);
@@ -4147,6 +4148,7 @@ void Server::handle_client_getattr(const MDRequestRef& mdr, bool is_lookup)
41474148
auto em = in->batch_ops.emplace(std::piecewise_construct, std::forward_as_tuple(mask), std::forward_as_tuple());
41484149
if (em.second) {
41494150
em.first->second = std::make_unique<Batch_Getattr_Lookup>(this, mdr);
4151+
mdr->mark_event("creating getattr batch head");
41504152
} else {
41514153
dout(20) << __func__ << ": GETATTR op, wait for previous same getattr ops to respond. " << *mdr << dendl;
41524154
em.first->second->add_request(mdr);

0 commit comments

Comments
 (0)