Re: IndexWriter concurrent flushing

2019-02-17 Thread Michael McCandless
+1 to make it simple to let multiple threads help with commit/refresh operations. IW.yield is a simple way to achieve it, matching (roughly) how IW's commit/refresh work today, hijacking incoming indexing threads to gain concurrency. I think this would be a small change? Adding an ExecutorServic

IndexWriter concurrent flushing

2019-02-15 Thread Michael Sokolov
I noticed that commit() was taking an inordinately long time. It turned out IndexWriter was flushing using only a single thread because it relies on its caller to supply it with threads (via updateDocument, deleteDocument, etc), which it then "hijacks" to do flushing. If (as we do) a caller indexes