Re: thoughts on memory usage...

From: Duane Wessels <wessels@dont-contact.us>
Date: Tue, 19 Aug 97 23:00:10 -0700

luyer@ucs.uwa.edu.au writes:

>We still haven't seen a response from Duane on what effects he thinks URL
>compression would have (and if the URL and key differ, should the key be
>compressed, and so on). Since he knows the internals of squid best I was

I've been lurking. I'm trying to catch up on email after spending
a week writing some papers.

Its probably not necessary to compress StoreEntry->key. That should
only be different from StoreEntry->url while a request is in progress.

Initially I was going to suggest that we always leave StoreEntry->url
compressed and change every reference of entry->url with
DECODE(entry->url). But then things become complicated if you ever
need to do:

    foo(.., DECODE(e1->url), DECODE(e2->url), ...)

because you can't just decode into a static array (i.e. like
inet_ntoa() does).

Another idea would be to uncompress entry->url when a StoreEntry
becomes locked, and compress it when the lock count reaches zero.
That might be safer.

Also it would probably be smart to prepend some identifying character
to the start of a compressed URL to catch bugs.

Finally, I would like to have this work done on squid-1.2, not 1.1.

Duane W.
Received on Tue Jul 29 2003 - 13:15:42 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:11:23 MST