You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Yonik Seeley (JIRA)" <ji...@apache.org> on 2015/12/15 18:36:46 UTC

[jira] [Updated] (SOLR-8372) Canceled recovery can lead to data loss

     [ https://issues.apache.org/jira/browse/SOLR-8372?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Yonik Seeley updated SOLR-8372:
-------------------------------
    Attachment: SOLR-8372.patch

Here's a patch that allows bufferUpdates() to be called more than once, and removes the call to dropBufferedUpdates() from RecoveryStrategy.

Previously, if bufferUpdates() was called in a state!=ACTIVE, we simply returned w/o changing the state.  This is now logged at least.

This has an additional side effect of having buffered versions in our log that were never applied to the index.  This seems OK though... better not to lose updates in general.

> Canceled recovery can lead to data loss
> ---------------------------------------
>
>                 Key: SOLR-8372
>                 URL: https://issues.apache.org/jira/browse/SOLR-8372
>             Project: Solr
>          Issue Type: Bug
>            Reporter: Yonik Seeley
>         Attachments: SOLR-8372.patch
>
>
> A recovery via index replication tells the update log to start buffering updates.  If that recovery is canceled for whatever reason by the replica, the RecoveryStrategy calls ulog.dropBufferedUpdates() which stops buffering and places the UpdateLog back in active mode.  If updates come from the leader after this point (and before ReplicationStrategy retries recovery), the update will be processed as normal and added to the transaction log. If the server is bounced, those last updates to the transaction log look normal (no FLAG_GAP) and can be used to determine who is more up to date. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org