]> git.apps.os.sepia.ceph.com Git - ceph-ci.git/commit
test: add timer loop tests
authorLucian Petrut <lpetrut@cloudbasesolutions.com>
Thu, 4 May 2023 13:16:56 +0000 (13:16 +0000)
committerLucian Petrut <lpetrut@cloudbasesolutions.com>
Wed, 30 Aug 2023 12:59:00 +0000 (12:59 +0000)
commit09a8cb0a6afca48501b36c5c9c2fcaf082860a4c
tree52570e0f1dce4ddef61139bf279191ee689f3bff
parent3ce1e4a5c64bc0d71d3e6ad9ece040e4884d0378
test: add timer loop tests

We've been experiencing timer hangs with mingw-llvm.
std::condition_variable::wait_for was returning a few microseconds
before the requested time and then hanging when called with a
small interval (e.g. microseconds).

This was affecting the OSD periodic tick, which would hang after
a while (20m up to 2h).

The issue can be reproduced with a timer loop and a small interval
(e.g. 40us), in which case the timer is likely to hang after about
10s.

We're adding some tests, while the actual mingw-llvm issue will
be mitigated in a separate commit.

Signed-off-by: Lucian Petrut <lpetrut@cloudbasesolutions.com>
src/test/TestTimers.cc
src/test/common/CMakeLists.txt
src/test/common/test_ceph_timer.cc