]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
test/crimson/seastore: teardown in reactor
authorKefu Chai <kchai@redhat.com>
Wed, 19 May 2021 10:02:59 +0000 (18:02 +0800)
committerKefu Chai <kchai@redhat.com>
Thu, 20 May 2021 05:10:03 +0000 (13:10 +0800)
commit9957b046c33b075d66c380862ec22fa0d32f5bd3
tree4305a4f4be862eb46def363ee858d491ec7b1c42
parent3acb2cb53e777e95dfca55e9f374b0a4a322159f
test/crimson/seastore: teardown in reactor

otherwise, we rely on the destructor of TMTestState to teardown the
fixuture created in TMTestState::_init(), but TMTestState::_init() is
called in reactor. the objects like seastar::metric_groups are
supposed to be destroyed on the same thread where they are created.
because they use thread local storage of storing persisting their status.
if we destroy objects like seastar::metric_groups on different reactor
or thread where they are created, we would have memory leak and
unexpected behavior.

Signed-off-by: Kefu Chai <kchai@redhat.com>
src/test/crimson/seastore/transaction_manager_test_state.h