]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph.git/commit
test/crimson/test_crimson_coroutine: introduce repeat example 66637/head
authorMatan Breizman <mbreizma@redhat.com>
Mon, 15 Dec 2025 12:39:49 +0000 (12:39 +0000)
committerMatan Breizman <mbreizma@redhat.com>
Mon, 15 Dec 2025 16:25:57 +0000 (18:25 +0200)
commita02f6b037109bfda14d1e644f5dadc5a5f59c278
treeb08d8f648957bbcee06af3af5060b789df3a230b
parent86840cd7e157707efbdafd2e460d8bc60d6dd8ac
test/crimson/test_crimson_coroutine: introduce repeat example

interruptible repeat methods use internally seastar::repeat which
require passing a seastar::stop_iteration.
Using coroutines, it's far nicer to use primitive for/while
loops with interrutible futures inside.

Adding interruptible_coroutine_interrupted_repeat as an example.
to a discussion from https://github.com/ceph/ceph/pull/65157

Signed-off-by: Matan Breizman <mbreizma@redhat.com>
src/test/crimson/test_crimson_coroutine.cc