Keep Solr slaves in sync

与世无争的帅哥 提交于 2019-12-06 09:32:12

The problem here is following, during your poll interval, potentially, your slaves could be out-of-sync. In your case you have 1 hour interval.

The thing which could be done with minimal effort is following, you could force replication on slaves at the same time by calling the command:

http://slave_host:port/solr/core_name/replication?command=fetchindex

However, I'm not sure how often you could call this command, since most likely you couldn't do it every minute or so.

Another possibility is to trigger replication whenever a commit is performed on the master index. You could do this by adding configuration:

<str name="replicateAfter">commit</str>

For more information about it take a look here

The traditional master-slave is basically doing rsync over http. So, maybe you can rsync between slaves (and reload cores after rsync).

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!