Skip to content

Commit

Permalink
Fix test suite "TestDataMigrationWhenAlterTtl" (ydb-platform#14420)
Browse files Browse the repository at this point in the history
  • Loading branch information
vlad-gogov authored Feb 12, 2025
1 parent eba58c9 commit dac5bad
Showing 1 changed file with 16 additions and 8 deletions.
24 changes: 16 additions & 8 deletions ydb/tests/olap/ttl_tiering/data_migration_when_alter_ttl.py
Original file line number Diff line number Diff line change
Expand Up @@ -188,14 +188,18 @@ def bucket_is_not_empty(bucket_name):

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

# Wait until bucket1 is empty
if not self.wait_for(
lambda: not bucket_is_not_empty(self.bucket1),
plain_or_under_sanitizer(120, 240), # TODO: change wait time use config "PeriodicWakeupActivationPeriod"
):
raise Exception("Bucket1 is not empty")

# Step 8
t0 = time.time()
stmt = f"""
Expand All @@ -210,10 +214,14 @@ def bucket_is_not_empty(bucket_name):

# Step 9
if not self.wait_for(
lambda: get_rows_in_portion("__DEFAULT") == self.row_count
# TODO: Uncomment after fix https://github.com/ydb-platform/ydb/issues/13616
# and not bucket_is_not_empty(self.bucket1) and not bucket_is_not_empty(self.bucket2)
,
lambda: get_rows_in_portion("__DEFAULT") == self.row_count,
plain_or_under_sanitizer(600, 1200),
):
raise Exception("Data eviction has not been started")

# Wait until buckets are empty
if not self.wait_for(
lambda: not bucket_is_not_empty(self.bucket1) and not bucket_is_not_empty(self.bucket2),
plain_or_under_sanitizer(120, 240), # TODO: change wait time use config "PeriodicWakeupActivationPeriod"
):
raise Exception("Buckets are not empty")

0 comments on commit dac5bad

Please sign in to comment.