mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-03 18:47:53 +00:00
Bug 1810205 - Eat notfound io errors in kvstore r=jstutte,janerik
Differential Revision: https://phabricator.services.mozilla.com/D166816
This commit is contained in:
parent
1e9c502e31
commit
7668096e51
@ -278,7 +278,15 @@ impl Task for PutTask {
|
||||
Err(err) => return Err(KeyValueError::StoreError(err)),
|
||||
}
|
||||
|
||||
writer.commit()?;
|
||||
// Ignore errors caused by simultaneous access.
|
||||
// We intend to investigate/revert this in bug 1810212.
|
||||
match writer.commit() {
|
||||
Err(StoreError::IoError(e)) if e.kind() == std::io::ErrorKind::NotFound => {
|
||||
// Explicitly ignore errors from simultaneous access.
|
||||
}
|
||||
Err(e) => return Err(From::from(e)),
|
||||
_ => (),
|
||||
};
|
||||
break;
|
||||
}
|
||||
|
||||
@ -383,7 +391,15 @@ impl Task for WriteManyTask {
|
||||
}
|
||||
}
|
||||
|
||||
writer.commit()?;
|
||||
// Ignore errors caused by simultaneous access.
|
||||
// We intend to investigate/revert this in bug 1810212.
|
||||
match writer.commit() {
|
||||
Err(StoreError::IoError(e)) if e.kind() == std::io::ErrorKind::NotFound => {
|
||||
// Explicitly ignore errors from simultaneous access.
|
||||
}
|
||||
Err(e) => return Err(From::from(e)),
|
||||
_ => (),
|
||||
};
|
||||
break; // 'outer: loop
|
||||
}
|
||||
|
||||
@ -543,7 +559,15 @@ impl Task for DeleteTask {
|
||||
Err(err) => return Err(KeyValueError::StoreError(err)),
|
||||
};
|
||||
|
||||
writer.commit()?;
|
||||
// Ignore errors caused by simultaneous access.
|
||||
// We intend to investigate/revert this in bug 1810212.
|
||||
match writer.commit() {
|
||||
Err(StoreError::IoError(e)) if e.kind() == std::io::ErrorKind::NotFound => {
|
||||
// Explicitly ignore errors from simultaneous access.
|
||||
}
|
||||
Err(e) => return Err(From::from(e)),
|
||||
_ => (),
|
||||
};
|
||||
|
||||
Ok(())
|
||||
}()));
|
||||
@ -582,7 +606,15 @@ impl Task for ClearTask {
|
||||
let env = self.rkv.read()?;
|
||||
let mut writer = env.write()?;
|
||||
self.store.clear(&mut writer)?;
|
||||
writer.commit()?;
|
||||
// Ignore errors caused by simultaneous access.
|
||||
// We intend to investigate/revert this in bug 1810212.
|
||||
match writer.commit() {
|
||||
Err(StoreError::IoError(e)) if e.kind() == std::io::ErrorKind::NotFound => {
|
||||
// Explicitly ignore errors from simultaneous access.
|
||||
}
|
||||
Err(e) => return Err(From::from(e)),
|
||||
_ => (),
|
||||
};
|
||||
|
||||
Ok(())
|
||||
}()));
|
||||
|
Loading…
Reference in New Issue
Block a user