Hi, currently I'm reading the way Lucene index document and I found this
code and wondering that is it a bug?
DocumentsWriterPerThread.finishDocument(Term delTerm) {
deleteQueue.add(delTerm, deleteSlice);
// A point
deleteSlice.apply(pendingUpdates, numDocsInRAM);
}
In the scenario when DWPT1 finish they deleteQueue.add() but not reach the
apply(). DWPT2 finish they deleteQueue.add() but not reach the apply() too.
So the deleteQueue will be in this form
<DWPT1 delTerm node> -> <DWPT2 delTerm node>
So when DWPT1 and DWPT2 apply the deleteSlice they will both insert <DWPT1
delTerm node>, <DWPT2 delTerm node> to their pendingUpdates.
--
*Best regards,*
*Cao Mạnh Đạt*
*D.O.B : 31-07-1991Cell: (+84) 946.328.329E-mail: [email protected]
<[email protected]>Hanoi University of Science and TechnologySchool
of information & communication technologyClass : Computer Science K54*