github-actions[bot] commented on code in PR #26772:
URL: https://github.com/apache/doris/pull/26772#discussion_r1389201420


##########
be/src/vec/exec/scan/scanner_context.h:
##########
@@ -145,25 +145,19 @@
     virtual bool empty_in_queue(int id);
 
     // todo(wb) rethinking how to calculate ```_max_bytes_in_queue``` when 
executing shared scan
-    inline bool should_be_scheduled() const {
-        return (_cur_bytes_in_queue < _max_bytes_in_queue / 2) &&
-               (_serving_blocks_num < allowed_blocks_num());
+    virtual inline bool has_enough_space_in_blocks_queue() const {
+        return _cur_bytes_in_queue < _max_bytes_in_queue / 2;
     }
 
-    int get_available_thread_slot_num() {
+    int cal_thread_slot_num_by_free_block_num() {

Review Comment:
   warning: method 'cal_thread_slot_num_by_free_block_num' can be made static 
[readability-convert-member-functions-to-static]
   
   ```suggestion
       static int cal_thread_slot_num_by_free_block_num() {
   ```
   



##########
be/src/vec/exec/scan/scanner_context.h:
##########
@@ -74,13 +74,13 @@ class ScannerContext {
     ScannerContext(RuntimeState* state_, VScanNode* parent,
                    const TupleDescriptor* output_tuple_desc,
                    const std::list<VScannerSPtr>& scanners_, int64_t limit_,
-                   int64_t max_bytes_in_blocks_queue_, const int 
num_parallel_instances = 1,
+                   int64_t max_bytes_in_blocks_queue_, const int 
num_parallel_instances = 0,

Review Comment:
   warning: parameter 'num_parallel_instances' is const-qualified in the 
function declaration; const-qualification of parameters only has an effect in 
function definitions [readability-avoid-const-params-in-decls]
   
   ```suggestion
                      int64_t max_bytes_in_blocks_queue_, int 
num_parallel_instances = 0,
   ```
   



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