Dan/Elizabeth,

Thank you for considering my response, let me rephrase and then
I'll go back to my own list (*grins*).

On Tue, Oct 21, 2003 at 09:25:48PM +0200, Elizabeth Mattijsen wrote:
| At 15:18 -0400 10/21/03, Dan Sugalski wrote:
| >On Tue, 21 Oct 2003, Clark C. Evans wrote:
| > > If you are going to go this far (including content-length) may I
| > > just suggest using a MIME envelope?  This has several advantages:
| >This is a very good idea, but not this time, as it's too easy to get stuck
| >in the endless churn of very good ideas and alternatives.

I should have just suggested RFC822 like headers (used by E-Mail 
and HTTP) and not imply that MIME, with its multi-part and encoding
glory need be supported.   In other words, the header could simply be:

   Parrot-version: 0.3
   Content-type: binary/parrot        <- or text/yaml, text/xml
   Content-length: 49384
                                      <- blank line   
   (binary payload)

This has the advantages of:
  (a) satisifies mentioned requirements: version, type, and size
  (a) easy to parse, well known syntax
  (b) fits in well with Intranet infrastructure
  (c) easy to extend down the road, ie, more headers can be added

| I would think the MIME-envelope would have to be part of the data, 
| rather than in the header.  Or am I missing anything?  It's 
| encode/decoder determined, is it not?

Well, it seemed you were making an 'envelope', and this is
exactly what RFC822 is all about.  In particular, all of the
items you wanted to put in your header could be done easily
with RFC822. 

| >The simple header format, without the null byte (taking it out is a good
| >idea, since we may have the possibility of an all-text file in that case),
| 
| I have no particular feeling about the null byte.  It would just be a 
| convenience when debugging as it would allow you to just print the 
| string, as it would be null-delimited.  The CRLF (or just the CR or 
| just the LF) could serve as an end of header marker just as well.

RFC822 uses a "blank line", that is two adjacent "CRLF" items to 
mark the end of the header.

Back to the YAML list... sorry for interloping!

Clark

Reply via email to