Skip to content
Closed
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
Original file line number Diff line number Diff line change
Expand Up @@ -261,11 +261,16 @@ public ByteBuffer sendRpcSync(ByteBuffer message, long timeoutMs) throws IOExcep
new RpcResponseCallback() {
@Override
public void onSuccess(ByteBuffer response) {
ByteBuffer copy = ByteBuffer.allocate(response.remaining());
copy.put(response);
// flip "copy" to make it readable
copy.flip();
result.set(copy);
try {
ByteBuffer copy = ByteBuffer.allocate(response.remaining());
copy.put(response);
// flip "copy" to make it readable
copy.flip();
result.set(copy);
} catch (Throwable t) {
logger.warn("Error in responding RPC callback", t);
result.setException(t);
}
}

@Override
Expand Down