You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucenenet.apache.org by "George Aroush (JIRA)" <ji...@apache.org> on 2007/01/03 04:04:27 UTC
[jira] Assigned: (LUCENENET-29) some bug in .net 1.*
[ https://issues.apache.org/jira/browse/LUCENENET-29?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
George Aroush reassigned LUCENENET-29:
--------------------------------------
Assignee: George Aroush
> some bug in .net 1.*
> --------------------
>
> Key: LUCENENET-29
> URL: https://issues.apache.org/jira/browse/LUCENENET-29
> Project: Lucene.Net
> Issue Type: Bug
> Environment: windows 2003
> Reporter: udanax
> Assigned To: George Aroush
> Priority: Critical
> Attachments: fixed_files.zip
>
>
> some bug in .net 1.*
> if use sort() then we meet memory leak error.
> must be readerCache.Clear(); in Store() method.
> open Search\FieldSortedHitQueue.cs
> and add method.
> internal static void Close(IndexReader reader)
> {
> lock (Comparators.SyncRoot)
> {
> System.Collections.Hashtable readerCache = (System.Collections.Hashtable) Comparators[reader];
> if (readerCache != null)
> {
> readerCache.Clear();
> }
> Comparators.Remove(reader);
> }
> }
> and... FieldCacheImpl.cs add method,too
> public virtual void Close(IndexReader reader)
> {
> lock (this)
> {
> System.Collections.Hashtable readerCache = (System.Collections.Hashtable) cache[reader];
> if (readerCache != null)
> {
> readerCache.Clear();
> readerCache = null;
> }
> cache.Remove(reader);
> }
> }
> and then, edit Close() method of IndexSearcher class
> public override void Close()
> {
> FieldSortedHitQueue.Close(reader);
> Lucene.Net.Search.FieldCache_Fields.DEFAULT.Close(reader);
> if (closeReader)
> reader.Close();
> }
> And there is an omission in the article that I made.
> Additionaly the FieldCacheImpl Class was inherited an 'FieldCache interface (FirldCache.cs)'
> and you should define its 'close() method' as a 'void Close (IndexReader reader);'
> i wanna become lucene.net committer.
> how can i do?
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: https://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira