mrhhsg commented on code in PR #23981: URL: https://github.com/apache/doris/pull/23981#discussion_r1318023637
########## be/src/vec/exec/scan/new_olap_scanner.cpp: ########## @@ -412,7 +412,7 @@ Status NewOlapScanner::_init_tablet_reader_params( } } - if (!config::disable_storage_page_cache) { + if (_state->enable_page_cache()) { _tablet_reader_params.use_page_cache = true; } Review Comment: ```cpp _tablet_reader_params.use_page_cache = _state->enable_page_cache(); ``` ########## be/src/runtime/runtime_state.h: ########## @@ -352,6 +352,8 @@ class RuntimeState { return _query_options.__isset.skip_delete_bitmap && _query_options.skip_delete_bitmap; } + bool enable_page_cache() const { return _query_options.enable_page_cache; } Review Comment: ```cpp return _query_options.__isset.enable_page_cache && _query_options.enable_page_cache; ``` And here, it may be necessary to consider the default value: ```cpp return _query_options.__isset.enable_page_cache ? _query_options.enable_page_cache : !config::disable_storage_page_cache; ``` -- 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: commits-unsubscr...@doris.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: commits-unsubscr...@doris.apache.org For additional commands, e-mail: commits-h...@doris.apache.org