[ 
https://issues.apache.org/jira/browse/THRIFT-704?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

James E. King, III updated THRIFT-704:
--------------------------------------
    Component/s: C++ - Library

> Compact Protocol improvement: combine sequence of multiple STOP fields 
> together
> -------------------------------------------------------------------------------
>
>                 Key: THRIFT-704
>                 URL: https://issues.apache.org/jira/browse/THRIFT-704
>             Project: Thrift
>          Issue Type: Improvement
>          Components: C++ - Library
>    Affects Versions: 0.2
>            Reporter: Bryan Duxbury
>            Assignee: Bryan Duxbury
>
> One thing I've noticed looking at some of our compact-protocol-serialized 
> structs is that we often have a sequence of STOP markers at the end of the 
> stream. This occurs when you have a relatively deep object tree - once you 
> are done serializing the last "leaf" object, you will write out a number of 
> STOP fields equal to the height of the tree. Strictly speaking, there will be 
> benefit found in the last leaf node of every subtree, not just the last leaf 
> node of the entire tree.
> It should be possible to compress these STOPs together by packing a count 
> into a single STOP. Then, when reading, the protocol can sort of pre-buffer 
> the correct number of STOPs. These changes would leave the protocol 
> implementation backwards compatible from the reading perspective, but not 
> from the writing perspective. As such, I would probably add a flag to enable 
> and disable this behavior when writing. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to