[ 
https://issues.apache.org/jira/browse/THRIFT-110?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12638177#action_12638177
 ] 

noble.paul edited comment on THRIFT-110 at 10/8/08 8:31 PM:
------------------------------------------------------------

bq.As distasteful as it would to me to have to separate generated code paths 
for driving the traditional and compact protocols

'If possible' we must use the same API . It will relieve us from touching the 
codegen part. But ,  how do we know which all fields are present when a 
writeStructBegin()is invoked. As it is the API is not a very convenient one for 
the current protocol also because it does not use most of the methods

      was (Author: noble.paul):
    bq.As distasteful as it would to me to have to separate generated code 
paths for driving the traditional and compact protocols

'If possible' we must use the same API . It will relieve us from touching the 
codegen part. I guess making the new Protocol stateful can solve a lot of 
problems. 
  
> A more compact format 
> ----------------------
>
>                 Key: THRIFT-110
>                 URL: https://issues.apache.org/jira/browse/THRIFT-110
>             Project: Thrift
>          Issue Type: Improvement
>            Reporter: Noble Paul
>         Attachments: compact_proto_spec.txt, compact_proto_spec.txt
>
>
> Thrift is not very compact in writing out data as (say protobuf) . It does 
> not have the concept of variable length integers and various other 
> optimizations possible . In Solr we use a lot of such optimizations to make a 
> very compact payload. Thrift has a lot common with that format.
> It is all done in a single class
> http://svn.apache.org/viewvc/lucene/solr/trunk/src/java/org/apache/solr/common/util/NamedListCodec.java?revision=685640&view=markup
> The other optimizations include writing type/value  in same byte, very fast 
> writes of Strings, externalizable strings etc 
> We could use a thrift format for non-java clients and I would like to see it 
> as compact as the current java version

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to