: are added. Since documents may be re-indexed or new documents added at any : time, trying to synchronize populating these values with content indexing is : not an option. We also want to avoid forcing all the indexers to change how : they index. We are using Solr 3.6. : : What we would like is to have Solr keep any field values if they are not : specified in a document to add, if that document was already existing in the : index. Since these other indexing programs do not touch these fields at : all, we'd like to keep (copy over) the stored values for these unspecified : fields when a document with the same key is indexed. : : E.g., say a document has "popularity", "body", and "title" field and someone : issues a delete command to solr to delete the document then adds a document : with the same id but only "body" and "title" we want to have the previous : "popularity" value copied over.
if a client deletes the doc then that's it -- game over, the doc is gone. Other then that, what you are generally describing (letting clients "add" field values to existing documents) is possible with the "Atomic Updates" feature... https://wiki.apache.org/solr/Atomic_Updates ...if you really can't modify the indexing apps to explicitly send their updates structured as atomic updates, you could concievably write an UpdateProcessor that converts any simple document add into an atomic update (by replacing the values of all the fields in the input odc with the ("set" => value) mapping. : then adding those values to the input document. Since deleting does not : actual change the indexing until a commit is made it should be possible to : get the old values, right? you really, really, REALLY, don't want to try counting on the idea that you can recover a deleted doc up until a commit happens, because i really doubt you could get it to work the way you are thinking. if you must o down this road, you'd be better of having your UpdateProcessor convert any "delete" into an atomic update that sets a "doc_is_deleted" field which you filter out of all queries, so thta you cna be confident the doc will always be available if you need it later to add ore field values to. -Hoss