I'm planning to use SOLR for full-text search. Question: when I update my MySQL-database, is there any way to trigger a SOLR-update after I updated my database, so the data will be exactly the same in both MySQL and SOLR? DataImportHandler? Or UpdateHandler? I'm using PHP, and sometimes about 100 insert/update/delete-queries/minute (not always).
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
Either you call Solr to update data from PHP when you are updating DB or you can set up the cron job do do so.
They are planning to add scheduler do Solr: http://wiki.apache.org/solr/DataImportHandler#Scheduling
回答2:
Run a cron job in the background to perform a delta index of the database.