@Override
  public int getBytesRemainingInBuffer() {
    // return -1 can make the caller protocol to copy binary data from the underlying transport.
    return copyBinary ? -1 : readBuffer.getBytesRemainingInBuffer();
  }
When copyBinary flag is true, the transport will copy the binary data from the underlying.
This is a protection for the underlying buffer to be reused by the caller protocol.
iotdb-client/service-rpc/src/main/java/org/apache/iotdb/rpc/TElasticFramedTransport.java