Github user jasobrown commented on a diff in the pull request:

    https://github.com/apache/cassandra/pull/253#discussion_r215944830
  
    --- Diff: 
src/java/org/apache/cassandra/net/async/RebufferingByteBufDataInputPlus.java ---
    @@ -183,6 +195,11 @@ public int available() throws EOFException
             return availableBytes;
         }
     
    +    public boolean isEmpty() throws EOFException
    +    {
    +        return available() == 0;
    --- End diff --
    
    Nice find. I added that side effect to 
    [StreamingInboundHandler to help 
deserialization](https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/streaming/async/StreamingInboundHandler.java#L167).
 Clearly, I could move that into a separate method, and have 
`StreamingInboundHandler` invoke that after the `available()` call. wdyt?


---

---------------------------------------------------------------------
To unsubscribe, e-mail: pr-unsubscr...@cassandra.apache.org
For additional commands, e-mail: pr-h...@cassandra.apache.org

Reply via email to