lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Cao Manh Dat (JIRA)" <>
Subject [jira] [Commented] (SOLR-8120) Validate index files on replica before old index is deleted
Date Mon, 14 Dec 2015 07:01:46 GMT


Cao Manh Dat commented on SOLR-8120:

Hi Varun, I dont think try-witch-resource is a good idea because we will have empty try block
try (IndexReader reader = solrCore.getIndexReaderFactory().newReader(tmpIndexDir, solrCore))
  //empty catch
} catch (IOException e){
  //do stuff here
I also prefer an IOException (it tell specific what problem IndexFetcher encountered and handled
perfectly by ReplicationHandler) to be thrown more than return false (which mean slave is
already in sync).

> Validate index files on replica before old index is deleted
> -----------------------------------------------------------
>                 Key: SOLR-8120
>                 URL:
>             Project: Solr
>          Issue Type: Improvement
>          Components: replication (java)
>            Reporter: Shalin Shekhar Mangar
>              Labels: difficulty-easy, impact-high
>             Fix For: 5.4, Trunk
>         Attachments: SOLR-8120.patch
> During replication, if a full sync is necessary then the detection of corruption will
happen after the index has been cleaned up (refer to solrCore.getDirectoryFactory().remove(indexDir);
before calling openNewSearcherAndUpdateCommitPoint()) in IndexFetcher.
> SOLR-8119 will make this issue obsolete but until then we should perform trivial verification
(maybe just open a reader and close?) before the replica blows away its old index?

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message