diff options
author | hcpp <hcpp@ydb.tech> | 2023-11-23 16:05:43 +0300 |
---|---|---|
committer | hcpp <hcpp@ydb.tech> | 2023-11-23 16:55:11 +0300 |
commit | 5aecdb67595db1a47c933b7d8da2cb662a50e185 (patch) | |
tree | bac6ecf89b0a8763c7febeb1731e1b5c56f56780 | |
parent | b07264456a2e8b5929901f258ad60399bb64678a (diff) | |
download | ydb-5aecdb67595db1a47c933b7d8da2cb662a50e185.tar.gz |
sub issues have been fixed
-rw-r--r-- | ydb/core/fq/libs/control_plane_storage/internal/task_ping.cpp | 2 | ||||
-rw-r--r-- | ydb/tests/fq/restarts/test_insert_restarts.py | 15 |
2 files changed, 15 insertions, 2 deletions
diff --git a/ydb/core/fq/libs/control_plane_storage/internal/task_ping.cpp b/ydb/core/fq/libs/control_plane_storage/internal/task_ping.cpp index 004e90b8aa..f1e987e8f1 100644 --- a/ydb/core/fq/libs/control_plane_storage/internal/task_ping.cpp +++ b/ydb/core/fq/libs/control_plane_storage/internal/task_ping.cpp @@ -184,7 +184,7 @@ TPingTaskParams ConstructHardPingTask( builder << " at " << Now(); // in case of problems with finalization, do not change the issues - if (query.meta().status() == FederatedQuery::QueryMeta::FAILING) { + if (query.meta().status() == FederatedQuery::QueryMeta::FAILING || query.meta().status() == FederatedQuery::QueryMeta::ABORTING_BY_SYSTEM || query.meta().status() == FederatedQuery::QueryMeta::ABORTING_BY_USER) { if (issues) { transientIssues->AddIssues(*issues); } diff --git a/ydb/tests/fq/restarts/test_insert_restarts.py b/ydb/tests/fq/restarts/test_insert_restarts.py index 9a8d9678e7..dfc154dd12 100644 --- a/ydb/tests/fq/restarts/test_insert_restarts.py +++ b/ydb/tests/fq/restarts/test_insert_restarts.py @@ -13,6 +13,12 @@ from ydb.tests.tools.fq_runner.kikimr_utils import yq_all class TestS3(object): + def get_issues_depth(self, issues): + deepest_path_size = 0 + for issue in issues: + deepest_path_size = max(self.get_issues_depth(issue.issues), deepest_path_size) + return deepest_path_size + 1 + def run_atomic_upload_check_query(self, client, bucket, connection, prefix, format): if len(list(bucket.objects.filter(Prefix=prefix))) == 0: return 0 @@ -90,13 +96,20 @@ class TestS3(object): client.wait_query(query_id, statuses=[fq.QueryMeta.COMPLETED, fq.QueryMeta.ABORTED_BY_SYSTEM, fq.QueryMeta.FAILED], timeout=timeout) final_number_rows = self.run_atomic_upload_check_query(client, bucket, "ibucket", "insert/", "csv_with_names") - final_status = client.describe_query(query_id).result.query.meta.status + query = client.describe_query(query_id).result.query + final_status = query.meta.status if final_status == fq.QueryMeta.COMPLETED: assert final_number_rows == number_rows, "Invalid result in bucket for COMPLETED final status" elif final_status == fq.QueryMeta.ABORTED_BY_SYSTEM: + assert self.get_issues_depth(query.issue) <= 3, str(query.issue) + assert self.get_issues_depth(query.transient_issue) <= 3, str(query.transient_issue) + assert "Query failed with code UNAVAILABLE at" in query.issue[0].message, query.issue[0].message assert final_number_rows == 0, "Incomplete final result in bucket" else: + assert self.get_issues_depth(query.issue) <= 3, str(query.issue) + assert self.get_issues_depth(query.transient_issue) <= 3, str(query.transient_issue) + assert "Query failed with code UNAVAILABLE at" in query.issue[0].message, query.issue[0].message assert final_number_rows == 0 or final_number_rows == number_rows assert len(list(bucket.multipart_uploads.all())) == 0, "Unexpected uncommited upload in bucket" |