Skip to content

Commit dac5bad

Browse files
author
Vladislav Gogov
authored
Fix test suite "TestDataMigrationWhenAlterTtl" (#14420)
1 parent eba58c9 commit dac5bad

File tree

1 file changed

+16
-8
lines changed

1 file changed

+16
-8
lines changed

ydb/tests/olap/ttl_tiering/data_migration_when_alter_ttl.py

Lines changed: 16 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -188,14 +188,18 @@ def bucket_is_not_empty(bucket_name):
188188

189189
# Step 7
190190
if not self.wait_for(
191-
lambda: get_rows_in_portion(bucket2_path) == self.row_count and bucket_is_not_empty(self.bucket2)
192-
# TODO: Uncomment after fix https://github.com/ydb-platform/ydb/issues/13616
193-
# and not bucket_is_not_empty(self.bucket1)
194-
,
191+
lambda: get_rows_in_portion(bucket2_path) == self.row_count and bucket_is_not_empty(self.bucket2),
195192
plain_or_under_sanitizer(600, 1200),
196193
):
197194
raise Exception("Data eviction has not been started")
198195

196+
# Wait until bucket1 is empty
197+
if not self.wait_for(
198+
lambda: not bucket_is_not_empty(self.bucket1),
199+
plain_or_under_sanitizer(120, 240), # TODO: change wait time use config "PeriodicWakeupActivationPeriod"
200+
):
201+
raise Exception("Bucket1 is not empty")
202+
199203
# Step 8
200204
t0 = time.time()
201205
stmt = f"""
@@ -210,10 +214,14 @@ def bucket_is_not_empty(bucket_name):
210214

211215
# Step 9
212216
if not self.wait_for(
213-
lambda: get_rows_in_portion("__DEFAULT") == self.row_count
214-
# TODO: Uncomment after fix https://github.com/ydb-platform/ydb/issues/13616
215-
# and not bucket_is_not_empty(self.bucket1) and not bucket_is_not_empty(self.bucket2)
216-
,
217+
lambda: get_rows_in_portion("__DEFAULT") == self.row_count,
217218
plain_or_under_sanitizer(600, 1200),
218219
):
219220
raise Exception("Data eviction has not been started")
221+
222+
# Wait until buckets are empty
223+
if not self.wait_for(
224+
lambda: not bucket_is_not_empty(self.bucket1) and not bucket_is_not_empty(self.bucket2),
225+
plain_or_under_sanitizer(120, 240), # TODO: change wait time use config "PeriodicWakeupActivationPeriod"
226+
):
227+
raise Exception("Buckets are not empty")

0 commit comments

Comments
 (0)