github-actions[bot] commented on code in PR #65404:
URL: https://github.com/apache/doris/pull/65404#discussion_r3631047719
##########
be/src/exec/scan/file_scanner.cpp:
##########
@@ -997,8 +997,15 @@ void
FileScanner::_fill_base_init_context(ReaderInitContext* ctx) {
Status FileScanner::_get_next_reader() {
while (true) {
if (_cur_reader) {
- _cur_reader->collect_profile_before_close();
- RETURN_IF_ERROR(_cur_reader->close());
+ if (auto* paimon_jni_reader =
dynamic_cast<PaimonJniReader*>(_cur_reader.get());
Review Comment:
[P2] Keep Paimon reuse active for table-level COUNT splits
For a Paimon `COUNT(*)` split with `table_level_row_count`,
`prepare_split()` skips Java split setup, but the scanner later wraps this
reader in an owning `CountReader`. On the next range this top-level cast
therefore fails, the wrapper closes its inner `PaimonJniReader`, and the
following split constructs another Java scanner. Thus the common metadata-count
path still pays the per-split scanner/table setup this change is intended to
remove, and the direct reader test does not exercise this decorator transition.
Please preserve or avoid opening the Paimon reader on this path and cover two
count splits through `FileScanner`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]