]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
osd: Add snaptrim duration to pg dump stats. 45524/head
authorSridhar Seshasayee <sseshasa@redhat.com>
Mon, 14 Mar 2022 20:08:57 +0000 (01:38 +0530)
committerSridhar Seshasayee <sseshasa@redhat.com>
Sat, 19 Mar 2022 04:48:20 +0000 (10:18 +0530)
commit9542296135fb1e5b26abe192d2477ef777738225
treeda671d7358a901a24247ba260390179ac72742d3
parent5051511e0866de035c3680c41bb1f309ca677d02
osd: Add snaptrim duration to pg dump stats.

Add the snaptrim duration to the json formatted output of the pg dump
stats. Define methods for a PG to set the snaptrim begin time and then to
calculate the total time spent to trim all the objects for the snaps in
the snap_trimq for the PG.

Tests:
  - Librados C and C++ API tests to verify the time spent for a snaptrim
    operation on a PG. These tests use the self-managed snaps APIs.
  - Standalone tests to verify snaptrim duration using rados pool snaps.

Signed-off-by: Sridhar Seshasayee <sseshasa@redhat.com>
(cherry picked from commit a86ead953dc5fa2c78a4fe86700b0c1aba2727af)
qa/standalone/misc/test-snaptrim-stats.sh
src/osd/PG.h
src/osd/PeeringState.cc
src/osd/PrimaryLogPG.cc
src/osd/osd_types.cc
src/osd/osd_types.h
src/test/librados/snapshots_stats.cc
src/test/librados/snapshots_stats_cxx.cc