Add updateDocuments API which accept a query#12341
Conversation
|
To me this looks fine, although I wonder why we needed a new |
This reverts commit 52ab167.
|
Sorry I pressed merge on wrong PR, so I reverted this. Can you reopen this? |
|
Of course you can also revert the revert, if that's applicable. The change looks fine to me. |
mikemccand
left a comment
There was a problem hiding this comment.
Looks great! I left a couple minor comments. Thanks @zhaih.
| if (random().nextBoolean()) { | ||
| writer.updateDocuments(new Term("id", id), Arrays.asList(doc, doc)); | ||
| } else { | ||
| writer.updateDocuments( |
There was a problem hiding this comment.
Maybe also do this randomness in RandomIndexWriter?
There was a problem hiding this comment.
I added to it, not sure whether that's the place in your mind?
@uschindler We previously have a |
|
For some reason I cannot reopen this one, so I opened a new one #12346 |
Description
Essentially just wire up
updateDocuments(Query, Iterable<Document>)API, we could probably also addupdateDocumentfor single document update, but I don't see a good reason to add that (except for completion) yet.