Your solution of trying to parse after each byte received is not just slow,
it's completely incorrect. It's entirely possible, and quite likely, that
if you break the encoded version of a message in half, each half will parse
successfully on its own, but the contents of the message will be incorrect.
On Thu, Sep 2, 2010 at 7:29 AM, Jean-Sebastien Stoezel <js.stoe...@gmail.com
> Thanks for the status update. I guess I will be reusing the message
> delimiter I had developed a couple of years ago =].
> On Aug 26, 12:49 pm, Evan Jones <ev...@mit.edu> wrote:
> > On Aug 26, 2010, at 12:07 , Jean-Sebastien Stoezel wrote:
> > > More specifically how they are parsed from real time datastreams?
> > You should manually insert a leading "length of next message" field
> > into the data stream. The Java implementation even has a shortcut
> > methods for this (see below). In C++ you have to implement it
> > yourself, but it is only a few lines of code.
> > See:
> > http://code.google.com/apis/protocolbuffers/docs/techniques.html#stre...
> > Evan
> > --
> > Evan Joneshttp://evanjones.ca/
> You received this message because you are subscribed to the Google Groups
> "Protocol Buffers" group.
> To post to this group, send email to proto...@googlegroups.com.
> To unsubscribe from this group, send email to
> For more options, visit this group at
You received this message because you are subscribed to the Google Groups
"Protocol Buffers" group.
To post to this group, send email to proto...@googlegroups.com.
To unsubscribe from this group, send email to
For more options, visit this group at