monotone-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Monotone-devel] Re: Automate stdio chunk size


From: Timothy Brownawell
Subject: Re: [Monotone-devel] Re: Automate stdio chunk size
Date: Mon, 10 Jul 2006 12:34:23 -0500

On Mon, 2006-07-10 at 18:50 +0200, Thomas Keller wrote:
> > We can't use an in-stream EOF token, because the stream should be
> > binary-safe. So this means prefixing each data chunk with the size of
> > that chunk. A chunk is output when it reaches the maximum size (because
> > having a known maximum size seems convenient), or when the stream is
> > flushed (my understanding is that this is the Right Thing to do, plus it
> > could be nice if we have commands that take a long time to finish).
> 
> Well, the EOF token wouldn't really have to be '\0', just something a 
> parser could distinguish from the normal output flow. F.e. in emails the 
> header is separated from the body by double newlines \n\n. If basic_io 
> would become standard for all output of the automation interface there 
> could even be some well-defined end token there, like

basic_io is not always appropriate, for example "automate get_file".
This command also means that the output stream can contain arbirtrary
binary data, so no in-stream EOF token would be safe.

Tim






reply via email to

[Prev in Thread] Current Thread [Next in Thread]