Atomic updates (Intermediate)

Solr did not used to be at all like a database. It was designed to excel at searching, leaving data storage and rapid in-place updates to regular databases. However, with new features in Version 4, such as soft commits and other Near Real Time optimizations, Solr can substitute a database in previously impossible scenarios. Partial record (Atomic) update is also one of these features. It allows sending only changed document fields to Solr as part of the add/update command and having them merged with already known values for other fields of the same document.

How to do it...

  1. Copy and rename the commit directory to the update directory, delete the data directory, and add the core reference to update in solr.xml.
  2. In schema.xml ...

Get Instant Apache Solr for Indexing Data How-to now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.