[
https://issues.apache.org/jira/browse/LUCENE-5006?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13684150#comment-13684150
]
Michael McCandless commented on LUCENE-5006:
--------------------------------------------
Thanks Simon.
It looks like most of the changes are 1) the new Events system for DW
to communicate back to IW when something needs to happen (flush,
applyDeletes, etc.) so that DW never needs to call back into a sync'd
IW method, and 2) passing IW as an argument to various methods instead
of holding it as a member in DW? (Well and also adding IW as a member
in DocumentsWriterFlushControl).
Why does applyAllDeletes need a new boolean forced param?
Looks like BytesRefHash has accidental new int[] hashes?
What is flagForcePurge for? Can it somehow be passed as a param to
the ApplyDeletesEvent?
Maybe rename "boolean iwCheck" to "boolean iwHasEvents" in
DW.postUpdate? This returned boolean means new Events were added for
IW to process right?
There are some parts I don't quite understand, e.g. the changing logic
for when initializeThreadState or deactivateThreadState or
applyAllDeletes are invoked...
finishFlush has too much indentation.
> Simplify / understand IndexWriter/DocumentsWriter synchronization
> -----------------------------------------------------------------
>
> Key: LUCENE-5006
> URL: https://issues.apache.org/jira/browse/LUCENE-5006
> Project: Lucene - Core
> Issue Type: Bug
> Reporter: Michael McCandless
> Assignee: Simon Willnauer
> Attachments: LUCENE-5006.patch
>
>
> The concurrency in IW/DW/BD is terrifying: there are many locks involved, not
> just intrinsic locks but IW also has fullFlushLock, commitLock, and there are
> no clear rules about lock order to avoid deadlocks like LUCENE-5002.
> We have to somehow simplify this, and define the allowed concurrent behavior
> eg when an app calls deleteAll while other threads are indexing.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]