Skip to content

Commit

Permalink
nexus: fix log location
Browse files Browse the repository at this point in the history
  • Loading branch information
gila committed Aug 11, 2020
1 parent 0470c5f commit 8470ac0
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
1 change: 0 additions & 1 deletion mayastor/src/bdev/nexus/nexus_bdev.rs
Original file line number Diff line number Diff line change
Expand Up @@ -556,7 +556,6 @@ impl Nexus {
}

if r.await.unwrap() {
info!("Nexus {} destroyed", self.name);
Ok(())
} else {
Err(Error::NexusDestroy {
Expand Down
7 changes: 6 additions & 1 deletion mayastor/src/grpc/nexus_grpc.rs
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,12 @@ pub async fn nexus_add_child(
/// Idempotent destruction of the nexus.
pub async fn nexus_destroy(uuid: &str) -> Result<(), Error> {
if let Ok(n) = nexus_lookup(uuid) {
n.destroy().await?;
let result = n.destroy().await;
if result.is_ok() {
info!("Nexus {} destroyed", uuid)
} else {
return result;
}
};
Ok(())
}

0 comments on commit 8470ac0

Please sign in to comment.