lucene-solr-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Solr Wiki] Update of "UpdateXmlMessages" by YonikSeeley
Date Sun, 06 Nov 2011 23:04:49 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Solr Wiki" for change notification.

The "UpdateXmlMessages" page has been changed by YonikSeeley:
http://wiki.apache.org/solr/UpdateXmlMessages?action=diff&rev1=34&rev2=35

Comment:
more commit/optimize explanation

  
  === "commit" and "optimize" ===
  
+ A commit operation makes index changes visible to new search requests.
+ A '''hard commit''' also calls fsync on the index files to ensure they have been flushed
to stable storage and no data loss will result from a power failure.
+ 
+ A '''soft commit''' is much faster since it only makes index changes visible and does not
fsync index files or write a new index descriptor.  If the JVM crashes or there is a loss
of power, only changes that occurred before the last '''hard commit''' will be visible.  Search
collections that have near-real-time requirements (that want index changes to be quickly visible
to searches) will want to soft commit often but hard commit less frequently.
+ 
+ An '''optimize''' is like a '''hard commit''' except that it forces all of the index segments
to be merged into a single segment first.  Depending on the use cases, this operation should
be performed infrequently, if at all, since it involves reading and re-writing the entire
index.  Segments are normally merged over time anyway (as determined by the merge policy),
and optimize just forces these merges to occur immediately.
+ 
  Example:
     {{{
  <commit/>
@@ -69, +76 @@

  
     * `waitFlush = "true" | "false"`  &#8212; default is true   &#8212;  block until
index changes are flushed to disk <!> [[Solr1.4]] At least in Solr 1.4 and later (perhaps
earlier as well), this command has no affect. In <!> [[Solr4.0]] it will be removed.
     * `waitSearcher = "true" | "false"`   &#8212;  default is true  &#8212;  block
until a new searcher is opened and registered as the main query searcher, making the changes
visible.
-    * `softCommit = "true" | "false"`  &#8212; default is false   &#8212;  perform
a soft commit - this will refresh the 'view' of the index in a more performant manner, but
without "on-disk" guarantees. Generally you want to softCommit often and hard commit (softCommit=false)
less often.  <!> [[Solr4.0]]
+    * `softCommit = "true" | "false"`  &#8212; default is false   &#8212;  perform
a soft commit - this will refresh the 'view' of the index in a more performant manner, but
without "on-disk" guarantees. <!> [[Solr4.0]]
  ==== Optional attributes for "commit" ====
  
     * `expungeDeletes = "true" | "false"`   &#8212;  default is false  &#8212;  merge
segments with deletes away. <!> [[Solr1.4]]

Mime
View raw message