[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: [ANN] tnetstrings.lua 1.0.0
- From: Josh Simmons <simmons.44@...>
- Date: Mon, 6 Jun 2011 01:12:04 +1000
On Mon, Jun 6, 2011 at 1:07 AM, Michal Kottman <k0mpjut0r@gmail.com> wrote:
> On Sun, 2011-06-05 at 15:27 +0200, Florian Weimer wrote:
>> > * Fast and low resource intensive.
>>
>> The format requires buffering all data before decoding can start.
>> This means that decoding arbitrary messages requires unbounded
>> storage.
>
> I wonder why the decision to have TYPE specification of the tnetstring
> at the end? It could be decoded without buffering if the type was
> specified at the beginning of the payload, similar to the bencode used
> by BitTorrent.
>
Because it's backwards compatible with this:
http://cr.yp.to/proto/netstrings.txt
Personally I like the idea of using the type code as the separator.