From 90d22eb9ea37f02d55d5a7cd171ad1f8c0874a7c Mon Sep 17 00:00:00 2001 From: myoungwon oh Date: Tue, 12 Oct 2021 12:09:22 +0900 Subject: [PATCH] test: increase retry duration when calculating manifest ref. count In situation where the object is degraded and delayed, retry time can expire before the object is recovered ---it takes almost 6 minutes to be recovered according to the log. Fixes: https://tracker.ceph.com/issues/52872 Signed-off-by: Myoungwon Oh (cherry picked from 82bcf9b57fc4939677ef1af20a1a3fa258243a37) --- src/test/librados/tier_cxx.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/test/librados/tier_cxx.cc b/src/test/librados/tier_cxx.cc index b5032e9afb35c..51e3b3aa9c716 100644 --- a/src/test/librados/tier_cxx.cc +++ b/src/test/librados/tier_cxx.cc @@ -179,7 +179,8 @@ void is_intended_refcount_state(librados::IoCtx& src_ioctx, } dst_refcount = refs.count(); } - for (int tries = 0; tries < 10; ++tries) { + int tries = 0; + for (; tries < 30; ++tries) { r = cls_cas_references_chunk(src_ioctx, src_oid, dst_oid); if (r == -ENOENT || r == -ENOLINK) { src_refcount = 0; @@ -191,6 +192,7 @@ void is_intended_refcount_state(librados::IoCtx& src_ioctx, } break; } + ASSERT_TRUE(tries < 30); ASSERT_TRUE(src_refcount >= 0); ASSERT_TRUE(src_refcount == expected_refcount); ASSERT_TRUE(src_refcount <= dst_refcount); -- 2.39.5