DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=31240>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=31240 Memory leak when sorting ------- Additional Comments From [EMAIL PROTECTED] 2004-09-29 11:41 ------- Comparator cache entries couldn't ever go away because IndexReader objects used as weak referenced keys were strong-references by the very same WeakHashMap$Entry object. This was because IndexReader was referenced from an instance variable of the Comparator objects - an implicit one because final IndexReader reader argument of comparator* method is used inside Comparator object initialization. Moving initialization of the fieldOrder/index variables outside object initialization eliminates the implicit reader field, thus allowing IndexReader object's to be GCd correctly. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]