You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hbase.apache.org by "stack (JIRA)" <ji...@apache.org> on 2011/07/29 19:00:11 UTC
[jira] [Commented] (HBASE-3581) hbase rpc should send size of
response
[ https://issues.apache.org/jira/browse/HBASE-3581?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13072916#comment-13072916 ]
stack commented on HBASE-3581:
------------------------------
ugh
we should do this for tsdb and asynchbase I'm going to pull it in again (sorry Ted)... we can punt later if it don't make cut.
> hbase rpc should send size of response
> --------------------------------------
>
> Key: HBASE-3581
> URL: https://issues.apache.org/jira/browse/HBASE-3581
> Project: HBase
> Issue Type: Improvement
> Reporter: ryan rawson
> Assignee: ryan rawson
> Priority: Critical
> Fix For: 0.92.0
>
> Attachments: HBASE-rpc-response.txt
>
>
> The RPC reply from Server->Client does not include the size of the payload, it is framed like so:
> <i32> callId
> <byte> errorFlag
> <byte[]> data
> The data segment would contain enough info about how big the response is so that it could be decoded by a writable reader.
> This makes it difficult to write buffering clients, who might read the entire 'data' then pass it to a decoder. While less memory efficient, if you want to easily write block read clients (eg: nio) it would be necessary to send the size along so that the client could snarf into a local buf.
> The new proposal is:
> <i32> callId
> <i32> size
> <byte> errorFlag
> <byte[]> data
> the size being sizeof(data) + sizeof(errorFlag).
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira