dataroaring commented on code in PR #53408:
URL: https://github.com/apache/doris/pull/53408#discussion_r2213410027


##########
be/src/olap/olap_server.cpp:
##########
@@ -684,6 +684,24 @@ void StorageEngine::_compaction_tasks_producer_callback() {
                     last_base_score_update_time = cur_time;
                 }
             }
+            std::unique_ptr<ThreadPool>& thread_pool =
+                    (compaction_type == CompactionType::CUMULATIVE_COMPACTION)
+                            ? _cumu_compaction_thread_pool
+                            : _base_compaction_thread_pool;
+            // If all tasks in the thread pool queue are executed,
+            // double the number of tasks generated each time,
+            // with a maximum of 64 tasks per generation.
+            if (thread_pool->get_queue_size() == 0) {
+                if (_compaction_num_per_round < 64) {
+                    _compaction_num_per_round *= 2;

Review Comment:
   max should be a config.



-- 
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]

Reply via email to