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 Vincenzo D'Amore <v....@gmail.com> on 2017/07/12 15:57:21 UTC
Solr Cloud 6.x - rollback best practice
Hi,
I'm moving to Solr Cloud 6.x and I see rollback cannot be supported when is
in Cloud mode.
In my scenario, there are basically two tasks (full indexing, partial
indexing).
Full indexing
=========
This is the most important case, where I really need the possibility to
rollback.
The full reindex is basically done in 3 steps:
1. delete *:* all collection's documents
2. add all existing documents
3. commit
If during the step 2 something go wrong (usually some problem with the
source of data) I had to rollback.
Partial reindexing
=============
Unlike the the former, this case is executed in only 2 steps (no delete)
and the number of documents indexed usually is small (or very small).
Even in this case if the step 2 go wrong I had to rollback.
Do you know if there is a common pattern, a best practice, something of
useful to handle a rollback if something go wrong in these cases?
My simplistic idea is to have two collections (active/passive), and switch
from one to another only when all the steps are completed successfully.
But, as you can understand, having two collections works well with full
indexing, but how do I handle a partial reindexing if something goes wrong?
So, I'll be grateful to whom would spend his/her time to give me a
suggestion.
Thanks in advance and best regards,
Vincenzo
--
Vincenzo D'Amore
email: v.damore@gmail.com
skype: free.dev
mobile: +39 349 8513251
Re: Solr Cloud 6.x - rollback best practice
Posted by Mike Drob <md...@apache.org>.
The two collection approach with aliasing is a good approach.
You can also use the backup and restore APIs -
https://lucene.apache.org/solr/guide/6_6/making-and-restoring-backups.html
Mike
On Wed, Jul 12, 2017 at 10:57 AM, Vincenzo D'Amore <v....@gmail.com>
wrote:
> Hi,
>
> I'm moving to Solr Cloud 6.x and I see rollback cannot be supported when is
> in Cloud mode.
>
> In my scenario, there are basically two tasks (full indexing, partial
> indexing).
>
> Full indexing
> =========
>
> This is the most important case, where I really need the possibility to
> rollback.
>
> The full reindex is basically done in 3 steps:
>
> 1. delete *:* all collection's documents
> 2. add all existing documents
> 3. commit
>
> If during the step 2 something go wrong (usually some problem with the
> source of data) I had to rollback.
>
> Partial reindexing
> =============
>
> Unlike the the former, this case is executed in only 2 steps (no delete)
> and the number of documents indexed usually is small (or very small).
>
> Even in this case if the step 2 go wrong I had to rollback.
>
> Do you know if there is a common pattern, a best practice, something of
> useful to handle a rollback if something go wrong in these cases?
>
> My simplistic idea is to have two collections (active/passive), and switch
> from one to another only when all the steps are completed successfully.
>
> But, as you can understand, having two collections works well with full
> indexing, but how do I handle a partial reindexing if something goes wrong?
>
> So, I'll be grateful to whom would spend his/her time to give me a
> suggestion.
>
> Thanks in advance and best regards,
> Vincenzo
>
>
>
> --
> Vincenzo D'Amore
> email: v.damore@gmail.com
> skype: free.dev
> mobile: +39 349 8513251
>