Skip to content

Commit 0a3874f

Browse files
authored
[fix](move-memtable) close stream when cancel load stream stub (#38912) (#39039)
backport #38912
1 parent fcdd0cb commit 0a3874f

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

be/src/vec/sink/load_stream_stub.cpp

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -338,6 +338,9 @@ Status LoadStreamStub::close_wait(RuntimeState* state, int64_t timeout_ms) {
338338

339339
void LoadStreamStub::cancel(Status reason) {
340340
LOG(WARNING) << *this << " is cancelled because of " << reason;
341+
if (_is_init.load()) {
342+
brpc::StreamClose(_stream_id);
343+
}
341344
{
342345
std::lock_guard<bthread::Mutex> lock(_cancel_mutex);
343346
_cancel_reason = reason;

0 commit comments

Comments
 (0)