fix: bug crash when disk drop

This commit is contained in:
weisd
2024-12-12 09:54:06 +08:00
parent f6e3575a50
commit da4daee645
6 changed files with 31 additions and 6 deletions
+6 -2
View File
@@ -209,10 +209,14 @@ async fn run(opt: config::Opt) -> Result<()> {
// init store
let store = ECStore::new(server_address.clone(), endpoint_pools.clone())
.await
.map_err(|err| Error::from_string(err.to_string()))?;
.map_err(|err| {
error!("ECStore::new {:?}", &err);
panic!("{}", err);
Error::from_string(err.to_string())
})?;
ECStore::init(store.clone()).await.map_err(|err| {
error!("init faild {:?}", &err);
error!("ECStore init faild {:?}", &err);
Error::from_string(err.to_string())
})?;
warn!(" init store success!");