lucenenet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "ali koyuncu (JIRA)" <>
Subject [jira] [Commented] (LUCENENET-534) IndexWriter deletes all files in my global index folder
Date Mon, 20 Jan 2014 16:14:19 GMT


ali koyuncu commented on LUCENENET-534:

public IndexWriter iw_global { get; set; }
	#region Open IndexWriter
	this.iw_global = new IndexWriter(lcneFolder, new StandardAnalyzer(Lucene.Net.Util.Version.LUCENE_30),
!fiAktifYes.Exists, IndexWriter.MaxFieldLength.UNLIMITED);
    this.iw_global.UseCompoundFile = true;
	RAMDirectory idx = new RAMDirectory();
	IndexWriter iw = new IndexWriter(idx, new StandardAnalyzer(Lucene.Net.Util.Version.LUCENE_30),
true, IndexWriter.MaxFieldLength.UNLIMITED);
	iw.UseCompoundFile = true;
	foreach (var link in linkList)
	#region unnecessary code to understand bug

> IndexWriter deletes all files in my global index folder
> -------------------------------------------------------
>                 Key: LUCENENET-534
>                 URL:
>             Project: Lucene.Net
>          Issue Type: Bug
>          Components: .NET API
>            Reporter: ali koyuncu
>            Priority: Critical
> I process new data list in memory-directory. After that I commit memory-directory to
disk directrory.  After I commit global index writer,I see the files isn't combined.So when
I reopen the service,indexwriter deletes all files in global index folder. I traced codes
> "deleter = new IndexFileDeleter(directory, deletionPolicy == null?new KeepOnlyLastCommitDeletionPolicy():deletionPolicy,
segmentInfos, infoStream, docWriter, synced);" in IndexWriter Init method,it deletes all file
> I asked it on stackoverlow.

This message was sent by Atlassian JIRA

View raw message