Skip to content

Commit fc0279b

Browse files
authored
[minor](log) Delete useless logics checking (#41589)
1 parent 3eb24bf commit fc0279b

File tree

2 files changed

+2
-25
lines changed

2 files changed

+2
-25
lines changed

be/src/pipeline/local_exchange/local_exchange_sink_operator.cpp

+2-23
Original file line numberDiff line numberDiff line change
@@ -104,33 +104,14 @@ Status LocalExchangeSinkLocalState::open(RuntimeState* state) {
104104
return Status::OK();
105105
}
106106

107-
Status LocalExchangeSinkLocalState::close(RuntimeState* state, Status exec_status) {
108-
if (_closed) {
109-
return Status::OK();
110-
}
111-
RETURN_IF_ERROR(Base::close(state, exec_status));
112-
if (exec_status.ok()) {
113-
DCHECK(_release_count || _exchanger == nullptr ||
114-
_exchanger->_running_source_operators == 0)
115-
<< "Do not finish correctly! " << debug_string(0)
116-
<< " state: { cancel = " << state->is_cancelled() << ", "
117-
<< state->cancel_reason().to_string()
118-
<< "} query ctx: { cancel = " << state->get_query_ctx()->is_cancelled() << ", "
119-
<< state->get_query_ctx()->exec_status().to_string()
120-
<< "} Exchanger: " << (void*)_exchanger;
121-
}
122-
return Status::OK();
123-
}
124-
125107
std::string LocalExchangeSinkLocalState::debug_string(int indentation_level) const {
126108
fmt::memory_buffer debug_string_buffer;
127109
fmt::format_to(debug_string_buffer,
128110
"{}, _channel_id: {}, _num_partitions: {}, _num_senders: {}, _num_sources: {}, "
129-
"_running_sink_operators: {}, _running_source_operators: {}, _release_count: {}",
111+
"_running_sink_operators: {}, _running_source_operators: {}",
130112
Base::debug_string(indentation_level), _channel_id, _exchanger->_num_partitions,
131113
_exchanger->_num_senders, _exchanger->_num_sources,
132-
_exchanger->_running_sink_operators, _exchanger->_running_source_operators,
133-
_release_count);
114+
_exchanger->_running_sink_operators, _exchanger->_running_source_operators);
134115
return fmt::to_string(debug_string_buffer);
135116
}
136117

@@ -143,13 +124,11 @@ Status LocalExchangeSinkOperatorX::sink(RuntimeState* state, vectorized::Block*
143124

144125
// If all exchange sources ended due to limit reached, current task should also finish
145126
if (local_state._exchanger->_running_source_operators == 0) {
146-
local_state._release_count = true;
147127
local_state._shared_state->sub_running_sink_operators();
148128
return Status::EndOfFile("receiver eof");
149129
}
150130
if (eos) {
151131
local_state._shared_state->sub_running_sink_operators();
152-
local_state._release_count = true;
153132
}
154133

155134
return Status::OK();

be/src/pipeline/local_exchange/local_exchange_sink_operator.h

-2
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,6 @@ class LocalExchangeSinkLocalState final : public PipelineXSinkLocalState<LocalEx
4343

4444
Status init(RuntimeState* state, LocalSinkStateInfo& info) override;
4545
Status open(RuntimeState* state) override;
46-
Status close(RuntimeState* state, Status exec_status) override;
4746
std::string debug_string(int indentation_level) const override;
4847
std::vector<Dependency*> dependencies() const override;
4948

@@ -69,7 +68,6 @@ class LocalExchangeSinkLocalState final : public PipelineXSinkLocalState<LocalEx
6968

7069
// Used by random passthrough exchanger
7170
int _channel_id = 0;
72-
bool _release_count = false;
7371
};
7472

7573
// A single 32-bit division on a recent x64 processor has a throughput of one instruction every six cycles with a latency of 26 cycles.

0 commit comments

Comments
 (0)