How to make the SOLR System Auto commit

Source: Internet
Author: User
Tags solr
In many cases, we do not want to trigger the corresponding XML of commit to SOLR on our own, which brings a lot of inconvenience, with the configuration file, SOLR can automatically perform commit indexing under specified conditions. In addition, it allows the front-end retrieval instance to retrieve the latest data without human intervention.

The method is simple: Find the solrconfig. xml file

Find the following line and add the following configuration

View plaincopy to clipboardprint?
  1. <Updatehandler class = "SOLR. directupdatehandler2">
  2. <Autocommit>
  3. <Maxdoss> 10000 </maxdocs>
  4. <Maxtime> 300000 </maxtime>
  5. </Autocommit>

Note:

  • Maxdocs: when the number of memory indexes reaches the specified value, dump the memory index to the hard disk and notify the searcher class to load the new index.
  • Maxtime: The index data in the commit memory is automatically generated every specified time period, and the searcher class is notified to load new indexes.
  • The above two methods are subject to the first fulfillment of the conditions.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.