-
Notifications
You must be signed in to change notification settings - Fork 3.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[opt](scanner) optimize the number of threads of scanners #28640
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -283,7 +283,7 @@ DECLARE_Bool(doris_enable_scanner_thread_pool_per_disk); | |
DECLARE_mInt64(doris_blocking_priority_queue_wait_timeout_ms); | ||
// number of scanner thread pool size for olap table | ||
// and the min thread num of remote scanner thread pool | ||
DECLARE_Int32(doris_scanner_thread_pool_thread_num); | ||
DECLARE_mInt32(doris_scanner_thread_pool_thread_num); | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I suggest not removing the old config, for compatibility. |
||
// max number of remote scanner thread pool size | ||
// if equal to -1, value is std::max(512, CpuInfo::num_cores() * 10) | ||
DECLARE_Int32(doris_max_remote_scanner_thread_pool_thread_num); | ||
|
@@ -940,6 +940,10 @@ DECLARE_mInt32(parquet_rowgroup_max_buffer_mb); | |
DECLARE_mInt32(parquet_column_max_buffer_mb); | ||
// Merge small IO, the max amplified read ratio | ||
DECLARE_mDouble(max_amplified_read_ratio); | ||
// Equivalent min size of each IO that can reach the maximum storage speed limit | ||
// 1MB for oss, 8KB for hdfs | ||
DECLARE_mInt32(merged_oss_min_io_size); | ||
DECLARE_mInt32(merged_hdfs_min_io_size); | ||
|
||
// OrcReader | ||
DECLARE_mInt32(orc_natural_read_size_mb); | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -122,6 +122,8 @@ Status ScannerScheduler::init(ExecEnv* env) { | |
_remote_thread_pool_max_size = config::doris_max_remote_scanner_thread_pool_thread_num != -1 | ||
? config::doris_max_remote_scanner_thread_pool_thread_num | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
: std::max(512, CpuInfo::num_cores() * 10); | ||
_remote_thread_pool_max_size = | ||
std::max(_remote_thread_pool_max_size, config::doris_scanner_thread_pool_thread_num); | ||
_remote_scan_thread_pool = std::make_unique<PriorityThreadPool>( | ||
_remote_thread_pool_max_size, config::doris_remote_scanner_thread_pool_queue_size, | ||
"RemoteScanThreadPool"); | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
std::max ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if
doris_scanner_thread_pool_thread_num
not set,doris_scanner_thread_pool_thread_num
>= 48