On Apr 3, 8:08 pm, Kenton Varda <ken...@google.com> wrote:
> I'm guessing you enabled some kind of compression for the FI encoding?  Note
> that protocol buffers, while compact, do not actually apply any sort of
> compression themselves.  For repetitive data or data containing a lot of
> text strings, applying zlib compression to the encoded message can make it
> much smaller.

The Fast Infoset standard does not specify the use of GZIP or any
other compression algorithm within an FI document. Compression may
optionally be applied *after* the encoding, the same as with text XML
or any other type of document. However, FI does include a simple
vocabulary mechanism that reduces redundancy and which can be very
effective when there are repeating values within a document.

> I don't actually know much about FI.  My guess based on reading some
> descriptions of FI is that PB is similar to FI's non-self-describing,
> no-compression mode.

FI documents generated by FI Converter are always self-describing. The
FI standard does specify the use of an external vocabulary but AFAIK
this feature is rarely used. So anyone can decode an FI document back
to its original XML Infoset without any loss of information -- and
without requiring access to a schema or any other knowledge of the
original dataset.

> I would also guess that because XML is a much more
> complicated format than protocol buffers, FI probably has more overhead when
> encoding simple structured data, especially number-heavy data.  For
> string-heavy data, though, XML works pretty well and so this overhead may
> not be an issue in that case.

Yes, processing-wise protocol buffers is faster than both the text XML
and the FI encodings (and I would expect the same to be true for any
other XML encoding). That's because protocol buffers has a simpler job
to do than encoding XML. If processing performance is the major
concern and XML interoperability and self-description are of no
importance, then protocol buffers is a good option to consider.

Alexander
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to protobuf@googlegroups.com
To unsubscribe from this group, send email to 
protobuf+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/protobuf?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to