You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Shalin Shekhar Mangar <sh...@gmail.com> on 2010/11/11 04:07:52 UTC

Re: Replication with slaves and load balancing questions

On Wed, Nov 10, 2010 at 8:29 PM, Chris Hostetter
<ho...@fucit.org> wrote:
>
> (forwarded on behalf of robo ... trying to figured out odd spam blocking issue he's having)
>
> ---------- Forwarded message ----------
>
> Good day,
>
> We are new to Solr and trying to setup a HA configuration in the
> cloud.  We have setup a Solr Master server which does all the
> indexing.  We have 2 Solr Slaves that use the built-in Replication
> Handler (not the scripts).  We are thinking of load balancing the 2
> Solr Slaves but have a question about writes to the slaves.  I believe
> the only operation that might try to write to the indexes are the
> deletes from the web servers.
>
> Will the Slaves pass the delete query onto the Master to handle or
> will it try to do the delete on the Slave?

No, those deletes will only be done on the slave on which the delete
request is made but it gets worse.

>
> If the delete is done on the Slave will the master and other Slave get
> updated through the replication?
>

No. In fact, if the slave's index is changed, it will be deemed as
out-of-sync from the master and full index replication from the master
will happen. The best way is to delete from master and commit if you
deletes are very infrequent. If deletes are very frequent then you
must batch them before committing. If you cannot show the deleted data
to the user for subsequent searches, you can try to use filter queries
to filter out such documents from searches made by the user who
deleted the document.

--
Regards,
Shalin Shekhar Mangar.