mirror of
https://github.com/honeymoose/OpenSearch.git
synced 2025-02-09 06:25:07 +00:00
Handle IOException while checking translog corruption
We can hit an IOException while reading a translog header after corrupting it. Relates #58866
This commit is contained in:
parent
b769e9143d
commit
65645217bc
@ -246,7 +246,7 @@ public class TestTranslog {
|
||||
try {
|
||||
final int version = TranslogHeader.readHeaderVersion(corruptedFile, channel, in);
|
||||
return version == TranslogHeader.VERSION_CHECKPOINTS;
|
||||
} catch (IllegalStateException | TranslogCorruptedException e) {
|
||||
} catch (IllegalStateException | TranslogCorruptedException | IOException e) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user