Re: JSON headers

In message <>, Julian Reschke writes

>But right now the spec *is* written to use the list construct, and I 
>believe that's a good thing, as it's IMHO better to consider multiple 
>instances as legal, and require the definition of the header field to 
>deal with it.

I think it is a bad thing.

It prevents streaming processing of headers, since you never know
when you have the full picture for a particular header, until you've
received them all and seen that there are no more instances.

It means also means that either you have to rewrite the headers, or
all your code needs to do the brute-force collection scan and handle
an array of headers for further processing.  Both of which is wasteful
in terms of CPU and memory.

I see no advantages that come even close to compensating for those
disadvantages, but if I have overlooked something, please enlighten me...

Poul-Henning Kamp       | UNIX since Zilog Zeus 3.20
phk@FreeBSD.ORG         | TCP/IP since RFC 956
FreeBSD committer       | BSD since 4.3-tahoe    
Never attribute to malice what can adequately be explained by incompetence.

Received on Sunday, 10 July 2016 10:10:52 UTC