Thanks very much TX! Regarding "But the updates don't actually occur during the call", could you elaborate on this a bit more? So when would the actual update occur, by which I mean persisting to disk? Is there a cache of a number of docValues updates before committing to disk? If so, when happens if a crash occurs before those updates are committed?
Many thanks, Joe On Tue, Jul 4, 2017 at 10:53 PM, Trejkaz <trej...@trypticon.org> wrote: > On Tue, 4 Jul 2017 at 22:39, Joe Ye <yuanzhou...@gmail.com> wrote: > > > Hi, > > > > I'm using Lucene core 6.6. > > > > I noticed an issue that DocValue update methods > > (indexWriter.updateNumericDocValue > > & indexWriter.updateBinaryDocValue) don't appear to throw exception or > > return any error code if the document doesn't exist. Is this > intentional? I > > don't want to check the existence of the document before each docValue > > update. > > > Given that they take Term or Query, that's what one would intuitively > expect from such an API (it will match 0..n docs.) > > But the updates don't actually occur during the call, so there is no way > for it to know how many updates will happen in advance anyway. (Otherwise > it would be nice to know the number of docs it updated, like in JDBC.) > > TX >