diff options
author | ivanmorozov333 <ivanmorozov@ydb.tech> | 2024-11-20 11:34:10 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-11-20 11:34:10 +0300 |
commit | 8357e1ce980525089d6e1d21d8cc4c2505d69a34 (patch) | |
tree | 25ed02af5e4c70e7f68a87c2ad7cc76ba4792058 | |
parent | 509152a5675bc7cef11e90eeb815e3b9936220e1 (diff) | |
download | ydb-8357e1ce980525089d6e1d21d8cc4c2505d69a34.tar.gz |
fix reading logic in case memory control (#11768)
-rw-r--r-- | ydb/core/tx/columnshard/engines/reader/plain_reader/iterator/source.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/ydb/core/tx/columnshard/engines/reader/plain_reader/iterator/source.h b/ydb/core/tx/columnshard/engines/reader/plain_reader/iterator/source.h index 3647bb52a3..563dab4477 100644 --- a/ydb/core/tx/columnshard/engines/reader/plain_reader/iterator/source.h +++ b/ydb/core/tx/columnshard/engines/reader/plain_reader/iterator/source.h @@ -75,6 +75,7 @@ protected: virtual bool DoStartFetchingAccessor(const std::shared_ptr<IDataSource>& sourcePtr, const TFetchingScriptCursor& step) = 0; public: + virtual bool NeedAccessorsForRead() const = 0; virtual bool NeedAccessorsFetching() const = 0; bool StartFetchingAccessor(const std::shared_ptr<IDataSource>& sourcePtr, const TFetchingScriptCursor& step) { @@ -110,7 +111,7 @@ public: void SetSourceInMemory(const bool value) { AFL_VERIFY(!IsSourceInMemoryFlag); IsSourceInMemoryFlag = value; - if (NeedAccessorsFetching()) { + if (NeedAccessorsForRead()) { AFL_VERIFY(StageData); if (!value) { StageData->SetUseFilter(value); @@ -317,6 +318,10 @@ private: virtual bool DoStartFetchingAccessor(const std::shared_ptr<IDataSource>& sourcePtr, const TFetchingScriptCursor& step) override; public: + virtual bool NeedAccessorsForRead() const override { + return true; + } + virtual bool NeedAccessorsFetching() const override { return !StageData || !StageData->HasPortionAccessor(); } @@ -425,6 +430,10 @@ private: } public: + virtual bool NeedAccessorsForRead() const override { + return false; + } + virtual bool NeedAccessorsFetching() const override { return false; } |