Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 11 additions & 1 deletion src/ray/ray_syncer/ray_syncer_bidi_reactor_base.h
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,17 @@ class RaySyncerBidiReactorBase : public RaySyncerBidiReactor, public T {
}

// Successful rpc completion callback.
RAY_CHECK(!msg_batch->messages().empty());
// Note: gRPC may call OnReadDone with ok=true even when the message batch
// is empty in certain edge cases (e.g., connection established but no data
// sent yet, or race conditions).
if (msg_batch->messages().empty()) {
RAY_LOG(DEBUG) << "Received empty message batch from node: "
<< NodeID::FromBinary(GetRemoteNodeID())
<< ", starting next read";
StartPull();
return;
}

if (on_rpc_completion_) {
on_rpc_completion_(NodeID::FromBinary(remote_node_id_));
}
Expand Down