Re: [MERGE] Support large response headers

From: Henrik Nordstrom <henrik@dont-contact.us>
Date: Sun, 06 Apr 2008 16:48:26 +0200

sön 2008-04-06 klockan 08:33 -0600 skrev Alex Rousskov:

> Why do we only clone replies and not requests? Can a request have a
> large header? Do we already deal with that without cloning?

Requests is already referenced and cloned if needed only, and has been
since many years back.

For requests we have

1. parse
2. fixup
3. forward logics
4. optional clone and rework if using a parent
6. serialization into a text blob

For replies we have (ignoring ICAP)

1. Parse, and also store the received text blob
2. Fixup
3. lots of logics to determine if the response should be cached etc
4. parse the received text blob again
5. fixup to remove hop-by-hop, add our headers etc.
6. serialization into a text blob

Even on cache hits it's still this convoluted in Squid-3..

1. Swap in the object header
2. Parse the TLV + HTTP header
3. Feed the text blob (HTTP header + initial data) to client_side_reply
4. Parse the HTTP header text blob again as in 4 above..
...

This patch replaces 4 with a clone of the already received HTTP header.

Regards
Henrik
Received on Sun Apr 06 2008 - 08:49:51 MDT

This archive was generated by hypermail 2.2.0 : Wed Apr 30 2008 - 12:00:07 MDT