]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
crimson/osd/pg: SnapTrimEvent to support interrupts
authorXuehan Xu <xuxuehan@qianxin.com>
Thu, 25 Apr 2024 05:56:25 +0000 (13:56 +0800)
committerMatan Breizman <mbreizma@redhat.com>
Tue, 21 May 2024 12:50:35 +0000 (15:50 +0300)
commit168dbf16d9eceed6b3c0a22b485fb0a30930d1f6
tree1072216c56401c81a32e9fb99e57db815edcd260
parent045878a2cfb5555180523ecf7a4341a84e9b613e
crimson/osd/pg: SnapTrimEvent to support interrupts

SnapTrimEvent operations are scheduled from `PG::on_active_actmap()`
using a `seastar::do_until` loop. This commit replaces the loop type
into an `interruptor::repeat` and SnapTrimEvent are now scheduled by
`start_operation_may_interrupt`.

Previously, `SnapTrimEvent::start` handled interruptions by returning
a `crimson::ct_error::eagain::make();`. Now, the errorator is directly
returned via the `snap_trim_event_ret_t` and interrupts the loop
described above.

As a result, interruptions originated by interval changes are now
supported by SnapTrimEvent.

---

*** Manual conflict ***
The following PR is not included in S:
https://github.com/ceph/ceph/pull/55645/commits/6d561092faf1af5158f438af2a585197bf44683e

This backported commit had to manually revert some of the changes introduced by #55645.
Specially, crimson/osd/osd_operations/snaptrim_event.cc

Cherry-picked from: a4ddf6cfc88619f1f50f75a079af5f39f5167a46

Signed-off-by: Xuehan Xu <xuxuehan@qianxin.com>
src/crimson/osd/osd_operations/snaptrim_event.cc
src/crimson/osd/osd_operations/snaptrim_event.h
src/crimson/osd/pg.cc
src/crimson/osd/pg.h