Conversation
fulltext was stored=false, so Solr's atomic update reconstruction (which rebuilds a document from its stored/docValues fields) silently dropped it on any partial update to an IndexedFile document - e.g. AIP move (FILE_ANCESTORS) or permission propagation. Marking it stored lets Solr preserve it correctly. Fixes #3733
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
FileCollection'sfulltextfield wasstored=false. Solr's atomic/partial update ({"set": ...}) reconstructs the whole document from its stored/docValues fields before re-submitting it, so any field that's neither stored nor docValues is silently dropped in that reconstruction -fulltextwas being wiped on any partial update to anIndexedFiledocument (e.g. AIP move, which patchesFILE_ANCESTORS, or AIP permission propagation), taking thefulltext→searchcopyField's terms down with it, so basic/default search on the file was affected too, not just explicitfulltext:queries..setStored(false)so the field usesField's documented implicit default (stored=true), letting Solr correctly preserve it across partial updates. Also makesfulltext's raw value retrievable viafl=, which previously silently returned nothing for this field.Fixes #3733
Test plan
filecollection reportsstored=trueforfulltext, and thatfl=fulltextreturns real content after indexing a file with known textfulltext:<term>and default/basic search both still match a file after triggering a partial update on it (e.g. moving its parent AIP)Note for anyone applying this against an already-bootstrapped Solr collection:
SolrBootstrapUtils.bootstrapCollectiononly logs a warning for an existing field whose attributes no longer match - it never issues areplace-field- so this won't retroactively apply to a live collection without either a schemareplace-fieldcall or a from-scratch re-bootstrap, followed by a full File reindex to repopulatefulltextfor already-indexed documents.