Return-Path: Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 10316 invoked by uid 500); 10 Jul 2001 05:19:28 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 10276 invoked from network); 10 Jul 2001 05:19:25 -0000 Date: Mon, 9 Jul 2001 22:19:07 -0700 From: Justin Erenkrantz To: Jon Travis Cc: apr-dev@apache.org Subject: Re: Observations on fragmentation in SMS pools Message-ID: <20010709221907.E2369@ebuilt.com> References: <20010710012924.O18140@angua.rince.de> <20010709201426.B1138@covalent.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010709201426.B1138@covalent.net>; from jtravis@covalent.net on Mon, Jul 09, 2001 at 08:14:26PM -0700 X-AntiVirus: scanned for viruses by AMaViS 0.2.1-pre3 (http://amavis.org/) X-Spam-Rating: h31.sny.collab.net 1.6.2 0/1000/N On Mon, Jul 09, 2001 at 08:14:26PM -0700, Jon Travis wrote: > Tables should definitely be moved to APR-util if they are to remain. As > for Apache, there are better structures that dictate general order than > the table. IMNSHO, the only reason tables are still in Apache is inertia. > Nobody wants to go through and change everything to a more sane data > structure. Case insensitive searches -- linear search time over the > table ... ugh. One problem with hash tables is that if you want to retrieve a HTTP header, you now need to have it be the same case as it came in (unless you are normalizing every call). RFC 2616 states that (Section 4.2): "Field names are case-insensitive." Therefore, if the client sends: CoNnEcTiOn: Keep-Alive it should respect that. And, this data structure is primarily used for storing HTTP header info (I'm not sure about mod_mime). I'm not aware of any browsers that do this, but I'd bet someone will because the RFC says you can. (It's possible I'm misinterpreting the RFC, wouldn't be the first time...) AFAICT, this doesn't call for a true hash table or a true array. It's something slightly different. Any data structure which replaces tables needs to be able to handle the case-insensitivity gracefully. Just want to make sure that any solution keeps us correct to the RFC. -- justin