[prev in list] [next in list] [prev in thread] [next in thread] 

List:       log4j-user
Subject:    LRU-Indentity-HashMap
From:       Ceki =?iso-8859-1?Q?G=FClc=FC?= <ceki () qos ! ch>
Date:       2004-10-27 15:46:35
Message-ID: 6.0.3.0.0.20041027172657.0380cc70 () mail ! qos ! ch
[Download RAW message or body]


Hello all,


In addressing bug #6229 [1], it transpired that we needed a bounded
hash map using LRU heuristics and identity to compute hashmap and
object references for equality. Basically, it would be a HashMap
merging the qualities of a LRUMap [2] and those of IdentityHashMap [3,
4, 5].

This HashMap will serve as a cache of previously parsed logging
messages of type java.lang.String. String has rather slow equals and
hash methods, hence the need for an IdentityMap. We need to keep the
memory footprint of the cache limited, hence the requirement for the
LRU heuristics.

It's a little 2 or 3 day project. If you are interested, please let me
know.

[1] http://nagoya.apache.org/bugzilla/show_bug.cgi?id=16229
[2] 
http://jakarta.apache.org/commons/collections/apidocs-COLLECTIONS_3_1/org/apache/commons/collections/map/LRUMap.html
 [3] http://java.sun.com/j2se/1.4.2/docs/api/java/util/IdentityHashMap.html
[4] 
http://ws.apache.org/axis/java/apiDocs/org/apache/axis/utils/IdentityHashMap.html
[5] 
http://jakarta.apache.org/commons/collections/apidocs-COLLECTIONS_3_1/org/apache/commons/collections/map/IdentityMap.html



ps: Please reply to log4j-dev@logging.apache.org.

-- 
Ceki Gülcü

      For log4j documentation consider "The complete log4j manual"
      http://www.qos.ch/shop/products/eclm/  



---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic