diff options
author | hor911 <hor911@yandex-team.ru> | 2022-03-16 16:20:36 +0300 |
---|---|---|
committer | hor911 <hor911@yandex-team.ru> | 2022-03-16 16:20:36 +0300 |
commit | c5767d9ab2afc4d5e62f34a721146c78b950b6a1 (patch) | |
tree | a6399396b13a05ce158ac5d41e71e248475dd27f | |
parent | 27a5cd41211b4830645af09a405fec8d1d0c020e (diff) | |
download | ydb-c5767d9ab2afc4d5e62f34a721146c78b950b6a1.tar.gz |
Don't retry minikql Terminate()
ref:8294599c923626ee675eace43f03dd9f2b5f0a80
-rw-r--r-- | ydb/library/yql/dq/actors/compute/dq_compute_actor_impl.h | 3 | ||||
-rw-r--r-- | ydb/library/yql/providers/dq/actors/task_controller.cpp | 9 |
2 files changed, 10 insertions, 2 deletions
diff --git a/ydb/library/yql/dq/actors/compute/dq_compute_actor_impl.h b/ydb/library/yql/dq/actors/compute/dq_compute_actor_impl.h index c9f58160f6d..efb1889d5ab 100644 --- a/ydb/library/yql/dq/actors/compute/dq_compute_actor_impl.h +++ b/ydb/library/yql/dq/actors/compute/dq_compute_actor_impl.h @@ -212,7 +212,8 @@ protected: << ", host: " << HostName() << ", canAllocateExtraMemory: " << CanAllocateExtraMemory); } catch (const std::exception& e) { - InternalError(TIssuesIds::DEFAULT_ERROR, e.what()); + const TString message = e.what(); + InternalError(message.find("Terminate was called, reason(") != TString::npos ? TIssuesIds::UNEXPECTED : TIssuesIds::DEFAULT_ERROR, message); } if (reportTime) { diff --git a/ydb/library/yql/providers/dq/actors/task_controller.cpp b/ydb/library/yql/providers/dq/actors/task_controller.cpp index 83996830524..1cde6e7e942 100644 --- a/ydb/library/yql/providers/dq/actors/task_controller.cpp +++ b/ydb/library/yql/providers/dq/actors/task_controller.cpp @@ -139,7 +139,14 @@ private: case NDqProto::COMPUTE_STATE_FAILURE: { // TODO: don't convert issues to string NYql::IssuesFromMessage(state.GetIssues(), Issues); - OnError(Issues, true, false); + bool retriable = true; + for (const auto& issue : Issues) { + if (issue.IssueCode == TIssuesIds::UNEXPECTED) { + retriable = false; + break; + } + } + OnError(Issues, retriable, false); break; } case NDqProto::COMPUTE_STATE_EXECUTING: { |