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


##########
be/src/pipeline/exec/hashjoin_build_sink.h:
##########
@@ -155,6 +155,14 @@ class HashJoinBuildSinkOperatorX final
                                               ._should_build_hash_table;
     }
 
+    std::vector<TExpr> get_local_shuffle_exprs() const override { return 
_partition_exprs; }
+    ExchangeType get_local_exchange_type() const override {

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



##########
be/src/pipeline/exec/distinct_streaming_aggregation_sink_operator.h:
##########
@@ -110,6 +110,7 @@ class DistinctStreamingAggSinkOperatorX final
     Status init(const TPlanNode& tnode, RuntimeState* state) override;
     Status sink(RuntimeState* state, vectorized::Block* in_block,
                 SourceState source_state) override;
+    ExchangeType get_local_exchange_type() const override { return 
ExchangeType::PASSTHROUGH; }

Review Comment:
   warning: method 'get_local_exchange_type' can be made static 
[readability-convert-member-functions-to-static]
   
   ```suggestion
       static ExchangeType get_local_exchange_type() override { return 
ExchangeType::PASSTHROUGH; }
   ```
   



##########
be/src/pipeline/pipeline_x/local_exchange/local_exchange_source_operator.h:
##########
@@ -60,10 +60,9 @@ class LocalExchangeSourceLocalState final
 class LocalExchangeSourceOperatorX final : public 
OperatorX<LocalExchangeSourceLocalState> {
 public:
     using Base = OperatorX<LocalExchangeSourceLocalState>;
-    LocalExchangeSourceOperatorX(ObjectPool* pool, int id, OperatorXBase* 
parent)
-            : Base(pool, -1, id), _parent(parent) {}
-    Status init(const TPlanNode& tnode, RuntimeState* state) override {
-        _op_name = "LOCAL_EXCHANGE_OPERATOR";
+    LocalExchangeSourceOperatorX(ObjectPool* pool, int id) : Base(pool, -1, 
id) {}
+    Status init(ExchangeType type) override {

Review Comment:
   warning: method 'init' can be made static 
[readability-convert-member-functions-to-static]
   
   ```suggestion
       static Status init(ExchangeType type) override {
   ```
   



##########
be/src/pipeline/exec/exchange_sink_operator.cpp:
##########
@@ -245,7 +245,7 @@ Status ExchangeSinkLocalState::open(RuntimeState* state) {
     return Status::OK();
 }
 
-std::string ExchangeSinkLocalState::id_name() {
+std::string ExchangeSinkLocalState::name_suffix() {

Review Comment:
   warning: method 'name_suffix' can be made static 
[readability-convert-member-functions-to-static]
   
   be/src/pipeline/exec/exchange_sink_operator.h:186:
   ```diff
   -     std::string name_suffix() override;
   +     static std::string name_suffix() override;
   ```
   



##########
be/src/pipeline/exec/streaming_aggregation_sink_operator.h:
##########
@@ -120,6 +120,7 @@ class StreamingAggSinkOperatorX final : public 
AggSinkOperatorX<StreamingAggSink
     Status init(const TPlanNode& tnode, RuntimeState* state) override;
     Status sink(RuntimeState* state, vectorized::Block* in_block,
                 SourceState source_state) override;
+    ExchangeType get_local_exchange_type() const override { return 
ExchangeType::PASSTHROUGH; }

Review Comment:
   warning: method 'get_local_exchange_type' can be made static 
[readability-convert-member-functions-to-static]
   
   ```suggestion
       static ExchangeType get_local_exchange_type() override { return 
ExchangeType::PASSTHROUGH; }
   ```
   



##########
be/src/pipeline/pipeline_x/pipeline_x_fragment_context.cpp:
##########
@@ -606,49 +634,100 @@ Status 
PipelineXFragmentContext::_create_tree_helper(ObjectPool* pool,
     return Status::OK();
 }
 
-Status PipelineXFragmentContext::_add_local_exchange(ObjectPool* pool, 
OperatorXPtr& op,
-                                                     PipelinePtr& cur_pipe, 
const TPlanNode& tnode,
+Status PipelineXFragmentContext::_add_local_exchange(int idx, int node_id, 
ObjectPool* pool,

Review Comment:
   warning: function '_add_local_exchange' exceeds recommended size/complexity 
thresholds [readability-function-size]
   ```cpp
   Status PipelineXFragmentContext::_add_local_exchange(int idx, int node_id, 
ObjectPool* pool,
                                    ^
   ```
   <details>
   <summary>Additional context</summary>
   
   **be/src/pipeline/pipeline_x/pipeline_x_fragment_context.cpp:636:** 91 lines 
including whitespace and comments (threshold 80)
   ```cpp
   Status PipelineXFragmentContext::_add_local_exchange(int idx, int node_id, 
ObjectPool* pool,
                                    ^
   ```
   
   </details>
   



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