From 58fcacbd537e2c59d3ceef2069459657f295e271 Mon Sep 17 00:00:00 2001 From: Varsha Rao Date: Wed, 28 Aug 2019 13:07:32 +0530 Subject: [PATCH] client/MetaRequest: Add age to MetaRequest dump Fixes: https://tracker.ceph.com/issues/40821 Signed-off-by: Varsha Rao (cherry picked from commit 7af024345a8c5ef7d65401713fc73eed9ea9c6bb) --- src/client/MetaRequest.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/client/MetaRequest.cc b/src/client/MetaRequest.cc index b6574def51721..623b0f254ab7f 100644 --- a/src/client/MetaRequest.cc +++ b/src/client/MetaRequest.cc @@ -10,6 +10,8 @@ void MetaRequest::dump(Formatter *f) const { + auto age = std::chrono::duration(ceph_clock_now() - op_stamp); + f->dump_unsigned("tid", tid); f->dump_string("op", ceph_mds_op_name(head.op)); f->dump_stream("path") << path; @@ -29,6 +31,7 @@ void MetaRequest::dump(Formatter *f) const f->dump_stream("hint_ino") << inodeno_t(head.ino); f->dump_stream("sent_stamp") << sent_stamp; + f->dump_float("age", age.count()); f->dump_int("mds", mds); f->dump_int("resend_mds", resend_mds); f->dump_int("send_to_auth", send_to_auth); -- 2.39.5