mirror of https://github.com/apache/cassandra
Do not delete corrupt sstables on startup; skip it and let an operator intervene instead. Patch by Chris Goffinet; reviewed by jbellis for CASSANDRA-343
git-svn-id: https://svn.apache.org/repos/asf/incubator/cassandra/branches/cassandra-0.4@810311 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
0da45132f2
commit
4ae05b1036
|
|
@ -175,16 +175,17 @@ public final class ColumnFamilyStore implements ColumnFamilyStoreMBean
|
|||
for (File file : sstableFiles)
|
||||
{
|
||||
String filename = file.getAbsolutePath();
|
||||
SSTableReader sstable;
|
||||
try
|
||||
{
|
||||
SSTableReader sstable = SSTableReader.open(filename);
|
||||
ssTables_.put(filename, sstable);
|
||||
sstable = SSTableReader.open(filename);
|
||||
}
|
||||
catch (IOException ex)
|
||||
{
|
||||
logger_.error("Corrupt file " + filename, ex);
|
||||
FileUtils.delete(filename);
|
||||
logger_.error("Corrupt file " + filename + "; skipped", ex);
|
||||
continue;
|
||||
}
|
||||
ssTables_.put(filename, sstable);
|
||||
}
|
||||
|
||||
// submit initial check-for-compaction request
|
||||
|
|
|
|||
Loading…
Reference in New Issue